HOWTO - Make a BrewPi Fermentation Controller For Cheap

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.
Status
Not open for further replies.
2 Things I never got to work right… modifying any of the analog pins in the code and using a pro micro. the nanos and minis work just fine but something about the micro, wouldn't work for me… 3 years ago so I don't really have a lot of notes on the subject… only that I can tell you, use anything but a micro.

Well, I have taken your advice and given up on modifying the pins. I ripped out an older SainSmart Uno R3 from another project (may it RIP). Flashed it and everything is up and running. Now I just need to get an enclosure and bring it all together. Photos to come once it's done.

Thanks for the help.
 
Fwiw the nano is a what you want if your looking for a small board. probably even cheaper than the micro too. u don't see a whole lot of people use the micro because it's so different than all the other boards. The nano is pin for pin compatible with the uno
 
I updated my brewPi with a new RaspberryPi, and used my plot.ly script again. Not sure if anyone has used it, but it had a typo if you try to cut and paste. I had to add a space on the line that has "beer_data = beer_string.split(';', 9)" before the 9. I fixed it. I also reduced the posting to plot.ly in the cron to every 30 minutes, as they limit you to so many per day(50). Sometimes I wouldn't see my graphs if I had already posted to many. Since the script scans all my 'beers' and I didn't clean the directories up often enough, that causes an issue too. The script also assumes your brewpi data is in /home/brewpi/data/, change that if you need to. Still works great, see below and here: https://plot.ly/~virgil1/228/munich-helles-july-2017/

Code:
#!/usr/bin/python

# Learn about API authentication here: https://plot.ly/python/getting-started
# Find your api_key here(you need to sign up first): https://plot.ly/settings/api
# a few of the pages I read to get things going
# https://plot.ly/python/axes/
# https://plot.ly/python/line-and-scatter-plots-tutorial/
# this page really got me started with the multiple lines in one plot:
# https://plot.ly/python/line-charts/
# I put the script here on my pi:
# /home/pi/brewpi-tools/brewpi_plot_ly.py
# here is the crontab entry I used:
# 0,30 * * * * sudo /home/pi/brewpi-tools/brewpi_plot_ly.py >/home/pi/logs/brewpi_plot_ly.log 2>&1
# the script looks in your /var/www/data/ directory
# it will look for csv files of the same name of the directory and name your graph the same name as your directory
# It skips the "Sample Data", ".gitignore" ,"profiles" and "My First BrewPi Run" directories
# it will print out the name of the graph/directory and the URL when it is done

import os, sys
import os.path, time
import string
import plotly.plotly as py
from plotly.graph_objs import *
import plotly.tools as tls


def read_and_write_graph(whole_path, graph_name):
	graph_name = string.replace(graph_name, '%20', ' ')
	time_stamp = []
	bt = []
	ft = []
	bs = []
	fs = []
	with open(whole_path) as f:
		content = f.readlines()
	
	for beer_string in content:         
		beer_data = beer_string.split(';', 9)
		beer_date = beer_data[0]
		beer_temp = beer_data[1]
		beer_setting  = beer_data[2]
		ignore_1 = beer_data[3]
		fridge_temp  = beer_data[4]
		fridge_setting = beer_data[5]
		ignore_2 = beer_data[6]
		ignore_3 = beer_data[7]
		ignore_4 = beer_data[8] 
		time_stamp.append(beer_date)
		bt.append(beer_temp)
		ft.append(fridge_temp)
		bs.append(beer_setting)
		fs.append(fridge_setting)


	trace1 = Scatter(
		x=time_stamp,
		y=bt,
		mode='lines+markers',
		name="beer temp",
		line=Line(
			shape='linear',
			width=0.4
		),
		marker=Marker(
			size=2,
		)
	)

	trace2 = Scatter(
		x=time_stamp,
		y=ft,
		mode='lines+markers',
		name="fridge temp",
		line=Line(
			shape='linear',
			width=0.4
		),
		marker=Marker(
			size=2,
		)
	)

	trace3 = Scatter(
		x=time_stamp,
		y=bs,
		mode='lines+markers',
		name="beer setting",
		line=Line(
			shape='linear',
			width=0.4
		),
		marker=Marker(
			size=2,
		)
	)

	trace4 = Scatter(
		x=time_stamp,
		y=fs,
		mode='lines+markers',
		name="fridge setting",
		line=Line(
			shape='linear',
			width=0.4
		),
		marker=Marker(
			size=2,
		)
	)
	data = Data([trace1, trace2, trace3, trace4])
	layout = Layout(
		title=graph_name,
		legend=Legend(
			y=0.5,
			traceorder='reversed',
			font=Font(
				size=16
			),
		
		),
		xaxis=XAxis(
			tickmode='auto',
			nticks=6
		)
	)
	fig = Figure(data=data, layout=layout)
	plot_url = py.plot(fig, filename=graph_name)

	print graph_name + " is at this URL: " + plot_url



