Kinetis SDK v.1.3 API Reference Manual  Rev. 0
Freescale Semiconductor, Inc.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
fsl_clock_MKL28T7.h File Reference
#include "fsl_sim_hal.h"
#include "fsl_scg_hal.h"
#include "fsl_pcc_hal.h"

Data Structures

struct  sim_config_kl28t7_t
 SIM configuration structure for dynamic clock setting. More...
 

Macros

#define TPM_EXT_CLK_COUNT   2
 TPM external clock source count. More...
 
#define CLOCK_CONFIG_NUM   2
 Default clock configuration number. More...
 
#define CLOCK_CONFIG_INDEX_FOR_VLPR   0
 Clock configuration index for VLPR mode. More...
 
#define CLOCK_CONFIG_INDEX_FOR_RUN   1
 Clock configuration index for RUN mode. More...
 

Typedefs

typedef clock_ip_src_t clock_tpm_src_t
 
typedef clock_ip_src_t clock_lpuart_src_t
 
typedef clock_ip_src_t clock_lpi2c_src_t
 
typedef clock_ip_src_t clock_lpspi_src_t
 
typedef clock_ip_src_t clock_pit_src_t
 
typedef clock_ip_src_t clock_flexio_src_t
 
typedef clock_ip_src_t clock_evmsim_src_t
 
typedef clock_ip_src_t clock_usbfs_src_t
 

Functions

uint32_t CLOCK_SYS_GetExternalRefClock32kFreq (void)
 Gets the external reference 32k clock frequency. More...
 
static void CLOCK_SYS_SetExternalRefClock32kSrc (clock_er32k_src_t src)
 Set the clock selection of ERCLK32K. More...
 
static clock_er32k_src_t CLOCK_SYS_GetExternalRefClock32kSrc (void)
 Get the clock selection of ERCLK32K. More...
 
uint32_t CLOCK_SYS_GetOsc0ExternalRefClockFreq (void)
 Gets the OSC0ERCLK frequency. More...
 
uint32_t CLOCK_SYS_GetRtcOutFreq (void)
 Gets RTC_CLKOUT frequency. More...
 
void CLOCK_SYS_EnableXrdcClock (uint32_t instance)
 Enable the clock for XRDC module. More...
 
void CLOCK_SYS_DisableXrdcClock (uint32_t instance)
 Disable the clock for XRDC module. More...
 
bool CLOCK_SYS_GetXrdcGateCmd (uint32_t instance)
 Get the the clock gate state for XRDC module. More...
 
void CLOCK_SYS_EnableSemaClock (uint32_t instance)
 Enable the clock for SEMA module. More...
 
void CLOCK_SYS_DisableSemaClock (uint32_t instance)
 Disable the clock for SEMA module. More...
 
bool CLOCK_SYS_GetSemaGateCmd (uint32_t instance)
 Get the the clock gate state for SEMA module. More...
 
void CLOCK_SYS_EnableFlashClock (uint32_t instance)
 Enable the clock for FLASH module. More...
 
void CLOCK_SYS_DisableFlashClock (uint32_t instance)
 Disable the clock for FLASH module. More...
 
bool CLOCK_SYS_GetFlashGateCmd (uint32_t instance)
 Get the the clock gate state for FLASH module. More...
 
static void CLOCK_SYS_EnableDmamuxClock (uint32_t instance)
 Enable the clock for DMAMUX module. More...
 
static void CLOCK_SYS_DisableDmamuxClock (uint32_t instance)
 Disable the clock for DMAMUX module. More...
 
static bool CLOCK_SYS_GetDmamuxGateCmd (uint32_t instance)
 Get the the clock gate state for DMAMUX module. More...
 
void CLOCK_SYS_EnableMuClock (uint32_t instance)
 Enable the clock for MU module. More...
 
void CLOCK_SYS_DisableMuClock (uint32_t instance)
 Disable the clock for MU module. More...
 
bool CLOCK_SYS_GetMuGateCmd (uint32_t instance)
 Get the the clock gate state for MU module. More...
 
void CLOCK_SYS_EnableIntmuxClock (uint32_t instance)
 Enable the clock for INTMUX module. More...
 
void CLOCK_SYS_DisableIntmuxClock (uint32_t instance)
 Disable the clock for INTMUX module. More...
 
bool CLOCK_SYS_GetIntmuxGateCmd (uint32_t instance)
 Get the the clock gate state for INTMUX module. More...
 
