NRF24 plugins updates

Updates by Sil333033 with some changes, furi_hal speaker direct calls was removed and replaced with notification service to avoid bypassing of user set silent mode
This commit is contained in:
MX
2023-07-18 02:53:30 +03:00
parent e2028eb731
commit bb6d3cb796
7 changed files with 85 additions and 45 deletions

View File

@@ -517,4 +517,14 @@ uint8_t nrf24_find_channel(
}
return ch;
}
bool nrf24_check_connected(FuriHalSpiBusHandle* handle) {
uint8_t status = nrf24_status(handle);
if(status != 0x00) {
return true;
} else {
return false;
}
}

View File

@@ -361,6 +361,13 @@ void int32_to_bytes(uint32_t val, uint8_t* out, bool bigendian);
*/
uint32_t bytes_to_int32(uint8_t* bytes, bool bigendian);
/** Check if the nrf24 is connected
* @param handle - pointer to FuriHalSpiHandle
*
* @return true if connected, otherwise false
*/
bool nrf24_check_connected(FuriHalSpiBusHandle* handle);
#ifdef __cplusplus
}
#endif