tls.set_credentials_file(username='YOUR_USER_ID', api_key='YOUR_KEY')

# Open the directory
path = "/home/brewpi/data/"
dirs = os.listdir( path )
file_list = []

# This would print all the files and directories
for file in dirs:
   #print file
   if file != "Sample Data" and file != ".gitignore" and file != "profiles" and file != "My First BrewPi Run":
   	#print "adding ", file
   	whole_path = path + file + "/" + file + ".csv"
   	#print "adding whole path", whole_path
   	#print "last modified: %s" % time.ctime(os.path.getmtime(whole_path))
	#print "created: %s" % time.ctime(os.path.getctime(whole_path))
	read_and_write_graph(whole_path,file)

Munich Helles - July 2017.png
 
Hi guys,

I have searched for an answer for my issue, but after doing a search and looking through 20+ page I haven't found anything.

I am having trouble with updating my arduino through the RPI interface, the link I found doesn't seem to work. Can anyone point me in the right direction.

link that doesn't work - http://dl.brewpi.com/brewpi-avr/stable
 
Hi guys,

I have searched for an answer for my issue, but after doing a search and looking through 20+ page I haven't found anything.

I am having trouble with updating my arduino through the RPI interface, the link I found doesn't seem to work. Can anyone point me in the right direction.

link that doesn't work - http://dl.brewpi.com/brewpi-avr/stable
What exactly is going on that you think you need to upgrade?

I think what you are looking for might be here:

http://docs.brewpi.com/en/latest/after-install/program-arduino.html

Version 0.2.10 is the last Arduino release, dated Apr 23, 2015. It's available here:

https://github.com/BrewPi/firmware/releases?after=0.4.0
 
What exactly is going on that you think you need to upgrade?

I think what you are looking for might be here:

http://docs.brewpi.com/en/latest/after-install/program-arduino.html

Version 0.2.10 is the last Arduino release, dated Apr 23, 2015. It's available here:

https://github.com/BrewPi/firmware/releases?after=0.4.0


My "Stop Script" kept flashing and I read some where that I needed to update the Hex straight from the brew pi interface to program it....

http://docs.brewpi.com/en/latest/after-install/program-arduino.html
 
I'm cleaning off my workbench and have five of Cadibrewers 2.01 BrewPi shields available. Five dollars each plus one dollar for shipping.Email me at jamesw@ tstonramp dot com. Include " "BrewPi shield 2.01" in the subject.
attachment.php
 
Having an issue with the time on my brewpi.

The time in the graph is wrong. It's a little over 13 hours behind the time that is on the pi at the system level. If I open the gui on the OS the time is set correct. The weird thing is if I make a new profile and select "start now" the time is correct. So I'm wondering where the function plotting the graph is getting time from if it's not from the pi? Just for a kicker I have a second brewpi on the same network right next the first and the time is correct? Anyone have any ideas? TIA.
 
The original time stamp was stored with the rest of the record data in the .csv file stored with the named Brew somewhere under /var/www/brewpi/data.

I just checked one of my BrewPis and the stored timestamps are correct.
Not surprised, they always are, but if the TOY clock got screwed up I imagine there would be resulting "time distortions" ;)

Cheers!
 
I am getting this error when programming a brand new arduino Uno:

Log:
Jul 17 2014 17:16:59 Notification: Script started for beer 'My First BrewPi Run'
Jul 17 2014 17:16:59 Warning: Cannot receive version number from Arduino. Your Arduino is either not programmed or running a very old version of BrewPi. Please upload a new version of BrewPi to your Arduino.

I searched the thread and found one other user with this error. He reported that a system shutdown corrected his issue. My was not resolved.
 
Are you sure it's not a clone UNO with the CH340 usb chip set?

I am getting this error when programming a brand new arduino Uno:

Log:
Jul 17 2014 17:16:59 Notification: Script started for beer 'My First BrewPi Run'
Jul 17 2014 17:16:59 Warning: Cannot receive version number from Arduino. Your Arduino is either not programmed or running a very old version of BrewPi. Please upload a new version of BrewPi to your Arduino.

I searched the thread and found one other user with this error. He reported that a system shutdown corrected his issue. My was not resolved.
 
