MSPM0L111X Driver Library  2.05.00.05
Modules | Data Structures | Macros | Enumerations | Functions
Common General Purpose Timer (TIMx)
Collaboration diagram for Common General Purpose Timer (TIMx):

Modules

 DL_TIMER_CCx
 
 DL_TIMER_CC_MODE
 
 DL_TIMER_CC_ZCOND
 
 DL_TIMER_CC_LCOND
 
 DL_TIMER_CC_ACOND
 
 DL_TIMER_CC_CCOND
 
 DL_TIMER_CC_OCTL_INIT_VAL
 
 DL_TIMER_CC_OCTL_INV_OUT
 
 DL_TIMER_CC_OCTL_SRC
 
 DL_TIMER_CC_SWFRCACT_CMPL
 
 DL_TIMER_CC_SWFRCACT
 
 DL_TIMER_CC_FEXACT
 
 DL_TIMER_CC_FENACT
 
 DL_TIMER_CC_CC2UACT
 
 DL_TIMER_CC_CC2DACT
 
 DL_TIMER_CC_CUACT
 
 DL_TIMER_CC_CDACT
 
 DL_TIMER_CC_LACT
 
 DL_TIMER_CC_ZACT
 
 DL_TIMER_CC_INPUT_INV
 
 DL_TIMER_CC_IN_SEL
 
 DL_TIMER_FAULT_SOURCE
 
 DL_TIMER_FAULT_CONFIG_TFIM
 
 DL_TIMER_FAULT_CONFIG_FL
 
 DL_TIMER_FAULT_CONFIG_FI
 
 DL_TIMER_FAULT_CONFIG_FIEN
 
 DL_TIMER_FAULT_FILT
 
 DL_TIMER_FAULT_FILTER_CPV
 
 DL_TIMER_FAULT_FILTER_FP
 
 DL_TIMER_CC_INPUT_FILT_CPV
 
 DL_TIMER_CC_INPUT_FILT_FP
 
 DL_TIMER_INTERRUPT
 
 DL_TIMER_EVENT
 
 DL_TIMER_CCP0_DIS_OUT_ADV
 
 DL_TIMER_CCP1_DIS_OUT_ADV
 
 DL_TIMER_CCP2_DIS_OUT_ADV
 
 DL_TIMER_CCP3_DIS_OUT_ADV
 

Data Structures

struct  DL_Timer_ClockConfig
 Configuration struct for DL_Timer_setClockConfig. More...
 
struct  DL_Timer_TimerConfig
 Configuration struct for DL_Timer_initTimerMode. More...
 
struct  DL_Timer_CaptureConfig
 Configuration struct for DL_Timer_initCaptureMode. More...
 
struct  DL_Timer_CaptureTriggerConfig
 Configuration struct for DL_Timer_initCaptureTriggerMode. More...
 
struct  DL_Timer_CaptureCombinedConfig
 Configuration struct for DL_Timer_initCaptureCombinedMode. More...
 
struct  DL_Timer_CompareConfig
 Configuration struct for DL_Timer_initCompareMode. More...
 
struct  DL_Timer_CompareTriggerConfig
 Configuration struct for DL_Timer_initCompareTriggerMode. More...
 
struct  DL_Timer_PWMConfig
 Configuration struct for DL_Timer_initPWMMode. More...
 
struct  DL_Timer_backupConfig
 Configuration structure to backup Timer peripheral state before entering STOP or STANDBY mode. Used by DL_Timer_saveConfiguration and DL_Timer_restoreConfiguration. More...
 

Macros

#define DL_Timer_initPWMMode   DL_Timer_initFourCCPWMMode
 Redirects to common DL_Timer_initFourCCPWMMode.
 

Enumerations

enum  DL_TIMER_CLOCK {
  DL_TIMER_CLOCK_BUSCLK = GPTIMER_CLKSEL_BUSCLK_SEL_ENABLE,
  DL_TIMER_CLOCK_2X_BUSCLK = GPTIMER_CLKSEL_BUS2XCLK_SEL_ENABLE,
  DL_TIMER_CLOCK_MFCLK = GPTIMER_CLKSEL_MFCLK_SEL_ENABLE,
  DL_TIMER_CLOCK_LFCLK = GPTIMER_CLKSEL_LFCLK_SEL_ENABLE,
  DL_TIMER_CLOCK_DISABLE = GPTIMER_CLKSEL_LFCLK_SEL_DISABLE
}
 
enum  DL_TIMER_CLOCK_DIVIDE {
  DL_TIMER_CLOCK_DIVIDE_1 = GPTIMER_CLKDIV_RATIO_DIV_BY_1,
  DL_TIMER_CLOCK_DIVIDE_2 = GPTIMER_CLKDIV_RATIO_DIV_BY_2,
  DL_TIMER_CLOCK_DIVIDE_3 = GPTIMER_CLKDIV_RATIO_DIV_BY_3,
  DL_TIMER_CLOCK_DIVIDE_4 = GPTIMER_CLKDIV_RATIO_DIV_BY_4,
  DL_TIMER_CLOCK_DIVIDE_5 = GPTIMER_CLKDIV_RATIO_DIV_BY_5,
  DL_TIMER_CLOCK_DIVIDE_6 = GPTIMER_CLKDIV_RATIO_DIV_BY_6,
  DL_TIMER_CLOCK_DIVIDE_7 = GPTIMER_CLKDIV_RATIO_DIV_BY_7,
  DL_TIMER_CLOCK_DIVIDE_8 = GPTIMER_CLKDIV_RATIO_DIV_BY_8
}
 
enum  DL_TIMER_CCP_DIS_OUT {
  DL_TIMER_CCP_DIS_OUT_LOW = GPTIMER_ODIS_C0CCP0_CCP_OUTPUT_LOW,
  DL_TIMER_CCP_DIS_OUT_SET_BY_OCTL = GPTIMER_ODIS_C0CCP0_CCP_OUTPUT_OCTL
}
 
enum  DL_TIMER_CC_INDEX {
  DL_TIMER_CC_0_INDEX = 0,
  DL_TIMER_CC_1_INDEX = 1,
  DL_TIMER_CC_2_INDEX = 2,
  DL_TIMER_CC_3_INDEX = 3,
  DL_TIMER_CC_4_INDEX = 4,
  DL_TIMER_CC_5_INDEX = 5
}
 
enum  DL_TIMER_EXT_TRIG_SEL {
  DL_TIMER_EXT_TRIG_SEL_TRIG_0 = GPTIMER_TSEL_ETSEL_TRIG0,
  DL_TIMER_EXT_TRIG_SEL_TRIG_1 = GPTIMER_TSEL_ETSEL_TRIG1,
  DL_TIMER_EXT_TRIG_SEL_TRIG_2 = GPTIMER_TSEL_ETSEL_TRIG2,
  DL_TIMER_EXT_TRIG_SEL_TRIG_3 = GPTIMER_TSEL_ETSEL_TRIG3,
  DL_TIMER_EXT_TRIG_SEL_TRIG_4 = GPTIMER_TSEL_ETSEL_TRIG4,
  DL_TIMER_EXT_TRIG_SEL_TRIG_5 = GPTIMER_TSEL_ETSEL_TRIG5,
  DL_TIMER_EXT_TRIG_SEL_TRIG_6 = GPTIMER_TSEL_ETSEL_TRIG6,
  DL_TIMER_EXT_TRIG_SEL_TRIG_7 = GPTIMER_TSEL_ETSEL_TRIG7,
  DL_TIMER_EXT_TRIG_SEL_TRIG_8 = GPTIMER_TSEL_ETSEL_TRIG8,
  DL_TIMER_EXT_TRIG_SEL_TRIG_9 = GPTIMER_TSEL_ETSEL_TRIG9,
  DL_TIMER_EXT_TRIG_SEL_TRIG_10 = GPTIMER_TSEL_ETSEL_TRIG10,
  DL_TIMER_EXT_TRIG_SEL_TRIG_11 = GPTIMER_TSEL_ETSEL_TRIG11,
  DL_TIMER_EXT_TRIG_SEL_TRIG_12 = GPTIMER_TSEL_ETSEL_TRIG12,
  DL_TIMER_EXT_TRIG_SEL_TRIG_13 = GPTIMER_TSEL_ETSEL_TRIG13,
  DL_TIMER_EXT_TRIG_SEL_TRIG_14 = GPTIMER_TSEL_ETSEL_TRIG14,
  DL_TIMER_EXT_TRIG_SEL_TRIG_15 = GPTIMER_TSEL_ETSEL_TRIG15,
  DL_TIMER_EXT_TRIG_SEL_TRIG_SUB_0 = GPTIMER_TSEL_ETSEL_TRIG_SUB0,
  DL_TIMER_EXT_TRIG_SEL_TRIG_SUB_1 = GPTIMER_TSEL_ETSEL_TRIG_SUB1
}
 
enum  DL_TIMER_TIMER_MODE {
  DL_TIMER_TIMER_MODE_ONE_SHOT,
  DL_TIMER_TIMER_MODE_PERIODIC,
  DL_TIMER_TIMER_MODE_ONE_SHOT_UP,
  DL_TIMER_TIMER_MODE_PERIODIC_UP,
  DL_TIMER_TIMER_MODE_ONE_SHOT_UP_DOWN,
  DL_TIMER_TIMER_MODE_PERIODIC_UP_DOWN
}
 
enum  DL_TIMER_CAPTURE_MODE {
  DL_TIMER_CAPTURE_MODE_EDGE_TIME,
  DL_TIMER_CAPTURE_MODE_PERIOD_CAPTURE,
  DL_TIMER_CAPTURE_MODE_PULSE_WIDTH,
  DL_TIMER_CAPTURE_MODE_EDGE_TIME_UP,
  DL_TIMER_CAPTURE_MODE_PERIOD_CAPTURE_UP,
  DL_TIMER_CAPTURE_MODE_PULSE_WIDTH_UP
}
 
enum  DL_TIMER_CAPTURE_COMBINED_MODE {
  DL_TIMER_CAPTURE_COMBINED_MODE_PULSE_WIDTH_AND_PERIOD,
  DL_TIMER_CAPTURE_COMBINED_MODE_PULSE_WIDTH_AND_PERIOD_UP
}
 
enum  DL_TIMER_COMPARE_MODE {
  DL_TIMER_COMPARE_MODE_EDGE_COUNT,
  DL_TIMER_COMPARE_MODE_EDGE_COUNT_UP,
  DL_TIMER_COMPARE_MODE_EDGE_COUNT_UP_DOWN
}
 
enum  DL_TIMER_COUNT_MODE {
  DL_TIMER_COUNT_MODE_DOWN = GPTIMER_CTRCTL_CM_DOWN,
  DL_TIMER_COUNT_MODE_UP_DOWN = GPTIMER_CTRCTL_CM_UP_DOWN,
  DL_TIMER_COUNT_MODE_UP = GPTIMER_CTRCTL_CM_UP
}
 
enum  DL_TIMER {
  DL_TIMER_START = GPTIMER_CTRCTL_EN_ENABLED,
  DL_TIMER_STOP = GPTIMER_CTRCTL_EN_DISABLED
}
 
enum  DL_TIMER_INTERM_INT {
  DL_TIMER_INTERM_INT_ENABLED = GPTIMER_CCCTL_01_COC_COMPARE,
  DL_TIMER_INTERM_INT_DISABLED = GPTIMER_CCCTL_01_COC_CAPTURE
}
 
enum  DL_TIMER_CAPTURE_EDGE_DETECTION_MODE {
  DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_RISING,
  DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_FALLING,
  DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_EDGE
}
 
enum  DL_TIMER_COMPARE_EDGE_DETECTION_MODE {
  DL_TIMER_COMPARE_EDGE_DETECTION_MODE_RISING,
  DL_TIMER_COMPARE_EDGE_DETECTION_MODE_FALLING,
  DL_TIMER_COMPARE_EDGE_DETECTION_MODE_EDGE
}
 
enum  DL_TIMER_PWM_MODE {
  DL_TIMER_PWM_MODE_EDGE_ALIGN = GPTIMER_CTRCTL_CM_DOWN,
  DL_TIMER_PWM_MODE_EDGE_ALIGN_UP = GPTIMER_CTRCTL_CM_UP,
  DL_TIMER_PWM_MODE_CENTER_ALIGN = GPTIMER_CTRCTL_CM_UP_DOWN
}
 
enum  DL_TIMER_DEAD_BAND_MODE {
  DL_TIMER_DEAD_BAND_MODE_0 = GPTIMER_DBCTL_M1_ENABLE_DISABLED,
  DL_TIMER_DEAD_BAND_MODE_1 = GPTIMER_DBCTL_M1_ENABLE_ENABLED
}
 
enum  DL_TIMER_FAULT_ENTRY_CCP {
  DL_TIMER_FAULT_ENTRY_CCP_DISABLED = GPTIMER_CCACT_01_FENACT_DISABLED,
  DL_TIMER_FAULT_ENTRY_CCP_HIGH = GPTIMER_CCACT_01_FENACT_CCP_HIGH,
  DL_TIMER_FAULT_ENTRY_CCP_LOW = GPTIMER_CCACT_01_FENACT_CCP_LOW,
  DL_TIMER_FAULT_ENTRY_CCP_TOGGLE = GPTIMER_CCACT_01_FENACT_CCP_TOGGLE,
  DL_TIMER_FAULT_ENTRY_CCP_HIGHZ = GPTIMER_CCACT_01_FENACT_CCP_HIGHZ
}
 
enum  DL_TIMER_FAULT_EXIT_CCP {
  DL_TIMER_FAULT_EXIT_CCP_DISABLED = GPTIMER_CCACT_01_FEXACT_DISABLED,
  DL_TIMER_FAULT_EXIT_CCP_HIGH = GPTIMER_CCACT_01_FEXACT_CCP_HIGH,
  DL_TIMER_FAULT_EXIT_CCP_LOW = GPTIMER_CCACT_01_FEXACT_CCP_LOW,
  DL_TIMER_FAULT_EXIT_CCP_TOGGLE = GPTIMER_CCACT_01_FEXACT_CCP_TOGGLE,
  DL_TIMER_FAULT_EXIT_CCP_HIGHZ = GPTIMER_CCACT_01_FEXACT_CCP_HIGHZ
}
 
enum  DL_TIMER_FAULT_EXIT_CTR {
  DL_TIMER_FAULT_EXIT_CTR_RESUME = GPTIMER_CTRCTL_FRB_RESUME,
  DL_TIMER_FAULT_EXIT_CTR_CVAE_ACTION = GPTIMER_CTRCTL_FRB_CVAE_ACTION
}
 
enum  DL_TIMER_FAULT_ENTRY_CTR {
  DL_TIMER_FAULT_ENTRY_CTR_CONT_COUNT = GPTIMER_CTRCTL_FB_CONT_COUNT,
  DL_TIMER_FAULT_ENTRY_CTR_SUSP_COUNT = GPTIMER_CTRCTL_FB_SUSP_COUNT
}
 
enum  DL_TIMER_CROSS_TRIG_SRC {
  DL_TIMER_CROSS_TRIG_SRC_FSUB0 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_FSUB0,
  DL_TIMER_CROSS_TRIG_SRC_FSUB1 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_FSUB1,
  DL_TIMER_CROSS_TRIG_SRC_ZERO = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_Z,
  DL_TIMER_CROSS_TRIG_SRC_LOAD = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_L,
  DL_TIMER_CROSS_TRIG_SRC_CCD0 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCD0,
  DL_TIMER_CROSS_TRIG_SRC_CCD1 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCD1,
  DL_TIMER_CROSS_TRIG_SRC_CCD2 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCD2,
  DL_TIMER_CROSS_TRIG_SRC_CCD3 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCD3,
  DL_TIMER_CROSS_TRIG_SRC_CCU0 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCU0,
  DL_TIMER_CROSS_TRIG_SRC_CCU1 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCU1,
  DL_TIMER_CROSS_TRIG_SRC_CCU2 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCU2,
  DL_TIMER_CROSS_TRIG_SRC_CCU3 = GPTIMER_CTTRIGCTL_EVTCTTRIGSEL_CCU3
}
 
enum  DL_TIMER_CROSS_TRIGGER_INPUT {
  DL_TIMER_CROSS_TRIGGER_INPUT_ENABLED = GPTIMER_CTTRIGCTL_EVTCTEN_ENABLE,
  DL_TIMER_CROSS_TRIGGER_INPUT_DISABLED = GPTIMER_CTTRIGCTL_EVTCTEN_DISABLED
}
 
