HAL ADC stm32f37x EXTSEL macro Topic is solved

Report here problems in any of ChibiOS components. This forum is NOT for support.
Post Reply
noah
Posts: 6
Joined: Wed Sep 28, 2016 8:09 pm
Been thanked: 2 times

HAL ADC stm32f37x EXTSEL macro

Post by noah »

Hi all

I think that the macro ADC_CR2_EXTSEL_SRC defined in adc_lld.h for setting the external trigger is wrong. The EXTSEL bits [2:0] are located on [19:17] in ADC_CR2.

Line 38:

Code: Select all

#define ADC_CR2_EXTSEL_SRC(n)   ((n) << 24) /**< @brief Trigger source.     */

should be

Code: Select all

#define ADC_CR2_EXTSEL_SRC(n)   ((n) << 17) /**< @brief Trigger source.     */


Can anyone confirm?

Version: 16.1.x
File: os/hal/ports/STM32/STM32F37x/adc_lld.h
User avatar
Giovanni
Site Admin
Posts: 14893
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 997 times

Re: HAL ADC stm32f37x EXTSEL macro

Post by Giovanni »

Hi,

Fixed as bug #785, thanks.

Giovanni
Post Reply