2020-11-11 04:24 PM
I'm trying to enable ADC channel 16 on STM32G031J6 but the IDE does not list up the channel.
What is the matter? How can I enable the channel?
My environment as bellow.
STM32CubeIDE
Version: 1.4.2
Build: 7643_20200813_1322 (UTC)
STM32CubeMX - STM32 Device Configuration Tool
Version: 6.0.1-RC3
Build: 20200810-1643 (UTC)
STM32CubeG0 Firmware Package V1.3.0 / 25-June-2019
Solved! Go to Solution.
2020-11-11 11:13 PM
Hello @SKiri ,
When sequencer is set to "not fully configurable" => CHSELRMOD = 0 in ADC_CFGR1
=> ADC_CHSELR is up to 19 channels (CHSEL 0 to CHSEL 18)
When sequencer is set to "fully configurable" => CHSELRMOD = 1 in ADC_CFGR1
=> ADC_CHSELR is able to sequence up to only 8 channels (CH 0 to CH 14)
The Rank configuration can be done only in the "fully configurable" sequencer case, for that, you cannot choose Channel 16 under Rank.
Best Regards,
Khouloud
2020-11-11 11:13 PM
Hello @SKiri ,
When sequencer is set to "not fully configurable" => CHSELRMOD = 0 in ADC_CFGR1
=> ADC_CHSELR is up to 19 channels (CHSEL 0 to CHSEL 18)
When sequencer is set to "fully configurable" => CHSELRMOD = 1 in ADC_CFGR1
=> ADC_CHSELR is able to sequence up to only 8 channels (CH 0 to CH 14)
The Rank configuration can be done only in the "fully configurable" sequencer case, for that, you cannot choose Channel 16 under Rank.
Best Regards,
Khouloud
2020-11-12 06:36 AM
Ah! I see!
Thanks a lot.