Microcontroller › 8051 › Delay function in C › Hi, What is the frequency of
May 10, 2014 at 3:46 am
#11708
SHAH DISHANT H.
Participant
Hi,
What is the frequency of your crystal ?
1275 value will give 1 milisecond delay i crystal of 11.0592MHz is sued and the code is compiled in GCC not in KEIL.
Try to reduce two values.
1. Instead of 1275, use low value.
2. Instead of msDelay(4000) also give low value like msDelay(10).
I had faced same issue. What was happening was, the delay was a lot more than what was expected. So I also thought that it is stucked in that function and not coming out of the loop.
Try with this and revert back.