- TasmotaSerial library from v3.4.0 to v3.5.0 (#14981) - TasmotaSerial implement ``end()`` - ESP32 TasmotaSerial uart mapping to support multiple ``begin()`` and implement ``getUart()`` (#14981)
28 lines
417 B
C++
28 lines
417 B
C++
|
|
#include <TasmotaSerial.h>
|
|
|
|
TasmotaSerial swSer(14, 12);
|
|
|
|
void setup() {
|
|
Serial.begin(115200);
|
|
swSer.begin();
|
|
|
|
Serial.println("\nTasmota serial test started");
|
|
|
|
for (char ch = ' '; ch <= 'z'; ch++) {
|
|
swSer.write(ch);
|
|
}
|
|
swSer.println("");
|
|
|
|
}
|
|
|
|
void loop() {
|
|
while (swSer.available() > 0) {
|
|
Serial.write(swSer.read());
|
|
}
|
|
while (Serial.available() > 0) {
|
|
swSer.write(Serial.read());
|
|
}
|
|
|
|
}
|