EasyManua.ls Logo

Keyestudio 4WD Bluetooth Multi-functional Car - Page 64

Keyestudio 4WD Bluetooth Multi-functional Car
151 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
keyestudio
www.keyestudio.com
62
digitalWrite(IN1,HIGH);
digitalWrite(IN2,LOW);
analogWrite(ENA,100);
digitalWrite(IN3,HIGH);
digitalWrite(IN4,LOW);
analogWrite(ENB,100);
delay(1000);
// pause for 1S
analogWrite(ENA,0);
analogWrite(ENB,0);
delay(1000);
}
*******************************************************************************
Result
After connection and power-on, two motors rotate clockwise for 1 second at a speed of 200 (PWM value is 200) and then stop for 1 second; two motors rotate
anticlockwise for 1 second at a speed of 100 (PWM value is 100) and then stop for 1 second; circulating like this.

Related product manuals