Oops! It appears that you have disabled your Javascript. In order for you to see this page as it is meant to appear, we ask that you please re-enable your Javascript!

Reply To: LED blinking problem

Home Forums MPLAB XC8 Tutorial Discussions LED blinking problem Reply To: LED blinking problem

#3202

Bitahwa Bindu
Keymaster

Try to make these few coinages and see if will make a difference:

  1.  In Proba.h, switch OFF the LVP: Change #pragma config LVP = OFF
  2. In Prob.c change int main(void) to void main(void)
  3. Remove the loop in the delay function, I used the loop in the past because the old XC8 compiler did not accept high delay values, but this limitation has been resolved in new compilers. Write: __delay_ms(1000);
  4. Do you experience the same problem even if you connect your LED to a different pin or PORT?