I used Xloader and that seemed to do the trick. At least that is what I thought until I went to apply devices. It finds them all but won't save. Any ideas for fixing the problem. I searched back in this forum and the BrewPi forum but found no advice that worked. It still won't let me load the .hex file from BrewPi itself. The other suggestions seem to be from am older version and had no effect.

***Edit***
I can get all devices recognized! I can get almost all devices saved! I can save any temp probe as a device as long as it isn't labeled "Beer Temp".? It will let me save them as room temp and chamber temp but not beer temp.

**Edit**
Turns out I am stupid! Beer 1 then beer temp! Not Chamber device then beer temp!

Thank you for all your help!!
 
Wow, last time I looked at this thread there were only 524 pages :eek: now over 700 . . . Well done.

Reason I'm back is my BrewPi was fried, well the SD card was when my fridge tripped the RCD, so I needed to rebuild it . . . for some reason imaging it didn't work, probably a bad image. . . as I only have the one PI II B I needed another one to work on, so thought about using an old laptop as a Pi while I sorted out wifi and brewpi on the Pi.

Wheezy goes out of support next year, anyone tried installing BrewPi on Scratch (preferred) or Jessie?
 
Wow, last time I looked at this thread there were only 524 pages :eek: now over 700 . . . Well done.

Reason I'm back is my BrewPi was fried, well the SD card was when my fridge tripped the RCD, so I needed to rebuild it . . . for some reason imaging it didn't work, probably a bad image. . . as I only have the one PI II B I needed another one to work on, so thought about using an old laptop as a Pi while I sorted out wifi and brewpi on the Pi.

Wheezy goes out of support next year, anyone tried installing BrewPi on Scratch (preferred) or Jessie?

Yep, it works.
 
"Scratch"?

I have a test bed RPi2B with Raspbian Jessie that's been running BrewPi, RaspberryPints and my other programs for almost a year now.
There are adjustments needed due to a change invoked by Apache2 to its default DocumentRoot location (used to be /var/www, is now /var/www/html) and the location of the console startup command stuff if needed has moved to the config file /home/pi/.config/lxsession/LXDE-pi/autostart.
But otherwise it runs just like my Wheezy machines...

Cheers!
 
So, has anyone seen a working brewpi (for easily a year) all of a sudden stop tripping the relay? I replaced the relay board and still same thing.

So...
brewpi calls for fridge to come on, and the relay board LED will light up. If I jumper the pins on the 120V (hot/swtiched) side of the relay device turns on. Voltage is coming from the one wire sensors "bus" and they are working fine as well. I don't hear the relay click (but I don't know if I ever did). The whole thing is in an enclosure and static, its my lagering chamber so its been quietly chugging along until, one day it didn't.

any ideas?

Thanks
 
The LEDs use the GPIO output power to light up.
If you're using the SainSmart dual relay board did the relay power jumper fall out or a separate relay power 5V lead fall off?

Cheers!
 
The LEDs use the GPIO output power to light up.
If you're using the SainSmart dual relay board did the relay power jumper fall out or a separate relay power 5V lead fall off?

Cheers!


Go figure the new one was doa. Opened another installed it and all is well.
 
Lost my first Pi - I've had to replace the SD card about three times since 2014 but this time the SD card tests good - all I get is a power light on the Pi. I hope the latest version of Pi works, I'll have through out my backup image and re-image and recreate a new image. Three years isn't bad for a hobby board.. :)
 
Lost my first Pi - I've had to replace the SD card about three times since 2014 but this time the SD card tests good - all I get is a power light on the Pi. I hope the latest version of Pi works, I'll have through out my backup image and re-image and recreate a new image. Three years isn't bad for a hobby board.. :)

As @wbarber69 would say... power supply. I had the same thing happen to mine and all my internet research told me it was the polyfuse. So I was set on replacing it when @wbarber69 told me it was most likely the power supply. Even though I had my doubts, I plugged it into my laptop and it fired right up.
 
As @wbarber69 would say... power supply. I had the same thing happen to mine and all my internet research told me it was the polyfuse. So I was set on replacing it when @wbarber69 told me it was most likely the power supply. Even though I had my doubts, I plugged it into my laptop and it fired right up.

That's easy enough to try - I'll give it a go

EDIT: Tried to different power cubes with the same result. I hope a Model 1 can be replaced with a Model 3.
 
That's easy enough to try - I'll give it a go

EDIT: Tried to different power cubes with the same result. I hope a Model 1 can be replaced with a Model 3.

Replaced with a model 3 no problem. Had to regenerate a new image from scratch but I was able to salvage all my fermentation profiles from the old card. :tank:
 
Testing multiple power supplies is useless unless they are all rated for 2.5a pr greater…
 
I've been having a hard time with setting this up. I'm attempting to set this up on an official arduino uno with rpi 3 running jessie.

