RTEMS 6.1-rc5
Loading...
Searching...
No Matches
Files | Data Structures | Enumerator | Variables
Lpadc

Files

file  fsl_lpadc.h
 

Data Structures

struct  lpadc_config_t
 LPADC global configuration. More...
 
struct  lpadc_conv_command_config_t
 Define structure to keep the configuration for conversion command. More...
 
struct  lpadc_conv_trigger_config_t
 Define structure to keep the configuration for conversion trigger. More...
 
struct  lpadc_conv_result_t
 Define the structure to keep the conversion result. More...
 

Variables

bool lpadc_config_t::enableInDozeMode
 
bool lpadc_config_t::enableAnalogPreliminary
 
uint32_t lpadc_config_t::powerUpDelay
 
lpadc_reference_voltage_source_t lpadc_config_t::referenceVoltageSource
 
lpadc_power_level_mode_t lpadc_config_t::powerLevelMode
 
lpadc_trigger_priority_policy_t lpadc_config_t::triggerPriorityPolicy
 
bool lpadc_config_t::enableConvPause
 
uint32_t lpadc_config_t::convPauseDelay
 
uint32_t lpadc_config_t::FIFOWatermark
 
lpadc_sample_channel_mode_t lpadc_conv_command_config_t::sampleChannelMode
 
uint32_t lpadc_conv_command_config_t::channelNumber
 
uint32_t lpadc_conv_command_config_t::chainedNextCommandNumber
 
bool lpadc_conv_command_config_t::enableAutoChannelIncrement
 
uint32_t lpadc_conv_command_config_t::loopCount
 
lpadc_hardware_average_mode_t lpadc_conv_command_config_t::hardwareAverageMode
 
lpadc_sample_time_mode_t lpadc_conv_command_config_t::sampleTimeMode
 
lpadc_hardware_compare_mode_t lpadc_conv_command_config_t::hardwareCompareMode
 
uint32_t lpadc_conv_command_config_t::hardwareCompareValueHigh
 
uint32_t lpadc_conv_command_config_t::hardwareCompareValueLow
 
uint32_t lpadc_conv_trigger_config_t::targetCommandId
 
uint32_t lpadc_conv_trigger_config_t::delayPower
 
uint32_t lpadc_conv_trigger_config_t::priority
 
bool lpadc_conv_trigger_config_t::enableHardwareTrigger
 
uint32_t lpadc_conv_result_t::commandIdSource
 
uint32_t lpadc_conv_result_t::loopCountIndex
 
uint32_t lpadc_conv_result_t::triggerIdSource
 
uint16_t lpadc_conv_result_t::convValue
 

Driver version

enum  _lpadc_status_flags { kLPADC_ResultFIFOOverflowFlag = ADC_STAT_FOF_MASK , kLPADC_ResultFIFOReadyFlag = ADC_STAT_RDY_MASK }
 Define hardware flags of the module. More...
 
enum  _lpadc_interrupt_enable { kLPADC_ResultFIFOOverflowInterruptEnable = ADC_IE_FOFIE_MASK , kLPADC_FIFOWatermarkInterruptEnable = ADC_IE_FWMIE_MASK }
 Define interrupt switchers of the module. More...
 
enum  _lpadc_sample_scale_mode { kLPADC_SamplePartScale , kLPADC_SampleFullScale = 1U }
 Define enumeration of sample scale mode. More...
 
enum  _lpadc_sample_channel_mode { kLPADC_SampleChannelSingleEndSideA = 0U , kLPADC_SampleChannelSingleEndSideB = 1U }
 Define enumeration of channel sample mode. More...
 
enum  _lpadc_hardware_average_mode {
  kLPADC_HardwareAverageCount1 = 0U , kLPADC_HardwareAverageCount2 = 1U , kLPADC_HardwareAverageCount4 = 2U , kLPADC_HardwareAverageCount8 = 3U ,
  kLPADC_HardwareAverageCount16 = 4U , kLPADC_HardwareAverageCount32 = 5U , kLPADC_HardwareAverageCount64 = 6U , kLPADC_HardwareAverageCount128 = 7U
}
 Define enumeration of hardware average selection. More...
 
