• Please visit and share your knowledge at our sister communities:
  • If you have not, please join our official Homebrewing Facebook Group!

    Homebrewing Facebook Group

Raspberry Pi Control Box

Homebrew Talk

Help Support Homebrew Talk:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

beer2d2

Member
Joined
May 5, 2016
Messages
22
Reaction score
6
This is for all you experienced builders out there. Putting together a controller based on Raspberry PI. I'm not too good with schematics but i can draw.. any comments on this? is it done correctly?
Pi Box.png
 
I don't see any mechanical switches. Solid state relays do not remove voltage from the element outlets. They only restrict max current to a few milliamps. SSR's can also fail in the on mode, in which case having a contactor in series with the SSR gives you a way to galvanticly isolate the incoming power from the element outlets.

Something else to think about: what are your SSR's going to be doing while the RPi is booting up?

Brew on :mug:
 
That's good info thank you. I am following this diagram from the craft beer pi website. I'll have to look into how to implement a mechanical switch.
wiring.png
 
(first.. sorry, I know its a mess. I hope its at least a little followable) ok, so now.. the power comes directly into a relay and the coil is actuated by a key switch. then I put a relay in for each 240v element, and switched the coils independently so I can turn the off manually if I wanted. I would also probably switch each side of the 110v outlet independently as well.

I am not understanding your question though as to what the SSR will be doing when the RPI is booting up. I'm guessing your saying that the PI will send voltage to the GPIO header? I wouldn't think they would, but I'm not an expert. i guess, as long as the manual switches are off for the elements then nothing would happen.
Pi Box v2.png
 
Last edited:
I strongly suggest adding fuses to the 110V (120V?) sockets. Without fuses, those wires could potentially attempt to carry a load of the breaker (50A?) connected to the power in on the box. A short or overload on the 110V line would very likely melt the 110V and possibly cause a fire. You can purchase in-line fuse holders with 10A (or so) fuses in them, though I think the panel mount fuse holders from Buss are a better and safer bet.
 
I strongly suggest adding fuses to the 110V (120V?) sockets. Without fuses, those wires could potentially attempt to carry a load of the breaker (50A?) connected to the power in on the box. A short or overload on the 110V line would very likely melt the 110V and possibly cause a fire. You can purchase in-line fuse holders with 10A (or so) fuses in them, though I think the panel mount fuse holders from Buss are a better and safer bet.
good call.. ill implement that as well
 
Second version looks much better.

You can leave out the "main power" relay, and just connect the output of the key switch to the 12V power supply, the 120V outlets, and in series with the element relay/contactor control switches. This only works if you expect a total 120V load of less than 10A. A typical Chugger pump draws about 1.4A.

Brew on :mug:
 
(first.. sorry, I know its a mess. I hope its at least a little followable) ok, so now.. the power comes directly into a relay and the coil is actuated by a key switch. then I put a relay in for each 240v element, and switched the coils independently so I can turn the off manually if I wanted. I would also probably switch each side of the 110v outlet independently as well.

I am not understanding your question though as to what the SSR will be doing when the RPI is booting up. I'm guessing your saying that the PI will send voltage to the GPIO header? I wouldn't think they would, but I'm not an expert. i guess, as long as the manual switches are off for the elements then nothing would happen.
View attachment 705667

Indicator LED lamps wired between the two "hots" after the relays/contactors feeding the 240V elements are also suggested. This way, you will know when the elements are active and could help to prevent dry firing and other mishaps.
 
Removed the main power relay and put the element switches in series with the key switch, as well as the 12v power supply and the 120v receptacles. also added 10 amp fuses for the 120v receptacles. Added lamps as well.
Pi Box v4.png
 

Attachments

  • Pi Box v3.png
    Pi Box v3.png
    282.3 KB
Removed the main power relay and put the element switches in series with the key switch, as well as the 12v power supply and the 120v receptacles. also added 10 amp fuses for the 120v receptacles. Added lamps as well.
View attachment 705791
You might want to move the element indicators to after the relays and SSRs to show they are active only when the relays are on. Otherwise, this is looking very nice. Also, the fan may be unnecessary if you use the proper heat sink. I purchased an Auber panel with an associated heat sink and on my panel, I've never noticed the heatsink getting beyond warm. It's one less item to worry about and then you could just use a USB 5V power supply to power the RPi. My panel is only a single element/30A panel, but they sell panels with heatsinks rated for 50A/240V as well.
 
