aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2026-01-31 17:35:51 +0530
committerAkshay Nair <phenax5@gmail.com>2026-01-31 17:36:10 +0530
commit7224fce49e4fa8c0b966dcc8d4f9b1d12b02f66a (patch)
treeb85f49881f843f1765f2ec0a3899cdb1b5253e3b /src/main.cpp
downloaddaft-watch-7224fce49e4fa8c0b966dcc8d4f9b1d12b02f66a.tar.gz
daft-watch-7224fce49e4fa8c0b966dcc8d4f9b1d12b02f66a.zip
Init commit with blink shit
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp
new file mode 100644
index 0000000..6226244
--- /dev/null
+++ b/src/main.cpp
@@ -0,0 +1,16 @@
+#include <Arduino.h>
+
+// Physical Pin 2 on the ATtiny84a is Arduino Digital Pin 0
+#define LED_PIN 0
+
+void setup() {
+ // Initialize the digital pin as an output.
+ pinMode(LED_PIN, OUTPUT);
+}
+
+void loop() {
+ digitalWrite(LED_PIN, HIGH); // Turn the LED on
+ delay(1000); // Wait for a second
+ digitalWrite(LED_PIN, LOW); // Turn the LED off
+ delay(1000); // Wait for a second
+}