MCUXpresso SDK API Reference Manual  Rev. 0
NXP Semiconductors
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Common Driver

Overview

The MCUXpresso SDK provides a driver for the common module of MCUXpresso SDK devices.

Macros

#define ADC_RSTS
 
#define MAKE_STATUS(group, code)   ((((group)*100) + (code)))
 Construct a status code value from a group and code number. More...
 
#define MAKE_VERSION(major, minor, bugfix)   (((major) << 16) | ((minor) << 8) | (bugfix))
 Construct the version number for drivers. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_NONE   0U
 No debug console. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_UART   1U
 Debug console based on UART. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_LPUART   2U
 Debug console based on LPUART. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_LPSCI   3U
 Debug console based on LPSCI. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_USBCDC   4U
 Debug console based on USBCDC. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_FLEXCOMM   5U
 Debug console based on FLEXCOMM. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_IUART   6U
 Debug console based on i.MX UART. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_VUSART   7U
 Debug console based on LPC_VUSART. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_MINI_USART   8U
 Debug console based on LPC_USART. More...
 
#define DEBUG_CONSOLE_DEVICE_TYPE_SWO   9U
 Debug console based on SWO. More...
 
#define ARRAY_SIZE(x)   (sizeof(x) / sizeof((x)[0]))
 Computes the number of elements in an array. More...
 

Typedefs

typedef int32_t status_t
 Type used for all status and error return values. More...
 

Enumerations

