159 cap->
ECCTL1 &= ~(1 << (2 * event));
162 cap->
ECCTL1 |= (polarity << (2 * event));
172 cap->
ECCTL1 &= ~(1 << (1 + (2 * event)));
175 cap->
ECCTL1 |= (reset << (1 + (2 * event)));
void CAP_setModeApwm(CAP_Handle capHandle)
Sets capture peripheral up for APWM mode.
void CAP_disableInt(CAP_Handle capHandle, const CAP_Int_Type_e intType)
Disables capture (CAP) interrupt source.
void CAP_setModeCap(CAP_Handle capHandle)
Sets capture peripheral up for capture mode.
void CAP_enableSyncIn(CAP_Handle capHandle)
Enables counter synchronization.
volatile uint16_t ECEINT
Capture Interrupt Enable Register.
Defines the capture (CAP) object.
void CAP_disableSyncIn(CAP_Handle capHandle)
Disables counter synchronization.
struct _CAP_Obj_ * CAP_Handle
Defines the capture (CAP) handle.
void CAP_setCapEvtReset(CAP_Handle capHandle, const CAP_Event_e event, const CAP_Reset_e reset)
Sets the capture event counter reset configuration.
#define CAP_ECCTL2_CAPAPWM_BITS
Defines the location of the CAP/APWM bits in the ECCTL2 register.
CAP_Int_Type_e
Enumeration to define the capture (CAP) interrupts.
void CAP_setSyncOut(CAP_Handle capHandle, const CAP_SyncOut_e syncOut)
Set the sync out mode.
void CAP_enableCaptureLoad(CAP_Handle capHandle)
Enables loading of CAP1-4 on capture event.
volatile uint16_t ECCTL1
Capture Control Register 1.
void CAP_disableCaptureLoad(CAP_Handle capHandle)
Disables loading of CAP1-4 on capture event.
void CAP_setCapEvtPolarity(CAP_Handle capHandle, const CAP_Event_e event, const CAP_Polarity_e polarity)
Sets the capture event polarity.
void CAP_setStopWrap(CAP_Handle capHandle, const CAP_Stop_Wrap_e stopWrap)
Set the stop/wrap mode.
CAP_Stop_Wrap_e
Enumeration to define the capture (CAP) Stop/Wrap modes.
void CAP_enableTimestampCounter(CAP_Handle capHandle)
Enables Time Stamp counter to running.
#define CAP_ECCTL2_STOP_WRAP_BITS
Defines the location of the STOP_WRAP bits in the ECCTL2 register.
CAP_SyncOut_e
Enumeration to define the Sync Out options.
#define CAP_ECCTL2_SYNCIEN_BITS
Defines the location of the SYNCI_EN bits in the ECCTL2 register.
CAP_Polarity_e
Enumeration to define the capture (CAP) event polarities.
void CAP_disableTimestampCounter(CAP_Handle capHandle)
Disables Time Stamp counter from running.
CAP_Reset_e
Enumeration to define the capture (CAP) event resets.
#define CAP_ECCTL2_CONTONESHOT_BITS
Defines the location of the CONT/ONESHOT bits in the ECCTL2 register.
#define CAP_ECCTL1_CAPLDEN_BITS
Defines the location of the CAPLDEN bits in the ECCTL1 register.
volatile uint16_t ECCTL2
Capture Control Register 2.
#define CAP_ECCTL2_SYNCOSEL_BITS
Defines the location of the SYNCO_SEL bits in the ECCTL2 register.
Contains public interface to various functions related to the Enhanced Capture (CAP) object...
#define CAP_ECCTL2_TSCTRSTOP_BITS
Defines the location of the TSCTRSTOP bits in the ECCTL2 register.
CAP_Handle CAP_init(void *pMemory, const size_t numBytes)
Initializes the capture (CAP) object handle.
void CAP_enableInt(CAP_Handle capHandle, const CAP_Int_Type_e intType)
Enables capture (CAP) interrupt source.
CAP_Event_e
Enumeration to define the capture (CAP) events.
void CAP_setCapContinuous(CAP_Handle capHandle)
Sets up for continuous Capture.
void CAP_setCapOneShot(CAP_Handle capHandle)
Sets up for one-shot Capture.