From b7e12f5c7183c6e9bf356c4ad50e3cd61ccf59fb Mon Sep 17 00:00:00 2001 From: Davide Lasagna Date: Tue, 21 Mar 2023 19:56:21 +0000 Subject: [PATCH] fix for #705 --- src/modules/SX126x/SX126x.cpp | 2 +- src/modules/SX128x/SX128x.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/SX126x/SX126x.cpp b/src/modules/SX126x/SX126x.cpp index 78727347..a7a17275 100644 --- a/src/modules/SX126x/SX126x.cpp +++ b/src/modules/SX126x/SX126x.cpp @@ -436,7 +436,7 @@ int16_t SX126x::sleep(bool retainConfig) { if(!retainConfig) { sleepMode = RADIOLIB_SX126X_SLEEP_START_COLD | RADIOLIB_SX126X_SLEEP_RTC_OFF; } - int16_t state = _mod->SPIwriteStream(RADIOLIB_SX126X_CMD_SET_SLEEP, &sleepMode, 1, false); + int16_t state = _mod->SPIwriteStream(RADIOLIB_SX126X_CMD_SET_SLEEP, &sleepMode, 1, false, false); // wait for SX126x to safely enter sleep mode _mod->delay(1); diff --git a/src/modules/SX128x/SX128x.cpp b/src/modules/SX128x/SX128x.cpp index b5aeed31..9a31231d 100644 --- a/src/modules/SX128x/SX128x.cpp +++ b/src/modules/SX128x/SX128x.cpp @@ -446,7 +446,7 @@ int16_t SX128x::sleep(bool retainConfig) { if(!retainConfig) { sleepConfig = RADIOLIB_SX128X_SLEEP_DATA_BUFFER_FLUSH | RADIOLIB_SX128X_SLEEP_DATA_RAM_FLUSH; } - int16_t state = _mod->SPIwriteStream(RADIOLIB_SX128X_CMD_SET_SLEEP, &sleepConfig, 1, false); + int16_t state = _mod->SPIwriteStream(RADIOLIB_SX128X_CMD_SET_SLEEP, &sleepConfig, 1, false, false); // wait for SX128x to safely enter sleep mode _mod->delay(1);