enum  SYSCON_RSTn_t {
  kROM_RST_SHIFT_RSTn = 0 | 1U,
  kSRAM1_RST_SHIFT_RSTn = 0 | 3U,
  kSRAM2_RST_SHIFT_RSTn = 0 | 4U,
  kSRAM3_RST_SHIFT_RSTn = 0 | 5U,
  kSRAM4_RST_SHIFT_RSTn = 0 | 6U,
  kFLASH_RST_SHIFT_RSTn = 0 | 7U,
  kFMC_RST_SHIFT_RSTn = 0 | 8U,
  kSPIFI_RST_SHIFT_RSTn = 0 | 10U,
  kMUX0_RST_SHIFT_RSTn = 0 | 11U,
  kIOCON_RST_SHIFT_RSTn = 0 | 13U,
  kGPIO0_RST_SHIFT_RSTn = 0 | 14U,
  kGPIO1_RST_SHIFT_RSTn = 0 | 15U,
  kGPIO2_RST_SHIFT_RSTn = 0 | 16U,
  kGPIO3_RST_SHIFT_RSTn = 0 | 17U,
  kPINT_RST_SHIFT_RSTn = 0 | 18U,
  kGINT_RST_SHIFT_RSTn = 0 | 19U,
  kDMA0_RST_SHIFT_RSTn = 0 | 20U,
  kCRC_RST_SHIFT_RSTn = 0 | 21U,
  kWWDT_RST_SHIFT_RSTn = 0 | 22U,
  kRTC_RST_SHIFT_RSTn = 0 | 23U,
  kMAILBOX_RST_SHIFT_RSTn = 0 | 26U,
  kADC0_RST_SHIFT_RSTn = 0 | 27U,
  kMRT_RST_SHIFT_RSTn = 65536 | 0U,
  kOSTIMER0_RST_SHIFT_RSTn = 65536 | 1U,
  kSCT0_RST_SHIFT_RSTn = 65536 | 2U,
  kSCTIPU_RST_SHIFT_RSTn = 65536 | 6U,
  kUTICK_RST_SHIFT_RSTn = 65536 | 10U,
  kFC0_RST_SHIFT_RSTn = 65536 | 11U,
  kFC1_RST_SHIFT_RSTn = 65536 | 12U,
  kFC2_RST_SHIFT_RSTn = 65536 | 13U,
  kFC3_RST_SHIFT_RSTn = 65536 | 14U,
  kFC4_RST_SHIFT_RSTn = 65536 | 15U,
  kFC5_RST_SHIFT_RSTn = 65536 | 16U,
  kFC6_RST_SHIFT_RSTn = 65536 | 17U,
  kFC7_RST_SHIFT_RSTn = 65536 | 18U,
  kCTIMER2_RST_SHIFT_RSTn = 65536 | 22U,
  kUSB0D_RST_SHIFT_RSTn = 65536 | 25U,
  kCTIMER0_RST_SHIFT_RSTn = 65536 | 26U,
  kCTIMER1_RST_SHIFT_RSTn = 65536 | 27U,
  kPVT_RST_SHIFT_RSTn = 65536 | 28U,
  kEZHA_RST_SHIFT_RSTn = 65536 | 30U,
  kEZHB_RST_SHIFT_RSTn = 65536 | 31U,
  kDMA1_RST_SHIFT_RSTn = 131072 | 1U,
  kCMP_RST_SHIFT_RSTn = 131072 | 2U,
  kSDIO_RST_SHIFT_RSTn = 131072 | 3U,
  kUSB1H_RST_SHIFT_RSTn = 131072 | 4U,
  kUSB1D_RST_SHIFT_RSTn = 131072 | 5U,
  kUSB1RAM_RST_SHIFT_RSTn = 131072 | 6U,
  kUSB1_RST_SHIFT_RSTn = 131072 | 7U,
  kFREQME_RST_SHIFT_RSTn = 131072 | 8U,
  kGPIO4_RST_SHIFT_RSTn = 131072 | 9U,
  kGPIO5_RST_SHIFT_RSTn = 131072 | 10U,
  kAES_RST_SHIFT_RSTn = 131072 | 11U,
  kOTP_RST_SHIFT_RSTn = 131072 | 12U,
  kRNG_RST_SHIFT_RSTn = 131072 | 13U,
  kMUX1_RST_SHIFT_RSTn = 131072 | 14U,
  kUSB0HMR_RST_SHIFT_RSTn = 131072 | 16U,
  kUSB0HSL_RST_SHIFT_RSTn = 131072 | 17U,
  kHASHCRYPT_RST_SHIFT_RSTn = 131072 | 18U,
  kPOWERQUAD_RST_SHIFT_RSTn = 131072 | 19U,
  kPLULUT_RST_SHIFT_RSTn = 131072 | 20U,
  kCTIMER3_RST_SHIFT_RSTn = 131072 | 21U,
  kCTIMER4_RST_SHIFT_RSTn = 131072 | 22U,
  kPUF_RST_SHIFT_RSTn = 131072 | 23U,
  kCASPER_RST_SHIFT_RSTn = 131072 | 24U,
  kCAP0_RST_SHIFT_RSTn = 131072 | 25U,
  kOSTIMER1_RST_SHIFT_RSTn = 131072 | 26U,
  kANALOGCTL_RST_SHIFT_RSTn = 131072 | 27U,
  kHSLSPI_RST_SHIFT_RSTn = 131072 | 28U,
  kGPIOSEC_RST_SHIFT_RSTn = 131072 | 29U,
  kGPIOSECINT_RST_SHIFT_RSTn = 131072 | 30U
}
 Enumeration for peripheral reset control bits. More...
 
