Hi..
Having some problem learning how to use the H-bridge I have indeed.
I have read and looked at a few tutorials on H-bridges, and on what I know, I think this should be working. I know what all the ports are for and what you do with them, so I wanted to make it simple for starters: turn the motor on any way around.
There is something I'm missing.
My circuit:
My code:
TEACH ME THE WAY OF CORRECT CIRCUITS MASTERS :C
The arduino projects book I got isn't covering a lot of this :/
Q1: What am I doing wrong?
Q2: Why is there four ground pins on the bridge? Can I use one of them for connecting to ground with both my 9V power supply and the Arduino's ground?
Thank you!
Having some problem learning how to use the H-bridge I have indeed.
I have read and looked at a few tutorials on H-bridges, and on what I know, I think this should be working. I know what all the ports are for and what you do with them, so I wanted to make it simple for starters: turn the motor on any way around.
There is something I'm missing.
My circuit:
My code:
Code:
void setup() {
pinMode(9, OUTPUT); //enable pin
digitalWrite(9, HIGH); //Motor is ON
pinMode(8, OUTPUT); //Control pin n.1
digitalWrite(8, HIGH); //..set to HIGH
pinMode(7, OUTPUT); //Control pin n.2
digitalWrite(7, LOW); //..set to LOW
} // =>motor should be spinning?
void loop() {
// no need for this, JUST GET THE MOTOR SPINNING D':
}
The arduino projects book I got isn't covering a lot of this :/
Q1: What am I doing wrong?
Q2: Why is there four ground pins on the bridge? Can I use one of them for connecting to ground with both my 9V power supply and the Arduino's ground?
Thank you!