STM32H735xx HAL User Manual
|
Defines | |
#define | __LL_DAC_CHANNEL_TO_DECIMAL_NB(__CHANNEL__) ((__CHANNEL__) & DAC_SWTR_CHX_MASK) |
Helper macro to get DAC channel number in decimal format from literals LL_DAC_CHANNEL_x. | |
#define | __LL_DAC_DECIMAL_NB_TO_CHANNEL(__DECIMAL_NB__) (((__DECIMAL_NB__) == 1UL)? (LL_DAC_CHANNEL_1 ):(((__DECIMAL_NB__) == 2UL) ? ( LL_DAC_CHANNEL_2):(0UL))) |
Helper macro to get DAC channel in literal format LL_DAC_CHANNEL_x from number in decimal format. | |
#define | __LL_DAC_DIGITAL_SCALE(__DAC_RESOLUTION__) ((0x00000FFFUL) >> ((__DAC_RESOLUTION__) << 1UL)) |
Helper macro to define the DAC conversion data full-scale digital value corresponding to the selected DAC resolution. | |
#define | __LL_DAC_CALC_VOLTAGE_TO_DATA(__VREFANALOG_VOLTAGE__, __DAC_VOLTAGE__, __DAC_RESOLUTION__) |
Helper macro to calculate the DAC conversion data (unit: digital value) corresponding to a voltage (unit: mVolt). |
#define __LL_DAC_CALC_VOLTAGE_TO_DATA | ( | __VREFANALOG_VOLTAGE__, | |
__DAC_VOLTAGE__, | |||
__DAC_RESOLUTION__ | |||
) |
((__DAC_VOLTAGE__) * __LL_DAC_DIGITAL_SCALE(__DAC_RESOLUTION__) \ / (__VREFANALOG_VOLTAGE__) \ )
Helper macro to calculate the DAC conversion data (unit: digital value) corresponding to a voltage (unit: mVolt).
__VREFANALOG_VOLTAGE__ | Analog reference voltage (unit: mV) |
__DAC_VOLTAGE__ | Voltage to be generated by DAC channel (unit: mVolt). |
__DAC_RESOLUTION__ | This parameter can be one of the following values: |
DAC | conversion data (unit: digital value) |
Definition at line 536 of file stm32h7xx_ll_dac.h.
#define __LL_DAC_CHANNEL_TO_DECIMAL_NB | ( | __CHANNEL__ | ) | ((__CHANNEL__) & DAC_SWTR_CHX_MASK) |
Helper macro to get DAC channel number in decimal format from literals LL_DAC_CHANNEL_x.
Example: __LL_DAC_CHANNEL_TO_DECIMAL_NB(LL_DAC_CHANNEL_1) will return decimal number "1".
__CHANNEL__ | This parameter can be one of the following values: |
1...2 |
Definition at line 485 of file stm32h7xx_ll_dac.h.
#define __LL_DAC_DECIMAL_NB_TO_CHANNEL | ( | __DECIMAL_NB__ | ) | (((__DECIMAL_NB__) == 1UL)? (LL_DAC_CHANNEL_1 ):(((__DECIMAL_NB__) == 2UL) ? ( LL_DAC_CHANNEL_2):(0UL))) |
Helper macro to get DAC channel in literal format LL_DAC_CHANNEL_x from number in decimal format.
Example: __LL_DAC_DECIMAL_NB_TO_CHANNEL(1) will return a data equivalent to "LL_DAC_CHANNEL_1".
__DECIMAL_NB__ | 1...2 |
Returned | value can be one of the following values: |
Definition at line 501 of file stm32h7xx_ll_dac.h.
#define __LL_DAC_DIGITAL_SCALE | ( | __DAC_RESOLUTION__ | ) | ((0x00000FFFUL) >> ((__DAC_RESOLUTION__) << 1UL)) |
Helper macro to define the DAC conversion data full-scale digital value corresponding to the selected DAC resolution.
__DAC_RESOLUTION__ | This parameter can be one of the following values: |
ADC | conversion data equivalent voltage value (unit: mVolt) |
Definition at line 515 of file stm32h7xx_ll_dac.h.