enum  _status_groups {
  kStatusGroup_Generic = 0,
  kStatusGroup_FLASH = 1,
  kStatusGroup_LPSPI = 4,
  kStatusGroup_FLEXIO_SPI = 5,
  kStatusGroup_DSPI = 6,
  kStatusGroup_FLEXIO_UART = 7,
  kStatusGroup_FLEXIO_I2C = 8,
  kStatusGroup_LPI2C = 9,
  kStatusGroup_UART = 10,
  kStatusGroup_I2C = 11,
  kStatusGroup_LPSCI = 12,
  kStatusGroup_LPUART = 13,
  kStatusGroup_SPI = 14,
  kStatusGroup_XRDC = 15,
  kStatusGroup_SEMA42 = 16,
  kStatusGroup_SDHC = 17,
  kStatusGroup_SDMMC = 18,
  kStatusGroup_SAI = 19,
  kStatusGroup_MCG = 20,
  kStatusGroup_SCG = 21,
  kStatusGroup_SDSPI = 22,
  kStatusGroup_FLEXIO_I2S = 23,
  kStatusGroup_FLEXIO_MCULCD = 24,
  kStatusGroup_FLASHIAP = 25,
  kStatusGroup_FLEXCOMM_I2C = 26,
  kStatusGroup_I2S = 27,
  kStatusGroup_IUART = 28,
  kStatusGroup_CSI = 29,
  kStatusGroup_MIPI_DSI = 30,
  kStatusGroup_SDRAMC = 35,
  kStatusGroup_POWER = 39,
  kStatusGroup_ENET = 40,
  kStatusGroup_PHY = 41,
  kStatusGroup_TRGMUX = 42,
  kStatusGroup_SMARTCARD = 43,
  kStatusGroup_LMEM = 44,
  kStatusGroup_QSPI = 45,
  kStatusGroup_DMA = 50,
  kStatusGroup_EDMA = 51,
  kStatusGroup_DMAMGR = 52,
  kStatusGroup_FLEXCAN = 53,
  kStatusGroup_LTC = 54,
  kStatusGroup_FLEXIO_CAMERA = 55,
  kStatusGroup_LPC_SPI = 56,
  kStatusGroup_LPC_USART = 57,
  kStatusGroup_DMIC = 58,
  kStatusGroup_SDIF = 59,
  kStatusGroup_SPIFI = 60,
  kStatusGroup_OTP = 61,
  kStatusGroup_MCAN = 62,
  kStatusGroup_CAAM = 63,
  kStatusGroup_ECSPI = 64,
  kStatusGroup_USDHC = 65,
  kStatusGroup_LPC_I2C = 66,
  kStatusGroup_DCP = 67,
  kStatusGroup_MSCAN = 68,
  kStatusGroup_ESAI = 69,
  kStatusGroup_FLEXSPI = 70,
  kStatusGroup_MMDC = 71,
  kStatusGroup_PDM = 72,
  kStatusGroup_SDMA = 73,
  kStatusGroup_ICS = 74,
  kStatusGroup_SPDIF = 75,
  kStatusGroup_LPC_MINISPI = 76,
  kStatusGroup_HASHCRYPT = 77,
  kStatusGroup_LPC_SPI_SSP = 78,
  kStatusGroup_I3C = 79,
  kStatusGroup_LPC_I2C_1 = 97,
  kStatusGroup_NOTIFIER = 98,
  kStatusGroup_DebugConsole = 99,
  kStatusGroup_SEMC = 100,
  kStatusGroup_ApplicationRangeStart = 101,
  kStatusGroup_IAP = 102,
  kStatusGroup_HAL_GPIO = 121,
  kStatusGroup_HAL_UART = 122,
  kStatusGroup_HAL_TIMER = 123,
  kStatusGroup_HAL_SPI = 124,
  kStatusGroup_HAL_I2C = 125,
  kStatusGroup_HAL_FLASH = 126,
  kStatusGroup_HAL_PWM = 127,
  kStatusGroup_HAL_RNG = 128,
  kStatusGroup_TIMERMANAGER = 135,
  kStatusGroup_SERIALMANAGER = 136,
  kStatusGroup_LED = 137,
  kStatusGroup_BUTTON = 138,
  kStatusGroup_EXTERN_EEPROM = 139,
  kStatusGroup_SHELL = 140,
  kStatusGroup_MEM_MANAGER = 141,
  kStatusGroup_LIST = 142,
  kStatusGroup_OSA = 143,
  kStatusGroup_COMMON_TASK = 144,
  kStatusGroup_MSG = 145,
  kStatusGroup_SDK_OCOTP = 146,
  kStatusGroup_SDK_FLEXSPINOR = 147,
  kStatusGroup_CODEC = 148
}
 Status group numbers. More...
 
enum  _generic_status
 Generic status return codes. More...
 

Functions

void RESET_SetPeripheralReset (reset_ip_name_t peripheral)
 Assert reset to peripheral. More...
 
void RESET_ClearPeripheralReset (reset_ip_name_t peripheral)
 Clear reset to peripheral. More...
 
void RESET_PeripheralReset (reset_ip_name_t peripheral)
 Reset peripheral module. More...
 
static status_t EnableIRQ (IRQn_Type interrupt)
 Enable specific interrupt. More...
 
