bug: int overflow

This commit is contained in:
2022-03-28 13:41:04 +02:00
parent 9cb4fb4ed7
commit 3b6f38eb65
+3 -2
View File
@@ -2,10 +2,11 @@
#include "Keyboard.h" #include "Keyboard.h"
const int waitTime = 480000; // 8 minutes const unsigned long waitTime = 300000; // 5 minutes
const int buttonPin = 2; const int buttonPin = 2;
void setup() { void setup() {
Serial.begin(9600);
Serial.println("Starting HID"); Serial.println("Starting HID");
pinMode(buttonPin, INPUT_PULLUP); pinMode(buttonPin, INPUT_PULLUP);
Keyboard.begin(); Keyboard.begin();
@@ -26,6 +27,6 @@ void loop() {
Serial.println("LOW"); Serial.println("LOW");
} }
// wait 8 minutes // wait
delay(waitTime); delay(waitTime);
} }