enum  _lpadc_sample_time_mode {
  kLPADC_SampleTimeADCK3 = 0U , kLPADC_SampleTimeADCK5 = 1U , kLPADC_SampleTimeADCK7 = 2U , kLPADC_SampleTimeADCK11 = 3U ,
  kLPADC_SampleTimeADCK19 = 4U , kLPADC_SampleTimeADCK35 = 5U , kLPADC_SampleTimeADCK67 = 6U , kLPADC_SampleTimeADCK131 = 7U
}
 Define enumeration of sample time selection. More...
 
enum  _lpadc_hardware_compare_mode { kLPADC_HardwareCompareDisabled = 0U , kLPADC_HardwareCompareStoreOnTrue = 2U , kLPADC_HardwareCompareRepeatUntilTrue = 3U }
 Define enumeration of hardware compare mode. More...
 
enum  _lpadc_reference_voltage_mode { kLPADC_ReferenceVoltageAlt1 = 0U , kLPADC_ReferenceVoltageAlt2 = 1U , kLPADC_ReferenceVoltageAlt3 = 2U }
 Define enumeration of reference voltage source. More...
 
enum  _lpadc_power_level_mode { kLPADC_PowerLevelAlt1 = 0U , kLPADC_PowerLevelAlt2 = 1U , kLPADC_PowerLevelAlt3 = 2U , kLPADC_PowerLevelAlt4 = 3U }
 Define enumeration of power configuration. More...
 
enum  _lpadc_trigger_priority_policy { kLPADC_TriggerPriorityPreemptImmediately = 0U , kLPADC_TriggerPriorityPreemptSoftly = 1U }
 Define enumeration of trigger priority policy. More...
 
typedef enum _lpadc_sample_scale_mode lpadc_sample_scale_mode_t
 Define enumeration of sample scale mode.
 
typedef enum _lpadc_sample_channel_mode lpadc_sample_channel_mode_t
 Define enumeration of channel sample mode.
 
typedef enum _lpadc_hardware_average_mode lpadc_hardware_average_mode_t
 Define enumeration of hardware average selection.
 
typedef enum _lpadc_sample_time_mode lpadc_sample_time_mode_t
 Define enumeration of sample time selection.
 
typedef enum _lpadc_hardware_compare_mode lpadc_hardware_compare_mode_t
 Define enumeration of hardware compare mode.
 
typedef enum _lpadc_reference_voltage_mode lpadc_reference_voltage_source_t
 Define enumeration of reference voltage source.
 
typedef enum _lpadc_power_level_mode lpadc_power_level_mode_t
 Define enumeration of power configuration.
 
typedef enum _lpadc_trigger_priority_policy lpadc_trigger_priority_policy_t
 Define enumeration of trigger priority policy.
 
#define FSL_LPADC_DRIVER_VERSION   (MAKE_VERSION(2, 6, 1))
 LPADC driver version 2.6.1.
 
#define LPADC_GET_ACTIVE_COMMAND_STATUS(statusVal)   ((statusVal & ADC_STAT_CMDACT_MASK) >> ADC_STAT_CMDACT_SHIFT)
 Define the MACRO function to get command status from status value.
 
#define LPADC_GET_ACTIVE_TRIGGER_STATUE(statusVal)   ((statusVal & ADC_STAT_TRGACT_MASK) >> ADC_STAT_TRGACT_SHIFT)
 Define the MACRO function to get trigger status from status value.
 

Initialization & de-initialization.

void LPADC_Init (ADC_Type *base, const lpadc_config_t *config)
 Initializes the LPADC module.
 
void LPADC_GetDefaultConfig (lpadc_config_t *config)
 Gets an available pre-defined settings for initial configuration.
 
void LPADC_Deinit (ADC_Type *base)
 De-initializes the LPADC module.
 

Trigger and conversion with FIFO.

bool LPADC_GetConvResult (ADC_Type *base, lpadc_conv_result_t *result)
 Get the result in conversion FIFO.
 
void LPADC_SetConvTriggerConfig (ADC_Type *base, uint32_t triggerId, const lpadc_conv_trigger_config_t *config)
 Configure the conversion trigger source.
 
void LPADC_GetDefaultConvTriggerConfig (lpadc_conv_trigger_config_t *config)
 Gets an available pre-defined settings for trigger's configuration.
 
void LPADC_SetConvCommandConfig (ADC_Type *base, uint32_t commandId, const lpadc_conv_command_config_t *config)
 Configure conversion command.
 