static status_t DisableIRQ (IRQn_Type interrupt)
 Disable specific interrupt. More...
 
static uint32_t DisableGlobalIRQ (void)
 Disable the global IRQ. More...
 
static void EnableGlobalIRQ (uint32_t primask)
 Enable the global IRQ. More...
 
void * SDK_Malloc (size_t size, size_t alignbytes)
 Allocate memory with given alignment and aligned size. More...
 
void SDK_Free (void *ptr)
 Free memory. More...
 

Driver version

#define FSL_RESET_DRIVER_VERSION   (MAKE_VERSION(2, 0, 0))
 reset driver version 2.0.0. More...
 

Driver version

#define FSL_COMMON_DRIVER_VERSION   (MAKE_VERSION(2, 1, 0))
 common driver version 2.0.1. More...
 

Min/max macros

#define MIN(a, b)   (((a) < (b)) ? (a) : (b))
 
#define MAX(a, b)   (((a) > (b)) ? (a) : (b))
 

UINT16_MAX/UINT32_MAX value

#define UINT16_MAX   ((uint16_t)-1)
 
#define UINT32_MAX   ((uint32_t)-1)
 

Timer utilities

#define USEC_TO_COUNT(us, clockFreqInHz)   (uint64_t)((uint64_t)us * clockFreqInHz / 1000000U)
 Macro to convert a microsecond period to raw count value.
 
#define COUNT_TO_USEC(count, clockFreqInHz)   (uint64_t)((uint64_t)count * 1000000U / clockFreqInHz)
 Macro to convert a raw count value to microsecond.
 
#define MSEC_TO_COUNT(ms, clockFreqInHz)   (uint64_t)((uint64_t)ms * clockFreqInHz / 1000U)
 Macro to convert a millisecond period to raw count value.
 
#define COUNT_TO_MSEC(count, clockFreqInHz)   (uint64_t)((uint64_t)count * 1000U / clockFreqInHz)
 Macro to convert a raw count value to millisecond.
 

Alignment variable definition macros

#define SDK_ALIGN(var, alignbytes)   var
 
#define SDK_SIZEALIGN(var, alignbytes)   ((unsigned int)((var) + ((alignbytes)-1)) & (unsigned int)(~(unsigned int)((alignbytes)-1)))
 Macro to change a value to a given size aligned value.
 

Non-cacheable region definition macros

#define AT_NONCACHEABLE_SECTION(var)   var
 
#define AT_NONCACHEABLE_SECTION_ALIGN(var, alignbytes)   var
 
#define AT_NONCACHEABLE_SECTION_INIT(var)   var
 
#define AT_NONCACHEABLE_SECTION_ALIGN_INIT(var, alignbytes)   var
 

Macro Definition Documentation

#define FSL_RESET_DRIVER_VERSION   (MAKE_VERSION(2, 0, 0))
#define ADC_RSTS
Value:
{ \
} /* Reset bits for ADC peripheral */
Definition: fsl_reset.h:61

Array initializers with peripheral reset bits

#define MAKE_STATUS (   group,
  code 
)    ((((group)*100) + (code)))
#define MAKE_VERSION (   major,
  minor,
  bugfix 
)    (((major) << 16) | ((minor) << 8) | (bugfix))
#define FSL_COMMON_DRIVER_VERSION   (MAKE_VERSION(2, 1, 0))
#define DEBUG_CONSOLE_DEVICE_TYPE_NONE   0U
#define DEBUG_CONSOLE_DEVICE_TYPE_UART   1U
#define DEBUG_CONSOLE_DEVICE_TYPE_LPUART   2U
#define DEBUG_CONSOLE_DEVICE_TYPE_LPSCI   3U
#define DEBUG_CONSOLE_DEVICE_TYPE_USBCDC   4U
#define DEBUG_CONSOLE_DEVICE_TYPE_FLEXCOMM   5U
#define DEBUG_CONSOLE_DEVICE_TYPE_IUART   6U
#define DEBUG_CONSOLE_DEVICE_TYPE_VUSART   7U
#define DEBUG_CONSOLE_DEVICE_TYPE_MINI_USART   8U
#define DEBUG_CONSOLE_DEVICE_TYPE_SWO   9U
#define ARRAY_SIZE (   x)    (sizeof(x) / sizeof((x)[0]))

