From f0805dd48ade1f36f7b20ff508757fdfd00b021e Mon Sep 17 00:00:00 2001 From: smayzy Date: Sun, 3 May 2026 17:20:12 +0200 Subject: [PATCH] add receiver --- receive-arduino/receive-arduino.ino | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 receive-arduino/receive-arduino.ino diff --git a/receive-arduino/receive-arduino.ino b/receive-arduino/receive-arduino.ino new file mode 100644 index 0000000..23bf03b --- /dev/null +++ b/receive-arduino/receive-arduino.ino @@ -0,0 +1,23 @@ +#include + +SoftwareSerial lora(8, 9); // RX, TX + +String line; + +void setup() { + Serial.begin(115200); + lora.begin(9600); +} + +void loop() { + while (lora.available()) { + char c = lora.read(); + + if (c == '\n') { + Serial.println(line); + line = ""; + } else { + line += c; + } + } +}