void LPADC_GetDefaultConvCommandConfig (lpadc_conv_command_config_t *config)
 Gets an available pre-defined settings for conversion command's configuration.
 

Detailed Description

Macro Definition Documentation

◆ LPADC_GET_ACTIVE_COMMAND_STATUS

#define LPADC_GET_ACTIVE_COMMAND_STATUS (   statusVal)    ((statusVal & ADC_STAT_CMDACT_MASK) >> ADC_STAT_CMDACT_SHIFT)

Define the MACRO function to get command status from status value.

The statusVal is the return value from LPADC_GetStatusFlags().

◆ LPADC_GET_ACTIVE_TRIGGER_STATUE

#define LPADC_GET_ACTIVE_TRIGGER_STATUE (   statusVal)    ((statusVal & ADC_STAT_TRGACT_MASK) >> ADC_STAT_TRGACT_SHIFT)

Define the MACRO function to get trigger status from status value.

The statusVal is the return value from LPADC_GetStatusFlags().

Typedef Documentation

◆ lpadc_hardware_average_mode_t

Define enumeration of hardware average selection.

It Selects how many ADC conversions are averaged to create the ADC result. An internal storage buffer is used to capture temporary results while the averaging iterations are executed.

◆ lpadc_hardware_compare_mode_t

Define enumeration of hardware compare mode.

After an ADC channel input is sampled and converted and any averaging iterations are performed, this mode setting guides operation of the automatic compare function to optionally only store when the compare operation is true. When compare is enabled, the conversion result is compared to the compare values.

◆ lpadc_power_level_mode_t

Define enumeration of power configuration.

Configures the ADC for power and performance. In the highest power setting the highest conversion rates will be possible. Refer to the device data sheet for power and performance capabilities for each setting.

◆ lpadc_reference_voltage_source_t

Define enumeration of reference voltage source.

For detail information, need to check the SoC's specification.

◆ lpadc_sample_channel_mode_t

Define enumeration of channel sample mode.

The channel sample mode configures the channel with single-end/differential/dual-single-end, side A/B.

◆ lpadc_sample_scale_mode_t

Define enumeration of sample scale mode.

The sample scale mode is used to reduce the selected ADC analog channel input voltage level by a factor. The maximum possible voltage on the ADC channel input should be considered when selecting a scale mode to ensure that the reducing factor always results voltage level at or below the VREFH reference. This reducing capability allows conversion of analog inputs higher than VREFH. A-side and B-side channel inputs are both scaled using the scale mode.

◆ lpadc_sample_time_mode_t

Define enumeration of sample time selection.

The shortest sample time maximizes conversion speed for lower impedance inputs. Extending sample time allows higher impedance inputs to be accurately sampled. Longer sample times can also be used to lower overall power consumption when command looping and sequencing is configured and high conversion rates are not required.

◆ lpadc_trigger_priority_policy_t

Define enumeration of trigger priority policy.

This selection controls how higher priority triggers are handled.

Enumeration Type Documentation

◆ _lpadc_hardware_average_mode

Define enumeration of hardware average selection.

It Selects how many ADC conversions are averaged to create the ADC result. An internal storage buffer is used to capture temporary results while the averaging iterations are executed.

Enumerator
kLPADC_HardwareAverageCount1 

Single conversion.

kLPADC_HardwareAverageCount2 

2 conversions averaged.

kLPADC_HardwareAverageCount4 

4 conversions averaged.

kLPADC_HardwareAverageCount8 

8 conversions averaged.

kLPADC_HardwareAverageCount16 

16 conversions averaged.

kLPADC_HardwareAverageCount32 

32 conversions averaged.

kLPADC_HardwareAverageCount64 

64 conversions averaged.

kLPADC_HardwareAverageCount128 

128 conversions averaged.

◆ _lpadc_hardware_compare_mode

Define enumeration of hardware compare mode.

After an ADC channel input is sampled and converted and any averaging iterations are performed, this mode setting guides operation of the automatic compare function to optionally only store when the compare operation is true. When compare is enabled, the conversion result is compared to the compare values.

Enumerator
kLPADC_HardwareCompareDisabled 

Compare disabled.

kLPADC_HardwareCompareStoreOnTrue 

Compare enabled. Store on true.

kLPADC_HardwareCompareRepeatUntilTrue 

Compare enabled. Repeat channel acquisition until true.

◆ _lpadc_interrupt_enable

