mirror of
https://github.com/espressif/esp-idf
synced 2025-03-12 18:49:08 -04:00
Merge branch 'backport/fix_energy_scan_api_para_mismatch_v53' into 'release/v5.3'
fix(openthread): set channel for energy scan(Backport v5.3) See merge request espressif/esp-idf!34596
This commit is contained in:
commit
6df4318039
@ -9,6 +9,8 @@
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
#define US_PER_SYMBLE 16
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
@ -412,7 +412,8 @@ void otPlatRadioClearSrcMatchExtEntries(otInstance *aInstance)
|
||||
|
||||
otError otPlatRadioEnergyScan(otInstance *aInstance, uint8_t aScanChannel, uint16_t aScanDuration)
|
||||
{
|
||||
esp_ieee802154_energy_detect(aScanDuration);
|
||||
esp_ieee802154_set_channel(aScanChannel);
|
||||
esp_ieee802154_energy_detect(aScanDuration * US_PER_MS / US_PER_SYMBLE);
|
||||
|
||||
return OT_ERROR_NONE;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user