2026-05-25 6:11 AM - edited 2026-05-25 6:13 AM
Based on discussion here, conclusion is, that given in 'L45x/'L46x there's no DAC1_CH2, and in 'L41x/'L42x no DAC at all, these are unavailable for inputs selectable for COMP for these sub-families of the low-end 'L4xx family group handled collectively by RM0394.
Description in stm32l4xx_hal_comp.c does not tell these completely, and there are also references to 'L43x/'L44x having some exceptions, which based on RM/DS doesn't appear to be the case:
Also, macros in stm32l4xx_ll_comp.c don't take the missing DAC channels into account, and they should.
Can these be looked at, please.
Thanks,
JW
2026-06-04 3:53 AM
Hello @waclawek.jan
According to the datasheet of L452 there is two dac channels for this MCU.
@waclawek.jan wrote:Also, macros in stm32l4xx_ll_comp.c don't take the missing DAC channels into account, and they should.
Could you explain more about this point please?
2026-06-04 6:12 AM
Hi @Saket_Om ,
Also, there is no DAC1_OUT2 in the pin definitions tables in 'L451 nor 'L452 DS.
If this is true, the IS_LL_COMP_INPUT_MINUS macro in stm32l4xx_ll_comp.c should have a different variant for the 'L45x/'L46x, omitting the option to use LL_COMP_INPUT_MINUS_DAC1_CH2.
JW
2026-06-04 8:21 AM
Hello @waclawek.jan
Thank you for bringing this issue to our attention.
I reported this internally.
Internal ticket number: CDM0063195 (This is an internal tracking number and is not accessible or usable by customers).
We’re moving the ST Community to a new platform to give you a better and more reliable community experience.