hello; can u explain me about power fail recovery in microcontroller. i m using c8051f020 controller,in that RSTSRC register is present, its 7th bit is set when power fails. but how to write the code after that, means suppose if my test is going on, and power fails, then depending upon RSTSRC.7 bit how to get back to test. on reset microcontroller starts from 0000h, then how to store the status before power fail can u provide me sample code, i m using 'c' language thank u all.