# Keg Scale and Digital Tap List project



## megabyte

A few months ago I had 2 great brews on tap. Naturally, one of them blew dry while I was entertaining guests - “Sorry guys, it’s just the porter now”. Straight afterwards what do you know? The porter blew dry as well. This happens to me a lot and it seems like kegs always abide by Murphy's law. Generally I have a ballpark idea about how much is remaining in my kegs, but I hate lifting or shifting them when they get low because it rouses the slurry and my next few beers pour cloudy. Surely there’s a solution for this problem right?

I scoured the internet, credit card in hand and it turns out... there are several options: 
-If the weather’s right you can warm your kegs and watch where the condensation forms, but this is difficult if you can’t reach some of your kegs (think the third keg at the back of a kegerator, or vertical kegs stacked like sardines in a keezer setup). In my experience the condensation takes a long time to form and I find it tedious.
-There’s a cool product called Ball and Keg that uses floating magnets to give an indication, but it’s equally restrained if you don’t have easy visual access to your kegs.
-Then there are these awesome DIY open source projects like KegBerry and Raspberry Pints, but I find them to be overcomplicated with loads of wiring and after you cobble together all the parts, you’re looking at a serious investment in time and money.
(There are many more options out there with similar drawbacks that I’ll omit for brevity)

I totally would have bought into one of the existing solutions but none of them really spoke to me, so for the past few months I’ve been working on yet another keg monitoring system. The idea is that if you take a digital bathroom scale then add bluetooth, you now have the basis for a no-wires keg monitoring system that can talk to almost any modern mobile device.




Some of the open source guys have tried using scales in the past but couldn’t get it to work, hence splicing flow sensors into their beer lines instead. I gave it a go anyway, logged measurements for days and found the results to be very linear in proportion to temperature so it’s actually quite easy to get an accurate measurement.

Here's a pic of how the weight reading varied along with changes in temperature. This was just weighing a keg full of water for a few days.


Using that correlation we can compensate for the temperature to get a much more stable measurement of the keg's weight, however, it may not even be necessary. Here's that same data when you chart it with the zero point included in the plot.


As you can see it's pretty darn flat and that's with temperature variances of about 6 degrees C. If your fridge has temperature swings of 6C it's probably on the frink 

Here's are some pics of one of my first test setup. I used a cheapo bathroom scale and hooked it up to a Spark Core to upload measurements to an online database.




And here’s the super ugly prototype I’ve been working with most recently. I got the glass cut at a local glass shop, but it's pretty dodgy and not very round.



Meanwhile I've been buying and tearing apart all manner of bathroom scales to see how they're built and learn from their designs.




The awesome thing about the bluetooth scale approach is that you don’t have any wires and you don’t have to splice anything into your beer lines. Bluetooth 4.0 (or BLE) uses very little power and it looks like we’ll be able to get a couple of years of operation from a pair of AAA batteries.

I taught myself iOS (swift) and began writing a demo app to interface with my bluetooth sensor and it quickly became evident that adding a fully featured tap list would make a lot of sense. That way you can leave your tablet with your kegerator when you have guests over and it behaves like the chalk board at a tap house - a digital tap list showing what’s on each tap, vital stats and telling a story about each beer, and of course showing how much is remaining. Following are some screenshots of the app as it's was being being developed.
At the moment there are no scales in range so the fill levels aren't being displayed, but you get the gist...


And here's an early version running on my iPhone.



I gave the app a trial run a few weeks ago at my son’s first birthday party and it was surprisingly popular with our family and friends! I got loads of questions about my beers and I noticed a lot of guests were treating it like a wine tasting event since they had the app telling them what’s on each tap and describing the styles and flavours of each of the beers.



Anyhow, we haven’t settled on a name yet, but one of my favourites is Barmaiden - as a nod to the way it keeps inventory of your kegs and also tells your guests about your beers to help them choose between them. Now it’s full steam ahead with the software and I'm also working on the 3D models for the scale part, but I really wanted to post this here on AHB sooner rather than later because I know you guys are going to have loads of awesome advice in these early stages of the design!

Ideas? Suggestions?


----------



## n87

one question....
Do you have calculations of weight based on FG and ABV? as these will change the weight.


One suggestion.
Have the ability for 'guests' to download the app, login to your account (as a guest) so they can read up on what they are drinking, and leave comments, ratings etc without blocking everyone elses access to the beer.


----------



## Grott

I love this type of thought, experimentation. Keep it up, keep us informed. I know AJS2154 will love you endeavour.
Cheers


----------



## wynnum1

Can you put a meter on the taps in bars they have automation to stop free or over size drinks.


----------



## paulyman

SG compares the density of a substance to the density of water, which is close enough to 1000kg/m^3, (1000 at 4C and 998.2 at 20C),so the density of our beer at FG is close enough to 1000FG kg/m^3.

The density is the mass per unit volume of a substance, so the mass of 1 cubic metre of our beer is close to 1000FG kg.

The actual volume of our beer then is its actual mass (remember to subtract off the mass of the empty keg) divided by 1000FG.

It is now easy to continue this process to find the percentage volume left at any given time. 

It's not perfect, but it would be good enough and far better than just "lifting the keg".


----------



## MastersBrewery

Very cool! Will you be releasing for Android later down the track?

Hell Gimme Gimme Gimme!!

Shut up and take my money already!


----------



## paulyman

To be honest though, I think caring about the effects of SG etc is overkill. Given the keg is roughly a cylinder, it is emptying close enough to linearly. So the percentage of the current mass to initial mass should correlate really well with the percentage of beer left.

Be easy enough to fit a linear model to the data you collect if wrong about the above.


----------



## MHB

