-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHello-World.ino
More file actions
28 lines (18 loc) · 888 Bytes
/
Hello-World.ino
File metadata and controls
28 lines (18 loc) · 888 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
//==============================================================================//
#include <CSE_MillisTimer.h>
//==============================================================================//
CSE_MillisTimer helloTimer (1000); // Create a timer with a time period of 1000 ms.
//==============================================================================//
void setup() {
Serial.begin (115200); // Initialize the serial port.
delay (2000);
helloTimer.start(); // Start the timer.
}
//==============================================================================//
void loop() {
if (helloTimer.isElapsed()) { // Check if the timer has elapsed.
Serial.println ("Hello World!"); // Print "Hello World!" to the serial port.
helloTimer.start(); // Restart the timer.
}
}
//==============================================================================//