Hi, I hope someone can help me I have built an automatic trasnfer switch for genset it makes all necesary to turn on the motor of the generator when the mains goes down. The circuit has a CPU and an LCD 2x16 Truly the problem is that sometimes the lcd after hours of working ok hangs up and the display becomes black ( the codep still works ok) I put big capacitors in the power source (4700uF - 7805-4700uF) but the problem persists
Another thing: Does you loose contact with the LCD or is it possible to read data from it?
Embedded systems requires a lot of the development time spent thinking about the hardware, and one important thing when developing software for embedded systems is to make them self-detecting and self-correcting.
Extra code should be added to verify that the hardware modules are still working as expected. If a problem is found, it is normal to try to reinitialize the hardware.
It is also common to allow power-cycling of external hardware, to allow the "ultimate reset" of connected equipment without requiring the owner/user to disconnect the power cord.
It is normally cheaper to use a plastic box than a metal box. But the end user may place their mobile phone directly on the box, or the box may be physically installed against other equipment that are allowed to emit very strong magnetic or electric fields.
Parts of the certification of systems is that they do not get destroyed by external abuse. Depending on type of equipment, and type of certification, the system may be required to recover as soon as the disturbance is removed. But in some situations, the equipment may have to continue to give full or partial service when disturbed.
Hi,
You don't posted any code, so it is impossible for you I cannot help to you. However... Seems your initlcd routine doesn't work with your LCD (maybe it doesn't contain an internal reset circuit?). I see you have the hd44780.pdf but I strongly recommended to apply a long delay first and after this send three reset commands (0x3) to the lcd. I wanted to attached here an example project written by me (it's for my project, it uses also the Busy flag, the source is in assembly but very well commented). The expected lcd inic steps are useful also for you I think. Study it!
OK, an initlcd eats long time but it runs at begin and only once. If it's not enough, (maybe) your code is wrong elsewhere. And again: do not use the init lcd routine under IT!
Without any code and schematic I cannot help more to you. Good luck. zuisti