diff options
Diffstat (limited to 'assignments/blink-a-led/solution')
-rw-r--r-- | assignments/blink-a-led/solution/assignment-1/assignment-1.ino | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/assignments/blink-a-led/solution/assignment-1/assignment-1.ino b/assignments/blink-a-led/solution/assignment-1/assignment-1.ino new file mode 100644 index 0000000..5b72892 --- /dev/null +++ b/assignments/blink-a-led/solution/assignment-1/assignment-1.ino @@ -0,0 +1,20 @@ +const int LED_PIN = D0; + +void setup() { + Serial.begin(115200); + Serial.println(); + Serial.println(); + Serial.println("Hello world!"); + pinMode(LED_PIN, OUTPUT); +} + +void loop() { + digitalWrite(LED_PIN, HIGH); + Serial.println("HIGH"); + delay(1000); + + digitalWrite(LED_PIN, LOW); + Serial.println("LOW"); + delay(1000); +} + |