myRaspberry

Mes aventures en Raspberry et Arduino

L9910 – carte contrôleur de commande de moteur,

Posted on 20 octobre 2016  in Arduino, Composants

L9110

Carte contrôleur de commande de moteur, peut entraîner deux moteurs à courant continu ou un 4 fils moteur pas à pas 2 phases. Spécifications: tension d’entrée: 3 ~ 12V, le courant: 800mA.

/* L9910 motor driver */
static const int A_IA = 3 ;
static const int A_IB = 4 ;
 
void setup() {
    pinMode(A_IA, OUTPUT) ;
    pinMode(A_IB, OUTPUT) ;
}
 
void loop() {
    // pump on
    digitalWrite(A_IA, LOW) ;
    digitalWrite(A_IB, HIGH) ;
 
    delay(5000) ; // 5 seconds
 
    // pump off
    digitalWrite(A_IA, LOW) ;
    digitalWrite(A_IB, LOW) ;
 
    delay(5000) ; // 5 seconds
}
ARDUINO-L9910