Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Switching a vending machine with a microcontroller

Status
Not open for further replies.

Microemission

Member level 3
Joined
Jan 4, 2005
Messages
59
Helped
4
Reputation
8
Reaction score
0
Trophy points
1,286
Activity points
619
I'm working on a project that will consist on switching a Vending machine on and off with a IR remote using a Microcontroller.
The schematic for the circuit is attached.
I need to know what other additional protection will I need when I switch on the relay, like for example switching it on when a zero of the voltage is detected or some other additional protection for the high voltage side....
 

Sorry for that I made a mistake with that ULN. I thought it has a different interial structure.

Swiching with zero is a good idea for heavy loads when high current can burn your fuse, and cause voltage drop.

You plan to use the rest of ULN ? Maybe a simple MOSFET + diode will do better?
 

Your circuit looks fine. The ULN2003 connection looks fine. Of course pin 8 is not shown here but it must be connected to GND. You dont need an external diode. The ULN already has the diodes built in, that is why pin 9 must be connected to 12 volts as in your design. The cathodes of all the internal diodes are connected to pin 9. If you are not using the rest of the ULN you could use a simple transistor such as a BC237 but then you will need to put a diode in reverse across the relays coil. Also make sure that the 12 volt to the relay and the gnd line to the ULN are connected directly to your battery. Do not connect the ULN gnd line to any other part of your PCB or else you will introduce electrical noise to your circuit. Also check out a data sheet for the 7805 regulator. It could do with a capacitor on the input and the output. In addition put a 0.1u capacitor across the power lines of the cpu. I have not checked the data sheet for your cpu but I think that it may require to small capacitor (pf range) between the legs of the crystal and gnd. Check CPU data sheet. Check out cpu requirements for the reset while you are at it :)
 
Tkx davidgrm!
I will be using the rest of the ULN to switch on a fan in the case, for it to cool the circuit. I have a ton of those lying around so that's why I'm not using individual transistors;)
All the rest I have done in the circuit I mounted but I forgot to put on the schematic I uploaded earlier.The one attached it's more accurate to the circuit I've built.

Can you please explain this part better?
Do not connect the ULN gnd line to any other part of your PCB or else you will introduce electrical noise to your circuit
I'm using the same ground for all the circuit...that is common to 7805, 7812 and the AT, am I doing something that can induce electrical noise?

But the thing that concerns me most, the 220V relay switch...
I've implemented a simple AC zero cross detection circuit that uses a diode and a resistor, so that the Microcontroller only turns on the relay when a zero of the AC tension is detected.
What else can I do to protect and secure the 220V switch on the relay?
It's a 16 Amp relay and I don't want to take risks...
 

Regarding the gnd. Connect the gnd going to the uln directly to its source eg the gnd pin of the 7805 regulator. The gnd to your logic ic's will also be connected here. This will look like a star with the gnd pin of regulator being the centre.If for example you connected the uln gnd to a gnd point that runs across your pcb supplying the ic,s and then arriving at the regulator the electrical noise generated by the relay switching will interfere with the other components. The zero crossing detector will most likely not be of much help with a mechanical relay being used. If this is just to check is power is there then it does not matter.
 

vending machines

Thanks for sharing the information with us.I also want the some suggestion regarding to the switching a vending machine with a micro controller. if you know any thing about this so tell me.

vending machines
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top