0

nano brewery building an automated filling rig
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

nano brewery building an automated filling rig

by burrito_poots on Thu May 30, 2019 5:16 pm

Hi all,

I was hoping I could pick your brains on what brain to pick. As the title says, this is for a semi-automated beverage filling machine (think pico-brewerys and coffee shops).
I’ve actually built a full working machine that we use ourselves — literally did 500 cans earlier today on it — the thing is, I control the entire thing with a lego mindstorms Kit because speed was more important than making a polished machine.

My needs:
    ability to control three (x3) solenoid valves
    very simple display add on for listing timing of main program (setting your filling time is the one thing customers will need to customize)
    Buttons for controlling simple UI on display

I don’t need any sort of WiFi/Bluetooth/radio connectivity. I need to operate three solenoid valves total: one to lower/raise the filling head into the cans, one to open/close a co2 purge line, and one more to open/close the filling head nozzle.
I need to be able to connect one proximity sensors (with the mindstorms Kit, I’m using an IR sensor to detect when a can is in the filling station, telling it to then run the filling cycle program). Unfortunately, I honestly have no idea where to start. my goal is to have as plug and play as possible here with the lowest learning curve. I would rather pay $30 for a board that requires less hands on customization as opposed to getting a bunch of smaller things and trying to get them all in in sync. However, I also know this will still take a lot of work, but I'm certain this community knows how to start with the least amount of bumps and bruises :)

I've looked at the feather line, they seem really modular and easy for someone like me, as well as raspberry pi stuff. What would you guys suggest here for doing the bare minimum of my needs with the least amount of steps involved? I'm trying to make this thing as simple as I possibly can. My best guess right now is to get one of the Adafruit feathers with the TFT + button feather wing stacked on top, with this along with three of the relay feather wings all grouped onto a Adafruit Quad Side-By-Side FeatherWing Kit with Headers, that way everything plugs in fairly compact. Would this be a pretty good start or am I committing some sort of faux pas here?

Thanks in advance :) excited to get my hands dirty in this area.

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Thu May 30, 2019 5:33 pm

My best guess right now is to get one of the Adafruit feathers with the TFT + button feather wing stacked on top, with this along with three of the relay feather wings all grouped onto a Adafruit Quad Side-By-Side FeatherWing Kit with Headers, that way everything plugs in fairly compact.

That is a good start. Although if two or more of the relays need to be actuated at once, you will be putting significant load on the 3.3v regulator to energize the coils. A more efficient solution would be 3 N-channel power MOSFETs on a proto-wing to drive the solenoids - https://www.adafruit.com/product/2884
You would also need a kickback protection diode wired in parallel to the solenoid coil - https://www.adafruit.com/product/755

What kind of IR proximity sensor? Reflective? Break-beam? Rangefinder? Time-Of-Flight? We have plenty of options there:
https://www.adafruit.com/product/2167
https://www.adafruit.com/category/57

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Re: nano brewery building an automated filling rig

by franklin97355 on Thu May 30, 2019 5:36 pm

Are you planning to sell this to brewers that want functionality over glitz or the "shiny" end user group?

franklin97355
 
Posts: 21215
Joined: Mon Apr 21, 2008 2:33 pm
Location: Lacomb, OR.

Re: nano brewery building an automated filling rig

by burrito_poots on Thu May 30, 2019 5:53 pm

adafruit_support_bill wrote:
My best guess right now is to get one of the Adafruit feathers with the TFT + button feather wing stacked on top, with this along with three of the relay feather wings all grouped onto a Adafruit Quad Side-By-Side FeatherWing Kit with Headers, that way everything plugs in fairly compact.

That is a good start. Although if two or more of the relays need to be actuated at once, you will be putting significant load on the 3.3v regulator to energize the coils. A more efficient solution would be 3 N-channel power MOSFETs on a proto-wing to drive the solenoids - https://www.adafruit.com/product/2884
You would also need a kickback protection diode wired in parallel to the solenoid coil - https://www.adafruit.com/product/755

What kind of IR proximity sensor? Reflective? Break-beam? Rangefinder? Time-Of-Flight? We have plenty of options there:
https://www.adafruit.com/product/2167
https://www.adafruit.com/category/57


Thanks so much for the helpful reply! I had assumed that the feather board would struggle to do three of the relays outright -- is there any sort of guide you know of offhand for getting that wired up on the mosfets / Proto-wing solution? Also, some solenoids have some sort of diode wired onto the actual solenoid where you hook the DC power up, from my previous experience this was to keep the coils actuating as fast as possible -- I believe it was called either a snubber circuit or scrubber circuit with the diode and I think a resistor of some sort -- is this the same thing and if so, would the one on the solenoid be fine (if it comes with one pre-installed) or would I still need to add this?

For IR sensors, I've been looking at either the time of flight ones or the VCNL4010 Proximity/Light sensor -- the time of flight seems overkill to me. I just need a simple sensor to tell me if a can is in front of it or not down a small can-chute path, so fairly close.