http://diybrewpi.wikia.com/wiki/DIYBrewPi_Wikia

https://community.brewpi.com/t/how-...-firmware-for-arduino-with-serial-errors/2489

http://www.silverfoxcrafts.com/2016/10/brewpi-new-jessie-install/

I'm able to get everything installed using the legacy firmware and loading the hex file using xloader. I've tried 3 separate installs now. I'm unable to read my ds18b20 sensor either in raspbian terminal or brewpi in chromium. Any tips appreciated! I'd like to not have to go back to rpi 2/wheezy since that still may not work.

poOfUAmRj
 
The preponderance of problems with ds18b20 probes over the last couple of years was due to folks actually ending up with ds18b20-par probes - which utilize the "parasitic power" paradigm which steals current from the signal wire pull-up to allow a 2 wire connection instead of 3.

BrewPi does not support parasitic mode.

There is a sketch out there that you can load on the Arduino that will reveal whether a probe is a parasitic model or not...

Cheers!
 
Thanks guys, I checked and it does indeed say that my ds18b20 are parasitic. I've ordered the following probes based on one comment in the amazon review saying that it was working with brewpi back in Jan 2016. Fingers crossed that they haven't changed their supplier x.x.

https://www.amazon.com/gp/product/B00EU70ZL8/?tag=skimlinks_replacement-20

I've used these for several builds and they have always worked. That's with strange brew Elsinore, Craftbeerpi and two versions of brewpi.
 
Last edited by a moderator:
Sorry about that hiccup, but you're just one of many folks that got bit over the last couple of years.
Prior to that one could be virtually guaranteed to get a true three-wired "one-wire" probe (btw, how stupid is the whole convention anyway :drunk:).
I have nearly three dozen 3 meter probes acquired over a few years in lots of 5 and never ran into a -par version.

Anyway...feel free to contact the seller to specify you need non-parasitic probes...

Cheers!
 
Hey gang. Have been using my controller for months with no problem. Now it will not activate heat or cool when needed. I am illiterate with this stuff and only got it set up due to the great instructions here. Where is the best place to get advice on fixing my issue?

Thanks!
 
This is pretty much the place for BrewPi issues on HBT.
But you're going to have to provide more info that you have.

Is the script running?
Do you see temperature readings?
Does the "LCD panel" (the box in the upper left corner) indicate cooling or heating or is it sitting in the "Idle" state?
Did you try resetting the Arduino?
After that, did you try rebooting the web host (RPi or other)?

The more info you provide the quicker we can get you up and running again...

Cheers!
 
This is pretty much the place for BrewPi issues on HBT.
But you're going to have to provide more info that you have.

Is the script running?
Do you see temperature readings?
Does the "LCD panel" (the box in the upper left corner) indicate cooling or heating or is it sitting in the "Idle" state?
Did you try resetting the Arduino?
After that, did you try rebooting the web host (RPi or other)?

The more info you provide the quicker we can get you up and running again...

Cheers!

Thanks for the response. I didnt want to post unless this was the place for it. Thanks in advance for the help!

Do you see temperature readings? Yes

Does the "LCD panel" (the box in the upper left corner) indicate cooling or heating or is it sitting in the "Idle" state? It is just idling

Did you try resetting the Arduino? I did not. Is there a reset on it or is this done through the software?

After that, did you try rebooting the web host (RPi or other)? i did reset the RPi. No change.
 
Hey everyone. Been a while since I've posted here.

I had my brewpi working for a couple months then I think my micro SD card became corrupted somehow (wouldn't boot at all).

I tried formatting and reinstalling, but now I can't figure this last part out. I downloaded the latest NOOBS file which installs Raspbian Jessie. I almost got it to work but it won't give me an IP address at the end.

It just says:

"To view your BrewPi web interface, enter http:// into your web browser

Happy Brewing!"

I'm using a wifi dongle. I don't know if that matters. Any ideas?
 
[...]Do you see temperature readings? Yes
[...]It is just idling
[...]

Ok, if you can see both Chamber and Beer temperatures in the gui, this indicates pretty near everything is working.

Yes, there's a reset button in the corner of the Uno near the USB receptacle.
You can push that any time.

I would go into the gui and verify that you (still) have actuators set up for cooling (and heating if you use that). If BrewPi doesn't have any actuators set up I believe it will behave exactly as you're seeing.

Then, set up a simple Beer Constant mode with the temperature goal set above or below the current Beer sensor temperature and see what happens.

You might also check the log file via the gui and see if there are any messages of interest therein...

Cheers!
 
Status
Not open for further replies.
Back
Top