enum  DL_TIMER_CROSS_TRIGGER_MODE {
  DL_TIMER_CROSS_TRIGGER_MODE_ENABLED = GPTIMER_CTTRIGCTL_CTEN_ENABLE,
  DL_TIMER_CROSS_TRIGGER_MODE_DISABLED = GPTIMER_CTTRIGCTL_CTEN_DISABLED
}
 
enum  DL_TIMER_IIDX {
  DL_TIMER_IIDX_ZERO = GPTIMER_CPU_INT_IIDX_STAT_Z,
  DL_TIMER_IIDX_LOAD = GPTIMER_CPU_INT_IIDX_STAT_L,
  DL_TIMER_IIDX_CC0_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD0,
  DL_TIMER_IIDX_CC1_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD1,
  DL_TIMER_IIDX_CC2_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD2,
  DL_TIMER_IIDX_CC3_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD3,
  DL_TIMER_IIDX_CC0_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU0,
  DL_TIMER_IIDX_CC1_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU1,
  DL_TIMER_IIDX_CC2_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU2,
  DL_TIMER_IIDX_CC3_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU3,
  DL_TIMER_IIDX_CC4_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD4,
  DL_TIMER_IIDX_CC5_DN = GPTIMER_CPU_INT_IIDX_STAT_CCD5,
  DL_TIMER_IIDX_CC4_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU4,
  DL_TIMER_IIDX_CC5_UP = GPTIMER_CPU_INT_IIDX_STAT_CCU5,
  DL_TIMER_IIDX_FAULT = GPTIMER_CPU_INT_IIDX_STAT_F,
  DL_TIMER_IIDX_OVERFLOW = GPTIMER_CPU_INT_IIDX_STAT_TOV,
  DL_TIMER_IIDX_REPEAT_COUNT = GPTIMER_CPU_INT_IIDX_STAT_REPC,
  DL_TIMER_IIDX_DIR_CHANGE = GPTIMER_CPU_INT_IIDX_STAT_DC,
  DL_TIMER_IIDX_QEIERR = GPTIMER_CPU_INT_IIDX_STAT_QEIERR
}
 
enum  DL_TIMER_PUBLISHER_INDEX {
  DL_TIMER_PUBLISHER_INDEX_0 = 0,
  DL_TIMER_PUBLISHER_INDEX_1 = 1
}
 
enum  DL_TIMER_SUBSCRIBER_INDEX {
  DL_TIMER_SUBSCRIBER_INDEX_0 = 0,
  DL_TIMER_SUBSCRIBER_INDEX_1 = 1
}
 
enum  DL_TIMER_EVENT_ROUTE {
  DL_TIMER_EVENT_ROUTE_1 = 0,
  DL_TIMER_EVENT_ROUTE_2 = 12
}
 
enum  DL_TIMER_INPUT_CHAN {
  DL_TIMER_INPUT_CHAN_0,
  DL_TIMER_INPUT_CHAN_1,
  DL_TIMER_INPUT_CHAN_2,
  DL_TIMER_INPUT_CHAN_3
}
 
enum  DL_TIMER_DEBUG_RES {
  DL_TIMER_DEBUG_RES_RESUME = GPTIMER_CTRCTL_DRB_RESUME,
  DL_TIMER_DEBUG_RES_CVAE_ACTION = GPTIMER_CTRCTL_DRB_CVAE_ACTION
}
 
enum  DL_TIMER_CZC {
  DL_TIMER_CZC_CCCTL0_ZCOND = GPTIMER_CTRCTL_CZC_CCCTL0_ZCOND,
  DL_TIMER_CZC_CCCTL1_ZCOND = GPTIMER_CTRCTL_CZC_CCCTL1_ZCOND,
  DL_TIMER_CZC_CCCTL2_ZCOND = GPTIMER_CTRCTL_CZC_CCCTL2_ZCOND,
  DL_TIMER_CZC_CCCTL3_ZCOND = GPTIMER_CTRCTL_CZC_CCCTL3_ZCOND,
  DL_TIMER_CZC_QEI_2INP = GPTIMER_CTRCTL_CZC_QEI_2INP,
  DL_TIMER_CZC_QEI_3INP = GPTIMER_CTRCTL_CZC_QEI_3INP
}
 
enum  DL_TIMER_CAC {
  DL_TIMER_CAC_CCCTL0_ACOND = GPTIMER_CTRCTL_CAC_CCCTL0_ACOND,
  DL_TIMER_CAC_CCCTL1_ACOND = GPTIMER_CTRCTL_CAC_CCCTL1_ACOND,
  DL_TIMER_CAC_CCCTL2_ACOND = GPTIMER_CTRCTL_CAC_CCCTL2_ACOND,
  DL_TIMER_CAC_CCCTL3_ACOND = GPTIMER_CTRCTL_CAC_CCCTL3_ACOND,
  DL_TIMER_CAC_QEI_2INP = GPTIMER_CTRCTL_CAC_QEI_2INP,
  DL_TIMER_CAC_QEI_3INP = GPTIMER_CTRCTL_CAC_QEI_3INP
}
 
enum  DL_TIMER_CLC {
  DL_TIMER_CLC_CCCTL0_LCOND = GPTIMER_CTRCTL_CLC_CCCTL0_LCOND,
  DL_TIMER_CLC_CCCTL1_LCOND = GPTIMER_CTRCTL_CLC_CCCTL1_LCOND,
  DL_TIMER_CLC_CCCTL2_LCOND = GPTIMER_CTRCTL_CLC_CCCTL2_LCOND,
  DL_TIMER_CLC_CCCTL3_LCOND = GPTIMER_CTRCTL_CLC_CCCTL3_LCOND,
  DL_TIMER_CLC_QEI_2INP = GPTIMER_CTRCTL_CLC_QEI_2INP,
  DL_TIMER_CLC_QEI_3INP = GPTIMER_CTRCTL_CLC_QEI_3INP
}
 
enum  DL_TIMER_COUNT_AFTER_EN {
  DL_TIMER_COUNT_AFTER_EN_LOAD_VAL = GPTIMER_CTRCTL_CVAE_LDVAL,
  DL_TIMER_COUNT_AFTER_EN_NO_CHANGE = GPTIMER_CTRCTL_CVAE_NOCHANGE,
  DL_TIMER_COUNT_AFTER_EN_ZERO = GPTIMER_CTRCTL_CVAE_ZEROVAL
}
 
enum  DL_TIMER_REPEAT_MODE {
  DL_TIMER_REPEAT_MODE_DISABLED = GPTIMER_CTRCTL_REPEAT_REPEAT_0,
  DL_TIMER_REPEAT_MODE_ENABLED = GPTIMER_CTRCTL_REPEAT_REPEAT_1,
  DL_TIMER_REPEAT_MODE_ENABLED_DEBUG = GPTIMER_CTRCTL_REPEAT_REPEAT_3
}
 
enum  DL_TIMER_CC_UPDATE_METHOD {
  DL_TIMER_CC_UPDATE_METHOD_IMMEDIATE = (GPTIMER_CCCTL_01_CCUPD_IMMEDIATELY),
  DL_TIMER_CC_UPDATE_METHOD_ZERO_EVT = (GPTIMER_CCCTL_01_CCUPD_ZERO_EVT),
  DL_TIMER_CC_UPDATE_METHOD_COMP_DN_EVT,
  DL_TIMER_CC_UPDATE_METHOD_COMP_UP_EVT,
  DL_TIMER_CC_UPDATE_METHOD_ZERO_OR_LOAD_EVT,
  DL_TIMER_CC_UPDATE_METHOD_ZERO_RC_EVT,
  DL_TIMER_CC_UPDATE_METHOD_TRIG_EVT = (GPTIMER_CCCTL_01_CCUPD_TRIG)
}
 
enum  DL_TIMER_CCACT_UPDATE_METHOD {
  DL_TIMER_CCACT_UPDATE_METHOD_IMMEDIATE,
  DL_TIMER_CCACT_UPDATE_METHOD_ZERO_EVT,
  DL_TIMER_CCACT_UPDATE_METHOD_COMP_DN_EVT,
  DL_TIMER_CCACT_UPDATE_METHOD_COMP_UP_EVT,
  DL_TIMER_CCACT_UPDATE_METHOD_ZERO_OR_LOAD_EVT,
  DL_TIMER_CCACT_UPDATE_METHOD_ZERO_RC_EVT,
  DL_TIMER_CCACT_UPDATE_METHOD_TRIG_EVT = (GPTIMER_CCCTL_01_CCACTUPD_TRIG)
}
 
enum  DL_TIMER_SEC_COMP_DOWN_EVT {
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC0 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD0),
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC1 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD1),
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC2 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD2),
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC3 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD3),
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC4 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD4),
  DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC5 = (GPTIMER_CCCTL_01_CC2SELD_SEL_CCD5)
}
 
enum  DL_TIMER_SEC_COMP_UP_EVT {
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC0 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU0),
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC1 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU1),
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC2 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU2),
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC3 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU3),
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC4 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU4),
  DL_TIMER_SEC_COMP_UP_EVT_SEL_CC5 = (GPTIMER_CCCTL_01_CC2SELU_SEL_CCU5)
}
 
enum  DL_TIMER_SEC_COMP_UP_ACT_SEL {
  DL_TIMER_SEC_COMP_UP_ACT_SEL_DISABLE = GPTIMER_CCACT_01_CC2UACT_DISABLED,
  DL_TIMER_SEC_COMP_UP_ACT_SEL_HIGH = GPTIMER_CCACT_01_CC2UACT_CCP_HIGH,
  DL_TIMER_SEC_COMP_UP_ACT_SEL_LOW = GPTIMER_CCACT_01_CC2UACT_CCP_LOW,
  DL_TIMER_SEC_COMP_UP_ACT_SEL_TOGGLE = GPTIMER_CCACT_01_CC2UACT_CCP_TOGGLE
}
 
enum  DL_TIMER_SEC_COMP_DOWN_ACT_SEL {
  DL_TIMER_SEC_COMP_DOWN_ACT_SEL_DISABLE = GPTIMER_CCACT_01_CC2DACT_DISABLED,
  DL_TIMER_SEC_COMP_DOWN_ACT_SEL_HIGH = GPTIMER_CCACT_01_CC2DACT_CCP_HIGH,
  DL_TIMER_SEC_COMP_DOWN_ACT_SEL_LOW = GPTIMER_CCACT_01_CC2DACT_CCP_LOW,
  DL_TIMER_SEC_COMP_DOWN_ACT_SEL_TOGGLE
}
 
enum  DL_TIMER_SUPP_COMP_EVT_RC {
  DL_TIMER_SUPP_COMP_EVT_RC_DISABLED = (GPTIMER_CCCTL_01_SCERCNEZ_DISABLED),
  DL_TIMER_SUPP_COMP_EVT_RC_ENABLED = (GPTIMER_CCCTL_01_SCERCNEZ_ENABLED)
}
 
enum  DL_TIMER_FORCE_OUT {
  DL_TIMER_FORCE_OUT_DISABLED = (GPTIMER_CCACT_01_SWFRCACT_DISABLED),
  DL_TIMER_FORCE_OUT_HIGH = (GPTIMER_CCACT_01_SWFRCACT_CCP_HIGH),
  DL_TIMER_FORCE_OUT_LOW = (GPTIMER_CCACT_01_SWFRCACT_CCP_LOW)
}
 
enum  DL_TIMER_FORCE_CMPL_OUT {
  DL_TIMER_FORCE_CMPL_OUT_DISABLED,
  DL_TIMER_FORCE_CMPL_OUT_HIGH = (GPTIMER_CCACT_01_SWFRCACT_CMPL_CCP_HIGH),
  DL_TIMER_FORCE_CMPL_OUT_LOW = (GPTIMER_CCACT_01_SWFRCACT_CMPL_CCP_LOW)
}
 
enum  DL_TIMER_CORE_HALT {
  DL_TIMER_CORE_HALT_IMMEDIATE,
  DL_TIMER_CORE_HALT_DELAYED,
  DL_TIMER_CORE_HALT_FREE_RUN
}
 
enum  DL_TIMER_QEI_MODE {
  DL_TIMER_QEI_MODE_2_INPUT,
  DL_TIMER_QEI_MODE_3_INPUT
}
 
enum  DL_TIMER_QEI_DIRECTION {
  DL_TIMER_QEI_DIR_DOWN = GPTIMER_QDIR_DIR_DOWN,
  DL_TIMER_QEI_DIR_UP = GPTIMER_QDIR_DIR_UP
}
 

Functions

__STATIC_INLINE void DL_Timer_enablePower (GPTIMER_Regs *gptimer)
 Enables the Peripheral Write Enable (PWREN) register for the timer. More...
 
__STATIC_INLINE void DL_Timer_disablePower (GPTIMER_Regs *gptimer)
 Disables the Peripheral Write Enable (PWREN) register for the timer. More...
 
__STATIC_INLINE bool DL_Timer_isPowerEnabled (const GPTIMER_Regs *gptimer)
 Returns if the Peripheral Write Enable (PWREN) register for the timer is enabled. More...
 
__STATIC_INLINE void DL_Timer_reset (GPTIMER_Regs *gptimer)
 Resets timer peripheral. More...
 
__STATIC_INLINE bool DL_Timer_isReset (const GPTIMER_Regs *gptimer)
 Returns if timer peripheral has been reset. More...
 
__STATIC_INLINE void DL_Timer_setCCPDirection (GPTIMER_Regs *gptimer, uint32_t ccpConfig)
 Sets CCP Direction. More...
 
__STATIC_INLINE uint32_t DL_Timer_getCCPDirection (const GPTIMER_Regs *gptimer)
 Gets CCP Direction. More...
 
__STATIC_INLINE void DL_Timer_setCCPOutputDisabled (GPTIMER_Regs *gptimer, DL_TIMER_CCP_DIS_OUT ccp0Config, DL_TIMER_CCP_DIS_OUT ccp1Config)
 Forces the output of the timer low via the ODIS register. This can be useful during shutdown or configuring the timer. The output pin still passes through the inversion (INV) bit. See figure "Output connection for TIMG" in Technical Reference Manual (TRM) for diagram. DL_Timer_overrideCCPOut() can be used for for similar functionality, where independent overrride settings for the output and complementary output channels can be configured. More...
 
__STATIC_INLINE void DL_Timer_setCCPOutputDisabledAdv (GPTIMER_Regs *gptimer, uint32_t ccpOdisConfig)
 Sets CCP Output configuration for timer instances with more than two CCP channels via the ODIS register. The output pin still passes through the inversion (INV) bit. More...
 
void DL_Timer_setClockConfig (GPTIMER_Regs *gptimer, const DL_Timer_ClockConfig *config)
 Configure timer source clock. More...
 
void DL_Timer_getClockConfig (const GPTIMER_Regs *gptimer, DL_Timer_ClockConfig *config)
 Get timer source clock configuration. More...
 
__STATIC_INLINE void DL_Timer_enableClock (GPTIMER_Regs *gptimer)
 Enable timer clock. More...
 
__STATIC_INLINE void DL_Timer_disableClock (GPTIMER_Regs *gptimer)
 Disable timer clock. More...
 
__STATIC_INLINE bool DL_Timer_isClockEnabled (const GPTIMER_Regs *gptimer)
 Returns if timer clock is disabled. More...
 
__STATIC_INLINE void DL_Timer_configCrossTrigger (GPTIMER_Regs *gptimer, DL_TIMER_CROSS_TRIG_SRC ctSource, DL_TIMER_CROSS_TRIGGER_INPUT enInTrigCond, DL_TIMER_CROSS_TRIGGER_MODE enCrossTrig)
 Configure Cross Timer Trigger. More...
 
__STATIC_INLINE void DL_Timer_configCrossTriggerSrc (GPTIMER_Regs *gptimer, DL_TIMER_CROSS_TRIG_SRC ctSource)
 Configure Cross Timer Trigger source. More...
 
__STATIC_INLINE void DL_Timer_configCrossTriggerInputCond (GPTIMER_Regs *gptimer, DL_TIMER_CROSS_TRIGGER_INPUT enInTrigCond)
 Enables/DIsables Input Trigger condition for Cross Timer Trigger. More...
 
__STATIC_INLINE void DL_Timer_configCrossTriggerEnable (GPTIMER_Regs *gptimer, DL_TIMER_CROSS_TRIGGER_MODE enCrossTrig)
 Enable/Disable Cross Timer Trigger. More...
 
