mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
feat(openthread): disable the rx on when idle in coex scenario
This commit is contained in:
parent
ba2350dde8
commit
970626ec2f
@ -376,6 +376,15 @@ menu "OpenThread"
|
||||
default n
|
||||
help
|
||||
Select this option to enable the OpenThread Radio Spinel for external protocol stack, such as Zigbee.
|
||||
|
||||
config OPENTHREAD_RX_ON_WHEN_IDLE
|
||||
bool "Enable OpenThread radio capibility rx on when idle"
|
||||
default y if !ESP_COEX_SW_COEXIST_ENABLE
|
||||
default n if ESP_COEX_SW_COEXIST_ENABLE
|
||||
help
|
||||
Select this option to enable OpenThread radio capibility rx on when idle. Do not support this feature when
|
||||
SW coexistence is enabled.
|
||||
|
||||
menu "Thread Address Query Config"
|
||||
config OPENTHREAD_ADDRESS_QUERY_TIMEOUT
|
||||
int "Timeout value (in seconds) for a address notification response after sending an address query."
|
||||
|
@ -343,7 +343,11 @@ int8_t otPlatRadioGetRssi(otInstance *aInstance)
|
||||
|
||||
otRadioCaps otPlatRadioGetCaps(otInstance *aInstance)
|
||||
{
|
||||
return (otRadioCaps)(OT_RADIO_CAPS_ENERGY_SCAN | OT_RADIO_CAPS_RX_ON_WHEN_IDLE |
|
||||
// FIXME: Remove `CONFIG_OPENTHREAD_RX_ON_WHEN_IDLE` when JIRA: TZ-609 fixed.
|
||||
return (otRadioCaps)(OT_RADIO_CAPS_ENERGY_SCAN |
|
||||
#if CONFIG_OPENTHREAD_RX_ON_WHEN_IDLE
|
||||
OT_RADIO_CAPS_RX_ON_WHEN_IDLE |
|
||||
#endif
|
||||
OT_RADIO_CAPS_TRANSMIT_SEC | OT_RADIO_CAPS_RECEIVE_TIMING | OT_RADIO_CAPS_TRANSMIT_TIMING |
|
||||
OT_RADIO_CAPS_ACK_TIMEOUT | OT_RADIO_CAPS_SLEEP_TO_TX);
|
||||
}
|
||||
@ -771,8 +775,10 @@ otError otPlatRadioSetChannelMaxTransmitPower(otInstance *aInstance, uint8_t aCh
|
||||
return OT_ERROR_NONE;
|
||||
}
|
||||
|
||||
#if CONFIG_OPENTHREAD_RX_ON_WHEN_IDLE
|
||||
void otPlatRadioSetRxOnWhenIdle(otInstance *aInstance, bool aEnable)
|
||||
{
|
||||
OT_UNUSED_VARIABLE(aInstance);
|
||||
esp_ieee802154_set_rx_when_idle(aEnable);
|
||||
}
|
||||
#endif
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
#include "esp_openthread_radio.h"
|
||||
|
||||
#include "sdkconfig.h"
|
||||
#include "esp_check.h"
|
||||
#include "esp_err.h"
|
||||
#include "esp_openthread_border_router.h"
|
||||
@ -413,7 +414,9 @@ otError otPlatRadioConfigureEnhAckProbing(otInstance *aInstance, otLinkMetrics a
|
||||
}
|
||||
#endif
|
||||
|
||||
#if CONFIG_OPENTHREAD_RX_ON_WHEN_IDLE
|
||||
void otPlatRadioSetRxOnWhenIdle(otInstance *aInstance, bool aEnable)
|
||||
{
|
||||
s_radio.SetRxOnWhenIdle(aEnable);
|
||||
}
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user