void CLOCK_SYS_EnableTpmClock (uint32_t instance)
 Enable the clock for TPM module. More...
 
void CLOCK_SYS_DisableTpmClock (uint32_t instance)
 Disable the clock for TPM module. More...
 
bool CLOCK_SYS_GetTpmGateCmd (uint32_t instance)
 Get the the clock gate state for TPM module. More...
 
static clock_tpm_src_t CLOCK_SYS_GetTpmSrc (uint32_t instance)
 Get the TPM clock source selection. More...
 
static void CLOCK_SYS_SetTpmSrc (uint32_t instance, clock_tpm_src_t tpmSrc)
 Set the TPM clock source selection. More...
 
uint32_t CLOCK_SYS_GetTpmFreq (uint32_t instance)
 Gets TPM clock frequency. More...
 
uint32_t CLOCK_SYS_GetTpmExternalFreq (uint32_t instance)
 Get the TPM external clock source frequency. More...
 
static void CLOCK_SYS_EnablePitClock (uint32_t instance)
 Enable the clock for PIT module. More...
 
static void CLOCK_SYS_DisablePitClock (uint32_t instance)
 Disable the clock for PIT module. More...
 
static bool CLOCK_SYS_GetPitGateCmd (uint32_t instance)
 Get the the clock gate state for PIT module. More...
 
clock_pit_src_t CLOCK_SYS_GetPitSrc (uint32_t instance)
 Gets the clock source for PIT module. More...
 
void CLOCK_SYS_SetPitSrc (uint32_t instance, clock_pit_src_t pitSrc)
 Sets the clock source for PIT module. More...
 
static uint32_t CLOCK_SYS_GetPitFreq (uint32_t instance)
 Gets the clock frequency for PIT module. More...
 
static void CLOCK_SYS_EnableLptmrClock (uint32_t instance)
 Enable the clock for LPTIMER module. More...
 
static void CLOCK_SYS_DisableLptmrClock (uint32_t instance)
 Disable the clock for LPTIMER module. More...
 
static bool CLOCK_SYS_GetLptmrGateCmd (uint32_t instance)
 Get the the clock gate state for LPTIMER module. More...
 
uint32_t CLOCK_SYS_GetLptmrFreq (uint32_t instance, clock_lptmr_src_t lptmrSrc)
 Gets LPTMRx pre-scaler/glitch filter clock frequency. More...
 
static void CLOCK_SYS_EnableRtcClock (uint32_t instance)
 Enable the clock for RTC module. More...
 
static void CLOCK_SYS_DisableRtcClock (uint32_t instance)
 Disable the clock for RTC module. More...
 
static bool CLOCK_SYS_GetRtcGateCmd (uint32_t instance)
 Get the the clock gate state for RTC module. More...
 
void CLOCK_SYS_EnableLpspiClock (uint32_t instance)
 Enable the clock for LPSPI module. More...
 
void CLOCK_SYS_DisableLpspiClock (uint32_t instance)
 Disable the clock for LPSPI module. More...
 
bool CLOCK_SYS_GetLpspiGateCmd (uint32_t instance)
 Get the the clock gate state for LPSPI module. More...
 
clock_lpspi_src_t CLOCK_SYS_GetLpspiSrc (uint32_t instance)
 Gets the clock source for LPSPI module. More...
 
void CLOCK_SYS_SetLpspiSrc (uint32_t instance, clock_lpspi_src_t lpspiSrc)
 Sets the clock source for LPSPI module. More...
 
uint32_t CLOCK_SYS_GetLpspiFreq (uint32_t instance)
 Gets the clock frequency for LPSPI module. More...
 
void CLOCK_SYS_EnableLpi2cClock (uint32_t instance)
 Enable the clock for LPI2C module. More...
 
void CLOCK_SYS_DisableLpi2cClock (uint32_t instance)
 Disable the clock for LPI2C module. More...
 
bool CLOCK_SYS_GetLpi2cGateCmd (uint32_t instance)
 Get the the clock gate state for LPI2C module. More...
 
clock_lpi2c_src_t CLOCK_SYS_GetLpi2cSrc (uint32_t instance)
 Gets the clock source for LPI2C module. More...
 
void CLOCK_SYS_SetLpi2cSrc (uint32_t instance, clock_lpi2c_src_t lpi2cSrc)
 Sets the clock source for LPI2C module. More...
 
uint32_t CLOCK_SYS_GetLpi2cFreq (uint32_t instance)
 Gets the clock frequency for LPI2C module. More...
 