__STATIC_INLINE uint32_t DL_Timer_getCrossTriggerConfig (const GPTIMER_Regs *gptimer)
 Get Cross Timer Trigger configuration. More...
 
__STATIC_INLINE DL_TIMER_CROSS_TRIG_SRC DL_Timer_getCrossTriggerSrc (const GPTIMER_Regs *gptimer)
 Get Cross Timer Trigger source. More...
 
__STATIC_INLINE DL_TIMER_CROSS_TRIGGER_INPUT DL_Timer_getCrossTriggerInputCond (const GPTIMER_Regs *gptimer)
 Get Input Trigger condition for Cross Timer Trigger. More...
 
__STATIC_INLINE DL_TIMER_CROSS_TRIGGER_MODE DL_Timer_getCrossTriggerEnable (const GPTIMER_Regs *gptimer)
 Checks if Cross Timer Trigger is enabled or disabled. More...
 
__STATIC_INLINE void DL_Timer_generateCrossTrigger (GPTIMER_Regs *gptimer)
 Generates a synchronized trigger condition across all trigger enabled Timer instances. More...
 
__STATIC_INLINE void DL_Timer_enableShadowFeatures (GPTIMER_Regs *gptimer)
 Enable shadow to activate load of buffered registers and register fields. More...
 
__STATIC_INLINE void DL_Timer_disableShadowFeatures (GPTIMER_Regs *gptimer)
 Disable shadow to activate load of buffered registers and register fields. More...
 
__STATIC_INLINE void DL_Timer_setLoadValue (GPTIMER_Regs *gptimer, uint32_t value)
 Sets timer LOAD register value. More...
 
__STATIC_INLINE uint32_t DL_Timer_getLoadValue (const GPTIMER_Regs *gptimer)
 Gets the timer LOAD register value. More...
 
__STATIC_INLINE uint32_t DL_Timer_getTimerCount (const GPTIMER_Regs *gptimer)
 Gets the current counter value of the timer. More...
 
__STATIC_INLINE void DL_Timer_setTimerCount (GPTIMER_Regs *gptimer, uint32_t value)
 Set timer counter value. More...
 
__STATIC_INLINE void DL_Timer_enableLZEventSuppression (GPTIMER_Regs *gptimer)
 Enable suppression of load and zero events. More...
 
__STATIC_INLINE void DL_Timer_disableLZEventSuppression (GPTIMER_Regs *gptimer)
 Disable suppression of load and zero events. More...
 
__STATIC_INLINE bool DL_Timer_isLZEventSuppressionEnabled (const GPTIMER_Regs *gptimer)
 Checks if suppression of load and zero events is enabled. More...
 
__STATIC_INLINE void DL_Timer_setDebugReleaseBehavior (GPTIMER_Regs *gptimer, DL_TIMER_DEBUG_RES debResB)
 Configures timer behavior during debug release/exit. More...
 
__STATIC_INLINE DL_TIMER_DEBUG_RES DL_Timer_getDebugReleaseBehavior (const GPTIMER_Regs *gptimer)
 Get timer resume behavior after relase/exit of debug mode. More...
 
__STATIC_INLINE void DL_Timer_setCounterControl (GPTIMER_Regs *gptimer, DL_TIMER_CZC zeroCtl, DL_TIMER_CAC advCtl, DL_TIMER_CLC loadCtl)
 Configure timer counter control operation. More...
 
__STATIC_INLINE DL_TIMER_CZC DL_Timer_getCounterZeroControl (const GPTIMER_Regs *gptimer)
 Get timer counter zero control operation. More...
 
__STATIC_INLINE DL_TIMER_CAC DL_Timer_getCounterAdvanceControl (const GPTIMER_Regs *gptimer)
 Get timer counter advance control operation. More...
 
__STATIC_INLINE DL_TIMER_CLC DL_Timer_getCounterLoadControl (const GPTIMER_Regs *gptimer)
 Get timer counter load control operation. More...
 
__STATIC_INLINE void DL_Timer_setCounterMode (GPTIMER_Regs *gptimer, DL_TIMER_COUNT_MODE countMode)
 Configure timer counter couting mode. More...
 
__STATIC_INLINE DL_TIMER_COUNT_MODE DL_Timer_getCounterMode (const GPTIMER_Regs *gptimer)
 Get timer counter couting mode. More...
 
__STATIC_INLINE void DL_Timer_setCounterValueAfterEnable (GPTIMER_Regs *gptimer, DL_TIMER_COUNT_AFTER_EN cvae)
 Configures counter value after enable. More...
 
__STATIC_INLINE DL_TIMER_COUNT_AFTER_EN DL_Timer_getCounterValueAfterEnable (const GPTIMER_Regs *gptimer)
 Returns counter value after enable cofiguration. More...
 
__STATIC_INLINE void DL_Timer_setCounterRepeatMode (GPTIMER_Regs *gptimer, DL_TIMER_REPEAT_MODE repeatMode)
 Configure timer repeat counter mode. More...
 
__STATIC_INLINE DL_TIMER_REPEAT_MODE DL_Timer_getCounterRepeatMode (const GPTIMER_Regs *gptimer)
 Get timer repeat counter mode. More...
 
void DL_Timer_initTimerMode (GPTIMER_Regs *gptimer, const DL_Timer_TimerConfig *config)
 Configure timer in one shot or periodic timer mode Initializes all the common configurable options for the TIMx peripheral when used in Timer mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initCaptureMode (GPTIMER_Regs *gptimer, const DL_Timer_CaptureConfig *config)
 Configure timer in edge count, period capture, edge time or pulse-width capture mode Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initCaptureTriggerMode (GPTIMER_Regs *gptimer, const DL_Timer_CaptureTriggerConfig *config)
 Configure timer in edge count, period capture, edge time or pulse-width capture mode using the trigger as input source Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initCaptureCombinedMode (GPTIMER_Regs *gptimer, const DL_Timer_CaptureCombinedConfig *config)
 Configure timer in combined pulse-width and period capture Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initCompareMode (GPTIMER_Regs *gptimer, const DL_Timer_CompareConfig *config)
 Configure timer in edge count compare mode Initializes all the common configurable options for the TIMx peripheral when used in Compare mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initCompareTriggerMode (GPTIMER_Regs *gptimer, const DL_Timer_CompareTriggerConfig *config)
 Configure timer in edge count compare mode using the trigger as input source Initializes all the common configurable options for the TIMx peripheral when used in Compare mode. Any other custom configuration can be done after calling this API. More...
 
void DL_Timer_initFourCCPWMMode (GPTIMER_Regs *gptimer, const DL_Timer_PWMConfig *config)
 Configure timer in Pulse Width Modulation Mode Initializes all the common configurable options for the TIMx peripheral when used in PWM mode. Any other custom configuration can be done after calling this API. Configures the top two CC blocks and then configures the bottom two CC blocks. More...
 
__STATIC_INLINE void DL_Timer_resetCounterMode (GPTIMER_Regs *gptimer)
 Reset register controlling counter operation. More...
 
void DL_Timer_setCaptureCompareValue (GPTIMER_Regs *gptimer, uint32_t value, DL_TIMER_CC_INDEX ccIndex)
 Sets Timer Capture Compare Value. More...
 
