motor control

deleted other post. I'm stuck now and banging my head on wall. CAN i use one 12v wal wart to power: arduino, 3 dc motors, and laser?

Reason is this I had my board done, powered on and the lm7805 vreg got way hot and board shut down. If any1 has ANY ideas please let me know I am stuck as this point.

Maybe use the lm7805 for the arduino, use a lm317 for h bridge, and just power laser from the power source. I took out one lm7805 so was using it for the arduino and the motor supply on hbridge. I can't figure out why it drew so much as each motor draws 200 ma 5v.

Initially the motors actually pull more amps then that. They could be drawing as much as 500mA each but once they are at a steady speed they only draw the 200mA. Its not a good idea to run any motor directly threw the arduino. The I/O pins can only offer 40mA. the motors need to be on a separate power supply. Just be sure that all the grounds from the different power sources are tied together.

If the power inverter gets hot from the 12V source then put a heat sink on it. The LM7805 can easily handle 12V and offer as much as 1A. But the more voltage you put into it the hotter it will get.

Made another board. I made it like you said but tied the grounds together. They share the same Vin from the 12v supply.

Power supply=12v 1500mah 12v=lm7805=arduino 12v=lm7805=motor supply pin on hbridge 12v=laser (current set) coming from same wal wart but splits off to each

+12v supply +| +| +| Ard. Motor. Laser

Tied to ground

Reason why I need one suppy is because I need use one walwart for everything... 3 positive (1 for arduino, one for motors, one for laser) wires going to walwart + and the grounds all tied together... I think this will work but I need make sure.

http://img694.imageshack.us/img694/5752/47792925.jpg

This work?

That should work; I would add heat-sinks to the 7805s, though. Also, does the laser already have a regulator or something (you didn't give any info on it); is it a 12VDC tube-based laser or something like that? Finally, you need to be sure of your current needs on each 7805; while it can supply 1A, you don't have the 2+ amps needed from the wall-wart, but if your current requirements don't exceed that (remember the start-up current for the motors may be larger than their running current), you should be ok.

Laser can run 9 to 12v. It has a laser driver on it. Yes I'm going add heatsinks... Want get this done lots trial and error

The motors are 5v dc 200mah x 3 I'm using either a switching 9v or 12v 1a. I do have a 12v dc 1500mah but it's unregulated. Should I spend the 40 bucks to get the 6v to 12v 2.5a supply from radioshack?

I wouldn't rely on a radio shack power supply to be regulated. I have a 12V 1500ma supply that puts out just over 15V. Not very regulated eh? :-/

Do you know the stall current of the motors? The startup current is unlikely to be higher than the stall current; if it isn't beyond 300-350 ma per motor, the only other question would be the laser current usage. I am tentatively going to say you should be OK with the setup (worse case scenario is you'll either burn out the 7805s or the power supply; just keep an eye on all the parts and if they appear to be getting excessively warm, turn it off).

Not for sure on motors. I have laser set at around 50ma what I figured but my driver tester didn't work right

Hmm - well, if the laser is being kept around below 100ma, then you probably have enough headroom for the current surge of the motors at startup, with a 1.5A power supply and the regulators you are using. You could hook a small value resistor (temporarily) - say a couple 10 ohm resistors in parallel for 5 ohms - to one of the motor leads, then measure the voltage across the resistor, then compute the current from there as you stall the shaft, but I doubt this is really necessary.

I would say you are good to go - give it a shot, try it out, live a little, see if a fire starts or the magic smoke is let out!

;D

Right... I have a new board done now it's plug n play just cause :). But the 1.5mah supply is UNREGULATED, but under load it gets around 12v or should correct? My only other option is use my 3v to 12v switching at 1000mah or buying the 6v to 12v 2.5A for 40 bucks (that's almost the price of all the parts!)

I'm almost done have to supply it and what not will post pics and video :)

Right... I have a new board done now it's plug n play just cause Smiley. But the 1.5mah supply is UNREGULATED, but under load it gets around 12v or should correct? My only other option is use my 3v to 12v switching at 1000mah or buying the 6v to 12v 2.5A for 40 bucks (that's almost the price of all the parts!)

Well, maybe.

I have seen wall-warts and the like put out 14-16 volts without a load, and even with a load still float above 12 volts (sometimes up around 13 volts). If this a large concern for the laser, then stick a 7812 regulator (and heatsink) on it - its basically the same kind of part as a 7805, but for 12 volts instead.

i got it finished have to trim the pot sticks but check out the exhibition forum ;)

Yeah, just checked it - great work!

Is there a way whenevr I do push the button it doesnt have to go through the else { ? Here's what happens: I push the button it goes through the else when its LOW but when I push it to HIGH it has to wait for the else { to end before I can start using the pots again... anyway to fix this?

Post the code, but I suspect setting the button up on an interrupt is what you may want (although I wonder why your else clause is causing such a pause)...