Define interrupt switchers of the module.

Enumerator
kLPADC_ResultFIFOOverflowInterruptEnable 

Configures ADC to generate overflow interrupt requests when FOF flag is asserted.

kLPADC_FIFOWatermarkInterruptEnable 

Configures ADC to generate watermark interrupt requests when RDY flag is asserted.

◆ _lpadc_power_level_mode

Define enumeration of power configuration.

Configures the ADC for power and performance. In the highest power setting the highest conversion rates will be possible. Refer to the device data sheet for power and performance capabilities for each setting.

Enumerator
kLPADC_PowerLevelAlt1 

Lowest power setting.

kLPADC_PowerLevelAlt2 

Next lowest power setting.

kLPADC_PowerLevelAlt3 

...

kLPADC_PowerLevelAlt4 

Highest power setting.

◆ _lpadc_reference_voltage_mode

Define enumeration of reference voltage source.

For detail information, need to check the SoC's specification.

Enumerator
kLPADC_ReferenceVoltageAlt1 

Option 1 setting.

kLPADC_ReferenceVoltageAlt2 

Option 2 setting.

kLPADC_ReferenceVoltageAlt3 

Option 3 setting.

◆ _lpadc_sample_channel_mode

Define enumeration of channel sample mode.

The channel sample mode configures the channel with single-end/differential/dual-single-end, side A/B.

Enumerator
kLPADC_SampleChannelSingleEndSideA 

Single end mode, using side A.

kLPADC_SampleChannelSingleEndSideB 

Single end mode, using side B.

◆ _lpadc_sample_scale_mode

Define enumeration of sample scale mode.

The sample scale mode is used to reduce the selected ADC analog channel input voltage level by a factor. The maximum possible voltage on the ADC channel input should be considered when selecting a scale mode to ensure that the reducing factor always results voltage level at or below the VREFH reference. This reducing capability allows conversion of analog inputs higher than VREFH. A-side and B-side channel inputs are both scaled using the scale mode.

Enumerator
kLPADC_SamplePartScale 

Use divided input voltage signal. (For scale select,please refer to the reference manual).

kLPADC_SampleFullScale 

Full scale (Factor of 1).

◆ _lpadc_sample_time_mode

Define enumeration of sample time selection.

The shortest sample time maximizes conversion speed for lower impedance inputs. Extending sample time allows higher impedance inputs to be accurately sampled. Longer sample times can also be used to lower overall power consumption when command looping and sequencing is configured and high conversion rates are not required.

Enumerator
kLPADC_SampleTimeADCK3 

3 ADCK cycles total sample time.

kLPADC_SampleTimeADCK5 

5 ADCK cycles total sample time.

kLPADC_SampleTimeADCK7 

7 ADCK cycles total sample time.

kLPADC_SampleTimeADCK11 

11 ADCK cycles total sample time.

kLPADC_SampleTimeADCK19 

19 ADCK cycles total sample time.

kLPADC_SampleTimeADCK35 

35 ADCK cycles total sample time.

kLPADC_SampleTimeADCK67 

69 ADCK cycles total sample time.

kLPADC_SampleTimeADCK131 

131 ADCK cycles total sample time.

◆ _lpadc_status_flags

Define hardware flags of the module.

Enumerator
kLPADC_ResultFIFOOverflowFlag 

Indicates that more data has been written to the Result FIFO than it can hold.

kLPADC_ResultFIFOReadyFlag 

Indicates when the number of valid datawords in the result FIFO is greater than the setting watermark level.

◆ _lpadc_trigger_priority_policy

Define enumeration of trigger priority policy.

This selection controls how higher priority triggers are handled.

Enumerator
kLPADC_TriggerPriorityPreemptImmediately 

If a higher priority trigger is detected during command processing, the current conversion is aborted and the new command specified by the trigger is started.

kLPADC_TriggerPriorityPreemptSoftly 

If a higher priority trigger is received during command processing, the current conversion is completed (including averaging iterations and compare function if enabled) and stored to the result FIFO before the higher priority trigger/command is initiated.

Function Documentation

◆ LPADC_Deinit()

void LPADC_Deinit ( ADC_Type base)

De-initializes the LPADC module.

Parameters
baseLPADC peripheral base address.

brief De-initializes the LPADC module.

param base LPADC peripheral base address.

◆ LPADC_GetConvResult()

