mirror of
https://github.com/deq-boards/microcontroller.git
synced 2025-10-21 18:59:18 +02:00
Add serial debug code
This commit is contained in:
parent
f1d1526f38
commit
436a7b3ad0
1 changed files with 10 additions and 0 deletions
10
debug.ino
Normal file
10
debug.ino
Normal file
|
@ -0,0 +1,10 @@
|
|||
void setup() {
|
||||
Serial.begin(9600); // Initialize serial communication at 9600 baud
|
||||
}
|
||||
|
||||
void loop() {
|
||||
if (Serial.available() > 0) { // Check if data is available to read
|
||||
char receivedChar = Serial.read(); // Read the incoming byte
|
||||
Serial.print(receivedChar); // Echo the byte back over Serial
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue