Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Designing a vending machine

Status
Not open for further replies.

Thomas Collins

New Member
My company is looking into designing and building a vending machine for a specific use. My first goal is to figure out which embedded microprocessor system to use that would suit best. I will explain the requirements that we want for this machine so perhaps this would make a more clear choice of system to pursue.
The vending machine needs are as follows thus far.
6 door lock control lines
4 actuator control lines to control 2 PWM motors
2 carosel lock lines
4 binary weighted lines to read the position of the carosel. The carosel will encompass 24 cell locations with product in it to be selected by keypad.
2 lighting control lines
2 sensing lines to verify a cell has product in it. Likely infrared sensing.
1 line to turn on security camera system for recording transactions.
? how ever many lines a keypad needs.

We also want this vending machine to have a touch screen and credit card/crypto currency payment system as well as keep track of inventory over the internet to a central Ip address. This payment system will likely be purchased and interfaced into whatever embedded processing system we wind up developing on.

I started looking down the pic microchip line and Arduino but I think this project would require numerous chips to be set up for various different purposes such as the keypad, motor controllers, another for the various lines. Also thinking a combination of embedded systems because some are more suited to particular purposes such as the rabbit system, fairly cheap to at 45 dollars for the core.

I’ve been looking at the latest rabbit system as it has internet wifi and Bluetooth and video capabilities with 40 I/O lines for control programming.

I’m sure there are plenty more possibilities but I’m fairly new at using an embedded system for controlling anything. Any input to which way to go with what embedding system or systems appreciated .
 
I saw my first vending machine today that had a touch screen for 3 digit product entry, so a real keypad isn't a requirement. It also seems to allow multiple transactions before giving you change.

Check out the Anaren Atmosphere package: https://www.anaren.com/iot/

I've done 4 position sensing using a Small PCB with hall sensors on them and studs with magnets on them (Forgot who made them). this was a 4 position filter wheel. The edge contained holes for a roller microswitch. So, I could do is filter moving; Move filter; Is filter moving; remove control and it would stop on it's own and I could determine the position.

You might be able to get away with using grey code and essentially that is read while the tray is in motion. Grey has one bit changing at a time. For a valid "next position" one bit has to change. Once you have the desired position-1 found, put the system in auto-stop mode and then check after it's stopped.

Re-think your carosel:
4 bit grey encoded input, 1 move motor output, 1 motor out of index mark. e.g. the system will move to the next index mark if the microswitch moves out of the index mark briefly. The computer doesn't have to stop the carosel.

Move to next position is different than move to pos #20.

I used a synchronous motor which stops instantly.

Are you sure you want "product in it" or "product dispensed" or both. I recent saw a vending machine with that option too. No product dispensed. Refund.
 
I will bring the keypad up at the next meeting as overkill and we should eliminate it with the touch screen thanks for that. We would only be a product in it situation. The carosel will be 3 levels with 8 cells per level so we would be moving it 45 degrees per cell. The speed of movement for the carosel won't be fast per say and can't be too fast as product would move around in the cell. The carosel is driven by a PMW motor/linear actuator which is set for a specific distance each time it is energized. We presently have a a locking mechanism which has plus minus a few degrees adjustable to lock in the carosel so it can't be turned by hand by a customer when one of the doors are open. It is basically a pointed solenoid approx 1/2 inch dia that will drive into holes in the carosel kind of like a sharp pencil shape that will move the carosel slightly either way as it lines up with the hole. The top of the carosel will be using 4 magnets on each of the top frame spokes to read position as they will be binary weighted. At this point I'm thinking to use a pic for most of the basic machine control and interface with a rabbit for the internet and driving the touch video screen. I have to look into the rabbit more and figure out the interfacing of the touch screen as I've never worked with a touch screen system yet. Thanks for the idea of touch screen to eliminate the keypad... there are 3 of us at work on this and we were all thinking just a video screen and keypad.
 
Your PWM method might be more problematic than my idea.

Read about Gray Code here: https://en.wikipedia.org/wiki/Gray_code

With DC motors, over run can exist.

The standard car door lock actuator using two relays does brake the motor when de-energized.
That might be better than a solenoid with a spring to return. https://www.walmart.com/ip/Car-Auto...38760&wl11=online&wl12=48518051&wl13=&veh=sem Basically a motor that can push and pull.

Another possibility is worm drive. You can't move it by the shaft.
 
4 binary weighted lines to read the position of the carosel. The carosel will encompass 24 cell locations with product in it to be selected by keypad.
Maybe I missed something here but 4 bits binary can only represent 0 to 15 - you need 5 for 24 locations.

Mike.
 
Good point! i think the OP/TS said every 45 degrees which is 8 positions or 0-7 although I probably would not use 0.
 
Last edited:
the binary weighted input set up on the spokes for each cell at the top of the machine only need to address 8 positions. The 3 levels of the carosel create the 24 cells. We will have 3 doors to present product to the customer and only allow one to be unlocked when the customer chooses what he wants by input of level A1 , A2, A3 ....A8 etc or B1, B2, B3 ....B8... etc and also C1... C8. As for the carosel lock we do have a sample of a PWM linear actuator that uses a screw drive from Progressive automation out in Vancouver Canada. We also use the same thing to move the carosel it's just much longer and it stops up with very little play. We likely will use the PMW for the carosel lock as well. The solenoid did get pinched once and wouldn't retract so a motor drive I think will overcome some slight resistance.
 
So we met with our first touch screen company this morning and found out a few things. Industrial level touch screens are expensive and are only good for likely 3 to 5 years in a vending machine use. This sheds a whole new light on things. Our team has decided to use a raspberry pi 3 as our core.
 
Is that a good or a bad thing? Do you expect the same level of use as a "candy" vending machine? They replaced the membrane keypads at a local gas station. I swear they haven't lasted 6 months. Some are real push-buttons too. They seem to work.

Staples used an Android platform for their self-service copiers. The interface is an Android tablet.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top