Last edited:
THINK this is the final version. It has sure went through a bit of change.. lol, I want to send shout out to both CraigMW, as well as Doug293cz! You guys really helped out tha
Pi Box v5.png
nk you!
 
You will want to run your indicator lamps in parallel with the output sockets rather than in series. So, for the 240V outlets for the heating elements, connect each LED indicator to the black and red wires that lead to each socket. For the 120V outlets, connect the LED to the black hot wire and the neutral bus. If you wire it as pictured, you will quickly fry your indicator bulbs when a load is connected.
 
Last edited:
You will want to run your indicator lamps in parallel with the output sockets rather than in series. So, for the 240V outlets for the heating elements, connect each LED indicator to the black and red wires that lead to each socket. For the 120V outlets, connect the LED to the black hot wire and the neutral bus. If you wire it as pictured, you will quickly fry your indicator bulbs when a load is connected.
like this?
Pi Box v6.png
 
This looks good. Just make sure that your red and black wires between the relay/contactor and 240V outlet connects to the led indicator in parallel. One way to do so is to connect wires from the outlet side of the contactor directly to the LED. Most 240V contactors have multiple connectors for each output pole. You also might put the 120V LEDs on the other side of the fuse so that the failure to see an indicator when switched on would tell you that a fuse was blown.
 
This looks good. Just make sure that your red and black wires between the relay/contactor and 240V outlet connects to the led indicator in parallel. One way to do so is to connect wires from the outlet side of the contactor directly to the LED. Most 240V contactors have multiple connectors for each output pole. You also might put the 120V LEDs on the other side of the fuse so that the failure to see an indicator when switched on would tell you that a fuse was blown.
Ideally the fuses are placed where the wire size drops from the incoming power source. If you place a single 10A fuse on the unswitched side of the main power switch, you are covered.

Brew on :mug:
 
Ideally the fuses are placed where the wire size drops from the incoming power source. If you place a single 10A fuse on the unswitched side of the main power switch, you are covered.

Brew on :mug:
Ok. Good to know
 

Attachments

  • Pi Box v7.png
    Pi Box v7.png
    192.3 KB
Last edited:
The way you have wired the "element firing" lights, they will come on when the RPi is telling the SSR's to send power to the elements even if the switches controlling the element contactors are off. And, there is a good chance that due to the off state leakage current of the SSR's, that they will be on all the time (although brightness may vary.) Those lamps should be moved to the switched side of the element relays/contactors.

Brew on :mug:
 
The way you have wired the "element firing" lights, they will come on when the RPi is telling the SSR's to send power to the elements even if the switches controlling the element contactors are off. And, there is a good chance that due to the off state leakage current of the SSR's, that they will be on all the time (although brightness may vary.) Those lamps should be moved to the switched side of the element relays/contactors.

