A INCRIVEL FABRICA DE CHOCOLATE
Por: WtfAlvesz • 21/6/2022 • Trabalho acadêmico • 274 Palavras (2 Páginas) • 126 Visualizações
[pic 1][pic 2]
Tarefa de SE – 3 Leds, 3 Botões
Aluno - Gabriel Alves Pinto
Professor - Helton
Classe - 1 AE
Matéria - SE
Fotos do Circuito no Proteus
[pic 3][pic 4]
Programação no Arduino
const int buttonPin1 = 2;
const int buttonPin2 = 3;
const int buttonPin3 = 4;
const int ledPin1 = 8;
const int ledPin2 = 11;
const int ledPin3 = 13;
int buttonState1 = 0;
int buttonState2 = 0;
int buttonState3 = 0;
void setup() {
pinMode(ledPin1, OUTPUT);
pinMode(buttonPin1, INPUT);
pinMode(ledPin2, OUTPUT);
pinMode(buttonPin2, INPUT);
pinMode(ledPin3, OUTPUT);
pinMode(buttonPin3, INPUT);
}
void loop() {
buttonState1 = digitalRead(ledPin1);
buttonState2 = digitalRead(ledPin2);
buttonState3 = digitalRead(ledPin3);
if (buttonState1 == LOW) {
digitalWrite(ledPin1, HIGH);
} else {
digitalWrite(ledPin1, LOW);
}
if (buttonState2 == HIGH) {
digitalWrite(ledPin2, LOW);
delay(1500);
} else {
digitalWrite(ledPin2, HIGH);
delay(2000);
}
if (buttonPin3 == LOW);
digitalWrite(ledPin3, LOW);
delay(1000);
} else {
digitalWrite(ledPin3, HIGH);
delay(1000);
}
}
Programação Compilada
:100000000C9461000C9473000C9473000C947300B6 :100010000C9473000C9473000C9473000C94730094 :100020000C9473000C9473000C9473000C94730084 :100030000C9473000C9473000C9473000C94730074 :100040000C94CB000C9473000C9473000C9473000C :100050000C9473000C9473000C9473000C94730054 :100060000C9473000C94730000000000240027001F :100070002A000000000023002600290000000000E4 :10008000250028002B0004040404040404040202D4 :100090000202020203030303030301020408102007 :1000A0004080010204081020010204081020000012 :1000B0000008000201000003040700000000000027 :1000C000000011241FBECFEFD8E0DEBFCDBF21E07E :1000D000A0E0B1E001C01D92AB30B207E1F70E9491 :1000E00015010C94CF010C940000833081F028F4AA :1000F000813099F08230A1F008958730A9F08830DE :10010000B9F08430D1F4809180008F7D03C080915C :1001100080008F7780938000089584B58F7702C028 :1001200084B58F7D84BD08958091B0008F7703C022 :100130008091B0008F7D8093B00008951F93CF937E :10014000DF93EBEBF0E09491E7EAF0E0D491E3E9A0 :10015000F0E0C491CC23D9F0182F992319F0892FFE :100160000E947500EC2FF0E0EE0FFF1FE458FF4FE8 :10017000A591B4918FB7F894111105C09C91ED2F02 :10018000E095E92302C0EC91ED2BEC938FBFDF915A :10019000CF911F9108951F920F920FB60F921124C5 :1001A0002F933F938F939F93AF93BF9380910701BA :1001B00090910801A0910901B0910A0130910601C6 :1001C00023E0230F2D3720F40196A11DB11D05C09A :1001D00026E8230F0296A11DB11D209306018093EE :1001E000070190930801A0930901B0930A0180913F :1001F000020190910301A0910401B09105010196C3 :10020000A11DB11D8093020190930301A0930401ED :10021000B0930501BF91AF919F918F913F912F9125 :100220000F900FBE0F901F901895789484B5826040 :1002300084BD84B5816084BD85B5826085BD85B58A :10024000816085BD80916E00816080936E00109208 :100250008100809181008260809381008091810083 :100260008160809381008091800081608093800014 :100270008091B10084608093B1008091B000816072 :100280008093B00080917A00846080937A0080919E :100290007A00826080937A0080917A0081608093F6 :1002A0007A0080917A00806880937A001092C10071 :1002B000E7EAF0E02491E3E9F0E08491882399F003 :1002C00090E0880F991FFC01E859FF4FA591B49168 :1002D000FC01E458FF4F859194918FB7F894EC910D :1002E000E22BEC938FBFC4EAD0E0FE01249100E939 :1002F00010E0F80184918823C9F090E0880F991FDD :10030000FC01E859FF4FA591B49184589F4FFC011F :10031000459154913FB7F8949C91822F80959823F2 :100320009C93FA019081892380833FBF98EBE92E4B :1003300090E0F92E20E0C22E20E0D22EF701849129 :10034000FE01A490F801B490BB20B1F081110E948D :100350007500EB2DF0E0EE0FFF1FCF018E589F4F81 :10036000FC01A591B4918C91A82231E020E009F420 :1003700030E0832F922F02C080E090E09093010143 :1003800080930001019711F481E001C080E00E9498 :100390009E00C114D10491F20E940000CFCFF894C6 :0203A000FFCF8D :00000001FF
...