H_Bridge Motor Driver or how to control my DC motors

Dear, Mates ! 

For less than ten days i suffer for second time trying to construct my own HBridge so probably i really need somebody helps me, please.

The last time i bought the set i thought everything whould be fine :

- 4 Transistors (2xIRF640 and 2xIRF9540n) and two resistors(8K,0.25) this should be the most basic things to build an HBridge ?  

I am not really sure as i've been 30 minutes ago, but the most important parameters i had to suppose was

 -For IRF640       VDSS 100 V  ID 22 A

 -For IRF9540N  VDSS -100 V  ID -22 A

( I chose them because i am expecting to turn a motor with 30V and 4A consumption. )

and VGS(th) for both transistors 2 to 4 Volts - perfect for my parallel port.

If you haven't corrected me yet please don't be ashame, but isn't VGS(th) the trigger and the Only requirement on Gate to turn transistors working ?

thetry.jpg

 

 

I don't know where do i make mistake so, please look at the diagram above.

As i see when in initial position OUT A and OUT B are 0V so PChannels are passing, but NChannels do not and as result noting happens.

If i set OUT A to 5V left PChannel stops passing, right P is passing and left N is passing so motor is working.

If i set OUT B, motors spins opossite.

 

If all this is fine with you i would like to ask if the problem is wrong pin mapping? Both P and N Channel Mosfets are Gate,Drain,Source oriented when look at in front (they have an equal mapping) 

 

Any help for how HBridge works would be highly appreciated ! 

The reason i need to know it is becouse i want to call myself one day a robot builder as you do !

Thank you again !

Do you have a multimeter or

Do you have a multimeter or something you can use to check the voltages around your circuit? As far as I can tell, the high level output of your parallel port will be somewhere in the 2.6 - 5V range, so if it’s on the low end it may not be enough to switch your transistors.

Also there is a ground connected to OUT B on your schematic, is this part of the real circuit? If so, you won’t be able to turn on Q4 or turn off Q3.

Its true for both.4.45V is

Its true for both.

4.45V is the output. but how do you know if it is enough or not ?

I don’t understand because i thought the only parameter is VGS(th).

About the ground there is not such a thing on the real circuit, sorry i forgot to clean this part.