Typedef Documentation

typedef int32_t status_t

Enumeration Type Documentation

Defines the enumeration for peripheral reset control bits in PRESETCTRL/ASYNCPRESETCTRL registers

Enumerator
kROM_RST_SHIFT_RSTn 

ROM reset control

kSRAM1_RST_SHIFT_RSTn 

SRAM1 reset control

kSRAM2_RST_SHIFT_RSTn 

SRAM2 reset control

kSRAM3_RST_SHIFT_RSTn 

SRAM3 reset control

kSRAM4_RST_SHIFT_RSTn 

SRAM4 reset control

kFLASH_RST_SHIFT_RSTn 

Flash controller reset control

kFMC_RST_SHIFT_RSTn 

Flash accelerator reset control

kSPIFI_RST_SHIFT_RSTn 

SPIFI reset control

kMUX0_RST_SHIFT_RSTn 

Input mux0 reset control

kIOCON_RST_SHIFT_RSTn 

IOCON reset control

kGPIO0_RST_SHIFT_RSTn 

GPIO0 reset control

kGPIO1_RST_SHIFT_RSTn 

GPIO1 reset control

kGPIO2_RST_SHIFT_RSTn 

GPIO2 reset control

kGPIO3_RST_SHIFT_RSTn 

GPIO3 reset control

kPINT_RST_SHIFT_RSTn 

Pin interrupt (PINT) reset control

kGINT_RST_SHIFT_RSTn 

Grouped interrupt (PINT) reset control.

kDMA0_RST_SHIFT_RSTn 

DMA reset control

kCRC_RST_SHIFT_RSTn 

CRC reset control

kWWDT_RST_SHIFT_RSTn 

Watchdog timer reset control

kRTC_RST_SHIFT_RSTn 

RTC reset control

kMAILBOX_RST_SHIFT_RSTn 

Mailbox reset control

kADC0_RST_SHIFT_RSTn 

ADC0 reset control

kMRT_RST_SHIFT_RSTn 

Multi-rate timer (MRT) reset control

kOSTIMER0_RST_SHIFT_RSTn 

OSTimer0 reset control

kSCT0_RST_SHIFT_RSTn 

SCTimer/PWM 0 (SCT0) reset control

kSCTIPU_RST_SHIFT_RSTn 

SCTIPU reset control

kUTICK_RST_SHIFT_RSTn 

Micro-tick timer reset control

kFC0_RST_SHIFT_RSTn 

Flexcomm Interface 0 reset control

kFC1_RST_SHIFT_RSTn 

Flexcomm Interface 1 reset control

kFC2_RST_SHIFT_RSTn 

Flexcomm Interface 2 reset control

kFC3_RST_SHIFT_RSTn 

Flexcomm Interface 3 reset control

kFC4_RST_SHIFT_RSTn 

Flexcomm Interface 4 reset control

kFC5_RST_SHIFT_RSTn 

Flexcomm Interface 5 reset control

kFC6_RST_SHIFT_RSTn 

Flexcomm Interface 6 reset control

kFC7_RST_SHIFT_RSTn 

Flexcomm Interface 7 reset control

kCTIMER2_RST_SHIFT_RSTn 

CTimer 2 reset control

kUSB0D_RST_SHIFT_RSTn 

USB0 Device reset control

kCTIMER0_RST_SHIFT_RSTn 

CTimer 0 reset control

kCTIMER1_RST_SHIFT_RSTn 

CTimer 1 reset control

kPVT_RST_SHIFT_RSTn 

PVT reset control

kEZHA_RST_SHIFT_RSTn 

EZHA reset control

kEZHB_RST_SHIFT_RSTn 

EZHB reset control

kDMA1_RST_SHIFT_RSTn 

DMA1 reset control

kCMP_RST_SHIFT_RSTn 

CMP reset control

kSDIO_RST_SHIFT_RSTn 

SDIO reset control

kUSB1H_RST_SHIFT_RSTn 

USBHS Host reset control

