snipplets.dev/code/C/libserialport/Board/Board.ino

25 lines
388 B
Arduino
Raw Normal View History

2023-07-30 11:10:19 +03:00
/*
Author: Alexander Popov
License: Unlicense
*/
#include "3party/AsyncStream.h"
AsyncStream<50> serial(&Serial, '\n');
void setup() {
Serial.begin(9600);
}
void loop() {
if (strcmp(serial.buf, "ping") == 0) {
Serial.println("PONG");
}
Serial.println("ooooo");
// delay(1000);
Serial.println("zzzz");
// delay(1000);
Serial.println("xxx");
// delay(1000);
}