uint32_t DL_Timer_getCaptureCompareValue (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Get Timer Capture Compare value. More...
 
void DL_Timer_setCaptureCompareCtl (GPTIMER_Regs *gptimer, uint32_t ccMode, uint32_t ccCondMask, DL_TIMER_CC_INDEX ccIndex)
 Sets Capture Compare Control configuration. More...
 
uint32_t DL_Timer_getCaptureCompareCtl (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets Capture Compare Control configuration. More...
 
void DL_Timer_setSecondCompSrcDn (GPTIMER_Regs *gptimer, DL_TIMER_SEC_COMP_DOWN_EVT secCompDn, DL_TIMER_CC_INDEX ccIndex)
 Configures source for second capture compare down event. More...
 
DL_TIMER_SEC_COMP_DOWN_EVT DL_Timer_getSecondCompSrcDn (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets source for second capture compare down event. More...
 
void DL_Timer_setSecondCompSrcUp (GPTIMER_Regs *gptimer, DL_TIMER_SEC_COMP_UP_EVT secCompUp, DL_TIMER_CC_INDEX ccIndex)
 Configures source for second capture compare up event. More...
 
DL_TIMER_SEC_COMP_UP_EVT DL_Timer_getSecondCompSrcUp (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets source for second capture compare down event. More...
 
void DL_Timer_enableSuppressionOfCompEvent (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Enables suppression of compare event if repeat counter is not equal to zero. More...
 
void DL_Timer_disableSuppressionOfCompEvent (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Disables suppression of compare event if repeat counter is not equal to zero. More...
 
void DL_Timer_setCaptCompUpdateMethod (GPTIMER_Regs *gptimer, DL_TIMER_CC_UPDATE_METHOD ccUpdtMode, DL_TIMER_CC_INDEX ccIndex)
 Configures capture compare shadow register update method. More...
 
DL_TIMER_CC_UPDATE_METHOD DL_Timer_getCaptCompUpdateMethod (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets capture compare shadow register update method. More...
 
void DL_Timer_setCaptCompActUpdateMethod (GPTIMER_Regs *gptimer, DL_TIMER_CCACT_UPDATE_METHOD ccUpdtMode, DL_TIMER_CC_INDEX ccIndex)
 Configures capture compare action shadow register update method. More...
 
DL_TIMER_CCACT_UPDATE_METHOD DL_Timer_getCaptCompActUpdateMethod (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets capture compare action shadow register update method. More...
 
void DL_Timer_setCaptureCompareOutCtl (GPTIMER_Regs *gptimer, uint32_t ccpIV, uint32_t ccpOInv, uint32_t ccpO, DL_TIMER_CC_INDEX ccIndex)
 Sets Capture Compare Output Control. More...
 
uint32_t DL_Timer_getCaptureCompareOutCtl (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets Capture Compare Output Control. More...
 
void DL_Timer_setCaptureCompareAction (GPTIMER_Regs *gptimer, uint32_t actionsMask, DL_TIMER_CC_INDEX ccIndex)
 Sets actions of the signal generator. More...
 
uint32_t DL_Timer_getCaptureCompareAction (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets actions of the signal generator. More...
 
void DL_Timer_setSecondCompActionDn (GPTIMER_Regs *gptimer, DL_TIMER_SEC_COMP_DOWN_ACT_SEL secCompDnAct, DL_TIMER_CC_INDEX ccIndex)
 Set second comparator down counting timer channel output action. More...
 
DL_TIMER_SEC_COMP_DOWN_ACT_SEL DL_Timer_getSecondCompActionDn (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets second comparator down counting timer channel output action. More...
 
void DL_Timer_setSecondCompActionUp (GPTIMER_Regs *gptimer, DL_TIMER_SEC_COMP_UP_ACT_SEL secCompUpAct, DL_TIMER_CC_INDEX ccIndex)
 Sets second comparator up counting timer channel output action. More...
 
DL_TIMER_SEC_COMP_UP_ACT_SEL DL_Timer_getSecondCompActionUp (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets second comparator up counting timer channel output action. More...
 
void DL_Timer_overrideCCPOut (GPTIMER_Regs *gptimer, DL_TIMER_FORCE_OUT out, DL_TIMER_FORCE_CMPL_OUT outComp, DL_TIMER_CC_INDEX ccIndex)
 Overrides the timer CCP output. More...
 
void DL_Timer_setCaptureCompareInput (GPTIMER_Regs *gptimer, uint32_t inv, uint32_t isel, DL_TIMER_CC_INDEX ccIndex)
 Sets Capture Compare Input. More...
 
uint32_t DL_Timer_getCaptureCompareInput (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets Capture Compare Input. More...
 
void DL_Timer_setCaptureCompareInputFilter (GPTIMER_Regs *gptimer, uint32_t cpv, uint32_t fp, DL_TIMER_CC_INDEX ccIndex)
 Sets Capture Compare Input Filter. More...
 
uint32_t DL_Timer_getCaptureCompareInputFilter (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Gets Capture Compare Input Filter. More...
 
void DL_Timer_enableCaptureCompareInputFilter (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Enables the capture compare input filter. More...
 
void DL_Timer_disableCaptureCompareInputFilter (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Disables the capture compare input filter. More...
 
bool DL_Timer_isCaptureCompareInputFilterEnabled (GPTIMER_Regs *gptimer, DL_TIMER_CC_INDEX ccIndex)
 Checks if the capture compare input filter is enabled. More...
 
__STATIC_INLINE void DL_Timer_setDeadBand (GPTIMER_Regs *gptimer, uint16_t falldelay, uint16_t risedelay, uint32_t mode)
 Sets dead band fall and raise delay. More...
 
__STATIC_INLINE uint16_t DL_Timer_getDeadBandFallDelay (const GPTIMER_Regs *gptimer)
 Gets dead band fall delay. More...
 
__STATIC_INLINE uint16_t DL_Timer_getDeadBandRiseDelay (const GPTIMER_Regs *gptimer)
 Gets dead band rise delay. More...
 
__STATIC_INLINE void DL_Timer_setExternalTriggerEvent (GPTIMER_Regs *gptimer, DL_TIMER_EXT_TRIG_SEL trigSel)
 Set External Trigger Event. More...
 
__STATIC_INLINE DL_TIMER_EXT_TRIG_SEL DL_Timer_getExternalTriggerEvent (const GPTIMER_Regs *gptimer)
 Gets External Trigger Event. More...
 
__STATIC_INLINE void DL_Timer_enableExternalTrigger (GPTIMER_Regs *gptimer)
 Enables external trigger. More...
 
__STATIC_INLINE void DL_Timer_disableExternalTrigger (GPTIMER_Regs *gptimer)
 Disables external trigger. More...
 
__STATIC_INLINE bool DL_Timer_isExternalTriggerEnabled (const GPTIMER_Regs *gptimer)
 Checks if external trigger is enabled. More...
 
__STATIC_INLINE void DL_Timer_setRepeatCounter (GPTIMER_Regs *gptimer, uint8_t repeatCount)
 Sets repeat counter value. Repeat counter feature is used to reduce interupt overhead. More...
 
__STATIC_INLINE uint8_t DL_Timer_getRepeatCounter (const GPTIMER_Regs *gptimer)
 Gets repeat counter value. More...
 
__STATIC_INLINE void DL_Timer_enablePhaseLoad (GPTIMER_Regs *gptimer)
 Enables phase load. More...
 
__STATIC_INLINE void DL_Timer_disablePhaseLoad (GPTIMER_Regs *gptimer)
 Disables phase load. More...
 
__STATIC_INLINE bool DL_Timer_isPhaseLoadEnabled (const GPTIMER_Regs *gptimer)
 Checks if phase load enabled. More...
 
__STATIC_INLINE void DL_Timer_setPhaseLoadValue (GPTIMER_Regs *gptimer, uint32_t value)
 Sets phase load value. More...
 
__STATIC_INLINE uint32_t DL_Timer_getPhaseLoadValue (const GPTIMER_Regs *gptimer)
 Gets phase load value. More...
 
__STATIC_INLINE void DL_Timer_startCounter (GPTIMER_Regs *gptimer)
 Starts Timer Counter. More...
 
__STATIC_INLINE void DL_Timer_stopCounter (GPTIMER_Regs *gptimer)
 Stops Timer Counter. More...
 
__STATIC_INLINE bool DL_Timer_isRunning (const GPTIMER_Regs *gptimer)
 Check if timer is actively running. More...
 
__STATIC_INLINE void DL_Timer_configQEI (GPTIMER_Regs *gptimer, DL_TIMER_QEI_MODE mode, uint32_t invert, DL_TIMER_CC_INDEX ccIndex)
 Configure Quadrature Encoder Interface (QEI) More...
 
void DL_Timer_configQEIHallInputMode (GPTIMER_Regs *gptimer)
 Configure Hall Input Mode. More...
 
__STATIC_INLINE DL_TIMER_QEI_DIRECTION DL_Timer_getQEIDirection (const GPTIMER_Regs *gptimer)
 Get direction of Quadrature Encoder Interface (QEI) count. More...
 
__STATIC_INLINE void DL_Timer_setFaultConfig (GPTIMER_Regs *gptimer, uint32_t faultConfMask)
 Sets Fault Configuration. More...
 
__STATIC_INLINE uint32_t DL_Timer_getFaultConfig (const GPTIMER_Regs *gptimer)
 Gets Fault Configuration. More...
 
__STATIC_INLINE void DL_Timer_enableFaultInput (GPTIMER_Regs *gptimer)
 Enables fault input detection. More...
 
__STATIC_INLINE void DL_Timer_disableFaultInput (GPTIMER_Regs *gptimer)
 Disables fault input detection. More...
 
__STATIC_INLINE bool DL_Timer_isFaultInputEnabled (const GPTIMER_Regs *gptimer)
 Specifies if fault input is enabled. More...
 
__STATIC_INLINE void DL_Timer_enableClockFaultDetection (GPTIMER_Regs *gptimer)
 Enables source clock fault detection. More...
 
__STATIC_INLINE void DL_Timer_disableClockFaultDetection (GPTIMER_Regs *gptimer)
 Disables source clock fault detection. More...
 
__STATIC_INLINE bool DL_Timer_isClockFaultDetectionEnabled (const GPTIMER_Regs *gptimer)
 Specifies if source clock fault detection is enabled. More...
 
void DL_Timer_setFaultSourceConfig (GPTIMER_Regs *gptimer, uint32_t source)
 Configures the fault source and and fault input mode. More...
 
uint32_t DL_Timer_getFaultSourceConfig (const GPTIMER_Regs *gptimer)
 
__STATIC_INLINE void DL_Timer_setFaultInputFilterConfig (GPTIMER_Regs *gptimer, uint32_t filten, uint32_t cpv, uint32_t fp)
 Set Fault Input Filtering Configuration. More...
 
__STATIC_INLINE uint32_t DL_Timer_getFaultInputFilterConfig (const GPTIMER_Regs *gptimer)
 Get Fault Input Filtering Configuration. More...
 
__STATIC_INLINE void DL_Timer_configFaultOutputAction (GPTIMER_Regs *gptimer, DL_TIMER_FAULT_ENTRY_CCP faultEntry, DL_TIMER_FAULT_EXIT_CCP faultExit, DL_TIMER_CC_INDEX ccIndex)
 Configures output behavior upon fault entry and exit. More...
 
__STATIC_INLINE void DL_Timer_configFaultCounter (GPTIMER_Regs *gptimer, DL_TIMER_FAULT_ENTRY_CTR faultEntry, DL_TIMER_FAULT_EXIT_CTR faultExit)
 Configures timer counter behavior upon fault entry and exit. More...
 
__STATIC_INLINE void DL_Timer_enableInterrupt (GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Enable timer interrupts. More...
 
__STATIC_INLINE void DL_Timer_disableInterrupt (GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Disable timer interrupts. More...
 
__STATIC_INLINE uint32_t DL_Timer_getEnabledInterrupts (const GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Check which timer interrupts are enabled. More...
 
__STATIC_INLINE uint32_t DL_Timer_getEnabledInterruptStatus (const GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Check interrupt flag of enabled timer interrupts. More...
 
__STATIC_INLINE uint32_t DL_Timer_getRawInterruptStatus (const GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Check interrupt flag of any timer interrupt. More...
 
__STATIC_INLINE DL_TIMER_IIDX DL_Timer_getPendingInterrupt (const GPTIMER_Regs *gptimer)
 Get highest priority pending timer interrupt. More...
 
__STATIC_INLINE void DL_Timer_clearInterruptStatus (GPTIMER_Regs *gptimer, uint32_t interruptMask)
 Clear pending timer interrupts. More...
 
__STATIC_INLINE void DL_Timer_setPublisherChanID (GPTIMER_Regs *gptimer, DL_TIMER_PUBLISHER_INDEX index, uint8_t chanID)
 Sets the event publisher channel id. More...
 
__STATIC_INLINE uint8_t DL_Timer_getPublisherChanID (GPTIMER_Regs *gptimer, DL_TIMER_PUBLISHER_INDEX index)
 Gets the event publisher channel id. More...
 
__STATIC_INLINE void DL_Timer_setSubscriberChanID (GPTIMER_Regs *gptimer, DL_TIMER_SUBSCRIBER_INDEX index, uint8_t chanID)
 Sets the event subscriber channel id. More...
 
__STATIC_INLINE uint8_t DL_Timer_getSubscriberChanID (GPTIMER_Regs *gptimer, DL_TIMER_SUBSCRIBER_INDEX index)
 Gets the event subscriber channel id. More...
 
__STATIC_INLINE void DL_Timer_enableEvent (GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Enable timer event. More...
 
__STATIC_INLINE void DL_Timer_disableEvent (GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Disable timer event. More...
 
__STATIC_INLINE uint32_t DL_Timer_getEnabledEvents (GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Check which timer events are enabled. More...
 
__STATIC_INLINE uint32_t DL_Timer_getEnabledEventStatus (const GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Check event flag of enabled timer event. More...
 
__STATIC_INLINE uint32_t DL_Timer_getRawEventsStatus (const GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Check interrupt flag of any timer event. More...
 
__STATIC_INLINE void DL_Timer_clearEventsStatus (GPTIMER_Regs *gptimer, DL_TIMER_EVENT_ROUTE index, uint32_t eventMask)
 Clear pending timer events. More...
 
bool DL_Timer_saveConfiguration (const GPTIMER_Regs *gptimer, DL_Timer_backupConfig *ptr)
 Saves Timer configuration before entering STOP or STANDBY mode. Timer must be in IDLE state before calling this API. Timer can be put IDLE state by calling DL_TimerG_stopCounter or DL_Timer_stopCounter. More...
 
bool DL_Timer_restoreConfiguration (GPTIMER_Regs *gptimer, DL_Timer_backupConfig *ptr, bool restoreCounter)
 Restore Timer configuration after leaving STOP or STANDBY mode. More...
 
__STATIC_INLINE void DL_Timer_setCoreHaltBehavior (GPTIMER_Regs *gptimer, DL_TIMER_CORE_HALT haltMode)
 Configures timer behavior when the core is halted. More...
 
__STATIC_INLINE DL_TIMER_CORE_HALT DL_Timer_getCoreHaltBehavior (const GPTIMER_Regs *gptimer)
 Get timer behavior when the core is halted. More...
 

Detailed Description

Overview

GPTimer module has different variations and have been defined as TimerG and TimerA. This file contains APIs which are common between different variations.


Usage

It is not recommended to include this header file in the application. In order to access TimerG and TimerA functionality include to appropriate timer header file at the application level. Accessing the functionality via the corresponding header file will allow user to determine the functionality supported by the each Timer variant.

To access TimerG functionality:

// Import TIMG definitions

To access TimerA functionality:

// Import TIMA definitions

Enumeration Type Documentation

§ DL_TIMER_CLOCK

Enumerator
DL_TIMER_CLOCK_BUSCLK 

Selects BUSCLK as clock source

DL_TIMER_CLOCK_2X_BUSCLK 

Selects 2X BUSCLK as clock source

DL_TIMER_CLOCK_MFCLK 

Selects MFCLK as clock source

DL_TIMER_CLOCK_LFCLK 

Selects LFCLK as clock source

DL_TIMER_CLOCK_DISABLE 

Disables selected clock source

§ DL_TIMER_CLOCK_DIVIDE

Enumerator
DL_TIMER_CLOCK_DIVIDE_1 

Timer source clock divide ratio set to 1

DL_TIMER_CLOCK_DIVIDE_2 

Timer source clock divide ratio set to 2

DL_TIMER_CLOCK_DIVIDE_3 

Timer source clock divide ratio set to 3

DL_TIMER_CLOCK_DIVIDE_4 

Timer source clock divide ratio set to 4

DL_TIMER_CLOCK_DIVIDE_5 

Timer source clock divide ratio set to 5

DL_TIMER_CLOCK_DIVIDE_6 

Timer source clock divide ratio set to 6

DL_TIMER_CLOCK_DIVIDE_7 

Timer source clock divide ratio set to 7

DL_TIMER_CLOCK_DIVIDE_8 

Timer source clock divide ratio set to 8

§ DL_TIMER_CCP_DIS_OUT

Enumerator
DL_TIMER_CCP_DIS_OUT_LOW 

CCP output source is disabled and driven low before conditional inversion

DL_TIMER_CCP_DIS_OUT_SET_BY_OCTL 

CCP output source is not disabled

§ DL_TIMER_CC_INDEX

Enumerator
DL_TIMER_CC_0_INDEX 

Index associated to Capture Compare 0

DL_TIMER_CC_1_INDEX 

Index associated to Capture Compare 1

DL_TIMER_CC_2_INDEX 

Index associated to Capture Compare 2

DL_TIMER_CC_3_INDEX 

Index associated to Capture Compare 3

DL_TIMER_CC_4_INDEX 

Index associated to Capture Compare 4

DL_TIMER_CC_5_INDEX 

Index associated to Capture Compare 5

§ DL_TIMER_EXT_TRIG_SEL

Enumerator
DL_TIMER_EXT_TRIG_SEL_TRIG_0 

External trigger 0

DL_TIMER_EXT_TRIG_SEL_TRIG_1 

External trigger 1

DL_TIMER_EXT_TRIG_SEL_TRIG_2 

External trigger 2

DL_TIMER_EXT_TRIG_SEL_TRIG_3 

External trigger 3

DL_TIMER_EXT_TRIG_SEL_TRIG_4 

External trigger 4

DL_TIMER_EXT_TRIG_SEL_TRIG_5 

External trigger 5

DL_TIMER_EXT_TRIG_SEL_TRIG_6 

External trigger 6

DL_TIMER_EXT_TRIG_SEL_TRIG_7 

External trigger 7

DL_TIMER_EXT_TRIG_SEL_TRIG_8 

External trigger 8

DL_TIMER_EXT_TRIG_SEL_TRIG_9 

External trigger 9

DL_TIMER_EXT_TRIG_SEL_TRIG_10 

External trigger 10

DL_TIMER_EXT_TRIG_SEL_TRIG_11 

External trigger 11

DL_TIMER_EXT_TRIG_SEL_TRIG_12 

External trigger 12

DL_TIMER_EXT_TRIG_SEL_TRIG_13 

External trigger 13

DL_TIMER_EXT_TRIG_SEL_TRIG_14 

External trigger 14

DL_TIMER_EXT_TRIG_SEL_TRIG_15 

External trigger 15

DL_TIMER_EXT_TRIG_SEL_TRIG_SUB_0 

External event subscriber 0

DL_TIMER_EXT_TRIG_SEL_TRIG_SUB_1 

External event subscriber 1

§ DL_TIMER_TIMER_MODE

Enumerator
DL_TIMER_TIMER_MODE_ONE_SHOT 

Configures Timer in one shot mode in DOWN COUNTING mode

DL_TIMER_TIMER_MODE_PERIODIC 

Configures Timer in periodic mode in DOWN COUNTING mode

DL_TIMER_TIMER_MODE_ONE_SHOT_UP 

Configures Timer in one shot mode in UP COUNTING mode

DL_TIMER_TIMER_MODE_PERIODIC_UP 

Configures Timer in periodic mode in UP COUNTING mode

DL_TIMER_TIMER_MODE_ONE_SHOT_UP_DOWN 

Configures Timer in one shot mode in UP/DOWN COUNTING mode

DL_TIMER_TIMER_MODE_PERIODIC_UP_DOWN 

Configures Timer in periodic mode in UP/DOWN COUNTING mode

§ DL_TIMER_CAPTURE_MODE

Enumerator
DL_TIMER_CAPTURE_MODE_EDGE_TIME 

Configures Timer in edge time capture mode and timer is configured ! in down counting mode

DL_TIMER_CAPTURE_MODE_PERIOD_CAPTURE 

Configures Timer in period capture mode and timer is configured ! in down counting mode

DL_TIMER_CAPTURE_MODE_PULSE_WIDTH 

Configures Timer in pulse width capture mode and timer is configured ! in down counting mode

DL_TIMER_CAPTURE_MODE_EDGE_TIME_UP 

Configures Timer in edge time capture mode and timer is configured ! in up counting mode

DL_TIMER_CAPTURE_MODE_PERIOD_CAPTURE_UP 

Configures Timer in period capture mode and timer is configured ! in up counting mode

DL_TIMER_CAPTURE_MODE_PULSE_WIDTH_UP 

Configures Timer in pulse width capture mode and timer is configured ! in up counting mode

§ DL_TIMER_CAPTURE_COMBINED_MODE

Enumerator
DL_TIMER_CAPTURE_COMBINED_MODE_PULSE_WIDTH_AND_PERIOD 

Configures Timer in pulse width and period mode and timer is configured ! in down counting mode

DL_TIMER_CAPTURE_COMBINED_MODE_PULSE_WIDTH_AND_PERIOD_UP 

Configures Timer in pulse width and period mode and timer is configured ! in up counting mode

§ DL_TIMER_COMPARE_MODE

Enumerator
DL_TIMER_COMPARE_MODE_EDGE_COUNT 

Configures Timer in edge count mode and timer is configured ! in down counting mode

DL_TIMER_COMPARE_MODE_EDGE_COUNT_UP 

Configures Timer in edge count mode and timer is configured ! in up counting mode

DL_TIMER_COMPARE_MODE_EDGE_COUNT_UP_DOWN 

Configures Timer in edge count mode and timer is configured ! in up/down counting mode

§ DL_TIMER_COUNT_MODE

Enumerator
DL_TIMER_COUNT_MODE_DOWN 

Timer counts in DOWN mode

DL_TIMER_COUNT_MODE_UP_DOWN 

Timer counts in UP/DOWN mode

DL_TIMER_COUNT_MODE_UP 

Timer counts in UP mode

§ DL_TIMER

enum DL_TIMER
Enumerator
DL_TIMER_START 

Start running timer

DL_TIMER_STOP 

Don't start running timer

§ DL_TIMER_INTERM_INT

Enumerator
DL_TIMER_INTERM_INT_ENABLED 

Enables intermediate interrupt in timer mode

DL_TIMER_INTERM_INT_DISABLED 

Disabled intermediate interrupt in timer mode

§ DL_TIMER_CAPTURE_EDGE_DETECTION_MODE

Enumerator
DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_RISING 

Selects rising edge detection

DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_FALLING 

Selects falling edge detection

DL_TIMER_CAPTURE_EDGE_DETECTION_MODE_EDGE 

Selects both falling and rising edge detection

§ DL_TIMER_COMPARE_EDGE_DETECTION_MODE

Enumerator
DL_TIMER_COMPARE_EDGE_DETECTION_MODE_RISING 

Selects rising edge detection

DL_TIMER_COMPARE_EDGE_DETECTION_MODE_FALLING 

Selects falling edge detection

DL_TIMER_COMPARE_EDGE_DETECTION_MODE_EDGE 

Selects both (rising and falling) edge detection

§ DL_TIMER_PWM_MODE

Enumerator
DL_TIMER_PWM_MODE_EDGE_ALIGN 

Configured Timer for PWM in edge align mode

DL_TIMER_PWM_MODE_EDGE_ALIGN_UP 

Configured Timer for PWM in edge align mode

DL_TIMER_PWM_MODE_CENTER_ALIGN 

Configured Timer for PWM in center align mode

§ DL_TIMER_DEAD_BAND_MODE

Enumerator
DL_TIMER_DEAD_BAND_MODE_0 

Selects dead band insertion mode 0

DL_TIMER_DEAD_BAND_MODE_1 

Selects dead band insertion mode 1

§ DL_TIMER_FAULT_ENTRY_CCP

Enumerator
DL_TIMER_FAULT_ENTRY_CCP_DISABLED 

The CCP output value is not affected by the event

DL_TIMER_FAULT_ENTRY_CCP_HIGH 

The CCP output value is set high

DL_TIMER_FAULT_ENTRY_CCP_LOW 

The CCP output value is set to low

DL_TIMER_FAULT_ENTRY_CCP_TOGGLE 

The CCP output value is toggled

DL_TIMER_FAULT_ENTRY_CCP_HIGHZ 

The CCP output value is High-Z

§ DL_TIMER_FAULT_EXIT_CCP

Enumerator
DL_TIMER_FAULT_EXIT_CCP_DISABLED 

The CCP output value is not affected by the event

DL_TIMER_FAULT_EXIT_CCP_HIGH 

The CCP output value is set high

DL_TIMER_FAULT_EXIT_CCP_LOW 

The CCP output value is set to low

DL_TIMER_FAULT_EXIT_CCP_TOGGLE 

The CCP output value is toggled

DL_TIMER_FAULT_EXIT_CCP_HIGHZ 

The CCP output value is High-Z

§ DL_TIMER_FAULT_EXIT_CTR

Enumerator
DL_TIMER_FAULT_EXIT_CTR_RESUME 

Timer resumes counting upon release of fault condition

DL_TIMER_FAULT_EXIT_CTR_CVAE_ACTION 

Timer resumes operation based on counter value after enable configuration

§ DL_TIMER_FAULT_ENTRY_CTR

Enumerator
DL_TIMER_FAULT_ENTRY_CTR_CONT_COUNT 

Timer counter continues running during fault

DL_TIMER_FAULT_ENTRY_CTR_SUSP_COUNT 

Timer counter continues is suspended during fault

§ DL_TIMER_CROSS_TRIG_SRC

Enumerator
DL_TIMER_CROSS_TRIG_SRC_FSUB0 

Use FSUB0 for Event manager

DL_TIMER_CROSS_TRIG_SRC_FSUB1 

Use FSUB1 for Event manager

DL_TIMER_CROSS_TRIG_SRC_ZERO 

Use Zero event as cross trigger source

DL_TIMER_CROSS_TRIG_SRC_LOAD 

Use Load event as cross trigger source

DL_TIMER_CROSS_TRIG_SRC_CCD0 

Use Capture Compare Down 0 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCD1 

Use Capture Compare Down 1 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCD2 

Use Capture Compare Down 2 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCD3 

Use Capture Compare Down 3 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCU0 

Use Capture Compare Up 0 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCU1 

Use Capture Compare Up 1 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCU2 

Use Capture Compare Up 2 event as cross trigger source.

DL_TIMER_CROSS_TRIG_SRC_CCU3 

Use Capture Compare Up 3 event as cross trigger source.

§ DL_TIMER_CROSS_TRIGGER_INPUT

Enumerator
DL_TIMER_CROSS_TRIGGER_INPUT_ENABLED 

Cross Triggering through subscriber ports enabled

DL_TIMER_CROSS_TRIGGER_INPUT_DISABLED 

Cross Triggering through subscriber ports disabled

§ DL_TIMER_CROSS_TRIGGER_MODE

Enumerator
DL_TIMER_CROSS_TRIGGER_MODE_ENABLED 

Cross Triggering Enabled

DL_TIMER_CROSS_TRIGGER_MODE_DISABLED 

Cross Triggering Disabled

§ DL_TIMER_IIDX

Enumerator
DL_TIMER_IIDX_ZERO 

Timer interrupt index for zero interrupt

DL_TIMER_IIDX_LOAD 

Timer interrupt index for load interrupt

DL_TIMER_IIDX_CC0_DN 

Timer interrupt index for compare 0 down interrupt

DL_TIMER_IIDX_CC1_DN 

Timer interrupt index for compare 1 down interrupt

DL_TIMER_IIDX_CC2_DN 

Timer interrupt index for compare 2 down interrupt

DL_TIMER_IIDX_CC3_DN 

Timer interrupt index for compare 3 down interrupt

DL_TIMER_IIDX_CC0_UP 

Timer interrupt index for compare 0 up interrupt

DL_TIMER_IIDX_CC1_UP 

Timer interrupt index for compare 1 up interrupt

DL_TIMER_IIDX_CC2_UP 

Timer interrupt index for compare 2 up interrupt

DL_TIMER_IIDX_CC3_UP 

Timer interrupt index for compare 3 up interrupt

DL_TIMER_IIDX_CC4_DN 

Timer interrupt index for compare 4 down interrupt

DL_TIMER_IIDX_CC5_DN 

Timer interrupt index for compare 5 down interrupt

DL_TIMER_IIDX_CC4_UP 

Timer interrupt index for compare 4 up interrupt

DL_TIMER_IIDX_CC5_UP 

Timer interrupt index for compare 5 up interrupt

DL_TIMER_IIDX_FAULT 

Timer interrupt index for fault interrupt

DL_TIMER_IIDX_OVERFLOW 

Timer interrupt index for timer overflow interrupt

DL_TIMER_IIDX_REPEAT_COUNT 

Timer interrupt index for repeat counter

Note
This is a Timer A specific interrupt.
DL_TIMER_IIDX_DIR_CHANGE 

Timer interrupt index for direction change interrupt

Note
Please refer the Timer TRM to determine TIMG instances which support this feature.
DL_TIMER_IIDX_QEIERR 

Timer interrupt index for QEI incorrect state transition

Note
Please refer the Timer TRM to determine TIMG instances which support this feature.

§ DL_TIMER_PUBLISHER_INDEX

Enumerator
DL_TIMER_PUBLISHER_INDEX_0 

TIMER Publisher index 0

DL_TIMER_PUBLISHER_INDEX_1 

TIMER Publisher index 1

§ DL_TIMER_SUBSCRIBER_INDEX

Enumerator
DL_TIMER_SUBSCRIBER_INDEX_0 

TIMER Subscriber index 0

DL_TIMER_SUBSCRIBER_INDEX_1 

TIMER Subscriber index 1

§ DL_TIMER_EVENT_ROUTE

Enumerator
DL_TIMER_EVENT_ROUTE_1 

TIMER event route 1

DL_TIMER_EVENT_ROUTE_2 

TIMER event route 2

§ DL_TIMER_INPUT_CHAN

Enumerator
DL_TIMER_INPUT_CHAN_0 

Selected timer instance channel 0 as input capture channel

DL_TIMER_INPUT_CHAN_1 

Selects timer instance channel 1 as input capture channel

DL_TIMER_INPUT_CHAN_2 

Selects timer instance channel 2 as input capture channel. Please refer to device DS to determine number of input channels by the timer instance

DL_TIMER_INPUT_CHAN_3 

Selects timer instance channel 3 as input capture channel. Please refer to device DS to determine number of input channels by the timer instance

§ DL_TIMER_DEBUG_RES

Enumerator
DL_TIMER_DEBUG_RES_RESUME 

Resume counting

DL_TIMER_DEBUG_RES_CVAE_ACTION 

Perform the action as specified by the Counter Value After Enable (CVAE) ! field.

§ DL_TIMER_CZC

Enumerator
DL_TIMER_CZC_CCCTL0_ZCOND 

Zero event is controlled by CCCTL0 Zero condition

DL_TIMER_CZC_CCCTL1_ZCOND 

Zero event is controlled by CCCTL1 Zero condition

DL_TIMER_CZC_CCCTL2_ZCOND 

Zero event is controlled by CCCTL2 Zero condition

DL_TIMER_CZC_CCCTL3_ZCOND 

Zero event is controlled by CCCTL3 Zero condition

DL_TIMER_CZC_QEI_2INP 

Zero event is controlled by 2-input QEI mode

DL_TIMER_CZC_QEI_3INP 

Zero event is controlled by 3-input QEI mode

§ DL_TIMER_CAC

Enumerator
DL_TIMER_CAC_CCCTL0_ACOND 

Advance event is controlled by CCCTL0 advance condition

DL_TIMER_CAC_CCCTL1_ACOND 

Advance event is controlled by CCCTL1 advance condition

DL_TIMER_CAC_CCCTL2_ACOND 

Advance event is controlled by CCCTL2 advance condition

DL_TIMER_CAC_CCCTL3_ACOND 

Advance event is controlled by CCCTL3 advance condition

DL_TIMER_CAC_QEI_2INP 

Advance event is controlled by 2-input QEI mode

DL_TIMER_CAC_QEI_3INP 

Advance event is controlled by 3-input QEI mode

§ DL_TIMER_CLC

Enumerator
DL_TIMER_CLC_CCCTL0_LCOND 

Load event is controlled by CCCTL0 load condition

DL_TIMER_CLC_CCCTL1_LCOND 

Load event is controlled by CCCTL1 load condition

DL_TIMER_CLC_CCCTL2_LCOND 

Load event is controlled by CCCTL2 load condition

DL_TIMER_CLC_CCCTL3_LCOND 

Load event is controlled by CCCTL3 load condition

DL_TIMER_CLC_QEI_2INP 

Load event is controlled by 2-input QEI mode

DL_TIMER_CLC_QEI_3INP 

Load event is controlled by 3-input QEI mode

§ DL_TIMER_COUNT_AFTER_EN

Enumerator
DL_TIMER_COUNT_AFTER_EN_LOAD_VAL 

The counter is set to the LOAD register value

DL_TIMER_COUNT_AFTER_EN_NO_CHANGE 

The counter value is unchanged from its current value

DL_TIMER_COUNT_AFTER_EN_ZERO 

The counter is set to zero

§ DL_TIMER_REPEAT_MODE

Enumerator
DL_TIMER_REPEAT_MODE_DISABLED 

Does not automatically advance following a zero event

DL_TIMER_REPEAT_MODE_ENABLED 

Continues to advance following a zero event

DL_TIMER_REPEAT_MODE_ENABLED_DEBUG 

Continues to advance following a zero event if the debug mode is not in ! effect, or following the release of the debug mode

§ DL_TIMER_CC_UPDATE_METHOD

Enumerator
DL_TIMER_CC_UPDATE_METHOD_IMMEDIATE 

Value written to the CCACT.SWFRCACT register has immediate effect

DL_TIMER_CC_UPDATE_METHOD_ZERO_EVT 

Following a zero event. Writes to the CCx_y register are stored in Shadow register and transferred to CCx_y in the TIMCLK cycle following CTR equals 0

DL_TIMER_CC_UPDATE_METHOD_COMP_DN_EVT 

Following a compare (down) event. Writes to the CCx_y register are stored in Shadow register and transferred to CCx_y in the TIMCLK cycle following CTR equals the CCx_y register value.

DL_TIMER_CC_UPDATE_METHOD_COMP_UP_EVT 

Following a compare (up) event. Writes to the CCx_y register are stored in Shadow register and transferred to CCx_y in the TIMCLK cycle following CTR equals the CCx_y register value.

DL_TIMER_CC_UPDATE_METHOD_ZERO_OR_LOAD_EVT 

Following a zero or load event. Writes to the CCx_y register are stored in Shadow register and transferred to CCx_y in the TIMCLK cycle following CTR equals 0 or CTR. Equals LDn. Note this update mechanism is defined for use only in configurations using up/down counting. This mode is not intended for use in down count configurations

DL_TIMER_CC_UPDATE_METHOD_ZERO_RC_EVT 

Following a zero event with repeat count also zero. Writes to the CCx_y register are stored in Shadow register and transferred to CCx_y in the TIMCLK cycle following CTR equals 0 and if RC equal 0.

DL_TIMER_CC_UPDATE_METHOD_TRIG_EVT 

Following a TRIG pulse, writes to the ! Capture Compare register are stored in shadow register and transferred ! to Capture Compare register in the TIMCLK cycle following timer counter ! equal to zero AND repeaet counter value is 0

§ DL_TIMER_CCACT_UPDATE_METHOD

Enumerator
DL_TIMER_CCACT_UPDATE_METHOD_IMMEDIATE 

Value written to the CCACT register has immediate effect

DL_TIMER_CCACT_UPDATE_METHOD_ZERO_EVT 

Following a zero event (CTR=0) Writes to the CCACTx_y register are stored in shadow register and transferred to CCACTx_y in the TIMCLK cycle following CTR equals 0.

DL_TIMER_CCACT_UPDATE_METHOD_COMP_DN_EVT 

Following a CCD event (CTR=CC_xy). Writes to the CCACTx_y register are stored in shadow register and transferred to CCACTx_y in the TIMCLK cycle following CTR equals the CCx_y register value.

DL_TIMER_CCACT_UPDATE_METHOD_COMP_UP_EVT 

Following a CCU event (CTR=CC_xy) Writes to the CCACTx_y register are stored in shadow register and transferred to CCACTx_y in the TIMCLK cycle following CTR equals the CCx_y register value.

DL_TIMER_CCACT_UPDATE_METHOD_ZERO_OR_LOAD_EVT 

Following a zero event (CTR=0) or load event (CTR = LOAD) Writes to the CCACTx_y register are stored in shadow register and transferred to CCACTx_y in the TIMCLK cycle following CTR equals 0 or CTR. E

DL_TIMER_CCACT_UPDATE_METHOD_ZERO_RC_EVT 

Following a zero event (CTR=0) with repeat count also zero (RC=0). Writes to the CCACTx_y register are stored in shadow register and transferred to CCACTx_y in the TIMCLK cycle following CTR equals 0 and if RC equal 0.

DL_TIMER_CCACT_UPDATE_METHOD_TRIG_EVT 

On a TRIG pulse, the value stored in CCACT_xy shadow register is loaded into CCACT_xy register.

§ DL_TIMER_SEC_COMP_DOWN_EVT

Enumerator
DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC0 

Selects Capture Compare down event based on Capture Compare register 0 ! value

DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC1 

Selects Capture Compare down event based on Capture Compare register 1 ! value

DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC2 

Selects Capture Compare down event based on Capture Compare register 2 ! value

DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC3 

Selects Capture Compare down event based on Capture Compare register 3 ! value

DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC4 

Selects Capture Compare down event based on Capture Compare register 4 ! value

DL_TIMER_SEC_COMP_DOWN_EVT_SEL_CC5 

Selects Capture Compare down event based on Capture Compare register 5 ! value

§ DL_TIMER_SEC_COMP_UP_EVT

Enumerator
DL_TIMER_SEC_COMP_UP_EVT_SEL_CC0 

Selects Capture Compare up event based on Capture Compare register 0 ! value

DL_TIMER_SEC_COMP_UP_EVT_SEL_CC1 

Selects Capture Compare up event based on Capture Compare register 1 ! value

DL_TIMER_SEC_COMP_UP_EVT_SEL_CC2 

Selects Capture Compare up event based on Capture Compare register 2 ! value

DL_TIMER_SEC_COMP_UP_EVT_SEL_CC3 

Selects Capture Compare up event based on Capture Compare register 3 ! value

DL_TIMER_SEC_COMP_UP_EVT_SEL_CC4 

Selects Capture Compare up event based on Capture Compare register 4 ! value

DL_TIMER_SEC_COMP_UP_EVT_SEL_CC5 

Selects Capture Compare up event based on Capture Compare register 5 ! value

§ DL_TIMER_SEC_COMP_UP_ACT_SEL

Enumerator
DL_TIMER_SEC_COMP_UP_ACT_SEL_DISABLE 

Second comparator output action is disabled.

DL_TIMER_SEC_COMP_UP_ACT_SEL_HIGH 

Timer channel is set high when the second comparator up counting event is detected

DL_TIMER_SEC_COMP_UP_ACT_SEL_LOW 

Timer channel is set low when the second comparator up counting event is detected

DL_TIMER_SEC_COMP_UP_ACT_SEL_TOGGLE 

Timer channel is toggles when the second comparator up counting event is detected

§ DL_TIMER_SEC_COMP_DOWN_ACT_SEL

Enumerator
DL_TIMER_SEC_COMP_DOWN_ACT_SEL_DISABLE 

Second comparator output action is disabled.

DL_TIMER_SEC_COMP_DOWN_ACT_SEL_HIGH 

Timer channel is set high when the second comparator down counting event is detected

DL_TIMER_SEC_COMP_DOWN_ACT_SEL_LOW 

Timer channel is set low when the second comparator down counting event is detected

DL_TIMER_SEC_COMP_DOWN_ACT_SEL_TOGGLE 

Timer channel is toggles when the second comparator down counting event is detected

§ DL_TIMER_SUPP_COMP_EVT_RC

Enumerator
DL_TIMER_SUPP_COMP_EVT_RC_DISABLED 

Capture compare up and down events are always generated from the counter ! when their conditions are genreated

DL_TIMER_SUPP_COMP_EVT_RC_ENABLED 

Capture compare up and down events are generated from the counter when ! their conditions are genreated and the repeat counter value is 0

§ DL_TIMER_FORCE_OUT

Enumerator
DL_TIMER_FORCE_OUT_DISABLED 

The CCP output value is unaffected

DL_TIMER_FORCE_OUT_HIGH 

Output value is set high

DL_TIMER_FORCE_OUT_LOW 

Output value is set low

§ DL_TIMER_FORCE_CMPL_OUT

Enumerator
DL_TIMER_FORCE_CMPL_OUT_DISABLED 

The complementary CCP output value is unaffected

DL_TIMER_FORCE_CMPL_OUT_HIGH 

Complementary CCP output is set high

DL_TIMER_FORCE_CMPL_OUT_LOW 

Complementary CCP output is set low

§ DL_TIMER_CORE_HALT

Enumerator
DL_TIMER_CORE_HALT_IMMEDIATE 

Timer will halt immediately, even if the resultant state will result in corruption if the system is restarted

DL_TIMER_CORE_HALT_DELAYED 

Timer blocks the debug freeze until it has reached a boundary where it can resume without corruption

DL_TIMER_CORE_HALT_FREE_RUN 

Timer ignores the state of the Core Halted input

§ DL_TIMER_QEI_MODE

Enumerator
DL_TIMER_QEI_MODE_2_INPUT 

Set QEI to 2 input mode: PHA->CCP0, PHB->CCP1.

DL_TIMER_QEI_MODE_3_INPUT 

Set QEI to 3 input mode: PHA->CCP0, PHB->CCP1, Index input signal->IDX.

§ DL_TIMER_QEI_DIRECTION

Enumerator
DL_TIMER_QEI_DIR_DOWN 

Encoder counter going down

DL_TIMER_QEI_DIR_UP 

Encoder counter going up

Function Documentation

§ DL_Timer_enablePower()

__STATIC_INLINE void DL_Timer_enablePower ( GPTIMER_Regs *  gptimer)

Enables the Peripheral Write Enable (PWREN) register for the timer.

Before any peripheral registers can be configured by software, the peripheral itself must be enabled by writing the ENABLE bit together with the appropriate KEY value to the peripheral's PWREN register.

Parameters
gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disablePower()

__STATIC_INLINE void DL_Timer_disablePower ( GPTIMER_Regs *  gptimer)

Disables the Peripheral Write Enable (PWREN) register for the timer.

When the PWREN.ENABLE bit is cleared, the peripheral's registers are not accessible for read/write operations.

Note
This API does not provide large power savings.
Parameters
gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isPowerEnabled()

__STATIC_INLINE bool DL_Timer_isPowerEnabled ( const GPTIMER_Regs *  gptimer)

Returns if the Peripheral Write Enable (PWREN) register for the timer is enabled.

Before any peripheral registers can be configured by software, the peripheral itself must be enabled by writing the ENABLE bit together with the appropriate KEY value to the peripheral's PWREN register.

When the PWREN.ENABLE bit is cleared, the peripheral's registers are not accessible for read/write operations.

Parameters
gptimerPointer to the register overlay for the peripheral
Returns
true if peripheral register access is enabled
false if peripheral register access is disabled

§ DL_Timer_reset()

__STATIC_INLINE void DL_Timer_reset ( GPTIMER_Regs *  gptimer)

Resets timer peripheral.

Parameters
gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isReset()

__STATIC_INLINE bool DL_Timer_isReset ( const GPTIMER_Regs *  gptimer)

Returns if timer peripheral has been reset.

Parameters
gptimerPointer to the register overlay for the peripheral
Returns
true if peripheral was reset
false if peripheral wasn't reset

§ DL_Timer_setCCPDirection()

__STATIC_INLINE void DL_Timer_setCCPDirection ( GPTIMER_Regs *  gptimer,
uint32_t  ccpConfig 
)

Sets CCP Direction.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccpConfigDirection configuration for CCP as input or output. Bitwise OR of DL_TIMER_CCx

§ DL_Timer_getCCPDirection()

__STATIC_INLINE uint32_t DL_Timer_getCCPDirection ( const GPTIMER_Regs *  gptimer)

Gets CCP Direction.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Bitwise OR of CCP Direction configuration DL_TIMER_CCx

§ DL_Timer_setCCPOutputDisabled()

__STATIC_INLINE void DL_Timer_setCCPOutputDisabled ( GPTIMER_Regs *  gptimer,
DL_TIMER_CCP_DIS_OUT  ccp0Config,
DL_TIMER_CCP_DIS_OUT  ccp1Config 
)

Forces the output of the timer low via the ODIS register. This can be useful during shutdown or configuring the timer. The output pin still passes through the inversion (INV) bit. See figure "Output connection for TIMG" in Technical Reference Manual (TRM) for diagram. DL_Timer_overrideCCPOut() can be used for for similar functionality, where independent overrride settings for the output and complementary output channels can be configured.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccp0ConfigOutput Configuration for CCP0. One of DL_TIMER_CCP_DIS_OUT
[in]ccp1ConfigOutput Configuration for CCP1. One of DL_TIMER_CCP_DIS_OUT

References DL_Common_updateReg().

§ DL_Timer_setCCPOutputDisabledAdv()

__STATIC_INLINE void DL_Timer_setCCPOutputDisabledAdv ( GPTIMER_Regs *  gptimer,
uint32_t  ccpOdisConfig 
)

Sets CCP Output configuration for timer instances with more than two CCP channels via the ODIS register. The output pin still passes through the inversion (INV) bit.

Note
Refer to device datasheet to determine if timer instance supports this feature. Only Timer instance which supports more than two CCP channels should use this API.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccpOdisConfigOutput Configuration for CCP channels. Bitwise OR DL_TIMER_CCP0_DIS_OUT_ADV, DL_TIMER_CCP1_DIS_OUT_ADV, DL_TIMER_CCP2_DIS_OUT_ADV, DL_TIMER_CCP3_DIS_OUT_ADV

References DL_Common_updateReg(), DL_Timer_getClockConfig(), and DL_Timer_setClockConfig().

§ DL_Timer_setClockConfig()

void DL_Timer_setClockConfig ( GPTIMER_Regs *  gptimer,
const DL_Timer_ClockConfig config 
)

Configure timer source clock.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the clock configuration struct DL_Timer_ClockConfig.

Referenced by DL_Timer_setCCPOutputDisabledAdv().

§ DL_Timer_getClockConfig()

void DL_Timer_getClockConfig ( const GPTIMER_Regs *  gptimer,
DL_Timer_ClockConfig config 
)

Get timer source clock configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the clock configuration struct DL_Timer_ClockConfig.

Referenced by DL_Timer_setCCPOutputDisabledAdv().

§ DL_Timer_enableClock()

__STATIC_INLINE void DL_Timer_enableClock ( GPTIMER_Regs *  gptimer)

Enable timer clock.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableClock()

__STATIC_INLINE void DL_Timer_disableClock ( GPTIMER_Regs *  gptimer)

Disable timer clock.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isClockEnabled()

__STATIC_INLINE bool DL_Timer_isClockEnabled ( const GPTIMER_Regs *  gptimer)

Returns if timer clock is disabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
true if clock is enabled
false if clock is disabled

§ DL_Timer_configCrossTrigger()

__STATIC_INLINE void DL_Timer_configCrossTrigger ( GPTIMER_Regs *  gptimer,
DL_TIMER_CROSS_TRIG_SRC  ctSource,
DL_TIMER_CROSS_TRIGGER_INPUT  enInTrigCond,
DL_TIMER_CROSS_TRIGGER_MODE  enCrossTrig 
)

Configure Cross Timer Trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ctSourceSelects cross trigger source. DL_TIMER_CROSS_TRIG_SRC
[in]enInTrigCondCofigures Input Trigger Conditions to the Timer module as a condition for Cross Triggers * DL_TIMER_CROSS_TRIGGER_INPUT
[in]enCrossTrigConfigures Timer Cross trigger DL_TIMER_CROSS_TRIGGER_MODE

§ DL_Timer_configCrossTriggerSrc()

__STATIC_INLINE void DL_Timer_configCrossTriggerSrc ( GPTIMER_Regs *  gptimer,
DL_TIMER_CROSS_TRIG_SRC  ctSource 
)

Configure Cross Timer Trigger source.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ctSourceSelects cross trigger source. DL_TIMER_CROSS_TRIG_SRC

References DL_Common_updateReg().

§ DL_Timer_configCrossTriggerInputCond()

__STATIC_INLINE void DL_Timer_configCrossTriggerInputCond ( GPTIMER_Regs *  gptimer,
DL_TIMER_CROSS_TRIGGER_INPUT  enInTrigCond 
)

Enables/DIsables Input Trigger condition for Cross Timer Trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]enInTrigCondCofigures Input Trigger Conditions to the Timer module as a condition for Cross Triggers DL_TIMER_CROSS_TRIGGER_INPUT

References DL_Common_updateReg().

§ DL_Timer_configCrossTriggerEnable()

__STATIC_INLINE void DL_Timer_configCrossTriggerEnable ( GPTIMER_Regs *  gptimer,
DL_TIMER_CROSS_TRIGGER_MODE  enCrossTrig 
)

Enable/Disable Cross Timer Trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]enCrossTrigConfigures Timer Cross trigger DL_TIMER_CROSS_TRIGGER_MODE

References DL_Common_updateReg().

§ DL_Timer_getCrossTriggerConfig()

__STATIC_INLINE uint32_t DL_Timer_getCrossTriggerConfig ( const GPTIMER_Regs *  gptimer)

Get Cross Timer Trigger configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Bitwise OR of DL_TIMER_CROSS_TRIG_SRC, DL_TIMER_CROSS_TRIGGER_INPUT, DL_TIMER_CROSS_TRIGGER_MODE,

§ DL_Timer_getCrossTriggerSrc()

__STATIC_INLINE DL_TIMER_CROSS_TRIG_SRC DL_Timer_getCrossTriggerSrc ( const GPTIMER_Regs *  gptimer)

Get Cross Timer Trigger source.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
One of DL_TIMER_CROSS_TRIG_SRC

§ DL_Timer_getCrossTriggerInputCond()

__STATIC_INLINE DL_TIMER_CROSS_TRIGGER_INPUT DL_Timer_getCrossTriggerInputCond ( const GPTIMER_Regs *  gptimer)

Get Input Trigger condition for Cross Timer Trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
One of DL_TIMER_CROSS_TRIGGER_INPUT

§ DL_Timer_getCrossTriggerEnable()

__STATIC_INLINE DL_TIMER_CROSS_TRIGGER_MODE DL_Timer_getCrossTriggerEnable ( const GPTIMER_Regs *  gptimer)

Checks if Cross Timer Trigger is enabled or disabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
One of DL_TIMER_CROSS_TRIGGER_MODE

§ DL_Timer_generateCrossTrigger()

__STATIC_INLINE void DL_Timer_generateCrossTrigger ( GPTIMER_Regs *  gptimer)

Generates a synchronized trigger condition across all trigger enabled Timer instances.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_enableShadowFeatures()

__STATIC_INLINE void DL_Timer_enableShadowFeatures ( GPTIMER_Regs *  gptimer)

Enable shadow to activate load of buffered registers and register fields.

Note
Please refer to the device datasheet to determine shadow features avaialable per timer instance.
Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableShadowFeatures()

__STATIC_INLINE void DL_Timer_disableShadowFeatures ( GPTIMER_Regs *  gptimer)

Disable shadow to activate load of buffered registers and register fields.

Note
Please refer to the device datasheet to determine shadow features avaialable per timer instance.
Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_setLoadValue()

__STATIC_INLINE void DL_Timer_setLoadValue ( GPTIMER_Regs *  gptimer,
uint32_t  value 
)

Sets timer LOAD register value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]valueValue to be loaded to timer LOAD register. Refer to the device datasheet to determine the bit width of the counter for the selected Timer instance.

§ DL_Timer_getLoadValue()

__STATIC_INLINE uint32_t DL_Timer_getLoadValue ( const GPTIMER_Regs *  gptimer)

Gets the timer LOAD register value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the timer's LOAD register value.

§ DL_Timer_getTimerCount()

__STATIC_INLINE uint32_t DL_Timer_getTimerCount ( const GPTIMER_Regs *  gptimer)

Gets the current counter value of the timer.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the timer counter value

§ DL_Timer_setTimerCount()

__STATIC_INLINE void DL_Timer_setTimerCount ( GPTIMER_Regs *  gptimer,
uint32_t  value 
)

Set timer counter value.

Note
Warning setting the counter value directly while the timer's counter is running can lead to unpredictable behavior. This function should only be used when the timer's counter isn't running. If you need to change the counter value while it is running then use DL_Timer_setLoadValue(). For TimerH use DL_TimerH_setLoadValue() instead. These functions will update the LOAD register which will safely copy its value to the counter register.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]valueValue to set the timer counter value to

§ DL_Timer_enableLZEventSuppression()

__STATIC_INLINE void DL_Timer_enableLZEventSuppression ( GPTIMER_Regs *  gptimer)

Enable suppression of load and zero events.

Note
Refer to device datasheet to determine if timer instance supports this feature. Only Timer instance which supports Repeat Counter supports this feature.
Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableLZEventSuppression()

__STATIC_INLINE void DL_Timer_disableLZEventSuppression ( GPTIMER_Regs *  gptimer)

Disable suppression of load and zero events.

Note
Refer to device datasheet to determine if timer instance supports this feature. Only Timer instances which supports Repeat Counter supports this feature.
Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isLZEventSuppressionEnabled()

__STATIC_INLINE bool DL_Timer_isLZEventSuppressionEnabled ( const GPTIMER_Regs *  gptimer)

Checks if suppression of load and zero events is enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the status ofsuppression of load and zero events
Return values
truesuppression of load and zero events is enabled
falsesuppression of load and zero events is disabled

§ DL_Timer_setDebugReleaseBehavior()

__STATIC_INLINE void DL_Timer_setDebugReleaseBehavior ( GPTIMER_Regs *  gptimer,
DL_TIMER_DEBUG_RES  debResB 
)

Configures timer behavior during debug release/exit.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]debResBSpecifies timer behavior upon relase/exit of debug mode. DL_TIMER_DEBUG_RES

References DL_Common_updateReg().

§ DL_Timer_getDebugReleaseBehavior()

__STATIC_INLINE DL_TIMER_DEBUG_RES DL_Timer_getDebugReleaseBehavior ( const GPTIMER_Regs *  gptimer)

Get timer resume behavior after relase/exit of debug mode.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_DEBUG_RES

§ DL_Timer_setCounterControl()

__STATIC_INLINE void DL_Timer_setCounterControl ( GPTIMER_Regs *  gptimer,
DL_TIMER_CZC  zeroCtl,
DL_TIMER_CAC  advCtl,
DL_TIMER_CLC  loadCtl 
)

Configure timer counter control operation.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]zeroCtlSpecifies event which zeroes the counter value. DL_TIMER_CZC
[in]advCtlSpecifies event which increments or decrements the counter value. DL_TIMER_CAC
[in]loadCtlSpecifies event which sets counter value with LD register value. DL_TIMER_CLC

References DL_Common_updateReg().

§ DL_Timer_getCounterZeroControl()

__STATIC_INLINE DL_TIMER_CZC DL_Timer_getCounterZeroControl ( const GPTIMER_Regs *  gptimer)

Get timer counter zero control operation.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_CZC

§ DL_Timer_getCounterAdvanceControl()

__STATIC_INLINE DL_TIMER_CAC DL_Timer_getCounterAdvanceControl ( const GPTIMER_Regs *  gptimer)

Get timer counter advance control operation.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_CAC

§ DL_Timer_getCounterLoadControl()

__STATIC_INLINE DL_TIMER_CLC DL_Timer_getCounterLoadControl ( const GPTIMER_Regs *  gptimer)

Get timer counter load control operation.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_CLC

§ DL_Timer_setCounterMode()

__STATIC_INLINE void DL_Timer_setCounterMode ( GPTIMER_Regs *  gptimer,
DL_TIMER_COUNT_MODE  countMode 
)

Configure timer counter couting mode.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]countModeSpecifies timer counter couting mode. DL_TIMER_COUNT_MODE

References DL_Common_updateReg().

§ DL_Timer_getCounterMode()

__STATIC_INLINE DL_TIMER_COUNT_MODE DL_Timer_getCounterMode ( const GPTIMER_Regs *  gptimer)

Get timer counter couting mode.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_COUNT_MODE

§ DL_Timer_setCounterValueAfterEnable()

__STATIC_INLINE void DL_Timer_setCounterValueAfterEnable ( GPTIMER_Regs *  gptimer,
DL_TIMER_COUNT_AFTER_EN  cvae 
)

Configures counter value after enable.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]cvaeSpeficies counter value after enable. DL_TIMER_COUNT_AFTER_EN

References DL_Common_updateReg().

§ DL_Timer_getCounterValueAfterEnable()

__STATIC_INLINE DL_TIMER_COUNT_AFTER_EN DL_Timer_getCounterValueAfterEnable ( const GPTIMER_Regs *  gptimer)

Returns counter value after enable cofiguration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_COUNT_AFTER_EN

§ DL_Timer_setCounterRepeatMode()

__STATIC_INLINE void DL_Timer_setCounterRepeatMode ( GPTIMER_Regs *  gptimer,
DL_TIMER_REPEAT_MODE  repeatMode 
)

Configure timer repeat counter mode.

Note
Refer to device datasheet to determine if timer instance supports this feature. Only Timer instances which supports repeat counter supports this feature.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]repeatModeSpecifies timer repeat counter mode DL_TIMER_REPEAT_MODE

References DL_Common_updateReg().

§ DL_Timer_getCounterRepeatMode()

__STATIC_INLINE DL_TIMER_REPEAT_MODE DL_Timer_getCounterRepeatMode ( const GPTIMER_Regs *  gptimer)

§ DL_Timer_initTimerMode()

void DL_Timer_initTimerMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_TimerConfig config 
)

Configure timer in one shot or periodic timer mode Initializes all the common configurable options for the TIMx peripheral when used in Timer mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_TimerConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initCaptureMode()

void DL_Timer_initCaptureMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_CaptureConfig config 
)

Configure timer in edge count, period capture, edge time or pulse-width capture mode Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_CaptureConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initCaptureTriggerMode()

void DL_Timer_initCaptureTriggerMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_CaptureTriggerConfig config 
)

Configure timer in edge count, period capture, edge time or pulse-width capture mode using the trigger as input source Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_CaptureTriggerConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initCaptureCombinedMode()

void DL_Timer_initCaptureCombinedMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_CaptureCombinedConfig config 
)

Configure timer in combined pulse-width and period capture Initializes all the common configurable options for the TIMx peripheral when used in Capture mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_CaptureCombinedConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initCompareMode()

void DL_Timer_initCompareMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_CompareConfig config 
)

Configure timer in edge count compare mode Initializes all the common configurable options for the TIMx peripheral when used in Compare mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_CompareConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initCompareTriggerMode()

void DL_Timer_initCompareTriggerMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_CompareTriggerConfig config 
)

Configure timer in edge count compare mode using the trigger as input source Initializes all the common configurable options for the TIMx peripheral when used in Compare mode. Any other custom configuration can be done after calling this API.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]configPointer to the mode configuration struct DL_Timer_CompareTriggerConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_initFourCCPWMMode()

void DL_Timer_initFourCCPWMMode ( GPTIMER_Regs *  gptimer,
const DL_Timer_PWMConfig config 
)

Configure timer in Pulse Width Modulation Mode Initializes all the common configurable options for the TIMx peripheral when used in PWM mode. Any other custom configuration can be done after calling this API. Configures the top two CC blocks and then configures the bottom two CC blocks.

Parameters
gptimerPointer to the register overlay for the peripheral
configPointer to the mode configuration struct DL_Timer_PWMConfig.

Referenced by DL_Timer_getCounterRepeatMode().

§ DL_Timer_resetCounterMode()

__STATIC_INLINE void DL_Timer_resetCounterMode ( GPTIMER_Regs *  gptimer)

§ DL_Timer_setCaptureCompareValue()

void DL_Timer_setCaptureCompareValue ( GPTIMER_Regs *  gptimer,
uint32_t  value,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets Timer Capture Compare Value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]valueValue to write to capture compare register
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareValue()

uint32_t DL_Timer_getCaptureCompareValue ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Get Timer Capture Compare value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
The current capture compare value

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptureCompareCtl()

void DL_Timer_setCaptureCompareCtl ( GPTIMER_Regs *  gptimer,
uint32_t  ccMode,
uint32_t  ccCondMask,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets Capture Compare Control configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccModeSpecifies whether the CC register is used as a capture register or a compare register DL_TIMER_CC_MODE
[in]ccCondMaskSpecifies zero, load, advance and capture conditions. Bitwise OR of DL_TIMER_CC_ZCOND, DL_TIMER_CC_LCOND, DL_TIMER_CC_ACOND, DL_TIMER_CC_CCOND
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareCtl()

uint32_t DL_Timer_getCaptureCompareCtl ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets Capture Compare Control configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Bitwise OR of DL_TIMER_CC_MODE, DL_TIMER_CC_ZCOND, DL_TIMER_CC_LCOND, DL_TIMER_CC_ACOND, DL_TIMER_CC_CCOND

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setSecondCompSrcDn()

void DL_Timer_setSecondCompSrcDn ( GPTIMER_Regs *  gptimer,
DL_TIMER_SEC_COMP_DOWN_EVT  secCompDn,
DL_TIMER_CC_INDEX  ccIndex 
)

Configures source for second capture compare down event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]secCompDnSpecifies second capture compare down event source. DL_TIMER_SEC_COMP_DOWN_EVT
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getSecondCompSrcDn()

DL_TIMER_SEC_COMP_DOWN_EVT DL_Timer_getSecondCompSrcDn ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets source for second capture compare down event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_SEC_COMP_DOWN_EVT

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setSecondCompSrcUp()

void DL_Timer_setSecondCompSrcUp ( GPTIMER_Regs *  gptimer,
DL_TIMER_SEC_COMP_UP_EVT  secCompUp,
DL_TIMER_CC_INDEX  ccIndex 
)

Configures source for second capture compare up event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]secCompUpSpecifies second capture compare up event source. DL_TIMER_SEC_COMP_UP_EVT
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getSecondCompSrcUp()

DL_TIMER_SEC_COMP_UP_EVT DL_Timer_getSecondCompSrcUp ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets source for second capture compare down event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_SEC_COMP_UP_EVT

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_enableSuppressionOfCompEvent()

void DL_Timer_enableSuppressionOfCompEvent ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Enables suppression of compare event if repeat counter is not equal to zero.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_disableSuppressionOfCompEvent()

void DL_Timer_disableSuppressionOfCompEvent ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Disables suppression of compare event if repeat counter is not equal to zero.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptCompUpdateMethod()

void DL_Timer_setCaptCompUpdateMethod ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_UPDATE_METHOD  ccUpdtMode,
DL_TIMER_CC_INDEX  ccIndex 
)

Configures capture compare shadow register update method.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccUpdtModeSpecifies capture compare shadow register update method. DL_TIMER_CC_UPDATE_METHOD
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptCompUpdateMethod()

DL_TIMER_CC_UPDATE_METHOD DL_Timer_getCaptCompUpdateMethod ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets capture compare shadow register update method.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_CC_UPDATE_METHOD

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptCompActUpdateMethod()

void DL_Timer_setCaptCompActUpdateMethod ( GPTIMER_Regs *  gptimer,
DL_TIMER_CCACT_UPDATE_METHOD  ccUpdtMode,
DL_TIMER_CC_INDEX  ccIndex 
)

Configures capture compare action shadow register update method.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccUpdtModeSpecifies capture compare action shadow register update method. DL_TIMER_CCACT_UPDATE_METHOD
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptCompActUpdateMethod()

DL_TIMER_CCACT_UPDATE_METHOD DL_Timer_getCaptCompActUpdateMethod ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets capture compare action shadow register update method.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare action register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_CCACT_UPDATE_METHOD

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptureCompareOutCtl()

void DL_Timer_setCaptureCompareOutCtl ( GPTIMER_Regs *  gptimer,
uint32_t  ccpIV,
uint32_t  ccpOInv,
uint32_t  ccpO,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets Capture Compare Output Control.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccpIVSpecifies the logical value put on the CCP output while the output is disabled DL_TIMER_CC_OCTL_INIT_VAL
[in]ccpOInvSpecifies if the he output as selected by ccpo is inverted. DL_TIMER_CC_OCTL_INV_OUT
[in]ccpOCCP Output Source DL_TIMER_CC_OCTL_SRC
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareOutCtl()

uint32_t DL_Timer_getCaptureCompareOutCtl ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets Capture Compare Output Control.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Bitwise OR of DL_TIMER_CC_OCTL_INIT_VAL, DL_TIMER_CC_OCTL_INV_OUT, DL_TIMER_CC_OCTL_SRC

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptureCompareAction()

void DL_Timer_setCaptureCompareAction ( GPTIMER_Regs *  gptimer,
uint32_t  actionsMask,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets actions of the signal generator.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]actionsMaskBit mask of signal generator actions. Bitwise OR of DL_TIMER_CC_SWFRCACT_CMPL, DL_TIMER_CC_SWFRCACT, DL_TIMER_CC_CC2UACT, DL_TIMER_CC_CC2DACT, DL_TIMER_CC_FEXACT, DL_TIMER_CC_FENACT, DL_TIMER_CC_CUACT, DL_TIMER_CC_CDACT, DL_TIMER_CC_LACT, DL_TIMER_CC_ZACT,
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareAction()

uint32_t DL_Timer_getCaptureCompareAction ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets actions of the signal generator.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Bitwise OR of DL_TIMER_CC_SWFRCACT_CMPL, DL_TIMER_CC_SWFRCACT, DL_TIMER_CC_CC2UACT, DL_TIMER_CC_CC2DACT, DL_TIMER_CC_FEXACT, DL_TIMER_CC_FENACT, DL_TIMER_CC_CUACT, DL_TIMER_CC_CDACT, DL_TIMER_CC_LACT, DL_TIMER_CC_ZACT.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setSecondCompActionDn()

void DL_Timer_setSecondCompActionDn ( GPTIMER_Regs *  gptimer,
DL_TIMER_SEC_COMP_DOWN_ACT_SEL  secCompDnAct,
DL_TIMER_CC_INDEX  ccIndex 
)

Set second comparator down counting timer channel output action.

The timer channel output will be set to selected DL_TIMER_SEC_COMP_DOWN_ACT_SEL when the timer counter reaches the configured capture compare value configure by

See also
DL_Timer_setSecondCompSrcDn
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]secCompDnActOne of DL_TIMER_SEC_COMP_DOWN_ACT_SEL.
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getSecondCompActionDn()

DL_TIMER_SEC_COMP_DOWN_ACT_SEL DL_Timer_getSecondCompActionDn ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets second comparator down counting timer channel output action.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_SEC_COMP_DOWN_ACT_SEL

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setSecondCompActionUp()

void DL_Timer_setSecondCompActionUp ( GPTIMER_Regs *  gptimer,
DL_TIMER_SEC_COMP_UP_ACT_SEL  secCompUpAct,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets second comparator up counting timer channel output action.

The timer channel output will be set to selected DL_TIMER_SEC_COMP_UP_ACT_SEL when the timer counter reaches the configured capture compare value configure by

See also
DL_Timer_setSecondCompSrcUp
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]secCompUpActOne of DL_TIMER_SEC_COMP_UP_ACT_SEL.
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getSecondCompActionUp()

DL_TIMER_SEC_COMP_UP_ACT_SEL DL_Timer_getSecondCompActionUp ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets second comparator up counting timer channel output action.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
DL_TIMER_SEC_COMP_UP_ACT_SEL

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_overrideCCPOut()

void DL_Timer_overrideCCPOut ( GPTIMER_Regs *  gptimer,
DL_TIMER_FORCE_OUT  out,
DL_TIMER_FORCE_CMPL_OUT  outComp,
DL_TIMER_CC_INDEX  ccIndex 
)

Overrides the timer CCP output.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]outSpecifies the CCP output state. DL_TIMER_FORCE_OUT
[in]outCompIf timer insatance supports complementary output, it allows to override complementary out also. If timer instance doesn't support complementary output, this parameter is ignored. DL_TIMER_FORCE_CMPL_OUT
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptureCompareInput()

void DL_Timer_setCaptureCompareInput ( GPTIMER_Regs *  gptimer,
uint32_t  inv,
uint32_t  isel,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets Capture Compare Input.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]invSpecifies whether the selected input is inverted. DL_TIMER_CC_INPUT_INV
[in]iselSelects the input source to the filter input. DL_TIMER_CC_IN_SEL
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareInput()

uint32_t DL_Timer_getCaptureCompareInput ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets Capture Compare Input.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Bitwise OR of DL_TIMER_CC_INPUT_FILT_CPV, DL_TIMER_CC_INPUT_FILT_FP

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setCaptureCompareInputFilter()

void DL_Timer_setCaptureCompareInputFilter ( GPTIMER_Regs *  gptimer,
uint32_t  cpv,
uint32_t  fp,
DL_TIMER_CC_INDEX  ccIndex 
)

Sets Capture Compare Input Filter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]cpvSpecifies fitering mode. DL_TIMER_CC_INPUT_FILT_CPV
[in]fpSpecifies the filter period. DL_TIMER_CC_INPUT_FILT_FP
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_getCaptureCompareInputFilter()

uint32_t DL_Timer_getCaptureCompareInputFilter ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Gets Capture Compare Input Filter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Bitwise OR of DL_TIMER_CC_INPUT_FILT_CPV, DL_TIMER_CC_INPUT_FILT_FP

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_enableCaptureCompareInputFilter()

void DL_Timer_enableCaptureCompareInputFilter ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Enables the capture compare input filter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_disableCaptureCompareInputFilter()

void DL_Timer_disableCaptureCompareInputFilter ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Disables the capture compare input filter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_isCaptureCompareInputFilterEnabled()

bool DL_Timer_isCaptureCompareInputFilterEnabled ( GPTIMER_Regs *  gptimer,
DL_TIMER_CC_INDEX  ccIndex 
)

Checks if the capture compare input filter is enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.
Returns
Returns the status of capture compare input filter
Return values
truecapture compare input filter is enabled
falsecapture compare input filter is disabled

Referenced by DL_Timer_resetCounterMode().

§ DL_Timer_setDeadBand()

__STATIC_INLINE void DL_Timer_setDeadBand ( GPTIMER_Regs *  gptimer,
uint16_t  falldelay,
uint16_t  risedelay,
uint32_t  mode 
)

Sets dead band fall and raise delay.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]falldelayThe number of TIMCLK periods inserted between the fall of CCPi and the rise of CCPBo. Valid range [0- 4095]
[in]risedelayThe number of TIMCLK periods inserted between the fall of CCPi and the rise of CCPAo. Valid range [0- 4095].
[in]modeSpecifies the dead band insertion mode. One of DL_TIMER_DEAD_BAND_MODE

§ DL_Timer_getDeadBandFallDelay()

__STATIC_INLINE uint16_t DL_Timer_getDeadBandFallDelay ( const GPTIMER_Regs *  gptimer)

Gets dead band fall delay.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Dead Band Fall delay in TIMCLK

§ DL_Timer_getDeadBandRiseDelay()

__STATIC_INLINE uint16_t DL_Timer_getDeadBandRiseDelay ( const GPTIMER_Regs *  gptimer)

Gets dead band rise delay.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Dead Band Rise delay in TIMCLK

§ DL_Timer_setExternalTriggerEvent()

__STATIC_INLINE void DL_Timer_setExternalTriggerEvent ( GPTIMER_Regs *  gptimer,
DL_TIMER_EXT_TRIG_SEL  trigSel 
)

Set External Trigger Event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]trigSelExternal Trigger Select DL_TIMER_EXT_TRIG_SEL

References DL_Common_updateReg().

§ DL_Timer_getExternalTriggerEvent()

__STATIC_INLINE DL_TIMER_EXT_TRIG_SEL DL_Timer_getExternalTriggerEvent ( const GPTIMER_Regs *  gptimer)

Gets External Trigger Event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
DL_TIMER_EXT_TRIG_SEL

§ DL_Timer_enableExternalTrigger()

__STATIC_INLINE void DL_Timer_enableExternalTrigger ( GPTIMER_Regs *  gptimer)

Enables external trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableExternalTrigger()

__STATIC_INLINE void DL_Timer_disableExternalTrigger ( GPTIMER_Regs *  gptimer)

Disables external trigger.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isExternalTriggerEnabled()

__STATIC_INLINE bool DL_Timer_isExternalTriggerEnabled ( const GPTIMER_Regs *  gptimer)

Checks if external trigger is enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the status of external trigger
Return values
trueexternal trigger is enabled
falseexternal trigger is disabled

§ DL_Timer_setRepeatCounter()

__STATIC_INLINE void DL_Timer_setRepeatCounter ( GPTIMER_Regs *  gptimer,
uint8_t  repeatCount 
)

Sets repeat counter value. Repeat counter feature is used to reduce interupt overhead.

Note
This feature is not supported by all TimerA instances. Please refer to the "TIMx Configurations" table in the device specific datasheet to determine TimerA instances which support "Repeat Counter" configuration.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]repeatCountSpecifies repeat counter value

§ DL_Timer_getRepeatCounter()

__STATIC_INLINE uint8_t DL_Timer_getRepeatCounter ( const GPTIMER_Regs *  gptimer)

Gets repeat counter value.

Note
This feature is not supported by all TimerA instances. Please refer to the "TIMx Configurations" table in the device specific datasheet to determine TimerA instances which support "Repeat Counter" configuration.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Repeat counter value.

§ DL_Timer_enablePhaseLoad()

__STATIC_INLINE void DL_Timer_enablePhaseLoad ( GPTIMER_Regs *  gptimer)

Enables phase load.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disablePhaseLoad()

__STATIC_INLINE void DL_Timer_disablePhaseLoad ( GPTIMER_Regs *  gptimer)

Disables phase load.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isPhaseLoadEnabled()

__STATIC_INLINE bool DL_Timer_isPhaseLoadEnabled ( const GPTIMER_Regs *  gptimer)

Checks if phase load enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the status of phase load
Return values
truephase load is enabled
falsephase load is disabled

§ DL_Timer_setPhaseLoadValue()

__STATIC_INLINE void DL_Timer_setPhaseLoadValue ( GPTIMER_Regs *  gptimer,
uint32_t  value 
)

Sets phase load value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]valuePhase load value

§ DL_Timer_getPhaseLoadValue()

__STATIC_INLINE uint32_t DL_Timer_getPhaseLoadValue ( const GPTIMER_Regs *  gptimer)

Gets phase load value.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Phase load value

§ DL_Timer_startCounter()

__STATIC_INLINE void DL_Timer_startCounter ( GPTIMER_Regs *  gptimer)

Starts Timer Counter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_stopCounter()

__STATIC_INLINE void DL_Timer_stopCounter ( GPTIMER_Regs *  gptimer)

Stops Timer Counter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isRunning()

__STATIC_INLINE bool DL_Timer_isRunning ( const GPTIMER_Regs *  gptimer)

Check if timer is actively running.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Returns the running status of the Timer
Return values
trueTimer is running
falseTimer is not running

§ DL_Timer_configQEI()

__STATIC_INLINE void DL_Timer_configQEI ( GPTIMER_Regs *  gptimer,
DL_TIMER_QEI_MODE  mode,
uint32_t  invert,
DL_TIMER_CC_INDEX  ccIndex 
)

Configure Quadrature Encoder Interface (QEI)

Postcondition
User should call DL_Timer_setLoadValue and DL_Timer_startCounter to complete the QEI Configuration. Refer to Timer TRM for more details.
Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]modeChoose QEI input mode. One of DL_TIMER_QEI_MODE
[in]invertControl whether selected input is inverted. One of DL_TIMER_CC_INPUT_INV
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

References DL_Timer_configQEIHallInputMode().

§ DL_Timer_configQEIHallInputMode()

void DL_Timer_configQEIHallInputMode ( GPTIMER_Regs *  gptimer)

Configure Hall Input Mode.

Note
Refer to device datasheet to determine if timer instance supports this feature. Only TIMGx instances with QEI support should use this API.
Postcondition
User should call DL_Timer_setLoadValue and DL_Timer_startCounter to complete the Hall Input Mode Configuration. Refer to Timer TRM for more details.
Parameters
[in]gptimerPointer to the register overlay for the peripheral

Referenced by DL_Timer_configQEI().

§ DL_Timer_getQEIDirection()

__STATIC_INLINE DL_TIMER_QEI_DIRECTION DL_Timer_getQEIDirection ( const GPTIMER_Regs *  gptimer)

Get direction of Quadrature Encoder Interface (QEI) count.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Return values
Oneof DL_TIMER_QEI_DIRECTION values

§ DL_Timer_setFaultConfig()

__STATIC_INLINE void DL_Timer_setFaultConfig ( GPTIMER_Regs *  gptimer,
uint32_t  faultConfMask 
)

Sets Fault Configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]faultConfMaskSpecifies faults configuration. Bitwise OR of DL_TIMER_FAULT_CONFIG_TFIM, DL_TIMER_FAULT_CONFIG_FL, DL_TIMER_FAULT_CONFIG_FI, DL_TIMER_FAULT_CONFIG_FIEN

References DL_Common_updateReg().

§ DL_Timer_getFaultConfig()

__STATIC_INLINE uint32_t DL_Timer_getFaultConfig ( const GPTIMER_Regs *  gptimer)

Gets Fault Configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Bitwise OR value of DL_TIMER_FAULT_CONFIG_TFIM, DL_TIMER_FAULT_CONFIG_FL, DL_TIMER_FAULT_CONFIG_FI, DL_TIMER_FAULT_CONFIG_FIEN

§ DL_Timer_enableFaultInput()

__STATIC_INLINE void DL_Timer_enableFaultInput ( GPTIMER_Regs *  gptimer)

Enables fault input detection.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableFaultInput()

__STATIC_INLINE void DL_Timer_disableFaultInput ( GPTIMER_Regs *  gptimer)

Disables fault input detection.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isFaultInputEnabled()

__STATIC_INLINE bool DL_Timer_isFaultInputEnabled ( const GPTIMER_Regs *  gptimer)

Specifies if fault input is enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
true Fault input is enabled
false Fault input is disabled

§ DL_Timer_enableClockFaultDetection()

__STATIC_INLINE void DL_Timer_enableClockFaultDetection ( GPTIMER_Regs *  gptimer)

Enables source clock fault detection.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_disableClockFaultDetection()

__STATIC_INLINE void DL_Timer_disableClockFaultDetection ( GPTIMER_Regs *  gptimer)

Disables source clock fault detection.

Parameters
[in]gptimerPointer to the register overlay for the peripheral

§ DL_Timer_isClockFaultDetectionEnabled()

__STATIC_INLINE bool DL_Timer_isClockFaultDetectionEnabled ( const GPTIMER_Regs *  gptimer)

Specifies if source clock fault detection is enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
true if source clock fault detection is enabled
false if source clock fault detection is disabled

References DL_Timer_getFaultSourceConfig(), and DL_Timer_setFaultSourceConfig().

§ DL_Timer_setFaultSourceConfig()

void DL_Timer_setFaultSourceConfig ( GPTIMER_Regs *  gptimer,
uint32_t  source 
)

Configures the fault source and and fault input mode.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]sourceSelects fault source and and fault input mode. One of DL_TIMER_FAULT_SOURCE.