kUSB1D_RST_SHIFT_RSTn 

USBHS Device reset control

kUSB1RAM_RST_SHIFT_RSTn 

USB RAM reset control

kUSB1_RST_SHIFT_RSTn 

USBHS reset control

kFREQME_RST_SHIFT_RSTn 

FREQME reset control

kGPIO4_RST_SHIFT_RSTn 

GPIO4 reset control

kGPIO5_RST_SHIFT_RSTn 

GPIO5 reset control

kAES_RST_SHIFT_RSTn 

AES reset control

kOTP_RST_SHIFT_RSTn 

OTP reset control

kRNG_RST_SHIFT_RSTn 

RNG reset control

kMUX1_RST_SHIFT_RSTn 

Input mux1 reset control

kUSB0HMR_RST_SHIFT_RSTn 

USB0HMR reset control

kUSB0HSL_RST_SHIFT_RSTn 

USB0HSL reset control

kHASHCRYPT_RST_SHIFT_RSTn 

HASHCRYPT reset control

kPOWERQUAD_RST_SHIFT_RSTn 

PowerQuad reset control

kPLULUT_RST_SHIFT_RSTn 

PLU LUT reset control

kCTIMER3_RST_SHIFT_RSTn 

CTimer 3 reset control

kCTIMER4_RST_SHIFT_RSTn 

CTimer 4 reset control

kPUF_RST_SHIFT_RSTn 

PUF reset control

kCASPER_RST_SHIFT_RSTn 

CASPER reset control

kCAP0_RST_SHIFT_RSTn 

CASPER reset control

kOSTIMER1_RST_SHIFT_RSTn 

OSTIMER1 reset control

kANALOGCTL_RST_SHIFT_RSTn 

ANALOG_CTL reset control

kHSLSPI_RST_SHIFT_RSTn 

HS LSPI reset control

kGPIOSEC_RST_SHIFT_RSTn 

GPIO Secure reset control

kGPIOSECINT_RST_SHIFT_RSTn 

GPIO Secure int reset control

Enumerator
kStatusGroup_Generic 

Group number for generic status codes.

kStatusGroup_FLASH 

Group number for FLASH status codes.

kStatusGroup_LPSPI 

Group number for LPSPI status codes.

kStatusGroup_FLEXIO_SPI 

Group number for FLEXIO SPI status codes.

kStatusGroup_DSPI 

Group number for DSPI status codes.

kStatusGroup_FLEXIO_UART 

Group number for FLEXIO UART status codes.

kStatusGroup_FLEXIO_I2C 

Group number for FLEXIO I2C status codes.

kStatusGroup_LPI2C 

Group number for LPI2C status codes.

kStatusGroup_UART 

Group number for UART status codes.

kStatusGroup_I2C 

Group number for UART status codes.

kStatusGroup_LPSCI 

Group number for LPSCI status codes.

kStatusGroup_LPUART 

Group number for LPUART status codes.

kStatusGroup_SPI 

Group number for SPI status code.

kStatusGroup_XRDC 

Group number for XRDC status code.

kStatusGroup_SEMA42 

Group number for SEMA42 status code.

kStatusGroup_SDHC 

Group number for SDHC status code.

kStatusGroup_SDMMC 

Group number for SDMMC status code.

kStatusGroup_SAI 

Group number for SAI status code.

kStatusGroup_MCG 

Group number for MCG status codes.

kStatusGroup_SCG 

Group number for SCG status codes.

kStatusGroup_SDSPI 

Group number for SDSPI status codes.

kStatusGroup_FLEXIO_I2S 

Group number for FLEXIO I2S status codes.

kStatusGroup_FLEXIO_MCULCD 

Group number for FLEXIO LCD status codes.

kStatusGroup_FLASHIAP 

Group number for FLASHIAP status codes.

kStatusGroup_FLEXCOMM_I2C 

Group number for FLEXCOMM I2C status codes.

kStatusGroup_I2S 

Group number for I2S status codes.

kStatusGroup_IUART 

Group number for IUART status codes.

kStatusGroup_CSI 

Group number for CSI status codes.

kStatusGroup_MIPI_DSI 