bool LPADC_GetConvResult ( ADC_Type base,
lpadc_conv_result_t result 
)

Get the result in conversion FIFO.

Parameters
baseLPADC peripheral base address.
resultPointer to structure variable that keeps the conversion result in conversion FIFO.
Returns
Status whether FIFO entry is valid.

brief Get the result in conversion FIFO.

param base LPADC peripheral base address. param result Pointer to structure variable that keeps the conversion result in conversion FIFO.

return Status whether FIFO entry is valid.

◆ LPADC_GetDefaultConfig()

void LPADC_GetDefaultConfig ( lpadc_config_t config)

Gets an available pre-defined settings for initial configuration.

This function initializes the converter configuration structure with an available settings. The default values are:

config->enableInDozeMode = true;
config->enableAnalogPreliminary = false;
config->powerUpDelay = 0x80;
config->referenceVoltageSource = kLPADC_ReferenceVoltageAlt1;
config->powerLevelMode = kLPADC_PowerLevelAlt1;
config->enableConvPause = false;
config->convPauseDelay = 0U;
config->FIFOWatermark = 0U;
@ kLPADC_TriggerPriorityPreemptImmediately
Definition: fsl_lpadc.h:369
@ kLPADC_PowerLevelAlt1
Definition: fsl_lpadc.h:344
@ kLPADC_ReferenceVoltageAlt1
Definition: fsl_lpadc.h:331
Definition: deflate.c:114
Parameters
configPointer to configuration structure.

brief Gets an available pre-defined settings for initial configuration.

This function initializes the converter configuration structure with an available settings. The default values are: code config->enableInDozeMode = true; config->conversionAverageMode = kLPADC_ConversionAverage1; config->enableAnalogPreliminary = false; config->powerUpDelay = 0x80; config->referenceVoltageSource = kLPADC_ReferenceVoltageAlt1; config->powerLevelMode = kLPADC_PowerLevelAlt1; config->triggerPriorityPolicy = kLPADC_TriggerPriorityPreemptImmediately; config->enableConvPause = false; config->convPauseDelay = 0U; config->FIFO0Watermark = 0U; config->FIFO1Watermark = 0U; config->FIFOWatermark = 0U; endcode param config Pointer to configuration structure.

◆ LPADC_GetDefaultConvCommandConfig()

void LPADC_GetDefaultConvCommandConfig ( lpadc_conv_command_config_t config)

Gets an available pre-defined settings for conversion command's configuration.

This function initializes the conversion command's configuration structure with an available settings. The default values are:

config->sampleScaleMode = kLPADC_SampleFullScale;
config->channelBScaleMode = kLPADC_SampleFullScale;
config->channelNumber = 0U;
config->chainedNextCmdNumber = 0U;
config->enableAutoChannelIncrement = false;
config->loopCount = 0U;
config->hardwareAverageMode = kLPADC_HardwareAverageCount1;
config->sampleTimeMode = kLPADC_SampleTimeADCK3;
config->hardwareCompareMode = kLPADC_HardwareCompareDisabled;
config->hardwareCompareValueHigh = 0U;
config->hardwareCompareValueLow = 0U;
config->conversionResolutionMode = kLPADC_ConversionResolutionStandard;
config->enableWaitTrigger = false;
config->enableChannelB = false;
@ kLPADC_SampleFullScale
Definition: fsl_lpadc.h:204
@ kLPADC_SampleTimeADCK3
Definition: fsl_lpadc.h:259
@ kLPADC_SampleChannelSingleEndSideA
Definition: fsl_lpadc.h:214
@ kLPADC_HardwareAverageCount1
Definition: fsl_lpadc.h:234
@ kLPADC_HardwareCompareDisabled
Definition: fsl_lpadc.h:278
Parameters
configPointer to configuration structure.

brief Gets an available pre-defined settings for conversion command's configuration.