static void CLOCK_SYS_EnableLpuartClock (uint32_t instance)
 Enable the clock for LPUART module. More...
 
static void CLOCK_SYS_DisableLpuartClock (uint32_t instance)
 Disable the clock for LPUART module. More...
 
static bool CLOCK_SYS_GetLpuartGateCmd (uint32_t instance)
 Get the the clock gate state for LPUART module. More...
 
static clock_lpuart_src_t CLOCK_SYS_GetLpuartSrc (uint32_t instance)
 Gets the clock source for LPUART module. More...
 
static void CLOCK_SYS_SetLpuartSrc (uint32_t instance, clock_lpuart_src_t lpuartSrc)
 Sets the clock source for LPUART module. More...
 
uint32_t CLOCK_SYS_GetLpuartFreq (uint32_t instance)
 Gets the clock frequency for LPUART module. More...
 
static void CLOCK_SYS_EnableSaiClock (uint32_t instance)
 Enable the clock for SAI module. More...
 
static void CLOCK_SYS_DisableSaiClock (uint32_t instance)
 Disable the clock for SAI module. More...
 
static bool CLOCK_SYS_GetSaiGateCmd (uint32_t instance)
 Get the the clock gate state for SAI module. More...
 
uint32_t CLOCK_SYS_GetSaiFreq (uint32_t instance, clock_sai_src_t saiSrc)
 Gets the clock frequency for SAI. More...
 
void CLOCK_SYS_EnableEvmsimClock (uint32_t instance)
 Enable the clock for EVMSIM module. More...
 
void CLOCK_SYS_DisableEvmsimClock (uint32_t instance)
 Disable the clock for EVMSIM module. More...
 
bool CLOCK_SYS_GetEvmsimGateCmd (uint32_t instance)
 Get the the clock gate state for EVMSIM module. More...
 
clock_evmsim_src_t CLOCK_SYS_GetEvmsimSrc (uint32_t instance)
 Gets the clock source for EVMSIM module. More...
 
void CLOCK_SYS_SetEvmsimSrc (uint32_t instance, clock_evmsim_src_t evmsimSrc)
 Sets the clock source for EVMSIM module. More...
 
uint32_t CLOCK_SYS_GetEvmsimFreq (uint32_t instance)
 Gets the clock frequency for EVMSIM module. More...
 
static void CLOCK_SYS_EnableUsbfsClock (uint32_t instance)
 Enable the clock for USBFS module. More...
 
static void CLOCK_SYS_DisableUsbfsClock (uint32_t instance)
 Disable the clock for USBFS module. More...
 
static bool CLOCK_SYS_GetUsbfsGateCmd (uint32_t instance)
 Get the the clock gate state for USB module. More...
 
static clock_usbfs_src_t CLOCK_SYS_GetUsbfsSrc (uint32_t instance)
 Gets the clock source for USB FS OTG module. More...
 
static void CLOCK_SYS_SetUsbfsSrc (uint32_t instance, clock_usbfs_src_t usbfsSrc)
 Sets the clock source for USB FS OTG module. More...
 
uint32_t CLOCK_SYS_GetUsbfsFreq (uint32_t instance)
 Gets the clock frequency for USB FS OTG module. More...
 
void CLOCK_SYS_EnablePortClock (uint32_t instance)
 Enable the clock for PORT module. More...
 
void CLOCK_SYS_DisablePortClock (uint32_t instance)
 Disable the clock for PORT module. More...
 
bool CLOCK_SYS_GetPortGateCmd (uint32_t instance)
 Get the the clock gate state for PORT module. More...
 
static void CLOCK_SYS_EnableTsiClock (uint32_t instance)
 Enable the clock for TSI module. More...
 
static void CLOCK_SYS_DisableTsiClock (uint32_t instance)
 Disable the clock for TSI module. More...
 
static bool CLOCK_SYS_GetTsiGateCmd (uint32_t instance)
 Get the the clock gate state for TSI module. More...
 
void CLOCK_SYS_EnableAdcClock (uint32_t instance)
 Enable the clock for ADC module. More...
 
void CLOCK_SYS_DisableAdcClock (uint32_t instance)
 Disable the clock for ADC module. More...
 
bool CLOCK_SYS_GetAdcGateCmd (uint32_t instance)
 Get the the clock gate state for ADC module. More...
 
void CLOCK_SYS_EnableDacClock (uint32_t instance)
 Enable the clock for DAC module. More...
 
