We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi, I use AT89S52 in a project. I send and receive data through TXD, RXD pins to a GSM module for sending SMS to another mobile equipment. I use watchdog facility and the watchdog counter is reset at every 256 counts. My crystal frequency is 11.0592 MHz. It happens once in a while that the uC doesn't respond and remains as if it hangs. Then it has to be RESET again. I doubt whether it happens while serial data reception and sending happens simultaneously. I wrote the program in C using KEIL IDE. My questions are 1) What are the special precautions to be taken in this case?(sending and receiving simultaneously) 2)why this happens even when the watchdog is active? It will be highly appreciated if anybody can give some guidance.
this could explain why the watchdog has no effect - maybe your program does not even get the chance to configure it during startup after the failure...?
Or it could be that the watchdog did have the desired effect of resetting the processor, but the processor then hangs somewhere before the app starts.
Maybe there's a power supply glitch - is there a proper supervisor circuit in the system?
This seems to be very valid. My equipment works in a noisy (electrical noise) environment. I also think that the noise pick ups in the power supply may be coming to the reset pin and causing error. With RESET high all the O/P pins go high. Is it possible that a spike on the reset pin can cause all pins go to high state and remain like that? If so, can you suggest some solution for that? What do you mean by proper supervisor circuit?