This function initializes the conversion command's configuration structure with an available settings. The default values are: code config->sampleScaleMode = kLPADC_SampleFullScale; config->channelBScaleMode = kLPADC_SampleFullScale; config->channelSampleMode = kLPADC_SampleChannelSingleEndSideA; config->channelNumber = 0U; config ->alternateChannelNumber = 0U; config->chainedNextCmdNumber = 0U; config->enableAutoChannelIncrement = false; config->loopCount = 0U; config->hardwareAverageMode = kLPADC_HardwareAverageCount1; config->sampleTimeMode = kLPADC_SampleTimeADCK3; config->hardwareCompareMode = kLPADC_HardwareCompareDisabled; config->hardwareCompareValueHigh = 0U; config->hardwareCompareValueLow = 0U; config->conversionResolutionMode = kLPADC_ConversionResolutionStandard; config->enableWaitTrigger = false; config->enableChannelB = false; endcode param config Pointer to configuration structure.

◆ LPADC_GetDefaultConvTriggerConfig()

void LPADC_GetDefaultConvTriggerConfig ( lpadc_conv_trigger_config_t config)

Gets an available pre-defined settings for trigger's configuration.

This function initializes the trigger's configuration structure with an available settings. The default values are:

config->commandIdSource = 0U;
config->loopCountIndex = 0U;
config->triggerIdSource = 0U;
config->enableHardwareTrigger = false;
Parameters
configPointer to configuration structure.

brief Gets an available pre-defined settings for trigger's configuration.

This function initializes the trigger's configuration structure with an available settings. The default values are: code config->commandIdSource = 0U; config->loopCountIndex = 0U; config->triggerIdSource = 0U; config->enableHardwareTrigger = false; config->channelAFIFOSelect = 0U; config->channelBFIFOSelect = 0U; endcode param config Pointer to configuration structure.

◆ LPADC_Init()

void LPADC_Init ( ADC_Type base,
const lpadc_config_t config 
)

Initializes the LPADC module.

Parameters
baseLPADC peripheral base address.
configPointer to configuration structure. See "lpadc_config_t".

brief Initializes the LPADC module.

param base LPADC peripheral base address. param config Pointer to configuration structure. See "lpadc_config_t".

◆ LPADC_SetConvCommandConfig()

void LPADC_SetConvCommandConfig ( ADC_Type base,
uint32_t  commandId,
const lpadc_conv_command_config_t config 
)

Configure conversion command.

Parameters
baseLPADC peripheral base address.
commandIdID for command in command buffer. Typically, the available value range is 1 - 15.
configPointer to configuration structure. See to lpadc_conv_command_config_t.

brief Configure conversion command.

param base LPADC peripheral base address. param commandId ID for command in command buffer. Typically, the available value range is 1 - 15. param config Pointer to configuration structure. See to lpadc_conv_command_config_t.

◆ LPADC_SetConvTriggerConfig()

void LPADC_SetConvTriggerConfig ( ADC_Type base,
uint32_t  triggerId,
const lpadc_conv_trigger_config_t config 
)

Configure the conversion trigger source.

Each programmable trigger can launch the conversion command in command buffer.

Parameters
baseLPADC peripheral base address.
triggerIdID for each trigger. Typically, the available value range is from 0.
configPointer to configuration structure. See to lpadc_conv_trigger_config_t.

brief Configure the conversion trigger source.

Each programmable trigger can launch the conversion command in command buffer.

param base LPADC peripheral base address. param triggerId ID for each trigger. Typically, the available value range is from 0. param config Pointer to configuration structure. See to lpadc_conv_trigger_config_t.

Variable Documentation

◆ chainedNextCommandNumber

uint32_t lpadc_conv_command_config_t::chainedNextCommandNumber

Selects the next command to be executed after this command completes. 1-15 is available, 0 is to terminate the chain after this command.

◆ channelNumber

uint32_t lpadc_conv_command_config_t::channelNumber

Channel number, select the channel or channel pair.

◆ commandIdSource

uint32_t lpadc_conv_result_t::commandIdSource

Indicate the command buffer being executed that generated this result.

◆ convPauseDelay

uint32_t lpadc_config_t::convPauseDelay

Controls the duration of pausing during command execution sequencing. The pause delay is a count of (convPauseDelay*4) ADCK cycles. Only available when ADC pausing function is enabled. The available value range is in 9-bit.

◆ convValue

uint16_t lpadc_conv_result_t::convValue

Data result.

◆ delayPower

uint32_t lpadc_conv_trigger_config_t::delayPower

Select the trigger delay duration to wait at the start of servicing a trigger event. When this field is clear, then no delay is incurred. When this field is set to a non-zero value, the duration for the delay is 2^delayPower ADCK cycles. The available value range is 4-bit.

◆ enableAnalogPreliminary