Brew on :mug:
hmm.. i had that configuration above (picture with the amber LED's and was suggested to move to other side of relay in order to tell if the contact was actually closed and firing the element. i guess you could still have power across the coil and the contactor be shorted open and the lamp would be on but no power to the element. What's the best side to error on?
 
20201109_172851.jpg20201109_172927.jpg20201109_172920.jpg20201109_172905.jpg

I built something similar. The element rocker switches control the 3.3V DC signal from the RPI (which I have custom NodeJS web server with PID running on the Raspberry Pi).

I don't have any fuses, but it is attached to a GFCI 60A breaker. Maybe I should add fuses. I ran the 120V line to the contactor through both the key switch and the main power switch on the front power - but I think hindsight that it's overkill.

Mistakes:
  • Original SSRs would NOT TURN OFF after they got hot! Very scary on the kettle getting a boil-over. I eventually found ones that I haven't had any trouble. https://www.amazon.com/gp/product/B00E1LC1VK/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 I recommend a pull-down resistor ~10K for each 3.3V DC signal from the RPi.
  • I put the 30A 240V plugs too close together. The large diameter plug on the cord interfered and I had to re-drill the hole location.
  • OneWire temperature sensors (DS18B20) needed a real-time clock, so I had to make custom ATTiny85 microcontrollers with I2C communicating back to the RPi (calculate pull-up resistors as the ATTiny85 has too-high resistance build-in pull-up resistor).
  • Attaching btween 1-3 OneWire temp sensors required lower pull-up resistor or I got erroneous readings. I think I settled around 2K instead of 4.7K. I don't recommend using OneWire temperature sensors for the only benefit that you can plug any temp sensor into any RJ45 connector.
  • I connected a 7ft 6/3 power cord to my box. Very annoying to move the box around with a 10lb cord attached. I recommend putting a 240V 50A plug on the box itself.
Suggestions:
  • Use 3.5mm Audio cables/connectors for the temperature sensors at both ends - I try to walk off with a hot/heavy mashtun and only to realize it's still attached (RJ45s do not pull out!)
  • I use 5500 watt ULWD elements. For a 14 gallon batch a 50-60% duty on 240V will keep a rolling boil indoors. I hard-coded a separate boil power setting when kettle temp is over 205°F to prevent boil-overs. Defaults to 50% and does not use PID over 205°F, but is configurable via my web interface touchscreen.
  • Get a screw terminal hat for the RPi - super convenient!
Notes:
  • I used a dual port USB power for the dual fans (one in, one out) and the RPi. The 1/4" female spade crimp connectors fit over the 120V prongs very nicely.
  • As mentioned in previous comments, the SSRs need the two terminals shorted (as in with elements) because they bleed a small amount of voltage and will dimly light your signal lamp when the power cords are not connected to the elements. I don't mind it as it's super dim and not confusing with "ON". Also tells me that the 30A 240V cords are not plugged into the kettles.
-Joel
 
Last edited:
After studying your latest drawing update a bit more, it looks great! Adding the relay after the SSR is a great improvement. If you have auxiliary 120V available, such as a power strip on your brew bench, I wouldn't even bother adding it to your box. Then you could even get away with 6/2 wire since the neutral isn't necessary for anything. USB "wall warts" will take 240V just fine. FWIW, I have my two pumps mounted under my bench to a dual light switch box instead of taking room up in my control box.

-Joel
 
Helpful comments here, just wanted to mention that if this project uses CBPi you should be aware it is no longer actively developed or maintained.
 
Helpful comments here, just wanted to mention that if this project uses CBPi you should be aware it is no longer actively developed or maintained.
hmm, that does pose a situation now doesn't it.. what is the current Raspberry PI solution for brew controller then?
 
hmm, that does pose a situation now doesn't it.. what is the current Raspberry PI solution for brew controller then?
The same hardware will work with many projects, which is a benefit of using an RPi.

CBPi still works as it is, so you can still use it. You might run into some minor bugs or disgruntled users, but it's fine.

If you want something actively developed you could use Node-Red (see Facebook Groups). Pretty popular for home automation/hobby process control, and has a large user and developer base (see Node-RED Forum). Customizable to the point that it's inaccessible to some, but I would say that it's learnable by anyone. It's not programming so much as stringing predefined functions together (e.g. trigger a temperature reading, do a moving average of that temperature reading, then display it as 3 separate functions/nodes wired together in a sequence. Or take the temperature reading and feed it into a PID algorithm in the same way.)

brewblox (Brewblox) looks really nice, but would require another module to use with it.
 
You might want to look into Brucontrol as well if you havent already just as another option that might fit the bill better for growth and support down the road....

Its arduino based and not free but it has a huge amount of people including myself using it. and its reliable, enough so that I use it to control my 3bbl brewhouse at my brewpub and have been for 2 years now. It also has tons of flexibility with being able to control multiple controls and control panels on the same network. I use it to control my chiller and fermenters as well as my show tilt info. it also works with any type of temp probe hardware and multiple relay boards which is nice

I use rasberry pi s for my beer list displays and even with that duty Ive had the SD cards crash twice and need reformatting and one pi unit fail and need a full replacement in the last 2 years.
 
Last edited:
This is araspberry Pi thread. Please take the Brucontrol advertisement and discussion to the brucontrol thread.

I use one main contactor before everything but the Pi computer. I use Pi controlled 5v relays to switch the SSR + contacts as redundancy. Edit: Hosehead control boxes didn't have any external switches, FWIW...

I have used Strange Brew Elsinore software for years. It continues to work great, although it is not fancy. I've used the same SD card for years. If you keep getting corrupt cards, you're screwing it up. I never did any diagrams for my controller, but you can sort of get the gist from photos. View attachment 707124View attachment 707125
Some things never change. You know when I made my last post with my recommendation based on what I use I figured you would chime in again with your incorrect assumptions that I have some affiliation with Brucontrol. Why is it ok for you to make recommendations based on what you have experience with but when I do the same you accuse me of advertising? I mentioned it because he might not be aware it exists or how it works and it always helps to be aware of your options before starting down any path. arduino setups are very similiar to the raspberry pi setups so its worth mentioning, especially when the OP just learned that CBPi is a discontinued piece of software. I have no motivations here other than sharing my experiences with the different setups Ive built and used.
 
Last edited:
Back
Top