Again, appreciate all the wisdom so far!

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by burrito_poots on Thu May 30, 2019 5:57 pm

franklin97355 wrote:Are you planning to sell this to brewers that want functionality over glitz or the "shiny" end user group?


Just simply the brewers that want functionality :) but unfortunately for this sized customer (nano or pico brewery and other similar sized beverage startups) there's not much offered and if it is, its usually pretty low standards anyways. The filling head is where you want to spend your money on, we'll be using all stainless for that and a valve-in-tip design, so as long as that is well done and the machine works, it can look like an ugly pig when in use.

A good example of what some breweries larger than us legit use: https://imgur.com/a/dZZ6wEf

I'm not sure if I want to cry or to laugh. Outside of that, most our size use a Blichmann Beer Gun -- basically a hand operated valve-in-tip (meaning bottom up filling = low oxygen pickup) filling gun. We actually used these to begin with, and then rigged this up on our very first filling rig we built, just with a pneumatic system that would trip the "triggers" on the gun when it lowered to a certain point hitting a stop.

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Thu May 30, 2019 6:08 pm

The circuit is as below:. The kickback/snubber diode in parallel to the solenoid is to protect the rest of the circuit from the reverse voltage inductive spike that occurs when you de-energize the coil. If your solenoid valves already have one, you do not need another.

The VCNL4010 is a good choice. Although these Sharp sensors have quicker response and a simple digital output, so they are easier to program. They come in 2 distance ranges:
https://www.adafruit.com/product/1927
https://www.adafruit.com/product/3025

Image

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Re: nano brewery building an automated filling rig

by burrito_poots on Thu May 30, 2019 7:02 pm

adafruit_support_bill wrote:The circuit is as below:. The kickback/snubber diode in parallel to the solenoid is to protect the rest of the circuit from the reverse voltage inductive spike that occurs when you de-energize the coil. If your solenoid valves already have one, you do not need another.

The VCNL4010 is a good choice. Although these Sharp sensors have quicker response and a simple digital output, so they are easier to program. They come in 2 distance ranges:
https://www.adafruit.com/product/1927
https://www.adafruit.com/product/3025

Image


Woooot! Less wiring I have to do the happier I am, that is great news. I'll definitely be sticking to those solenoids I found then with the snubber diode built in. Also those sharp sensors sound like a much better option and perfect for the distance detecting I need, thank you for pointing me to those.

As far as the Mosfet setup to power everything, do you have any suggested reading material for that? Besides the programming, that seems like the last piece of the puzzle here that I need, assuming all of my components can hook up to the same main board/brain?? That also reminds me, still curious on which feather board to start with, there's so many options and I've no clue how to guesstimate that for this specific project. Your insight would be really appreciated :)

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Thu May 30, 2019 7:20 pm

Not much really to the MOSFETs. You connect the "Source" pin to GND. The "Drain" pin to one terminal of the Solenoid and the other terminal of the solenoid to your supply voltage (typically 12v-24v - depending on the solenoid). The "Gate" pin of the MOSFET connects to a digital pin on your processor. You set that pin HIGH to turn on the MOSFET and actuate the solenoid.

The Sharp sensor needs just a digital pin. The TFT wing will make use of the SPI and I2C buses of the processor.

If you are OK programming in Arduino language (a derivative of C++) you have plenty of choices. If you prefer something like Python, you are limited to the "Express" Feather processors like the M0 or M4.

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Re: nano brewery building an automated filling rig

by burrito_poots on Fri May 31, 2019 2:34 am

adafruit_support_bill wrote:Not much really to the MOSFETs. You connect the "Source" pin to GND. The "Drain" pin to one terminal of the Solenoid and the other terminal of the solenoid to your supply voltage (typically 12v-24v - depending on the solenoid). The "Gate" pin of the MOSFET connects to a digital pin on your processor. You set that pin HIGH to turn on the MOSFET and actuate the solenoid.

The Sharp sensor needs just a digital pin. The TFT wing will make use of the SPI and I2C buses of the processor.

If you are OK programming in Arduino language (a derivative of C++) you have plenty of choices. If you prefer something like Python, you are limited to the "Express" Feather processors like the M0 or M4.


For clarification, please correct me if I'm wrong, but the mosfet setup you're suggesting here completely replaces my need for the relays I mentioned I assume, and is not (what I initially thought) some intermediary/supplemental going to my aforementioned relay?

Edit: After some searching and finding this very beginner friendly explanation here https://oscarliang.com/how-to-use-mosfet-beginner-tutorial/ I feel pretty confident you we're saying that the MOSFET would replace my relay AND would get around the issue of my board also struggling to operate 3 switches on the original idea of a relay -- if you could confirm this last bit that would be great. Do you have suggestions on what type of MOSFET to get? I assume it would be based on the board logic's voltage (from what I have gathered, these either push out 3.3v or 5v depending on the board, so if that's the case would each MOSFET need to be rated at that voltage? Would lower work? I couldn't really find much that made sense on how to choose a MOSFET, the initial searches were a little confusing for me, but I'll keep digging in the meantime. Thanks!

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Fri May 31, 2019 6:29 am