bool lpadc_config_t::enableAnalogPreliminary

ADC analog circuits are pre-enabled and ready to execute conversions without startup delays(at the cost of higher DC current consumption).

◆ enableAutoChannelIncrement

bool lpadc_conv_command_config_t::enableAutoChannelIncrement

Loop with increment: when disabled, the "loopCount" field selects the number of times the selected channel is converted consecutively; when enabled, the "loopCount" field defines how many consecutive channels are converted as part of the command execution.

◆ enableConvPause

bool lpadc_config_t::enableConvPause

Enables the ADC pausing function. When enabled, a programmable delay is inserted during command execution sequencing between LOOP iterations, between commands in a sequence, and between conversions when command is executing in "Compare Until True" configuration.

◆ enableHardwareTrigger

bool lpadc_conv_trigger_config_t::enableHardwareTrigger

Enable hardware trigger source to initiate conversion on the rising edge of the input trigger source or not. THe software trigger is always available.

◆ enableInDozeMode

bool lpadc_config_t::enableInDozeMode

Control system transition to Stop and Wait power modes while ADC is converting. When enabled in Doze mode, immediate entries to Wait or Stop are allowed. When disabled, the ADC will wait for the current averaging iteration/FIFO storage to complete before acknowledging stop or wait mode entry.

◆ FIFOWatermark

uint32_t lpadc_config_t::FIFOWatermark

FIFOWatermark is a programmable threshold setting. When the number of datawords stored in the ADC Result FIFO is greater than the value in this field, the ready flag would be asserted to indicate stored data has reached the programmable threshold.

◆ hardwareAverageMode

lpadc_hardware_average_mode_t lpadc_conv_command_config_t::hardwareAverageMode

Hardware average selection.

◆ hardwareCompareMode

lpadc_hardware_compare_mode_t lpadc_conv_command_config_t::hardwareCompareMode

Hardware compare selection.

◆ hardwareCompareValueHigh

uint32_t lpadc_conv_command_config_t::hardwareCompareValueHigh

Compare Value High. The available value range is in 16-bit.

◆ hardwareCompareValueLow

uint32_t lpadc_conv_command_config_t::hardwareCompareValueLow

Compare Value Low. The available value range is in 16-bit.

◆ loopCount

uint32_t lpadc_conv_command_config_t::loopCount

Selects how many times this command executes before finish and transition to the next command or Idle state. Command executes LOOP+1 times. 0-15 is available.

◆ loopCountIndex

uint32_t lpadc_conv_result_t::loopCountIndex

Indicate the loop count value during command execution that generated this result.

◆ powerLevelMode

lpadc_power_level_mode_t lpadc_config_t::powerLevelMode

Power Configuration Selection.

◆ powerUpDelay

uint32_t lpadc_config_t::powerUpDelay

When the analog circuits are not pre-enabled, the ADC analog circuits are only powered while the ADC is active and there is a counted delay defined by this field after an initial trigger transitions the ADC from its Idle state to allow time for the analog circuits to stabilize. The startup delay count of (powerUpDelay * 4) ADCK cycles must result in a longer delay than the analog startup time.

◆ priority

uint32_t lpadc_conv_trigger_config_t::priority

Sets the priority of the associated trigger source. If two or more triggers have the same priority level setting, the lower order trigger event has the higher priority. The lower value for this field is for the higher priority, the available value range is 1-bit.

◆ referenceVoltageSource

lpadc_reference_voltage_source_t lpadc_config_t::referenceVoltageSource

Selects the voltage reference high used for conversions.

◆ sampleChannelMode

lpadc_sample_channel_mode_t lpadc_conv_command_config_t::sampleChannelMode

Channel sample mode.

◆ sampleTimeMode

lpadc_sample_time_mode_t lpadc_conv_command_config_t::sampleTimeMode

Sample time selection.

◆ targetCommandId

uint32_t lpadc_conv_trigger_config_t::targetCommandId

Select the command from command buffer to execute upon detect of the associated trigger event.

◆ triggerIdSource

uint32_t lpadc_conv_result_t::triggerIdSource

Indicate the trigger source that initiated a conversion and generated this result.

◆ triggerPriorityPolicy

lpadc_trigger_priority_policy_t lpadc_config_t::triggerPriorityPolicy

Control how higher priority triggers are handled, see to lpadc_trigger_priority_policy_t.