libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.

ADC Trigger API. More...

Collaboration diagram for ADC Trigger API:

Functions

void adc_enable_external_trigger_regular (uint32_t adc, uint32_t trigger, uint32_t polarity)
 ADC Enable an External Trigger for Regular Channels. More...
 
void adc_disable_external_trigger_regular (uint32_t adc)
 ADC Disable an External Trigger for Regular Channels. More...
 

Detailed Description

ADC Trigger API.

Function Documentation

◆ adc_disable_external_trigger_regular()

void adc_disable_external_trigger_regular ( uint32_t  adc)

ADC Disable an External Trigger for Regular Channels.

Parameters
[in]adcUnsigned int32. ADC base address (ADC register base addresses)

Definition at line 178 of file adc.c.

References ADC_CFGR1.

◆ adc_enable_external_trigger_regular()

void adc_enable_external_trigger_regular ( uint32_t  adc,
uint32_t  trigger,
uint32_t  polarity 
)

ADC Enable an External Trigger for Regular Channels.

This enables an external trigger for set of defined regular channels, and sets the polarity of the trigger event: rising or falling edge or both. Note that if the trigger polarity is zero, triggering is disabled.

Parameters
[in]adcperipheral of choice (ADC register base addresses)
[in]triggerexternal trigger ADC external trigger selection values
[in]polarityTrigger polarity EXTEN: External trigger enable and polarity selection for regular channels

Definition at line 162 of file adc.c.

References ADC_CFGR1, ADC_CFGR1_EXTEN_MASK, ADC_CFGR1_EXTSEL_MASK, and ADC_CFGR1_EXTSEL_SHIFT.