L9110 Motor control driver chip

used products:

1. Arduino UNO
2. L9110H

content:

Çeşme: http://moderntesla.blogspot.com.tr/2015/02/arduino-l9110-motor-kontrolu.html

Arduino:

#define motA 9 #define motB 5 byte speed = 100; // between 0-255 int sleep = 1000; void setup() { pinMode(motA, OUTPUT); pinMode(motB, OUTPUT); } void loop() { forward(); delay(sleep); back(); delay(sleep); } void forward() { analogWrite(motA, speed); analogWrite(motB, 0); } void back() { analogWrite(motA, 0); analogWrite(motB, speed); }