[Initial Release] RaspberryPints - Digital Taplist Solution

Homebrew Talk - Beer, Wine, Mead, & Cider Brewing Discussion Forum

Help Support Homebrew Talk - Beer, Wine, Mead, & Cider Brewing Discussion Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
<script>
$(function() {
var beerList = {
7: {id: 7, name: 'All Day Ale', beerStyleId: 19, notes: '', srm: '3.5', og: '1.048', fg: '1.009', ibu: '29', active: '1', createdDate: new Date('2015-04-20 16:08:18'), modifiedDate: new Date('2015-05-11 19:57:35') }, 2: {id: 2, name: 'Centennial Blonde Ale', beerStyleId: 19, notes: 'Gold color, fluffy white head, smells bready, fruity, yeasty (all fairly faint). Tastes light and crisp with an enjoyable sweet bready-ness. A quality blonde ale. 4% ', srm: '3.6', og: '1.042', fg: '1.010', ibu: '20', active: '1', createdDate: new Date('2014-11-07 00:31:12'), modifiedDate: new Date('2014-11-07 08:17:49') }, 9: {id: 9, name: 'Ditzy Blonde', beerStyleId: 19, notes: 'All Day Ale', srm: '3.8', og: '1.053', fg: '1.002', ibu: '26', active: '1', createdDate: new Date('2015-07-20 13:21:50'), modifiedDate: new Date('2015-08-04 19:24:59') }, 6: {id: 6, name: 'Hard Lemonade', beerStyleId: 83, notes: 'Just like Mikes', srm: '10.0', og: '1.170', fg: '1.040', ibu: '2', active: '1', createdDate: new Date('2015-04-10 23:34:00'), modifiedDate: new Date('2015-05-01 10:35:37') }, 5: {id: 5, name: 'Hibernation', beerStyleId: 50, notes: '', srm: '37.4', og: '1.068', fg: '1.017', ibu: '77', active: '1', createdDate: new Date('2015-04-10 23:27:00'), modifiedDate: new Date('2015-07-20 13:22:42') }, 10: {id: 10, name: 'Kitchen Sink', beerStyleId: 33, notes: 'Easy Drinking Ale', srm: '12.9', og: '1.068', fg: '1.010', ibu: '52', active: '1', createdDate: new Date('2015-09-17 18:26:14'), modifiedDate: new Date('2015-09-17 18:26:14') }, 8: {id: 8, name: 'Raspberry Tea', beerStyleId: 102, notes: '', srm: '0.0', og: '0.000', fg: '0.000', ibu: '0', active: '1', createdDate: new Date('2015-05-01 10:27:00'), modifiedDate: new Date('2015-05-01 10:32:12') }, 3: {id: 3, name: 'Ridge Runner Red Ale', beerStyleId: 31, notes: '&amp;quot;Robust, Dark and Smooth, hold on to your hat cause you&amp;rsquo;ll lose your feet on this one!&amp;quot; Brewed with pale, dark crystal, Munich, flaked barley, black and chocolate malts. Hops include Cascade, Crystal, Challenger and Perle.
', srm: '10.8', og: '1.051', fg: '1.014', ibu: '23', active: '1', createdDate: new Date('2014-11-07 00:38:52'), modifiedDate: new Date('2014-11-07 08:16:50') }, 4: {id: 4, name: 'Summer Fun', beerStyleId: 33, notes: '', srm: '11.8', og: '1.046', fg: '1.010', ibu: '25', active: '1', createdDate: new Date('2015-04-10 23:20:21'), modifiedDate: new Date('2015-04-10 23:20:21') }, 1: {id: 1, name: 'Surly Furious Clone', beerStyleId: 49, notes: 'A tempest on the tongue, or a moment of pure hop bliss? Brewed with a dazzling blend of American hops and Scottish malt, this crimson-hued ale delivers waves of citrus, pine and carmel-toffee. For those who favor flavor, Furious has the hop-fire your taste buds have been screaming for.
', srm: '9.0', og: '1.070', fg: '1.012', ibu: '124', active: '1', createdDate: new Date('2014-11-06 23:18:27'), modifiedDate: new Date('2014-11-07 08:15:50') }, };
 
<script>
$(function() {
var beerList = { ...

Please copy and paste that again, this time making sure you put it into code tags (the little '#' sign up there when editing a post). Otherwise the forum eats the characters that I'm looking for.

Alternatively, if you know your way around the RpI, you can try the following patch:

In your Pi's /var/www/admin/includes/, look for the file 'functions.php'
Code:
cd /var/www/admin/includes/
make a backup via
Code:
sudo cp functions.php functions.php.001
Edit the original with nano (or any other editor)
Code:
sudo nano functions.php
In the file, replace the following single line:
Code:
	return htmlentities ($string, ENT_QUOTES);
with the following two lines:
Code:
       $string = str_replace(array("\n", "\r"), '', $string);
       return json_encode ($string, JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_QUOT | JSON_HEX_AMP | JSON_UNESCAPED_UNICODE);
Make sure you get both lines in full.
exit by saving with ctrl-o, <enter>, then ctrl-x.

See if that works, that's how I fixed mine. If something breaks, you can always copy the backup over the original.

Cheers,
-Th
 
I think I have it figured out. I noticed a few hard returns at the end of some of the beer descriptions as well as a few inside the descriptions themselves. I edited out all the hard returns and as if by magic all of the fields actually fill themselves out when I select a beer to put on tap.

Thank you for pointing me in the right direction to figure this out.

Hopefully later this week I will have time to install your system on a new SD card.

Yep, the \r or \n control characters are the problem. You can also try the patch in my last post, and it should remove that stuff before generating the JS that drives the list.

Cheers,
-Th
 
--> and chocolate malts. Hops include Cascade, Crystal, Challenger and Perle.

Just took another look, it looks as if you have a return control character after 'Perle'. Try to delete the last character in that description (even tho it looks as if nothing is there). It may work again, unless I overlooked another one (It's alot easier to spot this when the code is quoted with code tags)

Cheers,
-Th
 
Just took another look, it looks as if you have a return control character after 'Perle'. Try to delete the last character in that description (even tho it looks as if nothing is there). It may work again, unless I overlooked another one (It's alot easier to spot this when the code is quoted with code tags)

Cheers,
-Th

Code:
 carmel-toffee. For those who favor flavor, Furious has the hop-fire your taste buds have been screaming for.
',

... and another one after 'for.'

Cheers,
-Th
 
Code:
<script>
	$(function() {
		var beerList = { 
			7: {id: 7, name: 'All Day Ale', beerStyleId: 19, notes: '', srm: '3.5', og: '1.048', fg: '1.009', ibu: '29', active: '1', createdDate: new Date('2015-04-20 16:08:18'), modifiedDate: new Date('2015-05-11 19:57:35') }, 2: {id: 2, name: 'Centennial Blonde Ale', beerStyleId: 19, notes: 'Gold color, fluffy white head, smells bready, fruity, yeasty (all fairly faint). Tastes light and crisp with an enjoyable sweet bready-ness. A quality blonde ale. 4% ', srm: '3.6', og: '1.042', fg: '1.010', ibu: '20', active: '1', createdDate: new Date('2014-11-07 00:31:12'), modifiedDate: new Date('2014-11-07 08:17:49') }, 9: {id: 9, name: 'Ditzy Blonde', beerStyleId: 19, notes: 'All Day Ale', srm: '3.8', og: '1.053', fg: '1.002', ibu: '26', active: '1', createdDate: new Date('2015-07-20 13:21:50'), modifiedDate: new Date('2015-08-04 19:24:59') }, 6: {id: 6, name: 'Hard Lemonade', beerStyleId: 83, notes: 'Just like Mikes', srm: '10.0', og: '1.170', fg: '1.040', ibu: '2', active: '1', createdDate: new Date('2015-04-10 23:34:00'), modifiedDate: new Date('2015-05-01 10:35:37') }, 5: {id: 5, name: 'Hibernation', beerStyleId: 50, notes: '', srm: '37.4', og: '1.068', fg: '1.017', ibu: '77', active: '1', createdDate: new Date('2015-04-10 23:27:00'), modifiedDate: new Date('2015-07-20 13:22:42') }, 10: {id: 10, name: 'Kitchen Sink', beerStyleId: 33, notes: 'Easy Drinking Ale', srm: '12.9', og: '1.068', fg: '1.010', ibu: '52', active: '1', createdDate: new Date('2015-09-17 18:26:14'), modifiedDate: new Date('2015-09-17 18:26:14') }, 8: {id: 8, name: 'Raspberry Tea', beerStyleId: 102, notes: '', srm: '0.0', og: '0.000', fg: '0.000', ibu: '0', active: '1', createdDate: new Date('2015-05-01 10:27:00'), modifiedDate: new Date('2015-05-01 10:32:12') }, 3: {id: 3, name: 'Ridge Runner Red Ale', beerStyleId: 31, notes: '&amp;quot;Robust, Dark and Smooth, hold on to your hat cause you&amp;rsquo;ll lose your feet on this one!&amp;quot; Brewed with pale, dark crystal, Munich, flaked barley, black and chocolate malts. Hops include Cascade, Crystal, Challenger and Perle.
', srm: '10.8', og: '1.051', fg: '1.014', ibu: '23', active: '1', createdDate: new Date('2014-11-07 00:38:52'), modifiedDate: new Date('2014-11-07 08:16:50') }, 4: {id: 4, name: 'Summer Fun', beerStyleId: 33, notes: '', srm: '11.8', og: '1.046', fg: '1.010', ibu: '25', active: '1', createdDate: new Date('2015-04-10 23:20:21'), modifiedDate: new Date('2015-04-10 23:20:21') }, 1: {id: 1, name: 'Surly Furious Clone', beerStyleId: 49, notes: 'A tempest on the tongue, or a moment of pure hop bliss? Brewed with a dazzling blend of American hops and Scottish malt, this crimson-hued ale delivers waves of citrus, pine and carmel-toffee. For those who favor flavor, Furious has the hop-fire your taste buds have been screaming for.
', srm: '9.0', og: '1.070', fg: '1.012', ibu: '124', active: '1', createdDate: new Date('2014-11-06 23:18:27'), modifiedDate: new Date('2014-11-07 08:15:50') }, 		};
		
		var kegList = {
 
CaptnDelta your awesome! Thanks for the help:mug:

Glad it worked for you :mug:

Code:
<script>
	$(function() {
		var beerList = { 
			7: {id: 7, name: 'All Day Ale', beerStyleId: 19, notes: '', srm: '3.5', og: '1.048', fg: '1.009', ibu: '29', active: '1', createdDate: new Date('2015-04-20 16:08:18'), modifiedDate: new Date('2015-05-11 19:57:35') }, 2: {id: 2, name: 'Centennial Blonde Ale', beerStyleId: 19, notes: 'Gold color, fluffy white head, smells bready, fruity, yeasty (all fairly faint). Tastes light and crisp with an enjoyable sweet bready-ness. A quality blonde ale. 4% ', srm: '3.6', og: '1.042', fg: '1.010', ibu: '20', active: '1', createdDate: new Date('2014-11-07 00:31:12'), modifiedDate: new Date('2014-11-07 08:17:49') }, 9: {id: 9, name: 'Ditzy Blonde', beerStyleId: 19, notes: 'All Day Ale', srm: '3.8', og: '1.053', fg: '1.002', ibu: '26', active: '1', createdDate: new Date('2015-07-20 13:21:50'), modifiedDate: new Date('2015-08-04 19:24:59') }, 6: {id: 6, name: 'Hard Lemonade', beerStyleId: 83, notes: 'Just like Mikes', srm: '10.0', og: '1.170', fg: '1.040', ibu: '2', active: '1', createdDate: new Date('2015-04-10 23:34:00'), modifiedDate: new Date('2015-05-01 10:35:37') }, 5: {id: 5, name: 'Hibernation', beerStyleId: 50, notes: '', srm: '37.4', og: '1.068', fg: '1.017', ibu: '77', active: '1', createdDate: new Date('2015-04-10 23:27:00'), modifiedDate: new Date('2015-07-20 13:22:42') }, 10: {id: 10, name: 'Kitchen Sink', beerStyleId: 33, notes: 'Easy Drinking Ale', srm: '12.9', og: '1.068', fg: '1.010', ibu: '52', active: '1', createdDate: new Date('2015-09-17 18:26:14'), modifiedDate: new Date('2015-09-17 18:26:14') }, 8: {id: 8, name: 'Raspberry Tea', beerStyleId: 102, notes: '', srm: '0.0', og: '0.000', fg: '0.000', ibu: '0', active: '1', createdDate: new Date('2015-05-01 10:27:00'), modifiedDate: new Date('2015-05-01 10:32:12') }, 3: {id: 3, name: 'Ridge Runner Red Ale', beerStyleId: 31, notes: '&amp;quot;Robust, Dark and Smooth, hold on to your hat cause you&amp;rsquo;ll lose your feet on this one!&amp;quot; Brewed with pale, dark crystal, Munich, flaked barley, black and chocolate malts. Hops include Cascade, Crystal, Challenger and Perle.
', srm: '10.8', og: '1.051', fg: '1.014', ibu: '23', active: '1', createdDate: new Date('2014-11-07 00:38:52'), modifiedDate: new Date('2014-11-07 08:16:50') }, 4: {id: 4, name: 'Summer Fun', beerStyleId: 33, notes: '', srm: '11.8', og: '1.046', fg: '1.010', ibu: '25', active: '1', createdDate: new Date('2015-04-10 23:20:21'), modifiedDate: new Date('2015-04-10 23:20:21') }, 1: {id: 1, name: 'Surly Furious Clone', beerStyleId: 49, notes: 'A tempest on the tongue, or a moment of pure hop bliss? Brewed with a dazzling blend of American hops and Scottish malt, this crimson-hued ale delivers waves of citrus, pine and carmel-toffee. For those who favor flavor, Furious has the hop-fire your taste buds have been screaming for.
', srm: '9.0', og: '1.070', fg: '1.012', ibu: '124', active: '1', createdDate: new Date('2014-11-06 23:18:27'), modifiedDate: new Date('2014-11-07 08:15:50') }, 		};
		
		var kegList = {

I guess you figured why the code tags help :)

BTW, this is fixed as a bug in the other RPints thread. If you wanna help me test it, check it out...

Cheers,
-Th
 
Is there anyway to change the color of the text, I want to use a certain background, and you cannot see clearly the text of the beer names
 
Sure. The things you can play with are in /var/www/style.css and /var/www/index.php. I did all kinds of size tweaking to tune the tap list for the (4:3) display I use on my keezer, change the font colors, and added some functionality. Just be sure to back up good files before playing with them...

Cheers!
 
Has anyone gotten the flow controls working using an arduino connected via USB to the Raspberry Pi.

I am currently using the GPIO port for a TFT display
 
I'm thinking this should be a trivial change - the flow_monitor listener probably just needs to be told to listen to a USB port instead of the serial port we use with the AlaMode (which is basically an UNO configured as an RPi shield).

Like, maybe swap these lines in flow_monitor.py?

#The following line is for serial over GPIO
port = '/dev/ttyS0'
#The following line is for serial over USB
#port = '/dev/ttyACM0'

Cheers!
 
thanks for the input guys!

Now i just have to find a good and cheaper source for the flow controls and I will try this out. I like the thought of using BT for it.

My task for today is to get my TFT working as my main display for the pi
 
I'm using the 1/4" ones, but I don't see why you couldn't use the 1/2" ones. I'd actually recommend you use the half inch ones because I had to drill out the 1/4" ones to get it to work without foaming. and 1/2" npt and 1/2" bsp are much better at kinda threading together than the 1/4" which needed quite a bit of Teflon to seal up.
 
The ISP handling the site definitely had shut 'em down - I saw an "account suspended" page when I checked last night.

Someone put another quarter in the slot - for which I say "Thanks guys!"

Cheers!
 
The ISP handling the site definitely had shut 'em down - I saw an "account suspended" page when I checked last night.

Someone put another quarter in the slot - for which I say "Thanks guys!"

Cheers!

Yep, definitely back up now :)
 
I started my install today. Everything was rolling along until I tried to install the chromium browser. This is what I got. Any help would be appreciated

'Chromium-Browser' has no installation canidate
 
ok so I'm downloading the Raspbian Wheezy zip and not the Noobs zip as per step 2 of the build you own instructions???

Yes, and follow the instructions here to install the OS: https://www.raspberrypi.org/documentation/installation/installing-images/README.md

Then jump back to the RPints instructions.

The web site is out of date, and hasn't been maintained in awhile.
There is also a newer thread over on this link: https://www.homebrewtalk.com/showthread.php?t=487694
where this has been answered a few times already.

Cheers,
-Th
 
Alright bout ready to throw in the towel on this one.
Redid the whole process with the other OS. Everything appeared to be rolling smoothly. I got all the way past installing chromium when the instructions required a reboot. It shut down started to reboot then went to a black screen. Nothing will pull it out. Anyone have any ideas?
Should I just wipe the card clean and start again?
 
Alright bout ready to throw in the towel on this one.
Redid the whole process with the other OS. Everything appeared to be rolling smoothly. I got all the way past installing chromium when the instructions required a reboot. It shut down started to reboot then went to a black screen. Nothing will pull it out. Anyone have any ideas?
Should I just wipe the card clean and start again?

Marginal power supply?
Bad HDMI cable?
Cheap SD card?

Could be any of those. If you try again, use a different card for now (to eliminate one of the problems). What are you using as power supply?

Cheers,
-Th
 
Everything was purchased off of Amazon through the links on raspberry pints for wo flow meters.
I'll give it a another shot tomorrow with a different card.
What's the minimum size card I'd need? The last one was a 16g
 
16gig is plenty, it'll run on a 4gig card.

If you got an iPhone, the little square chargers work well as power supply.

Cheers
-Th
 
Since I run my rpints on a tablet and I don't use the flow meters I wanted a cheap and dirty way to track pours. I think I may have mentioned in this thread before that I was working on some touch controls. Here is the first thing I've implemented:

http://brewingintheburgh.com/raspberrypints/

Tap (or click) on any row and a popup will appear allowing you to select how much you are pouring with a slider. Hit Pour and the amount you entered will be subtracted from the amount remaining in the keg. Simple and should at least give you a general idea how much you have left in the kegs.

If anyone is interested I will share the code.
 
Nice. Before the flow meters were an option (and I bought them) that was something I was wanting. Would still be nice for those times that for one reason or another the flow meters are out of commission (ahem... they come unplugged due to shoddy redneck rigged wiring. I really need to fix this)
 
Very nice! :mug:

Any chance you could write up a "How To" for the gui changes?
There've been a couple of similar layouts buried in the bowels of one of the R'Pints threads, it'd be great to have one more current...

Cheers!
 
Very nice! :mug:

Any chance you could write up a "How To" for the gui changes?
There've been a couple of similar layouts buried in the bowels of one of the R'Pints threads, it'd be great to have one more current...

Cheers!

Thanks. I plan to post the code when I have it finished, and I'll see if I can put together a quick "How To".

Nice job KCBrewer! Ditto on request for code. I like my dual column layout, but I like yours too! I'd like to try it out. :)

Thanks. Your version was one I liked a lot when searching through here. It basically requires changing it from one loop that fills from each row of the database to a separate loop for each field of the database, plus some CSS changes.
 
I know I inquired about this a little while ago, but I was still wondering if anyone was able to split the display vertically to basically have two different keezers on display.
Ex. I have 2 different keezers so I would like to put "basement keezer" after tap #4 to show that these taps are in the basement vs. upstairs keezer.

I attached a picture of what JonW has, but was hoping to edit the index.php to do this vertically instead of horizontally.

Thank you for any input.

beerboard1.jpg
 
Back
Top