Upgrade RadioLib to 5.50

This commit is contained in:
lewishe 2022-12-09 16:12:04 +08:00
commit 6301fa4734
208 changed files with 15925 additions and 10099 deletions

View file

@ -24,7 +24,7 @@
SX1280 radio = new Module(RADIO_CS_PIN, RADIO_DIO1_PIN, RADIO_RST_PIN, RADIO_BUSY_PIN);
// save transmission state between loops
int transmissionState = ERR_NONE;
int transmissionState = RADIOLIB_ERR_NONE;
// flag to indicate that a packet was sent
volatile bool transmittedFlag = false;
@ -60,14 +60,14 @@ void setup()
int state = radio.begin();
#ifdef HAS_DISPLAY
if (u8g2) {
if (state != ERR_NONE) {
if (state != RADIOLIB_ERR_NONE) {
u8g2->clearBuffer();
u8g2->drawStr(0, 12, "Initializing: FAIL!");
u8g2->sendBuffer();
}
}
#endif
if (state == ERR_NONE) {
if (state == RADIOLIB_ERR_NONE) {
Serial.println(F("success!"));
} else {
Serial.print(F("failed, code "));
@ -120,7 +120,7 @@ void loop()
// reset flag
transmittedFlag = false;
if (transmissionState == ERR_NONE) {
if (transmissionState == RADIOLIB_ERR_NONE) {
// packet was successfully sent
Serial.println(F("transmission finished!"));