#include <SoftwareSerial.h>
SoftwareSerial mainSerial(10, 11); // RX, TX
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
mainSerial.begin(57600);
}
void loop() {
// put your main code here, to run repeatedly:
if (mainSerial.available()) {
Serial.println("Comando da centrale: " + mainSerial.readString());
Serial.flush();
}
}
Comments