EFR32 Mighty Gecko 12 Software Documentation  efr32mg12-doc-5.1.2
em_smu.h File Reference

Detailed Description

Security Management Unit (SMU) peripheral API.

Version
5.1.2

License

Copyright 2016 Silicon Laboratories, Inc. http://www.silabs.com

Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:

  1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software.
  2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
  3. This notice may not be removed or altered from any source distribution.

DISCLAIMER OF WARRANTY/LIMITATION OF REMEDIES: Silicon Labs has no obligation to support this Software. Silicon Labs is providing the Software "AS IS", with no express or implied warranties of any kind, including, but not limited to, any implied warranties of merchantability or fitness for any particular purpose or warranties against infringement of any proprietary rights of a third party.

Silicon Labs will not be liable for any consequential, incidental, or special damages, or any other relief, or for any claim by any third party, arising from your use of this Software.

Definition in file em_smu.h.

#include "em_device.h"
#include "em_assert.h"
#include "em_bus.h"
#include <stdint.h>
#include <stdbool.h>

Go to the source code of this file.

Data Structures

struct  SMU_Init_TypeDef
 
struct  SMU_PrivilegedAccess_TypeDef
 

Macros

#define SMU_INIT_DEFAULT
 

Enumerations

enum  SMU_Peripheral_TypeDef {
  smuPeripheralACMP0 = _SMU_PPUPATD0_ACMP0_SHIFT,
  smuPeripheralACMP1 = _SMU_PPUPATD0_ACMP1_SHIFT,
  smuPeripheralADC0 = _SMU_PPUPATD0_ADC0_SHIFT,
  smuPeripheralCMU = _SMU_PPUPATD0_CMU_SHIFT,
  smuPeripheralCRYOTIMER = _SMU_PPUPATD0_CRYOTIMER_SHIFT,
  smuPeripheralCRYPTO0 = _SMU_PPUPATD0_CRYPTO0_SHIFT,
  smuPeripheralCRYPTO1 = _SMU_PPUPATD0_CRYPTO1_SHIFT,
  smuPeripheralCSEN = _SMU_PPUPATD0_CSEN_SHIFT,
  smuPeripheralVDAC0 = _SMU_PPUPATD0_VDAC0_SHIFT,
  smuPeripheralPRS = _SMU_PPUPATD0_PRS_SHIFT,
  smuPeripheralEMU = _SMU_PPUPATD0_EMU_SHIFT,
  smuPeripheralFPUEH = _SMU_PPUPATD0_FPUEH_SHIFT,
  smuPeripheralGPCRC = _SMU_PPUPATD0_GPCRC_SHIFT,
  smuPeripheralGPIO = _SMU_PPUPATD0_GPIO_SHIFT,
  smuPeripheralI2C0 = _SMU_PPUPATD0_I2C0_SHIFT,
  smuPeripheralI2C1 = _SMU_PPUPATD0_I2C1_SHIFT,
  smuPeripheralIDAC0 = _SMU_PPUPATD0_IDAC0_SHIFT,
  smuPeripheralMSC = _SMU_PPUPATD0_MSC_SHIFT,
  smuPeripheralLDMA = _SMU_PPUPATD0_LDMA_SHIFT,
  smuPeripheralLESENSE = _SMU_PPUPATD0_LESENSE_SHIFT,
  smuPeripheralLETIMER0 = _SMU_PPUPATD0_LETIMER0_SHIFT,
  smuPeripheralLEUART0 = _SMU_PPUPATD0_LEUART0_SHIFT,
  smuPeripheralPCNT0 = _SMU_PPUPATD0_PCNT0_SHIFT,
  smuPeripheralPCNT1 = _SMU_PPUPATD0_PCNT1_SHIFT,
  smuPeripheralPCNT2 = _SMU_PPUPATD0_PCNT2_SHIFT,
  smuPeripheralRMU = 32 + _SMU_PPUPATD1_RMU_SHIFT,
  smuPeripheralRTCC = 32 + _SMU_PPUPATD1_RTCC_SHIFT,
  smuPeripheralSMU = 32 + _SMU_PPUPATD1_SMU_SHIFT,
  smuPeripheralTIMER0 = 32 + _SMU_PPUPATD1_TIMER0_SHIFT,
  smuPeripheralTIMER1 = 32 + _SMU_PPUPATD1_TIMER1_SHIFT,
  smuPeripheralTRNG0 = 32 + _SMU_PPUPATD1_TRNG0_SHIFT,
  smuPeripheralUSART0 = 32 + _SMU_PPUPATD1_USART0_SHIFT,
  smuPeripheralUSART1 = 32 + _SMU_PPUPATD1_USART1_SHIFT,
  smuPeripheralUSART2 = 32 + _SMU_PPUPATD1_USART2_SHIFT,
  smuPeripheralUSART3 = 32 + _SMU_PPUPATD1_USART3_SHIFT,
  smuPeripheralWDOG0 = 32 + _SMU_PPUPATD1_WDOG0_SHIFT,
  smuPeripheralWDOG1 = 32 + _SMU_PPUPATD1_WDOG1_SHIFT,
  smuPeripheralWTIMER0 = 32 + _SMU_PPUPATD1_WTIMER0_SHIFT,
  smuPeripheralWTIMER1 = 32 + _SMU_PPUPATD1_WTIMER1_SHIFT,
  smuPeripheralEnd
}
 

Functions

__STATIC_INLINE void SMU_EnablePPU (bool enable)
 Enable or disable the Peripheral Protection Unit of the SMU. More...
 
__STATIC_INLINE SMU_Peripheral_TypeDef SMU_GetFaultingPeripheral (void)
 Get the ID of the peripheral that caused an access fault. More...
 
__STATIC_INLINE void SMU_Init (const SMU_Init_TypeDef *init)
 Initialize the Peripheral Protection Unit of the SMU. More...
 
__STATIC_INLINE void SMU_IntClear (uint32_t flags)
 Clear one or more pending SMU interrupts. More...
 
__STATIC_INLINE void SMU_IntDisable (uint32_t flags)
 Disable one or more SMU interrupts. More...
 
__STATIC_INLINE void SMU_IntEnable (uint32_t flags)
 Enable one or more SMU interrupts. More...
 
__STATIC_INLINE uint32_t SMU_IntGet (void)
 Get pending SMU interrupts. More...
 
__STATIC_INLINE uint32_t SMU_IntGetEnabled (void)
 Get enabled and pending SMU interrupt flags. Useful for handling more interrupt sources in the same interrupt handler. More...
 
__STATIC_INLINE void SMU_IntSet (uint32_t flags)
 Set one or more pending SMU interrupts from SW. More...
 
__STATIC_INLINE void SMU_SetPrivilegedAccess (SMU_Peripheral_TypeDef peripheral, bool privileged)
 Change the access settings for a peripheral. More...