void CLOCK_SYS_DisableDacClock (uint32_t instance)
 Disable the clock for DAC module. More...
 
bool CLOCK_SYS_GetDacGateCmd (uint32_t instance)
 Get the the clock gate state for DAC module. More...
 
static void CLOCK_SYS_EnableCmpClock (uint32_t instance)
 Enable the clock for CMP module. More...
 
static void CLOCK_SYS_DisableCmpClock (uint32_t instance)
 Disable the clock for CMP module. More...
 
static bool CLOCK_SYS_GetCmpGateCmd (uint32_t instance)
 Get the the clock gate state for CMP module. More...
 
static void CLOCK_SYS_EnableVrefClock (uint32_t instance)
 Enable the clock for VREF module. More...
 
static void CLOCK_SYS_DisableVrefClock (uint32_t instance)
 Disable the clock for VREF module. More...
 
static bool CLOCK_SYS_GetVrefGateCmd (uint32_t instance)
 Get the the clock gate state for VREF module. More...
 
void CLOCK_SYS_EnableAtxClock (uint32_t instance)
 Enable the clock for ATX module. More...
 
void CLOCK_SYS_DisableAtxClock (uint32_t instance)
 Disable the clock for ATX module. More...
 
bool CLOCK_SYS_GetAtxGateCmd (uint32_t instance)
 Get the the clock gate state for ATX module. More...
 
static void CLOCK_SYS_EnableCrcClock (uint32_t instance)
 Enable the clock for CRC module. More...
 
static void CLOCK_SYS_DisableCrcClock (uint32_t instance)
 Disable the clock for CRC module. More...
 
static bool CLOCK_SYS_GetCrcGateCmd (uint32_t instance)
 Get the the clock gate state for CRC module. More...
 
static void CLOCK_SYS_EnableTrngClock (uint32_t instance)
 Enable the clock for TRNG module. More...
 
static void CLOCK_SYS_DisableTrngClock (uint32_t instance)
 Disable the clock for TRNG module. More...
 
static bool CLOCK_SYS_GetTrngGateCmd (uint32_t instance)
 Get the clock gate state for TRNG module. More...
 
static void CLOCK_SYS_EnableFlexioClock (uint32_t instance)
 Enable the clock for FLEXIO module. More...
 
static void CLOCK_SYS_DisableFlexioClock (uint32_t instance)
 Disable the clock for FLEXIO module. More...
 
static bool CLOCK_SYS_GetFlexioGateCmd (uint32_t instance)
 Get the clock gate state for FLEXIO module. More...
 
static clock_flexio_src_t CLOCK_SYS_GetFlexioSrc (uint32_t instance)
 Get the FLEXIO clock source selection. More...
 
static void CLOCK_SYS_SetFlexioSrc (uint32_t instance, clock_flexio_src_t flexioSrc)
 Set the FLEXIO clock source selection. More...
 
uint32_t CLOCK_SYS_GetFlexioFreq (uint32_t instance)
 Gets FLEXIO clock frequency. More...
 
static void CLOCK_SYS_EnableDmaClock (uint32_t instance)
 Enable the clock for DMA module. More...
 
static void CLOCK_SYS_DisableDmaClock (uint32_t instance)
 Disable the clock for DMA module. More...
 
static bool CLOCK_SYS_GetDmaGateCmd (uint32_t instance)
 Get the the clock gate state for DMA module. More...
 
static void CLOCK_SYS_SetTpmExternalFreq (uint32_t srcInstance, uint32_t freq)
 Set the TPM external clock frequency(TPM_CLKx). More...
 

Variables

uint32_t g_tpmClkFreq [TPM_EXT_CLK_COUNT]
 TPM external clock frequency(TPM_CLK). More...
 

Function Documentation

static void CLOCK_SYS_SetExternalRefClock32kSrc ( clock_er32k_src_t  src)
inlinestatic

This function sets the clock selection of ERCLK32K.

Parameters
srcclock source.
static clock_er32k_src_t CLOCK_SYS_GetExternalRefClock32kSrc ( void  )
inlinestatic

This function gets the clock selection of ERCLK32K.

Returns
Current selection.
static void CLOCK_SYS_SetTpmExternalFreq ( uint32_t  srcInstance,
uint32_t  freq 
)
inlinestatic

This function sets the TPM external clock frequency (TPM_CLKx).

Parameters
srcInstanceExternal source instance.
freqFrequcney value.