Group number for MIPI DSI status codes.

kStatusGroup_SDRAMC 

Group number for SDRAMC status codes.

kStatusGroup_POWER 

Group number for POWER status codes.

kStatusGroup_ENET 

Group number for ENET status codes.

kStatusGroup_PHY 

Group number for PHY status codes.

kStatusGroup_TRGMUX 

Group number for TRGMUX status codes.

kStatusGroup_SMARTCARD 

Group number for SMARTCARD status codes.

kStatusGroup_LMEM 

Group number for LMEM status codes.

kStatusGroup_QSPI 

Group number for QSPI status codes.

kStatusGroup_DMA 

Group number for DMA status codes.

kStatusGroup_EDMA 

Group number for EDMA status codes.

kStatusGroup_DMAMGR 

Group number for DMAMGR status codes.

kStatusGroup_FLEXCAN 

Group number for FlexCAN status codes.

kStatusGroup_LTC 

Group number for LTC status codes.

kStatusGroup_FLEXIO_CAMERA 

Group number for FLEXIO CAMERA status codes.

kStatusGroup_LPC_SPI 

Group number for LPC_SPI status codes.

kStatusGroup_LPC_USART 

Group number for LPC_USART status codes.

kStatusGroup_DMIC 

Group number for DMIC status codes.

kStatusGroup_SDIF 

Group number for SDIF status codes.

kStatusGroup_SPIFI 

Group number for SPIFI status codes.

kStatusGroup_OTP 

Group number for OTP status codes.

kStatusGroup_MCAN 

Group number for MCAN status codes.

kStatusGroup_CAAM 

Group number for CAAM status codes.

kStatusGroup_ECSPI 

Group number for ECSPI status codes.

kStatusGroup_USDHC 

Group number for USDHC status codes.

kStatusGroup_LPC_I2C 

Group number for LPC_I2C status codes.

kStatusGroup_DCP 

Group number for DCP status codes.

kStatusGroup_MSCAN 

Group number for MSCAN status codes.

kStatusGroup_ESAI 

Group number for ESAI status codes.

kStatusGroup_FLEXSPI 

Group number for FLEXSPI status codes.

kStatusGroup_MMDC 

Group number for MMDC status codes.

kStatusGroup_PDM 

Group number for MIC status codes.

kStatusGroup_SDMA 

Group number for SDMA status codes.

kStatusGroup_ICS 

Group number for ICS status codes.

kStatusGroup_SPDIF 

Group number for SPDIF status codes.

kStatusGroup_LPC_MINISPI 

Group number for LPC_MINISPI status codes.

kStatusGroup_HASHCRYPT 

Group number for Hashcrypt status codes.

kStatusGroup_LPC_SPI_SSP 

Group number for LPC_SPI_SSP status codes.

kStatusGroup_I3C 

Group number for I3C status codes.

kStatusGroup_LPC_I2C_1 

Group number for LPC_I2C_1 status codes.

kStatusGroup_NOTIFIER 

Group number for NOTIFIER status codes.

kStatusGroup_DebugConsole 

Group number for debug console status codes.

kStatusGroup_SEMC 

Group number for SEMC status codes.

kStatusGroup_ApplicationRangeStart 

Starting number for application groups.

kStatusGroup_IAP 

Group number for IAP status codes.

kStatusGroup_HAL_GPIO 

Group number for HAL GPIO status codes.

kStatusGroup_HAL_UART 

Group number for HAL UART status codes.

kStatusGroup_HAL_TIMER 

Group number for HAL TIMER status codes.

kStatusGroup_HAL_SPI 

Group number for HAL SPI status codes.

kStatusGroup_HAL_I2C 

Group number for HAL I2C status codes.

kStatusGroup_HAL_FLASH 

Group number for HAL FLASH status codes.

kStatusGroup_HAL_PWM 

Group number for HAL PWM status codes.

kStatusGroup_HAL_RNG 

Group number for HAL RNG status codes.

kStatusGroup_TIMERMANAGER 

Group number for TiMER MANAGER status codes.

kStatusGroup_SERIALMANAGER 

Group number for SERIAL MANAGER status codes.

