Grupo de placas Arduino:
Aguirre, Josue
Puchir, Gonzalo
Mendez, Lautaro
Boceto de 1 led pin 13:
void setup() {
pinMode (13,OUTPUT);
}
void loop() {
digitalWrite(13,HIGH);
delay(1000);
digitalWrite(13,LOW);
delay(1000);
}
Boceto 1 led pin 2
void setup() {
pinMode (2,OUTPUT);
}
void loop() {
digitalWrite(2,HIGH);
delay(4000);
digitalWrite(2,LOW);
delay(3000);
digitalWrite(2,HIGH);
delay(2000);
digitalWrite(2,LOW);
delay(1000);
}
Bocetos 2 leds pin 2 y 3
(prenden las dos luces al mismo tiempo)
void setup() {
pinMode (2, OUTPUT);
pinMode (3, OUTPUT);
}
void loop() {
digitalWrite (2, HIGH);
digitalWrite (3, HIGH);
delay (2000)
digitalWrite (2, LOW);
digitalWrite (3, LOW);
}
(prende y apaga led pin 2, prende y apaga led pin 3)
void setup() {
pinMode (2, OUTPUT);
pinMode (3, OUTPUT);
}
void loop() {
digitalWrite (2, HIGH);
delay(2000)
digitalWrite (2, LOW);
delay (2000)
digitalWrite (3, HIGH);
delay (2000)
digitalWrite (3, LOW);
delay (2000)
}
Boceto 3 leds Semáforo
void setup() {
pinMode(2,OUTPUT);
pinMode(3,OUTPUT);
pinMode(4,OUTPUT);
}
void loop() {
digitalWrite(2,HIGH);
delay(2000);
digitalWrite(2,LOW);
delay(2000);
digitalWrite(3,HIGH);
delay(2000);
digitalWrite(3,LOW);
delay(2000);
digitalWrite(4,HIGH);
delay(2000);
digitalWrite(4,LOW);
delay(2000);
digitalWrite(3,HIGH);
delay(2000);
digitalWrite(3,LOW);
delay(2000);
}
0 comentarios:
Publicar un comentario