commit f7332764c82cfac7b3134efc9386947f808c8a4d Author: Kolodkin Timofey Date: Mon Apr 22 20:09:37 2024 +0300 Create diff --git a/sketch_apr22a/sketch_apr22a.ino b/sketch_apr22a/sketch_apr22a.ino new file mode 100644 index 0000000..95c4deb --- /dev/null +++ b/sketch_apr22a/sketch_apr22a.ino @@ -0,0 +1,22 @@ + +const int Pin = 2; + +void setup() { + Serial.begin(9600); + +} + +void loop() { + +int port = digitalRead(Pin); //считываем состояние порта + +if(port == LOW) +{ + Serial.print("0"); +} else + Serial.print("1"); + + + delay(500); + +}