nrfxlib API 2.7.99
Loading...
Searching...
No Matches

◆ nrf_802154_mcu_critical_enter

#define nrf_802154_mcu_critical_enter (   mcu_critical_state)

#include <nrf_802154/driver/src/nrf_802154_utils.h>

Value:
do \
{ \
(mcu_critical_state) = __get_PRIMASK(); \
__disable_irq(); \
} \
while (0)

Enters critical section on MCU level.

Use nrf_802154_mcu_critical_exit complementary. Consider following code:

// do your critical stuff as fast as possible
#define nrf_802154_mcu_critical_enter(mcu_critical_state)
Enters critical section on MCU level.
Definition: nrf_802154_utils.h:105
#define nrf_802154_mcu_critical_exit(mcu_critical_state)
Exits critical section on MCU level.
Definition: nrf_802154_utils.h:121
uint32_t nrf_802154_mcu_critical_state_t
Type holding MCU critical section state.
Definition: nrf_802154_utils.h:90
Parameters
mcu_critical_stateVariable of nrf_802154_mcu_critical_state_t where current state of MCU level critical section will be stored.