Referenced by DL_Timer_isClockFaultDetectionEnabled().

§ DL_Timer_getFaultSourceConfig()

uint32_t DL_Timer_getFaultSourceConfig ( const GPTIMER_Regs *  gptimer)
Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
The fault source and and fault input mode. One of DL_TIMER_FAULT_SOURCE.

Referenced by DL_Timer_isClockFaultDetectionEnabled().

§ DL_Timer_setFaultInputFilterConfig()

__STATIC_INLINE void DL_Timer_setFaultInputFilterConfig ( GPTIMER_Regs *  gptimer,
uint32_t  filten,
uint32_t  cpv,
uint32_t  fp 
)

Set Fault Input Filtering Configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]filtenSpecifies input is filter mode DL_TIMER_FAULT_FILT
[in]cpvSpecifies input filter type DL_TIMER_FAULT_FILTER_CPV
[in]fpSpecifies sample period for the input filter DL_TIMER_FAULT_FILTER_FP

§ DL_Timer_getFaultInputFilterConfig()

__STATIC_INLINE uint32_t DL_Timer_getFaultInputFilterConfig ( const GPTIMER_Regs *  gptimer)

Get Fault Input Filtering Configuration.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Bitwise OR of DL_TIMER_FAULT_FILT, DL_TIMER_FAULT_FILTER_CPV and DL_TIMER_FAULT_FILTER_FP

§ DL_Timer_configFaultOutputAction()

__STATIC_INLINE void DL_Timer_configFaultOutputAction ( GPTIMER_Regs *  gptimer,
DL_TIMER_FAULT_ENTRY_CCP  faultEntry,
DL_TIMER_FAULT_EXIT_CCP  faultExit,
DL_TIMER_CC_INDEX  ccIndex 
)

Configures output behavior upon fault entry and exit.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]faultEntrySpecifies the fault entry behavior. One of DL_TIMER_FAULT_ENTRY_CCP
[in]faultExitSpecifies the fault exit behavior. One of DL_TIMER_FAULT_EXIT_CCP
[in]ccIndexIndex associated to capture compare register DL_TIMER_CC_INDEX.

References DL_Common_updateReg().

§ DL_Timer_configFaultCounter()

__STATIC_INLINE void DL_Timer_configFaultCounter ( GPTIMER_Regs *  gptimer,
DL_TIMER_FAULT_ENTRY_CTR  faultEntry,
DL_TIMER_FAULT_EXIT_CTR  faultExit 
)

Configures timer counter behavior upon fault entry and exit.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]faultEntrySpecifies the fault entry behavior. One of DL_TIMER_FAULT_ENTRY_CTR
[in]faultExitSpecifies the fault exit behavior. One of DL_TIMER_FAULT_EXIT_CTR

References DL_Common_updateReg().

§ DL_Timer_enableInterrupt()

__STATIC_INLINE void DL_Timer_enableInterrupt ( GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Enable timer interrupts.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to enable. Bitwise OR of DL_TIMER_INTERRUPT.

§ DL_Timer_disableInterrupt()

__STATIC_INLINE void DL_Timer_disableInterrupt ( GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Disable timer interrupts.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to enable. Bitwise OR of DL_TIMER_INTERRUPT.

§ DL_Timer_getEnabledInterrupts()

__STATIC_INLINE uint32_t DL_Timer_getEnabledInterrupts ( const GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Check which timer interrupts are enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_INTERRUPT.
Returns
Which of the requested timer interrupts are enabled
Return values
BitwiseOR of DL_TIMER_INTERRUPT values

§ DL_Timer_getEnabledInterruptStatus()

__STATIC_INLINE uint32_t DL_Timer_getEnabledInterruptStatus ( const GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Check interrupt flag of enabled timer interrupts.

Checks if any of the timer interrupts that were previously enabled are pending.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_INTERRUPT.
Returns
Which of the requested timer interrupts are pending
Return values
BitwiseOR of DL_TIMER_INTERRUPT values
See also
DL_Timer_enableInterrupt

§ DL_Timer_getRawInterruptStatus()

__STATIC_INLINE uint32_t DL_Timer_getRawInterruptStatus ( const GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Check interrupt flag of any timer interrupt.

Checks if any of the timer interrupts are pending. Interrupts do not have to be previously enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_INTERRUPT.
Returns
Which of the requested timer interrupts are pending
Return values
BitwiseOR of DL_TIMER_INTERRUPT values

§ DL_Timer_getPendingInterrupt()

__STATIC_INLINE DL_TIMER_IIDX DL_Timer_getPendingInterrupt ( const GPTIMER_Regs *  gptimer)

Get highest priority pending timer interrupt.

Checks if any of the timer interrupts are pending. Interrupts do not have to be previously enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
The highest priority pending timer interrupt. One of DL_TIMER_IIDX

§ DL_Timer_clearInterruptStatus()

__STATIC_INLINE void DL_Timer_clearInterruptStatus ( GPTIMER_Regs *  gptimer,
uint32_t  interruptMask 
)

Clear pending timer interrupts.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]interruptMaskBit mask of interrupts to clear. Bitwise OR of DL_TIMER_INTERRUPT.

§ DL_Timer_setPublisherChanID()

__STATIC_INLINE void DL_Timer_setPublisherChanID ( GPTIMER_Regs *  gptimer,
DL_TIMER_PUBLISHER_INDEX  index,
uint8_t  chanID 
)

Sets the event publisher channel id.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]chanIDChannel ID number. Valid range 0-15. If ChanID == 0 publisher is disconnected.

§ DL_Timer_getPublisherChanID()

__STATIC_INLINE uint8_t DL_Timer_getPublisherChanID ( GPTIMER_Regs *  gptimer,
DL_TIMER_PUBLISHER_INDEX  index 
)

Gets the event publisher channel id.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
Returns
Event publisher channel ID

§ DL_Timer_setSubscriberChanID()

__STATIC_INLINE void DL_Timer_setSubscriberChanID ( GPTIMER_Regs *  gptimer,
DL_TIMER_SUBSCRIBER_INDEX  index,
uint8_t  chanID 
)

Sets the event subscriber channel id.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]chanIDChannel ID number. Valid range 0-15. If ChanID == 0 subscriber is disconnected.

§ DL_Timer_getSubscriberChanID()

__STATIC_INLINE uint8_t DL_Timer_getSubscriberChanID ( GPTIMER_Regs *  gptimer,
DL_TIMER_SUBSCRIBER_INDEX  index 
)

Gets the event subscriber channel id.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
Returns
Event subscriber channel ID

§ DL_Timer_enableEvent()

__STATIC_INLINE void DL_Timer_enableEvent ( GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Enable timer event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to enable. Bitwise OR of DL_TIMER_EVENT.

§ DL_Timer_disableEvent()

__STATIC_INLINE void DL_Timer_disableEvent ( GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Disable timer event.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to enable. Bitwise OR of DL_TIMER_EVENT.

§ DL_Timer_getEnabledEvents()

__STATIC_INLINE uint32_t DL_Timer_getEnabledEvents ( GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Check which timer events are enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_EVENT.
Returns
Which of the requested timer interrupts are enabled
Return values
BitwiseOR of DL_TIMER_EVENT values

§ DL_Timer_getEnabledEventStatus()

__STATIC_INLINE uint32_t DL_Timer_getEnabledEventStatus ( const GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Check event flag of enabled timer event.

Checks if any of the timer events that were previously enabled are pending.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_EVENT.
Returns
Which of the requested timer interrupts are pending
Return values
BitwiseOR of DL_TIMER_EVENT values
See also
DL_Timer_enableInterrupt

§ DL_Timer_getRawEventsStatus()

__STATIC_INLINE uint32_t DL_Timer_getRawEventsStatus ( const GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Check interrupt flag of any timer event.

Checks if any events are pending. Events do not have to be previously enabled.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to check. Bitwise OR of DL_TIMER_EVENT.
Returns
Which of the requested timer interrupts are pending
Return values
BitwiseOR of DL_TIMER_EVENT values

§ DL_Timer_clearEventsStatus()

__STATIC_INLINE void DL_Timer_clearEventsStatus ( GPTIMER_Regs *  gptimer,
DL_TIMER_EVENT_ROUTE  index,
uint32_t  eventMask 
)

Clear pending timer events.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]indexSpecifies the register event index to be configured
[in]eventMaskBit mask of interrupts to clear. Bitwise OR of DL_TIMER_EVENT.

References DL_Timer_restoreConfiguration(), and DL_Timer_saveConfiguration().

§ DL_Timer_saveConfiguration()

bool DL_Timer_saveConfiguration ( const GPTIMER_Regs *  gptimer,
DL_Timer_backupConfig ptr 
)

Saves Timer configuration before entering STOP or STANDBY mode. Timer must be in IDLE state before calling this API. Timer can be put IDLE state by calling DL_TimerG_stopCounter or DL_Timer_stopCounter.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ptrConfiguration backup setup structure. See DL_Timer_backupConfig.
Return values
FALSEif a configuration already exists in ptr (will not be overwritten). TRUE if a configuration was successfully saved

Referenced by DL_Timer_clearEventsStatus().

§ DL_Timer_restoreConfiguration()

bool DL_Timer_restoreConfiguration ( GPTIMER_Regs *  gptimer,
DL_Timer_backupConfig ptr,
bool  restoreCounter 
)

Restore Timer configuration after leaving STOP or STANDBY mode.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]ptrConfiguration backup setup structure. See DL_Timer_backupConfig.
[in]restoreCounterIf true timer counter value is also restored (e.g. resume counts of edge counts). If false timer counter is not restored.
Return values
FALSEif a configuration does not exist in ptr (will not be loaded). TRUE if a configuration successfully loaded

Referenced by DL_Timer_clearEventsStatus().

§ DL_Timer_setCoreHaltBehavior()

__STATIC_INLINE void DL_Timer_setCoreHaltBehavior ( GPTIMER_Regs *  gptimer,
DL_TIMER_CORE_HALT  haltMode 
)

Configures timer behavior when the core is halted.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
[in]haltModeTimer halt behavior. One of DL_TIMER_CORE_HALT.

§ DL_Timer_getCoreHaltBehavior()

__STATIC_INLINE DL_TIMER_CORE_HALT DL_Timer_getCoreHaltBehavior ( const GPTIMER_Regs *  gptimer)

Get timer behavior when the core is halted.

Parameters
[in]gptimerPointer to the register overlay for the peripheral
Returns
Timer bahvior when core is halted. One of DL_TIMER_CORE_HALT
© Copyright 1995-2025, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale