Quote Originally Posted by HenrikOlsson View Post
Hi,
You have a lot of PAUSE statements within the LCD sections, most noticable is the PAUSE 1500 (1.5 seconds!) in the Map_VrefInVal_to_PWM_Duty subroutine which you call each time thru your Main routine. When you don't include the LCD sections in the code it runs MUCH faster compared to when you DO include the LCD sections.

/Henrik.
Thanks Henrik. That would definitely seem to explain the slow reaction to reading ADC during the main loop, but why would the duty cycle on the PWM output go HIGH as soon as power is turned on?