LEDC triggers ADC

ardiehl
Posts: 7
Joined: Fri Oct 27, 2017 10:44 pm

LEDC triggers ADC

Postby ardiehl » Fri Oct 27, 2017 10:56 pm

I'm not sure if it is possible with the ESP32 (using esp-idf):

i need to create a 1 KHZ pulse with variable duty cycle, should be easy using ledc. However, i need to measure a voltage (8 bit resolution would be ok) at the high time of the cycle. I could simply connect 2 pins to generate an interrupt at the start of each cycle, but:
Is it possible to measure a voltage from within an interrupt routine ?
Would the timing allow me to measure the voltage, lets say, for a 10% duty cycle ?

Thx

Who is online

Users browsing this forum: chegewara, Google [Bot] and 115 guests