Sorry that I have ask very subjective question.
Actually the PIC base project is working perfectly when run in-house for a week without any problem.
However, when it is install at outdoor, it run fine initially, but may be a few hours, it just hang. After reset, it work again without problem, may be for a few days, it may hang again . (The PIC is not recover from hang.)
So I suspect problem may due to unstable power supply or noisy environment.
To solve the problem in-house, I need to be able to repeat and simulate problem. Hence, I am asking how to simulate noise, and throw the noise to the board and see what happened.
For firmware, I have turn on WDT, power up reset, brownout in my PIC 16F628, using internal 4MHz oscillator.
The clear watchdog is only place in main & delay routine, it shall be able to recover from hang. However, look like the watch dog is not function well.
For hardware, standard filtering on power supply, a 0.1uF cap put close to VCC of PIC.
The outdoor temperature, is less than 50deg C.
May be I ask other question:
1. Can watch dog itself hang? (it internal RC oscillator stop)
2. Can internal oscillator in PIC 16F628 stop?
3. Is PIC 100% reliable?
Thank you.