PICAXE powered by a wall wart

crndy52

New Member
I am working on a pretty simple project using an 08M to control a small 5.0vdc motor. The 08M turns two small relays on and off through a 2003 darlington. Everything works great using battery power. However, when I try to power it with a wall wart (12vdc@900mA through a 5v,1A 7805 regulator) the whole thing goes completely crazy. The motor pulses at about 4 to 6 Hz but the shaft won't turn. The relays also pulse but won't pull in. If I remove the motor from the circuit it works fine with the relays pulling in and dropping as they should. If I put the motor back in the circuit it all goes crazy again. I replaced the motor with another small relay coil - it went crazy with that too. I thought I was getting a severe ripple in the dc from the wall wart so I added 12,000mfd of filter capacitors to it with no change. I put a diode and 220nf nonpolarized capacitor across the motor terminals thinking that motor electrical noise was causing the problem. It did not help. I even added a seperate voltage regulator for the motor. That did not help either. The only way to make it work is to use batteries. I have a 33K pull-down resistor between the serial in (pin 2) and ground so that is not the problem. I have tried other 08Ms, darrlington arrays, relays, and even another small motor. Noting helps except powering it with batteries. Anyone got an idea of what might be going on here?
 

westaust55

Moderator
In the first instance, certainly seems like a ripple or AC related problem.
A DC coil will hum or chatter on AC but not pull in.

Do you have an electrolytic capacitor on the input side of the 8805 and a tantalum cap (say 10uF) on the output side of the 7805.

The electro acts as a filter and energy reservoir while the Tantalum capacitor is usually required by the datasheets to stop the 7805 oscillating.

Can you upload your complete schematic for us to have a better understanding of the circuit
 

BeanieBots

Moderator
I'd put money on it being the wall-wart not being capable of supplying the required current. Hence, the problem only manifests when there is a load on it.
Put the motor direct on the regulated output of the 7805. Does it run at the same speed as when using batteries? If not, point proved.
If yes, then you will need to get a DVM and do some more diagnostics such as measuring input voltage to the 7805.
 

manuka

Senior Member
Top marks on first taming the layout with batteries! Is your mains wall wart PSU a modern switched mode (which can be VERY "noisy"), or a classic step-down transformer? Have you put a ~100nF cap right across motor terminals? Tried a different mains PSU? Suggest please you provide a simple circuit. Stan
 

marcos.placona

Senior Member
Top marks on first taming the layout with batteries! Is your mains wall wart PSU a modern switched mode (which can be VERY "noisy"), or a classic step-down transformer? Have you put a ~100nF cap right across motor terminals? Tried a different mains PSU? Suggest please you provide a simple circuit. Stan
I believe he did Stan. he mentions that here:

I put a diode and 220nf nonpolarized capacitor across the motor terminals thinking that motor electrical noise was causing the problem
 

Dippy

Moderator
A you've done the basic tests already, I'd try the BeanieBot test i.e. measure the voltages under load without the PICAXE. It's a pity you don't have a 'scope - it can be quite an education.

Is your wall-wart a good one or an Ebay jobby? And as Stan has alluded to, is it Switched Mode or linear?
And is it regulated or unregulated. Some of the cheapoes droop hugely as you load them up. Cheap (usually) = rubbish.

You shouldn't need monster caps like 12000uF.

One further suggestion which is regularly recommended; put a capacitor between PICAXE +V supply pin and ground - as close as physically possible. For noisy circuits this may require 2 caps //d e.g. a 22nF ceramic and a 22uF electro/tantalum. I do this as 'standard' whenever I have a circuit with big pulses kicking about. (I also put 47nF between reset and ground).
 

crndy52

New Member
Finally Got It

Thanks for all of the suggestions. It took everyones advice but I finally got it to work. The wall wart is of the old step-down transformer type. To get it all to work I put a 2200 mfd cap on the wall wart leads before the voltage regulators. I also got a handfull of 220nf caps and ended up putting them on the regulators, across the 08M supply pins, on both of the relays as well as on the motor leads. I also put some pretty fast diodes at each of the points as well to clamp any reverse voltages. All together I used nearly (1) 2200 mfd caps, (12) 220 caps, and 9 diodes. Before this project, all my picaxe projects have been battery operated and after this mess all of my future projects will be the same. No more wall warts for me. Thanks again for all the help
 

BeanieBots

Moderator
You should be using a many of those caps and the clamp diodes with ANY power source. Sounds like your wall-wart has very little (if any) internal smoothing. Those used used for battery charging typically have none so what you did to make your circuit work was simply add the "missing" components to the cheap wall-wart.
 

Dippy

Moderator
I haven't seen a circuit so I am only basing this on your written descriptions and my vivid imagination.
That sounds awful.

Unless there is a serious problem, a few strategically placed caps and supressing components usually cures the ills.
Mind you, sometimes physical circuit layout with the same components can make a BIG difference.

Can you try another wall wart?
I wouldn't be put off all mains PSUs. But I would be put off from using cheap crap ones.
 
Top