apuntes_Arduino/leds/EncendidoProgresivoLed_PWM/EncendidoProgresivoLed_PWM.ino
jp.av.dev 85bf8bb429 proyectos renombrados, reestructuracion
pendientes crear, indexar y linkear readmes
2022-04-04 01:11:04 -04:00

27 lines
629 B
C++
Executable File

// the setup function runs once when you press reset or power the board
void setup() {
pinMode(10, OUTPUT);// initialize digital pin LED_BUILTIN as an output.
pinMode(11, OUTPUT);
}
void loop() { // the loop function runs over and over again forever
for (int i = 0; i <= 255; i++) {
analogWrite(10, i);
//delay(1);
for (int j = 255; j >= 0; j--) {
analogWrite(11, j);
//delay(1);
}
}
for (int i = 0; i <= 255; i++) {
analogWrite(11, i);
//delay(1);
for (int j = 255; j >= 0; j--) {
analogWrite(10, j);
//delay(1);
}
}
}