| S212 SoftDevice v2.0.0 |

Choose documentation: | nRF5 SDK | S130 SoftDevice API | S132 SoftDevice API | S212 SoftDevice API | S332 SoftDevice API

All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Functions
SoftDevice NVIC public functions
SoftDevice NVIC API

## Functions
static uint32_t | sd_nvic_EnableIRQ (IRQn_Type IRQn)
| Enable External Interrupt. More...
static uint32_t | sd_nvic_DisableIRQ (IRQn_Type IRQn)
| Disable External Interrupt. More...
static uint32_t | sd_nvic_GetPendingIRQ (IRQn_Type IRQn, uint32_t *p_pending_irq)
| Get Pending Interrupt. More...
static uint32_t | sd_nvic_SetPendingIRQ (IRQn_Type IRQn)
| Set Pending Interrupt. More...
static uint32_t | sd_nvic_ClearPendingIRQ (IRQn_Type IRQn)
| Clear Pending Interrupt. More...
static uint32_t | sd_nvic_SetPriority (IRQn_Type IRQn, uint32_t priority)
| Set Interrupt Priority. More...
static uint32_t | sd_nvic_GetPriority (IRQn_Type IRQn, uint32_t *p_priority)
| Get Interrupt Priority. More...
static uint32_t | sd_nvic_SystemReset (void)
| System Reset. More...
static uint32_t | sd_nvic_critical_region_enter (uint8_t *p_is_nested_critical_region)
| Enters critical region. More...
static uint32_t | sd_nvic_critical_region_exit (uint8_t is_nested_critical_region)
| Exit critical region. More...

## Detailed Description

## Function Documentation

static uint32_t sd_nvic_ClearPendingIRQ | ( | IRQn_Type | IRQn | ) |
| inline static

Clear Pending Interrupt.

Note
  Corresponds to NVIC_ClearPendingIRQ in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_ClearPendingIRQ documentation in CMSIS.

Return values

  NRF_SUCCESS | The interrupt pending flag is cleared.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | IRQn is not available for the application.

static uint32_t sd_nvic_critical_region_enter | ( | uint8_t * | p_is_nested_critical_region | ) |
| inline static

Enters critical region.

Postcondition
  Application interrupts will be disabled.

Note
  sd_nvic_critical_region_enter() and sd_nvic_critical_region_exit() must be called in matching pairs inside each execution context

See Also
  sd_nvic_critical_region_exit

Parameters

  [out] | p_is_nested_critical_region | If 1, the application is now in a nested critical region.

Return values

  NRF_SUCCESS |

static uint32_t sd_nvic_critical_region_exit | ( | uint8_t | is_nested_critical_region | ) |
| inline static

Exit critical region.

Precondition
  Application has entered a critical region using sd_nvic_critical_region_enter.

Postcondition
  If not in a nested critical region, the application interrupts will restored to the state before sd_nvic_critical_region_enter was called.

Parameters

  [in] | is_nested_critical_region | If this is set to 1, the critical region won't be exited.

See Also
  sd_nvic_critical_region_enter.

Return values

  NRF_SUCCESS |

static uint32_t sd_nvic_DisableIRQ | ( | IRQn_Type | IRQn | ) |
| inline static

Disable External Interrupt.

Note
  Corresponds to NVIC_DisableIRQ in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_DisableIRQ documentation in CMSIS.

Return values

  NRF_SUCCESS | The interrupt was disabled.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | The interrupt is not available for the application.

static uint32_t sd_nvic_EnableIRQ | ( | IRQn_Type | IRQn | ) |
| inline static

Enable External Interrupt.

Note
  Corresponds to NVIC_EnableIRQ in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_EnableIRQ documentation in CMSIS.

Return values

  NRF_SUCCESS | The interrupt was enabled.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | The interrupt is not available for the application.
  NRF_ERROR_SOC_NVIC_INTERRUPT_PRIORITY_NOT_ALLOWED | The interrupt has a priority not available for the application.

static uint32_t sd_nvic_GetPendingIRQ | ( | IRQn_Type | IRQn,
|  | uint32_t * | p_pending_irq
| ) |  |
| inline static

Get Pending Interrupt.

Note
  Corresponds to NVIC_GetPendingIRQ in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_GetPendingIRQ documentation in CMSIS.
  [out] | p_pending_irq | Return value from NVIC_GetPendingIRQ.

Return values

  NRF_SUCCESS | The interrupt is available for the application.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | IRQn is not available for the application.

static uint32_t sd_nvic_GetPriority | ( | IRQn_Type | IRQn,
|  | uint32_t * | p_priority
| ) |  |
| inline static

Get Interrupt Priority.

Note
  Corresponds to NVIC_GetPriority in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_GetPriority documentation in CMSIS.
  [out] | p_priority | Return value from NVIC_GetPriority.

Return values

  NRF_SUCCESS | The interrupt priority is returned in p_priority.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | - IRQn is not available for the application.

static uint32_t sd_nvic_SetPendingIRQ | ( | IRQn_Type | IRQn | ) |
| inline static

Set Pending Interrupt.

Note
  Corresponds to NVIC_SetPendingIRQ in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_SetPendingIRQ documentation in CMSIS.

Return values

  NRF_SUCCESS | The interrupt is set pending.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | IRQn is not available for the application.

static uint32_t sd_nvic_SetPriority | ( | IRQn_Type | IRQn,
|  | uint32_t | priority
| ) |  |
| inline static

Set Interrupt Priority.

Note
  Corresponds to NVIC_SetPriority in CMSIS.

Precondition
  IRQn is valid and not reserved by the stack.
  Priority is valid and not reserved by the stack.

Parameters

  [in] | IRQn | See the NVIC_SetPriority documentation in CMSIS.
  [in] | priority | A valid IRQ priority for use by the application.

Return values

  NRF_SUCCESS | The interrupt and priority level is available for the application.
  NRF_ERROR_SOC_NVIC_INTERRUPT_NOT_AVAILABLE | IRQn is not available for the application.
  NRF_ERROR_SOC_NVIC_INTERRUPT_PRIORITY_NOT_ALLOWED | The interrupt priority is not available for the application.

static uint32_t sd_nvic_SystemReset | ( | void |  | ) |
| inline static

System Reset.

Note
  Corresponds to NVIC_SystemReset in CMSIS.

Return values

  NRF_ERROR_SOC_NVIC_SHOULD_NOT_RETURN |