I feel pretty confident you we're saying that the MOSFET would replace my relay AND would get around the issue of my board also struggling to operate 3 switches on the original idea of a relay -- if you could confirm this last bit that would be great. Do you have suggestions on what type of MOSFET to get?

That is correct. And the N-Channel Power MOSFET I forgot to link above is the device of choice: https://www.adafruit.com/product/355
Most MOSFETs need a fairly high gate voltage to fully turn on. This particular one has been optimized for use with relatively low logic-level signals. 5v is ideal, but they work pretty well at 3.3v too.

MOSFET datasheets are a bit of a challenge to read. The parameter of interest here is Rds(on) - which is the resistance between the Drain and Source pins when the device is turned 'on'. But there are many shades of 'on - depending on the Vgs (Voltage between Gate and Source pins)

This one has a Rds(on) of about 13 milli-ohms at a Vgs of 4.5v. That means there is very little voltage drop (and associated heating) through the MOSFET. So, you can switch fairly high currents without the need for a heat-sink.

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Re: nano brewery building an automated filling rig

by burrito_poots on Sat Jun 01, 2019 9:46 pm

adafruit_support_bill wrote:
I feel pretty confident you we're saying that the MOSFET would replace my relay AND would get around the issue of my board also struggling to operate 3 switches on the original idea of a relay -- if you could confirm this last bit that would be great. Do you have suggestions on what type of MOSFET to get?

That is correct. And the N-Channel Power MOSFET I forgot to link above is the device of choice: https://www.adafruit.com/product/355
Most MOSFETs need a fairly high gate voltage to fully turn on. This particular one has been optimized for use with relatively low logic-level signals. 5v is ideal, but they work pretty well at 3.3v too.

MOSFET datasheets are a bit of a challenge to read. The parameter of interest here is Rds(on) - which is the resistance between the Drain and Source pins when the device is turned 'on'. But there are many shades of 'on - depending on the Vgs (Voltage between Gate and Source pins)

This one has a Rds(on) of about 13 milli-ohms at a Vgs of 4.5v. That means there is very little voltage drop (and associated heating) through the MOSFET. So, you can switch fairly high currents without the need for a heat-sink.


I believe this is my last hardware question for you, but as far as mounting the actual MOSFETs shown to the prototyping board? Do the three pins just slot straight down, or would I use wires and such? I'm hoping I can fit three of those cleanly on that one board, but I'm clueless on mounting those and would really appreciate the tips/advice here :)

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Sun Jun 02, 2019 5:30 am

The pins can be inserted through the holes in the proto-board and soldered. Then you can use some hookup wire to make connections to them.

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Re: nano brewery building an automated filling rig

by kcl1s on Sun Jun 02, 2019 6:33 am

If you are not familiar with working with proto boards do a google search on protoboard solder bridging or perfboard solder bridging and you will find some examples of the technique. This forum question has some good photos of a few techniques https://electronics.stackexchange.com/questions/55236/how-to-make-traces-on-an-universal-pcb Look on the back of the doubler, quad or proto wing to see the already made connections Adafruit has made. They include a solder hole for each pin and a row of holes for v+ and gnd.

Fellow hobbyist
Keith

kcl1s
 
Posts: 1291
Joined: Tue Aug 30, 2016 12:06 pm

Re: nano brewery building an automated filling rig

by burrito_poots on Sat Jun 29, 2019 6:00 am

adafruit_support_bill wrote:The pins can be inserted through the holes in the proto-board and soldered. Then you can use some hookup wire to make connections to them.


Hey Amigo, would this arrangement be fine regarding the MOSFETs being stacked so close together like this? I'm assuming having them flipped back to back with the large metal tabs touching or close to touching would obviously be frowned upon/accident waiting to happen, but in this configuration they're touching front-to-back. Since I have the proto space one the MO Express to potentially fit all three, I'd like to see if that's doable. If not, I can easily stack my OLED feathering on top of my MO express, opening up the a whole wing-sized canvas on the other side of the feathering Doubler, but I wanted to see what the experts here thought first. Thanks!

IMG_7461B.jpg
IMG_7461B.jpg (901.68 KiB) Viewed 128 times

burrito_poots
 
Posts: 64
Joined: Thu May 30, 2019 5:02 pm

Re: nano brewery building an automated filling rig

by adafruit_support_bill on Sat Jun 29, 2019 6:51 am

Electrically, there is no problem stacking them like that. But heat dissipation could be an issue - depending on how much current your solenoids are pulling. Having a little more space between them for air-flow would be a good idea.

adafruit_support_bill
 
Posts: 74646
Joined: Sat Feb 07, 2009 10:11 am

Please be positive and constructive with your questions and comments.