Lab_interaccio/2013/motores/motores.ino
2025-02-25 21:29:42 +01:00

29 lines
736 B
C++

void setup() {
// initialize the digital pin as an output.
pinMode(14, OUTPUT);
pinMode(15, OUTPUT);
}
// the loop routine runs over and over again forever:
void loop() {
/*Sentido de giro*/
digitalWrite(14, HIGH); //
digitalWrite(15, HIGH); //
delay(12000); // wait for a second
/*Stop*/
digitalWrite(14, HIGH); //
digitalWrite(15, LOW); //
delay(1000); // wait for a second
/*Sentido de giro*/
digitalWrite(14, LOW); //
digitalWrite(15, LOW); //
delay(12000); // wait for a second
/*Stop*/
digitalWrite(14, LOW); //
digitalWrite(15, HIGH); //
delay(1000); // wait for a second
}