#define ENABLE_RSSI true
#include "LoRa_E220.h"
LoRa_E220 e220ttl(&Serial2); // esp32 RX 16 –> e220 TX | esp32 TX 17 –> e220 RX
void setup() {
Serial.begin(115200);
delay(500);
e220ttl.begin();
Serial.println("Hi, I’m going to receive a message!");
ResponseStatus rs = e220ttl.sendMessage("Receiver listening");
Serial.println(rs.getResponseDescription()); // Check If there is some problem of succesfully send
}
void loop() {
// If something available
if (e220ttl.available() > 1) {
// read the String message
#ifdef ENABLE_RSSI
ResponseContainer rc = e220ttl.receiveMessageRSSI();
#else
ResponseContainer rc = e220ttl.receiveMessage();
#endif
// Is something goes wrong print error
if (rc.status.code != 1) {
Serial.println(rc.status.getResponseDescription());
} else {
// Print the data received
Serial.println(rc.status.getResponseDescription());
Serial.println(rc.data);
#ifdef ENABLE_RSSI
Serial.print("RSSI: ");
Serial.println(rc.rssi, DEC);
#endif
}
}
if (Serial.available()) {
String input = Serial.readString();
e220ttl.sendMessage(input);
}
}
Can you help me please? Thanks in advance and best regards. Problems with EBYTE E220-900T22D
Hello and thanks for the great library. Unfortunately I can't get the EBYTE E220-900T22D module to run. I am using an ESP-32 Dev Kit C V4. I configured the modules using a USB adapter. Both configurations are identical. Unfortunately I am not receiving anything. Below is my code: