Data Fields
LGPTimerLPF3_Params Struct Reference

LGPTimerLPF3 Parameters. More...

#include <LGPTimerLPF3.h>

Collaboration diagram for LGPTimerLPF3_Params:
Collaboration graph
[legend]

Data Fields

LGPTimerLPF3_HwiFxn hwiCallbackFxn
 
bool intPhaseLate
 
uint8_t prescalerDiv
 
LGPTimerLPF3_DebugMode debugStallMode
 
LGPTimerLPF3_ChannelCmpDir counterDirChCompare
 
LGPTimerLPF3_ChannelProp channelProperty [3]
 

Detailed Description

LGPTimerLPF3 Parameters.

LGPTimer parameters are used by the LGPTimerLPF3_open() call. Default values for these parameters are set using LGPTimerLPF3_Params_init().

Note
The prescalerDiv parameter determines the division factor of the system clock being input to the timer counter:
  • 0x00: Divide by 1
  • 0x01: Divide by 2
  • ...
  • 0xFF: Divide by 256
The intPhaseLate parameter which determines if the LGPTimerLPF3_INT_TGT and LGPTimerLPF3_INT_ZERO interrupt status flags will be set early or late, is specified as follows:
  • false: Interrupt status flags are set one system clock cycle after counter = TARGET/ZERO.
  • true : Interrupt status flags are set one timer clock cycle after counter = TARGET/ZERO.

Please note that if the value of the intPhaseLate parameter is set to false while the prescalerDiv parameter value is high and either the LGPTimerLPF3_INT_TGT or LGPTimerLPF3_INT_ZERO interrupts are enabled, these interrupts might occur multiple times back-to-back when the interrupts are first triggered. While the counter is active, the timer will hold the state of the counter for one clock period of the timer clock before the counter gets updated. When the timer clock frequency is configured low by a high prescalerDiv parameter value, this hold time might be longer than it takes for the interrupt service routine to clear the interrupt status. This will cause a new interrupt to be immediatly generated. In order to avoid this situation, the intPhaseLate parameter value needs to be set to true. Then the interrupt will occur one timer clock cycle after the counter has reached the TARGET/ZERO value, meaning that the described hold time is reduced to 0.

See also
LGPTimerLPF3_Params_init()

Field Documentation

§ hwiCallbackFxn

LGPTimerLPF3_HwiFxn LGPTimerLPF3_Params::hwiCallbackFxn

Hardware interrupt callback function. This pointer is optional and is only required if LGPTimerLPF3_enableInterrupt() is called.

§ intPhaseLate

bool LGPTimerLPF3_Params::intPhaseLate

Interrupt phase early or late for TGT and ZERO interrupts

§ prescalerDiv

uint8_t LGPTimerLPF3_Params::prescalerDiv

Prescaler division factor

§ debugStallMode

LGPTimerLPF3_DebugMode LGPTimerLPF3_Params::debugStallMode

Timer debug stall mode

§ counterDirChCompare

LGPTimerLPF3_ChannelCmpDir LGPTimerLPF3_Params::counterDirChCompare

Timer counter direction for channel compare. Covers all channels

§ channelProperty

LGPTimerLPF3_ChannelProp LGPTimerLPF3_Params::channelProperty[3]

Channel action and input edge type required for triggering a channel action of capture type


The documentation for this struct was generated from the following file:
© Copyright 1995-2024, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale