mirror of
https://github.com/espressif/openthread.git
synced 2026-08-06 18:57:47 +00:00
[data-poll] only allow data polling when rx-off-when-idle (#2770)
This commit is contained in:
@@ -71,7 +71,7 @@ otError DataPollManager::StartPolling(void)
|
||||
otError error = OT_ERROR_NONE;
|
||||
|
||||
VerifyOrExit(!mEnabled, error = OT_ERROR_ALREADY);
|
||||
VerifyOrExit(!GetNetif().GetMle().IsFullThreadDevice(), error = OT_ERROR_INVALID_STATE);
|
||||
VerifyOrExit(!GetNetif().GetMle().IsRxOnWhenIdle(), error = OT_ERROR_INVALID_STATE);
|
||||
|
||||
mEnabled = true;
|
||||
ScheduleNextPoll(kRecalculatePollPeriod);
|
||||
|
||||
Reference in New Issue
Block a user