Question
Peak detection with adc
Hi guys.
I have 2 GPIOs, one is used as a PWM, the other one is used as ADC.
and the peak comes in the falling edge of the PWM singal.and the plus width is only like 2us.
I want to get the value of the peak voltage using ADC.
The problem is, if I use a interrupt like PWM falling edge, then start the adc, it will take more than 2us. so I cannot get the right value.
is there any solutions to this problem?
PS: I am using STM32G4,fast enough I think.