Interesting idea. just a couple of points that might help
I think you only need to worry about mass.
If all your kegs were the same weight you could build in an automatic offset that takes the mass of the keg away from whatever you load onto the scale then just express fill as a % of original load. or as Kg's effectively L+/- not much
If all your kegs were Corneys it wouldn't be hard to weigh them and then add a bit of weight to bring the lightest up to the weight of the heaviest (stainless screws in the rubber foot comes to mind)
If you could enter data, you could wright the keg mass on each keg - then enterer the mass (or a keg# that the system knows the mass of) when you put the keg on the scales - so it deducts the keg mass from the total... hell you could chip the kegs like you do the cat too many options!

Good luck sounds like a fun project
mark

Oh just a thought, the mass of CO2 you add when force carbing, you will need to be aware of it, say you add 5g/L to 19L = 95g. Is the scale was accurate enough you might be able to build in a conditioning feature (if you work in Volumes 1g/L = 0.506 Volumes) - that feature actually appeals to me more than how full the kegs is, over the years I have trained my right index finger to be a pretty spot on keg scale - just a gentle vertical lift.
M


----------



## ChefKing

Great idea... I love the thought of tech and beer going hand in hand via bluetooth/smartphone tech.

A good idea for me would be a "safe keg" feature...

For example:

I am away from home for the weekend...

I have 3 kegs full in my kegerator that have been carbing and settling for a week and ready for a session when i get back.

My sneaky flatmate/kids/family/neighbours etc; think it would be cool to get stuck in to my brews in my absence!

Thus setting off a real time alarm to my phone noting exactly which keg is being consumed and how much each time is being drawn from it...

prolly would need a whole lotta more tech in it than ur current unit to enable sms msg/email etx...but damn it would have been useful for me a cpl of nights ago on my return to home noticed each and every keg had a 3rd or more drunk out of it...... I was livid to say the least!


----------



## megabyte

Wow so many great ideas. I'll try to address some of them.

Regarding the differences in final gravity mentioned by paylyman, MHB and n87, by my calculation the difference between a 1.006 and a 1.020 f.g beer is about 1.5% by mass. My thoughts were that when you get down to your last pint there's only going to be about 10 grams of error in a worst case scenario which probably wouldn't bother me enough that I would want to enter the f.g. for each beer I keg. Please share your thoughts on this.



n87 said:


> One suggestion.
> Have the ability for 'guests' to download the app, login to your account (as a guest) so they can read up on what they are drinking, and leave comments, ratings etc without blocking everyone elses access to the beer.


I love it! The app will definitely be free and I've been brainstorming an elegant way to make sure your guests can't just log in and change your keg weight, or rename your beers. I think it's nice if your guests can interact using their phones too.



MastersBrewery said:


> Very cool! Will you be releasing for Android later down the track?
> 
> Hell Gimme Gimme Gimme!!
> 
> Shut up and take my money already!


Will we do android? Yes definitely. Android represents about half the mobile market these days so I see it as being essential for this project (no current plans for windows phone though). Most of our costs are going to be for the injection moulding (about $8-16k) and certifications (about another $10k) so writing a second app to reach twice as many brewers will help amortise those costs. As for your closing statement - music to my ears! (I'm a massive Futurama fan)



MHB said:


> If you could enter data, you could wright the keg mass on each keg - then enterer the mass (or a keg# that the system knows the mass of) when you put the keg on the scales - so it deducts the keg mass from the total...


Exactly. I've implemented a zero function (to allow the scale to know what zero is without a keg) and a tare function (to weigh the empty keg and subtract it from all beer calculations) into the iOS app and it stores these against your keg (which you must name or number individually). That way no matter what style your keg is, you should be able to weigh it perfectly using the bluetooth scale. I'd love to simplify it even further and allow you to use a drop-down list to choose your keg (e.g. 19L corny or 9L corny) and it would use a default weight but I think the first method is going to yield better results when you consider that your individual beer and gas lines will add some weight that should be accounted for.

By knowing the weight of the keg, we know exactly how much beer is left, and if we enter the volume of the keg we can also display that as a percentage which may be nice.



MHB said:


> Oh just a thought, the mass of CO2 you add when force carbing, you will need to be aware of it, say you add 5g/L to 19L = 95g.


I hadn't considered CO2 weight, great point! Now that you mention it I think that will be fine too. With about 100 grams of CO2 per batch, that only represents about 0.5% in error, so it may be off by a fraction of a pint for a full keg, but by the time you're down to your last pint the error is only about 3 grams.

Note: In my above points about F.G and CO2 weight, I'm making the assumption that you care more about the accuracy of your measurements as you're drawing towards the end of the keg and it's ok if it's out by a few hundred ml with a full keg. This is one of the benefits of weighing the keg over using flow sensors. Weighing results in proportional errors and it will become more accurate towards the end of the keg, whereas using flow sensors the errors accumulate over the course of emptying the keg so your final readings are the most prone to error.



ChefKing said:


> A good idea for me would be a "safe keg" feature...
> ...
> setting off a real time alarm to my phone noting exactly which keg is being consumed and how much each time is being drawn from it...
> 
> prolly would need a whole lotta more tech in it than ur current unit to enable sms msg/email etx...but damn it would have been useful for me a cpl of nights ago on my return to home noticed each and every keg had a 3rd or more drunk out of it...... I was livid to say the least!


Yeah I love the idea of being "connected" with your beer and brewing no matter where you are. My first prototype and sketch involved WiFi and sending notifications to your phone, but when I did the math it turns out it would be a lot more expensive and getting power to it would add cords or big batteries.
Here was one of my earliest sketches, but it no longer applies:



I have planned an alternative which is to log the beer levels into the memory inside the bluetooth scale at regular intervals, so when you do open the app later and connect, it can download a chart of the usage over time and you can tell at exactly what times the beer was consumed. It's not as good as your suggestion because it's not immediate, but the hardware I'm using can easily handle this, it's just a few weeks more coding on my part.

Thanks for all of the great suggestions so far! There is such a wealth of knowledge here! Also I think Yob mentioned in another thread how dry hopping could be an issue too. I still haven't solved this one yet


----------



## megabyte

MHB said:


> Is the scale was accurate enough you might be able to build in a conditioning feature (if you work in Volumes 1g/L = 0.506 Volumes) - that feature actually appeals to me more than how full the kegs is, over the years I have trained my right index finger to be a pretty spot on keg scale - just a gentle vertical lift.


I almost missed this part. This suggestion is totally next level and I love it because I'd use it for force carbing too. Just turn up the gas and leave it until you've gained X grams of CO2.

In my tests without temperature compensation (images documented in my first post), the error for a full 19L keg of water was around 100 grams which won't be good enough. By adding temperature compensation I know I can make it a lot more accurate, I just don't know *how much* more accurate yet so no promises. I'll definitely keep this concept in mind.


----------



## MHB

The weight of a liquid in a closed container doesn't change with temperature! it's density does, if you want the equation - let me know
I strongly suspect that the variance is more to do with the electronics and how they respond to cooling. The other possibility that occurred to me was that it might be from gas and beer lines contracting as they cooled/heated, some plastics have fairly impressive response to temperature. Which leads to thinking about how your lines are laid out and effect on apparent mass, and when and how you adjust for the mass of the connections.
To me it would appear that you need to be able to put in a full keg (the mass of which you know) record the mass of the beer, make all your connections, then have the system "forget" the extra mass, something similar for taken up CO2, except that needs adding to the mass of beer

The other thought I had was if you don't want to compensate for variable SG's you would be better defaulting to a density of 1.010 or so rather than 1.000
I think its fair to say that a very large proportion of beer has an FG between 1.008-1.012, very few less than 1.000.
Re % error as discussed above, I suspect that there is something a little misleading with the relative error, SG might be the wrong scale, try doing the numbers in oP gets rid of that pesky nonunitary 1.000 part (SG =(4*oP)/1000+1) close enough unless you want the ridiculously precise quadratic form of the conversion.

Still think it would be easier to just express it as a % of full weight. Or % full weight + CO2
I do like the idea that as the keg empties error goes down - that's smart!
Mark


----------



## MastersBrewery

New rule: no reading Marks posts before 6am. 

Mark maybe you should colate all your posts and publish a book. I wouldn't be the first on the list to buy one, but that'd be down to my slow reflexes and net speed.


----------



## GibboQLD

Michael Burton said:


> Regarding the differences in final gravity mentioned by paylyman, MHB and n87, by my calculation the difference between a 1.006 and a 1.020 f.g beer is about 1.5% by mass. My thoughts were that when you get down to your last pint there's only going to be about 10 grams of error in a worst case scenario which probably wouldn't bother me enough that I would want to enter the f.g. for each beer I keg.
> 
> ...
> 
> I've implemented a zero function (to allow the scale to know what zero is without a keg) and a tare function (to weigh the empty keg and subtract it from all beer calculations) into the iOS app and it stores these against your keg (which you must name or number individually). That way no matter what style your keg is, you should be able to weigh it perfectly using the bluetooth scale.


I wondered if a QR code on your regular kegs would be a good way to speed up the setup process as kegs are changed out -- scan the code, pick from your saved list of brews (or enter a new one) and away you go, but then if you were in the habit of hosting "guest kegs", you'd need to zero/tare them anyway.



Michael Burton said:


> Yeah I love the idea of being "connected" with your beer and brewing no matter where you are. My first prototype and sketch involved WiFi and sending notifications to your phone, but when I did the math it turns out it would be a lot more expensive and getting power to it would add cords or big batteries.


You could always add an optional "watchdog" mode that only enables wifi/sends a text when it needs to. As a DIY project it's easy to set up something like Grovestreams or Twitter/IFTTT to send messages/notifications, but that becomes a little harder if you plan on either releasing an open source project to the wild or commercialising it.


----------



## mstrelan

If your guests have to download an app you should put a NFC tag on your kegerator to redirect them to the app store.


----------



## n87

Michael Burton said:


> Yeah I love the idea of being "connected" with your beer and brewing no matter where you are. My first prototype and sketch involved WiFi and sending notifications to your phone, but when I did the math it turns out it would be a lot more expensive and getting power to it would add cords or big batteries.
> Here was one of my earliest sketches, but it no longer applies:
> 
> 
> 
> early sketch - 1.jpg
> 
> I have planned an alternative which is to log the beer levels into the memory inside the bluetooth scale at regular intervals, so when you do open the app later and connect, it can download a chart of the usage over time and you can tell at exactly what times the beer was consumed. It's not as good as your suggestion because it's not immediate, but the hardware I'm using can easily handle this, it's just a few weeks more coding on my part.


One idea on this, is to have an optional BT>WiFi doohiky that can sit outside the fridge connected directly to the power
Pair your doohiky to your scale(s) and it can send updates to wherever.
Modular, no need to modify your current design, no need to run wires, out of the way.

Regarding the app at parties, you would want a 'party mode' on the main device, that when selected, puts all the information in a more 'viewer friendly' format (verses beer nerd format) but also locks the device down so noone can move away from that screen or change anything.




mstrelan said:


> If your guests have to download an app you should put a NFC tag on your kegerator to redirect them to the app store.


Have a print out with a QR code (much cheaper and easier than configuring an NFC tag).
once they download the app, they can scan the second QR code that will log them into that 'event'


----------



## klangers

Does no one else just tap their kegs and listen to the pitch?

It varies with pressure, and the height of the liquid. So since we all have different serving pressures it's not as nice as a loadcell, but after a bit of experience it works well to someone with a musical ear.

This method was used in old filling height measurements in industrial bottling lines - and the brand is still around - "Taptone". They don't use this method anymore though as machine vision blows it out of the water.


----------



## n87

One question just occurred to me, have you tested how well BT is transmitted in fridge<>out?
I would have thought the metal casing on most fridges would work as a Faraday cage


----------



## MastersBrewery

n87 said:


> One question just occurred to me, have you tested how well BT is transmitted in fridge<>out?
> I would have thought the metal casing on most fridges would work as a Faraday cage


The brewometer uses the same sort of tech they say about 3m outside the fridge. Note with better aerial or any aerial, coverage would increase, and the brewometer is submerged which would also interfere with signal strength.


----------



## megabyte

You're a wealth of information Mark!



MHB said:


> The weight of a liquid in a closed container doesn't change with temperature! it's density does, if you want the equation - let me know
> I strongly suspect that the variance is more to do with the electronics and how they respond to cooling.


Yes, it's definitely the electronics, sorry if I made it seem like the liquid would change mass. The load cells use a piece of metal under strain and as they heat and cool their output changes a little.



MHB said:


> The other possibility that occurred to me was that it might be from gas and beer lines contracting as they cooled/heated, some plastics have fairly impressive response to temperature. Which leads to thinking about how your lines are laid out and effect on apparent mass, and when and how you adjust for the mass of the connections.


Yes. This is one of the drawbacks of using weight instead of flow sensing, also if the kegs and beer lines rub up against each other it could affect the readings as well. I don't foresee any troubles with monitoring keg levels where it doesn't really matter if you're out by 100g which is less than a quarter of a pint but 100g of error could make the CO2 measuring concept impossible.



MHB said:


> The other thought I had was if you don't want to compensate for variable SG's you would be better defaulting to a density of 1.010 or so rather than 1.000
> I think its fair to say that a very large proportion of beer has an FG between 1.008-1.012, very few less than 1.000.


Awesome, I had it hard coded as 1.008 but I'll make it 1.010.




MHB said:


> Re % error as discussed above, I suspect that there is something a little misleading with the relative error, SG might be the wrong scale, try doing the numbers in oP gets rid of that pesky nonunitary 1.000 part (SG =(4*oP)/1000+1) close enough unless you want the ridiculously precise quadratic form of the conversion.


Let me know if I'm missing something here. I thought calculating the error between f.g was like 1.020 / 1.006 = 1.0139 which is about 1.4% difference in mass. I can't envisage a need for quadratic equations unless you want to factor in the expansion of the liquid and the mass of air it displaces? I could be totally wrong here so please let me know if I've oversimplified things. Hopefully the error is still small even when the math is done right 



GibboQLD said:


> I wondered if a QR code on your regular kegs would be a good way to speed up the setup process as kegs are changed out -- scan the code, pick from your saved list of brews (or enter a new one) and away you go, but then if you were in the habit of hosting "guest kegs", you'd need to zero/tare them anyway.


QR codes may be a great idea if we can get them to work. I'm not sure how hard scanning will be to implement in an app (there might be a library for it, or it could be a major undertaking) but I'll look into it. Alternatively, just draw a "1", "2" etc. on your kegs with a sharpie.




n87 said:


> One idea on this, is to have an optional BT>WiFi doohiky that can sit outside the fridge connected directly to the power
> Pair your doohiky to your scale(s) and it can send updates to wherever.
> Modular, no need to modify your current design, no need to run wires, out of the way.
> 
> Regarding the app at parties, you would want a 'party mode' on the main device, that when selected, puts all the information in a more 'viewer friendly' format (verses beer nerd format) but also locks the device down so noone can move away from that screen or change anything.
> ...
> have you tested how well BT is transmitted in fridge<>out?


n87 you are reading my mind!

Yes. Having a BT/WiFi bridge is on the cards for the future and there are so many other value adds it could offer. Just gotta get this project finished first 

As for party mode. YES exactly, you're tha man!. Here's a sketch I made back in Feb. Wow I have been thinking about this project for a while...


I even called it party mode, so that's how I know you're reading my mind :lol:

Regarding signal strength. Yap, I've tested in my kegerator and the range seemed a little reduced, but still ample. I could walk into another room 10m away and still get reception. I think this was an embarrassing oversight for the original BrewNanny project that needed to connect to your house's WiFi, but with Bluetooth (BLE) our use case is easier because you're not trying to reach a router that might be at the other end of your house.


----------



## megabyte

n87 said:


> Have a print out with a QR code (much cheaper and easier than configuring an NFC tag).
> once they download the app, they can scan the second QR code that will log them into that 'event'


Hey if users have a tablet sitting on their fridge (like I did) I could fit a "download the app" QR code on the screen and generate one for the event too. No stickers, no NFC? I love the idea.


----------



## n87

someone has likely written up a decoder that you would be able to buy and add into your program. this would be the easiest, and possibly even the cheapest in the long run.
Given you would likely only want QR, it wouldnt be much of a code (compared to a full decoder of common barcode symbologies)

http://iphonenativeapp.blogspot.com.au/2011/07/qr-code-readerscanner-for-iphone-app-in.html


----------



## MHB

The 1 part of 1.010 isn't measuring anything it is just saying times the equivalent mass of water.
For example if you were working out apparent attenuation on a beer 1.050 to 1.010, you cant go (1.050-1.010)/1.050 =0.0381*100=3.81%
The answer is actually (50-10/50)*100=80% or in Plato,(12.5-2.5/12.5)*100=80%

For your example it would be 20/6=3.33333*100= 333% error. 1.020/1.006 has no meaning mathematically
Use points or oP if you want a workable answer.

The quadratic Equation I mentioned was for converting from SG to oP the short form above is linear, the true conversion is exponential but the maximum error in the range between 1.000 and 1.100 is pretty small around 0.0008 so if that level of precision isn't needed don't worry about it.
If your precision isn't in the sub 1g range it is only of academic interest; down to your load cells I suppose.

Not trying to nit pick, but know from experience that small errors can grow out of proportion by the end.
Mark


----------



## megabyte

Awesome, thanks MHB. Yep I'd rather know about the small errors now rather than 6 months down the line when the test procedures are giving wacky results.

Hey I'm surprised (relieved) that nobody has asked about different keg sizes yet. So far I'm designing for cornie kegs using a 21cm diameter scale, but I was wondering if there are other keg sizes that are growing in popularity (like those european ones with bags in them) that people are using. Obviously CUB kegs could be a little difficult to cater for.


----------



## n87

Michael Burton said:


> Awesome, thanks MHB. Yep I'd rather know about the small errors now rather than 6 months down the line when the test procedures are giving wacky results.
> 
> Hey I'm surprised (relieved) that nobody has asked about different keg sizes yet. So far I'm designing for cornie kegs using a 21cm diameter scale, but I was wondering if there are other keg sizes that are growing in popularity (like those european ones with bags in them) that people are using. Obviously CUB kegs could be a little difficult to cater for.


eh... for a bigger keg, they just need a circle of wood or something to extend the platter, then add that to the weight of the keg, or tare it.
as long as its centred, and your scales cope with the 60+ kg (being bathroom scales, I would hope so)


----------



## Frothy1

Bluetooth can be buggy and frustrating when it wont connect.

With my igrill it will troubleshoot and give you a "restart bluetooth" option that works, even tho I may have restarted my phone and bluetooth already.

I dont know the brains behind why, when the igrill app restarts it, it works, but it does.


----------



## trhr

Michael,

Great idea and follow through with the prototypes, I'll be watching with interest for when we can purchase this in some form.
Many thanks for dumbing down your initial post for the Average Joe such as myself.

You have now joined the rarefied air of Husky and MHB in my books.
I read their posts.... I know I love what they're making... but I have no [email protected] idea how/why/when.... and also leaves me thinking _"I'm pretty sure that also sends emails?" _often with a headache and concluded Neanderthal statement of "Me love beer!"


----------



## MastersBrewery

Mytton rod are 22 and pin lock 22.5 but a plate of timber cut to size would fix size anomalies right quick.


----------



## Moad

I think you will do very well if you commercialise this into an all in one kit. Make it modular so you simply add another scale kit for additional kegs.

Another branch in the project I'd be interested in seeing would be to pour from the app too. Select glass size, hit pour. That way it could be locked down with an RFID tag or other method of authentication, you could restrict your housemate to a few beers a day while you were gone etc.

The keg level would be great and you'd have my money, my other suggestions are more of an interest from the tech perspective and not all that practical I guess...


----------



## blekk

Moad said:


> Another branch in the project I'd be interested in seeing would be to pour from the app too. Select glass size, hit pour. That way it could be locked down with an RFID tag or other method of authentication, you could restrict your housemate to a few beers a day while you were gone etc.
> ..


In theory would be pretty easy to do using a normally closed solenoid valve and receiver not sure about the programming side of things though.


----------



## DJ_L3ThAL

One 'addon' to the system could also be a CO2 bottle scale to measure the weight and track how close you are to finishing the gas. I know once the liquid CO2 is finished the high gauge starts dropping but sometimes this is too late, it's the weekend and now you're going to run outta gas for your party... Be nice to be able to 'predict' when the liquid is almost out. I currently manually weigh my bottle every few months which is fine. But automatic technology rules...


----------



## MastersBrewery

The issue with inline valves, flow meters and the like is the inline device can create foaming and you won't know until you try. When the original 'kegbot' forums were going ball valves were the valve of choice. Solenoid valves were found to cause foam issues. Note neither are in the easy to clean category. Also know that the spaghetti in you kegger will be a little wild. Tips: the closer to the coupler the device is placed the better ( particularly flow meters). A valve directly on the rear of a shank will effectively isolate it from cooled liquid, so first pours would be crapier than some have now. 

Put a lock on the kegger door, remove the liquid disconnect and lock the door problem solved.


----------



## klangers

Yeah standard solenoid valves aren't a good choice for beer - they have a very small orifice and this will cause massive pressure drops and hence foaming. And yes - very large pipe hammer from instant closing which may make rather unsettling noises to those not used to it. Any valve or tap kind of needs to be mounted near the spout, unless you want your whole beer line exposed to the (unclean) elements and heaps of dripping as the beer drains out of the line.

You'd be better off rigging an external solenoid to an existing tap I reckon.

Ball valves aren't sanitary either, and have the additional problem of possibly being buggered if frozen when shut (expanding water/beer trapped in the ball). 

Either way, at various sporting venues, there are beer auto-pourers. It may be worth, if you're willing to line up for a XXXX, checking out how these machines work as they've probably already solved 99% of the above issues.

As an aside, I would really like a simple, cheap set of remote isolation valves to enable me to isolate my kegs without opening my keezer. This would give me peace of mind when I'm away - I've already had a hose pop off the shank and lost a whole keg to the carpet! A simple font-mounted switch would then de-isolate the pouring taps, ready to go.


----------



## MastersBrewery

If we were all using commercial couplers I'd be more confident with a motorised ball valve using snaplocks for issolation. Ball lock connections just aren't anywhere near as solid.

Klangers, the valve idea was issolation only, ie not to pour.


----------



## megabyte

DJ_L3ThAL said:



> One 'addon' to the system could also be a CO2 bottle scale to measure the weight and track how close you are to finishing the gas. I know once the liquid CO2 is finished the high gauge starts dropping but sometimes this is too late, it's the weekend and now you're going to run outta gas for your party... Be nice to be able to 'predict' when the liquid is almost out. I currently manually weigh my bottle every few months which is fine. But automatic technology rules...


I get that too, when the pressure starts to drop you're already too low to carbonate or dispense much beer over the weekend. I started a brainstorming thread about CO2 leak detection recently and considering the cost of CO2 sensors, monitoring the CO2 bottle's weight might be a viable option if it had a WiFi bridge so it could guarantee getting notifications to your phone.


----------



## MastersBrewery

1. Will taps be idependant of kegs being weighed. So 3 tap kegger holding 5 kegs with 2 in reserve/conditioning, but all 5 on scales able to be selected as ontap.

2 would something like an esp8226 with hc06 bluetooth module do the trick?


----------



## megabyte

1. Currently you can label each keg as "Tap 1" or "Spare" or "Cellar" etc. You can also display beers not being weighed too like "Esky". Let me know if there's any problem with that, it's pretty flexible at the moment.

2. Do you mean on the scales or as a separate bridge? I like the ESP8266 but my reservation about WiFi on the scales is the increased power usage. It necessitates much bigger battery systems (usually Li+ or LiFe) which cost more and they're a logistical nightmare to ship globally. I also don't like that you'd have to recharge the batteries each month or so, or run a power cord that adds to cable clutter. BLE just makes a lot of sense for the scales.

The HC06 is a Bluetooth serial port and iOS doesn't support the Serial Port Profile (thanks a lot apple! :angry: ).

We might end up with a BLE/WiFi bridge later on and for that we could use ESP8266 for the WiFi side but it will come down to certification costs and reliability. I know the ESP8266 can get FCC these days, but it might be cheaper to work with the bigger brands. Also I feel that the Broadcom or TI chipsets may be a little more reliable. At least that's the word from the engineers at particle.io.

Keep the suggestions rolling


----------



## Frothy1

For me, if it's not designed to be moved while in use, I like it to have a permanent power supply.

It would be good if it had a secondary power option.


----------



## contrarian

Hi Michael, great to hear that this project is moving along and sounds like a fantastic way to make it work. 

The considerations I would have would be in relation to the durability of the scales. I use a chest freezer to serve from so it means lifting full kegs into the fridge, would the scales hold up to a keg being dropped or placed in a bit roughly?

I would also worry about how the electronics would hold up in a very damp environment. There is always some condensation but I must admit to having had he occasional beer leak where I have lost a few litres into the bottom so it would be handy to have scales that could cope with the moisture if that's a possibility. 

It's always annoying when kegs blow together, I think the worst I have experienced was 3 in 3 pours so would be awesome to be able to know when it is coming or when you were down to the point where it was time to run off a growler and hook up a new keg!


----------



## MastersBrewery

Yeah I was thinking bridge. And on that point the bridge will be limited by the number of devices that can connect. The best BT4.0 bridge I could find only did 7 slave devices and that was to ethernet. I can't remember if BT 4.x has a built in hard limit of 7 or not.
It may be that a software bridge within the app being the simplest solution. Though would require a dedicated tablet/phone to be near the kegger.


----------



## megabyte

An update... I was thinking about alternatives to weighing the kegs for situations where a scale wouldn't be practical and I wondered if I could use an infrared distance sensor to measure the distance from the keg lid down to the top of the beer. Here's a new video I put together showing the experiment and the results.

https://www.youtube.com/watch?v=IPW7vWlXodk

Enough distractions now, I gotta get back to programming and building a better looking prototype!


----------



## peteru

I was also pondering other methods and an ultrasonic distance measure or even a sonar like echo came to mind. The sonar method should work with an external transducer, but I wonder if the characteristics are likely to change with each keg and even with the state of the contents, such as level of carbonation.

One could waste months and $$$$ toying with such ideas.


----------



## Bomber Watson

I will be extremely happy to pay money dollars foe this once done.

Edit, just having a bit more of a think.

Are you currently working on a proper prototype loadcell, then going through pricing then starting a kickstarter or similar?

Easyest way to cover some of the development cost I think, just have a basic package with one scale then increasing packages ontop of that up to say 10, boom done.

My other thought, now I'm about as tech savvy as a cave man, but I was thinking a dedicated monitor mounted behind the font would be nice.

22" or so lcd monitors can be had for the spare change in your ash tray now days.

What kind of doohickey white mans magic thingy would be needed to pick up the Bluetooth from the scales, hold the app and send it to the monitor? Or is that harder than o thought?


----------



## megabyte

Bomber Watson said:


> My other thought, now I'm about as tech savvy as a cave man, but I was thinking a dedicated monitor mounted behind the font would be nice.
> 
> 22" or so lcd monitors can be had for the spare change in your ash tray now days.
> 
> What kind of doohickey white mans magic thingy would be needed to pick up the Bluetooth from the scales, hold the app and send it to the monitor? Or is that harder than o thought?


Thanks for the tips! For adding an external tv screen I was thinking of supporting tvOS in the app so you can use it with an Apple TV. There are android TVs too so running a native app on the TV might be an option, it's hard to work out what level of BLE compatibility these devices have though. I must admit I haven't ventured too far down this path yet.


----------



## boybrewer

klangers said:


> Does no one else just tap their kegs and listen to the pitch?
> 
> It varies with pressure, and the height of the liquid. So since we all have different serving pressures it's not as nice as a loadcell, but after a bit of experience it works well to someone with a musical ear.
> 
> This method was used in old filling height measurements in industrial bottling lines - and the brand is still around - "Taptone". They don't use this method anymore though as machine vision blows it out of the water.


Some people have limited hearing and might not be able to hear those type of nuances .


----------



## mstrelan

Michael Burton said:


> An update... I was thinking about alternatives to weighing the kegs for situations where a scale wouldn't be practical and I wondered if I could use an infrared distance sensor to measure the distance from the keg lid down to the top of the beer. Here's a new video I put together showing the experiment and the results.


Can you float some sort of sanitised stainless steel ball on the top of the liquid? Would the sensor need to be aimed directly at the ball or is the detection range fairly broad?

Or can you make the sensor waterproof and point it up to the lid instead of down from the lid?


----------



## contrarian

If you were going to use a float wouldn't it be easier to run it up and down a post of sorts and measure the height mechanically?

It wouldn't need to be rigid, some kind of food grade string or wire with a weight at the bottom and I would be surprised if this kind of arrangement would be more cost effective than load cells. 

With the scale arrangement have you considered using a Perspex top with the capacity to attach to the bottom of the keg with Velcro? 

For a keezer set up this would make it simpler to ensure it was placed properly and also to remove rather than having to retrieve form the bottom of the keezer. 

Can't wait until this is up and running!


----------



## megabyte

The beam from the IR sensors is pretty narrow, I think they're best pointed at an opaque surface as reflections can confuse it a bit.




contrarian said:


> With the scale arrangement have you considered using a Perspex top with the capacity to attach to the bottom of the keg with Velcro?
> 
> For a keezer set up this would make it simpler to ensure it was placed properly and also to remove rather than having to retrieve form the bottom of the keezer.
> 
> Can't wait until this is up and running!


Yes, coincidentally I've been considering this but for different reasons. Your point about convenience has sold me further on the idea.

My reasoning was more about how you explain the concept to people. Explaining to potential customers why they need a bluetooth scale for their kegs is a bit of a hard pitch until you list all the features and benefits because it's just not obvious at first, but if we make the sensing discs attach to the bottom of a keg, all of a sudden we're selling *"turn any keg into a smart keg"* which is much more intuitive and easy to visualise. I think most people can infer that it's going to link to an app and do awesome stuff.

The "Turn your X into a smart X" concept isn't new, examples include Chronos and Trivoli, turning regular watches into smart watches.


----------



## contrarian

That makes good sense, I'd be happy to help with some infomercial style advertising with kegs blowing at inappropriate times like the middle of a party, just after kick off in state of origin etc. 

As I think about it you might need a variety of attachments. Corny kegs have enough flat bottom for Velcro but I have a 23L that's the same diameter but nearly no flat bottom. I'm sure there's be work arounds for any keg. 

Will they be waterproof? Normal condensation is one thing but if you have a beer leak you could drown them!


----------



## megabyte

Yeah, I do worry about all the different keg shapes and how they will mate up. I have some from china with odd diameters and metal bases that look like the bottom of a coke can. I am yet to test them all for magnetism (so we could possibly use magnets instead of velcro). Stainless tends to become ferromagnetic after you punch it into different shapes. I'm not sure if the slight dome on the base of a keg is enough to make it ferromagnetic though.

We're going to need a video like what you describe in our kickstarter launch. Origin is a good idea but I don't think we can organise a script and camera crew by Wednesday. I'll have to tape it 

I've been thinking about how to make it waterproof and I still don't have an answer yet. It could be designed to tolerate being flooded by 1cm of water or so, but to make it dunk-proof it would need some special design around the load cells (that need to support unrestricted movement) and the battery bay. Any ideas?


----------



## contrarian

For different keg types you wouldn't want more than 2 or 3 different attachments. For anything with a flat surface Velcro would work. Magnets might be ok but not for cornys with rubber bottoms. 

For anything with a thinner metal lip some kind of clip, sort of like a bulldog clip but just push on should do the trick, either Velcro or magnets. 

Ha! You might run into some small copyright issues using origin but I'm sure the basic idea is sound! Hate running out of beer unexpectedly? You need smart kegs from digital homebrew!

Waterproofing is tricky. The first things that spring to mind are either an arrangement where the bottom of the load cells sit under a sealed case but not sure if that could work or not. 

The other thing that popped into my head is a zip lock bag style enclosure for the whole thing. I'm sure there would be something used in kayaking or other water sports that will do the job.. Let me work on that!


----------



## peteru

http://www.maxbotix.com/ looks like a good resource for ideas - even if you don't end up using one of their sensors, they still have some valuable info.


----------



## peteru

I found some awesome (fully sick) sensors here, but I suspect they will all be out of the price range for mounting these in a bunch of kegs.

https://www.sick.com/us/en/product-portfolio/fluid-sensors/level-sensors/c/g98155


----------



## peteru

I've been applying my brain to this problem. Along the way, I investigated some TDR (time domain reflectometry) concepts but came to the conclusion that the high speed electronics required for short distances would make it too hard and expensive.

So far the best candidate seems to be an acoustic solution. It may be possible to come up with a very simple solution, where you have an audio impulse source and a microphone that captures the reflected signal. No need to have it internal to the keg, just use an elastic strap to attach it to the side of the keg. A little bit of signal analysis should give you the time to the various reflections. You would probably need to train your estimation algorithm for each keg type you use.

Given that the keg level can be estimated within normal frequency range that people can hear (just by tapping it), I suspect that any device intended for audio could be used for hacking. In particular, I'm thinking a bluetooth headset - it has both a speaker and microphone and could be butchered/repurposed for some experimentation. Mind you, for the first pass at a proof of concept, you could just use mobile phone held to the side of the keg!


----------



## takai

Looks like you beat me to it. I currently have a prototype setup using Raspberry Pints and a gutted bathroom scale running through an Arduino for communication to the Pints.I figured i would just use Pints rather than rolling anything new as it would just be easier.

Currently i have it jerry rigged to display raw output to a simple Arduino LCD shield, which works relatively well. Have run out of time right now to do more though.


----------



## Matty3450

I havent read the complete post so please ignore if it has been mentioned. A digital flow meter may be an alternative


----------



## SBOB

Matty3450 said:


> I havent read the complete post so please ignore if it has been mentioned. A digital flow meter may be an alternative


been covered


----------



## megabyte

Updates!

I was playing with Untappd last night and finally decided to request an API key. If we can integrate with Untappd it makes sense because:
1. I'm a long-time Untappd fan.
2. You'll be able to check-in your beers from the barmaiden app as you pour them rather than launching a separate app.
3. You'll be able to use the Untappd database to easily import beer details when you have a keg of commercial brew on tap.
4. Other cool stuff?

Progress has been a little slow on the hardware front as we've been busy working on our business model. Last week we demoed the Barmaiden concept (along with the rest of our business) to a review panel at our local startup accelerator, so fingers crossed we were able to impress them enough to accept our application. It seemed like they enjoyed the presentation even if they declined to sample the beer from the keg (possibly because it was 9:15am?).

Can't wait to get back to prototyping. We still need to build a "looks-like" prototype and our 3D printer isn't big enough to print it in one go. The alternative is to glue smaller bits together and paint them, but I think it's going to look like a dog's breakfast. Time will tell!


----------



## technobabble66

Ok. 
Looks like all youse nerdy nerds are soaking up the tech volume adequately. 
I'll focus on the cool name [emoji41]

TapMaiden* (sorry for the ripoff, MB)
iTap, eTap (-names already used)
iPour*, ePour
iBar, eBar (-names already used)
KegDisplay, TapDisplay
TapMenu*, KegMenu, BarMenu*
The Tapperator* (it goes with the Kegerator!!)
The Beer Show

* - personal fav's

I'll keep brainstorming [emoji57]


----------



## contrarian

Just to bump this thread the slogan for this could be 'never blow unexpectedly again!'


----------



## megabyte

I think The Lonely Island made a song about that 

Sorry for the lull, we've joined with an accelerator program and we've been flat out learning all sorts of business stuff that will help us to launch well. Lately we've been pushing forward under the name POuRTAL.





Rationale:
It's like a portal letting you see inside your kegs.
It's like a digital chalk board (hence a chalk themed logo).
It pours beer and (my wife pointed this one out) it's a "pour tool" - a tool that helps with pouring beer.

We've been very active working on this concept. Here are some diagrams from our pitch deck as a sneak peek of the idea:


----------



## Drew

Pourtal is a cool name and will relate to a fair chunk of your target demographic I'm sure.

I'd like to see built in leak monitoring. (Says the person who just lost 10 litres to the floor!).

Might be hard to differentiate between 10 litres leaking onto the floor vs a normal Friday night though - but I do usually have a brief break between each 500ml! Slow leaks might be tricky to detect too - but surely possible.


----------



## contrarian

I think I know the song you're talking about Michael! Good to hear the idea is still being worked on and pourtal is much classier than anything I could have come up with!

I also like the idea of a leak alarm as I'm sure anyone else who has had to clean 10 litres of beer out of the bottom of a chesty with no drain plug would!


----------



## megabyte

Great idea with the leak alarm! I think it might be do-able without taxing the battery too much or increasing the bill of materials cost significantly. It's still a shame that CO2 sensing isn't as feasible on this product due to cost and battery life. I lose CO2 bottles all the time  Haven't lost a keg of beer yet, but man that would be a nightmare to clean up inside the house!


----------



## contrarian

Just need to sit one of your weighing devices under your has bottle too! Might take a bit longer to pick up the change but could save you losing the whole bottle!


----------



## megabyte

contrarian said:


> Just need to sit one of your weighing devices under your gas bottle too! Might take a bit longer to pick up the change but could save you losing the whole bottle!


Very true. The same could go for the beer leak detection. While we could incorporate an electronic probe into the scale to detect fluids, it may be easier to simply let the software sort it out. E.g. when it detects that over a certain volume has been poured at a constant rate it's highly likely there's a leak. We're also playing around with various methods to make the scale resilient to said leaks.

As an update, we're still running full steam ahead, currently refining the design for the injection moulding and researching the patents that are out there. People have been weighing kegs in various ways since the 70's so it pays to be prudent and make sure we don't step on anyone's toes.

Also, we're heading off to Boston in February so it's going to be great "researching" their craft beer scene


----------



## contrarian

Any progress on this mate? I had a keg blow unexpectedly yesterday and it reminded me of how handy something like this would be! Luckily on this occasion I had a back up ready to go but that isn't always the case!


----------



## Tex083

Boston is one of my favourite places to go. Make sure you catch a Bruins game (ice hockey) and have plenty of room for beer and burgers!


----------



## DJ_L3ThAL

Great work Michael, I've bought some in my mind already! One thing to consider on the software side is the ability to enter a 'maintenance' or 'cleaning' mode as when I clean my lines as I have a stand up all fridge kegerator I lose shite loads of cold air whilst the door it open and I'm flushing my lines. Therefore a large amount of condensation builds up on the kegs and could drip down onto the scales. So would be nice to be able to trip out nuisance leak alarms. Still think the leak detection function is essential though


----------



## megabyte

Cool, I'll see what we can do to handle leak detection economically. I really want to try and keep the scales cheap since some of us have a LOT of kegs


----------



## malt junkie

Is 14 a LOT??


----------



## DJ_L3ThAL

On tap or filled and in fridge at once??? YES.


----------



## XaxisYcross

I would love an update on this project! I have just read the thread from start to finish and I am ready to put down some cash money.

One thought I had was, using the Tilt hydrometer, you can link it to BrewStat.us which allows you to upload a beer .xml file which then provides all the information from the beer recipe to the logging page of the beer that that Tilt is assigned to. I imagine this wouldn't be too hard to implement into the Pourtal app?


----------



## contrarian

Any word on how this is going Michael?


----------



## megabyte

It's still chugging along. We're planning a China trip in the coming weeks to meet a manufacturer who can do injection moulding. With the samples underway we'll be pressing ahead with a launch on Kickstarter. So many projects launch too soon with no concrete plan for production, we really want to have all our ducks in a row before making promises and taking people's hard earned.

Xaxis I like the way you think. The Pourtal app can bridge Bluetooth to the cloud - no worries, but it would require a device (phone, iPad etc.) to be in range all the time to have access to live monitoring. Should be fine in many cases!


----------



## MattSR

Can't wait to see how this one pans out - It's something that could be very neat and handy!!

Cheers,
Matt


----------



## Chris Carter

its been a while - any progress?


----------

