Maker Pro
Maker Pro

Parallel port motor control

Hello Guys,

Please i need some little help and suggestions. the idea is to control a DC normal motor in both 2 directions using Parallel port.

I managed to get this working the schematic is attached. The batteries V1 and V3 are where 2 PINs from parallel port are supposed to be connected ( was just testing using the simulator) . The parallel port output is about 2V .

The problem is even if i measure the output voltage to the motor which it's about +/-5V , the turn force of the motor is not the same as if i supply it directly with 5V . i was wondering what cause this but can't figure it out . Please if someone have any suggestion that will be great.

Thanks
 

Attachments

  • motorCtrl.jpg
    motorCtrl.jpg
    122.9 KB · Views: 334

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
The LM324 almost certainly can't swing its output all the way to the supply rails (thus reducing the potential voltage to the motor) and it also may not be able to switch the current required for the motor (which will compound the first problem).

Using the op amp to switch mosfets would probably be the simplest solution.
 
hmm, i've also tried with LA6324N but it seems it has the same characteristics as the LM324. do you know any one that could work better in this case ?.

Thanks
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Using the op amp to switch mosfets would probably be the simplest solution.

Alternatively, you should look for an op-amp with mosfet output and capable of driving the current required for the motor. Since you don't specify the current required, I can't be much more specific.
 
hmm Mosfet transistor where the hell i can find one , and where can i connect it XD . I'll try look for a high current op amp 1st.

Thanks a lot for your help .
 
Finally got this working , i've used the H-bridge circuit, the schema is here : http://postimage.org/image/1kn4oi1b8/
And a little play around with it
:D

Here is a sample Python code to use parallel port if someone need it :

import parallel #import library
p=parallel.Parallel() # initialize parallel

p.setData(0x40) # send the data to the 8 parallel ports in Hexa 0x40 it's 0100 0000 , that's mean it will send the 2V (i think ) on the 7th pin and 0V to the
 
As usual with these simple bridges; be aware that if both inputs happen to be high at the same time the power supply will be short-circuited.
So in software, make very sure you turn off one output before turning on the other. Using all four separate inputs to the bridge you can implement motor braking.
 
Oh hm, i didn't notice that it may have a short-circuit , Thanks i'll make sure to not send on both. do you have any idea how to prevent short-circuit in this bridges circuit , or is there other ways ?

Thanks
 
I don't have a link at hand but there are circuits out there implementing such control protection in hardware, at the expense of a couple of extra transistors or digital gates.
 
Top