ВходНаше всё Теги codebook 无线电组件 Поиск Опросы Закон Пятница
4 июля
1527508 Топик полностью
LightElf (30.06.2025 19:31, просмотров: 73) ответил Бapбoc на Вот тут как-то так получилось. В кубе обнаружил, что ежели вход аналоговый, то на него можно посадить и АЦП и компаратор одновременно. Это логично. А в референсе мануале про это не нашёл ничего. Аглицкого не знаю, перевожу со словарём. Может пропустил чего? Хочется какого-то подтверждения, чтобы прямо словами.
Вот тута прямо пишут, что можно одну ногу подключить и к ADC и к компаратору. Но предупреждают, что зарядка емкости УВХ может вызвать срань на выходе компаратора. 

https://community.st.com/t5/stm32-mcus-products/sharing-inputs-between-adc-and-comparators-on-stm32f303/td-p/301594

https://electronics.stackexchange.com/questions/210292/stm32f0x1-comparator-comp-and-adc-on-same-pin-simultaneously

PS. В аппноте AN4232 прямо предлагают так делать

Moreover, the comparator input is an ADC channel so PCB designer does not need to make an external connection between the comparator input and the ADC channel. In an analog voltage monitoring application where the sensor output voltage is lower than the threshold, the MCU remains in Stop mode thereby saving power. As soon as the sensor output exceeds the threshold, the analog comparator wakes up the MCU, the ADC is powered on, and the analog input voltage is measured. When the sensor output is lower than the threshold, the MCU re-enters the low-power mode to save battery life. Enabling the ADC only when required (analog voltage higher than a threshold) dramatically reduces the average power consumption, as compared to an application where the ADC is always enabled whatever the analog voltage.
Не надо делать мне как лучше, оставьте мне как хорошо