Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void setup() {
- pinMode(2, INPUT_PULLUP);
- pinMode(4, INPUT_PULLUP);
- pinMode(7, INPUT_PULLUP);
- Serial.begin(9600);
- }
- void loop() {
- boolean b2 = digitalRead(2);
- boolean b4 = digitalRead(4);
- boolean b7 = digitalRead(7);
- Serial.println("Źle podpięte przyciski:" + String(b2 ? " 2," : " ") + String(b4 ? " 4," : "") + String(b7 ? " 7" : ""));
- delay(1000);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement