Thank you for your answer sougata Today I have changed to a digital scope, but I dont undestand why the pwm output some times stay freeze, or start doing the work and go to 0 volts the pwm output, other times stay in 5 volts, what can be doing it ?
I have modified my code using pwm and a/d interrup... each time that PTMR match PTPER, the PWM module go to interrup, in PWM interrupt I start A/D conversion and load the result to Duty cycle register, after I turn off PWM interrupt, I attach here the code, I hope u can check it please and tell me some suggestion, thank you.
Regards.
Tom.
Bookmarks