kStatusGroup_LED 

Group number for LED status codes.

kStatusGroup_BUTTON 

Group number for BUTTON status codes.

kStatusGroup_EXTERN_EEPROM 

Group number for EXTERN EEPROM status codes.

kStatusGroup_SHELL 

Group number for SHELL status codes.

kStatusGroup_MEM_MANAGER 

Group number for MEM MANAGER status codes.

kStatusGroup_LIST 

Group number for List status codes.

kStatusGroup_OSA 

Group number for OSA status codes.

kStatusGroup_COMMON_TASK 

Group number for Common task status codes.

kStatusGroup_MSG 

Group number for messaging status codes.

kStatusGroup_SDK_OCOTP 

Group number for OCOTP status codes.

kStatusGroup_SDK_FLEXSPINOR 

Group number for FLEXSPINOR status codes.

kStatusGroup_CODEC 

Group number for codec status codes.

Function Documentation

void RESET_SetPeripheralReset ( reset_ip_name_t  peripheral)

Asserts reset signal to specified peripheral module.

Parameters
peripheralAssert reset to this peripheral. The enum argument contains encoding of reset register and reset bit position in the reset register.
void RESET_ClearPeripheralReset ( reset_ip_name_t  peripheral)

Clears reset signal to specified peripheral module, allows it to operate.

Parameters
peripheralClear reset to this peripheral. The enum argument contains encoding of reset register and reset bit position in the reset register.
void RESET_PeripheralReset ( reset_ip_name_t  peripheral)

Reset peripheral module.

Parameters
peripheralPeripheral to reset. The enum argument contains encoding of reset register and reset bit position in the reset register.
static status_t EnableIRQ ( IRQn_Type  interrupt)
inlinestatic

Enable LEVEL1 interrupt. For some devices, there might be multiple interrupt levels. For example, there are NVIC and intmux. Here the interrupts connected to NVIC are the LEVEL1 interrupts, because they are routed to the core directly. The interrupts connected to intmux are the LEVEL2 interrupts, they are routed to NVIC first then routed to core.

This function only enables the LEVEL1 interrupts. The number of LEVEL1 interrupts is indicated by the feature macro FSL_FEATURE_NUMBER_OF_LEVEL1_INT_VECTORS.

Parameters
interruptThe IRQ number.
Return values
kStatus_SuccessInterrupt enabled successfully
kStatus_FailFailed to enable the interrupt
static status_t DisableIRQ ( IRQn_Type  interrupt)
inlinestatic

Disable LEVEL1 interrupt. For some devices, there might be multiple interrupt levels. For example, there are NVIC and intmux. Here the interrupts connected to NVIC are the LEVEL1 interrupts, because they are routed to the core directly. The interrupts connected to intmux are the LEVEL2 interrupts, they are routed to NVIC first then routed to core.

This function only disables the LEVEL1 interrupts. The number of LEVEL1 interrupts is indicated by the feature macro FSL_FEATURE_NUMBER_OF_LEVEL1_INT_VECTORS.

Parameters
interruptThe IRQ number.
Return values
kStatus_SuccessInterrupt disabled successfully
kStatus_FailFailed to disable the interrupt
static uint32_t DisableGlobalIRQ ( void  )
inlinestatic

Disable the global interrupt and return the current primask register. User is required to provided the primask register for the EnableGlobalIRQ().

Returns
Current primask value.
static void EnableGlobalIRQ ( uint32_t  primask)
inlinestatic

Set the primask register with the provided primask value but not just enable the primask. The idea is for the convenience of integration of RTOS. some RTOS get its own management mechanism of primask. User is required to use the EnableGlobalIRQ() and DisableGlobalIRQ() in pair.

Parameters
primaskvalue of primask register to be restored. The primask value is supposed to be provided by the DisableGlobalIRQ().
void* SDK_Malloc ( size_t  size,
size_t  alignbytes 
)

This is provided to support the dynamically allocated memory used in cache-able region.

Parameters
sizeThe length required to malloc.
alignbytesThe alignment size.
Return values
Theallocated memory.
void SDK_Free ( void *  ptr)
Parameters
ptrThe memory to be release.