Hi How can I make a software reset at LPC21xx family processors? thanks, joao
Hi, best way I know is using the watchdog timer. Basically the procedure is like that: After power on reset, during initializations you check a certain area in memory (SRAM) for a predefined key. If you did not find it because after a power on reset this is supposed to be random, you decide that this was NOT a soft reset. No you initialize this area of memory with a value that indicates a "real watchdog reset" Before you go into the softreset, you overwrite this word in memory with a value representing the "softreset". You will get a reset, and you will go back to the checking after reset. In case this seems a little confusing, let me know and ask specific questions. Hope this helps, regards, Robert Reset | check for magic value | Does value represent predifined reset? | If yes, it was a "real wdt" or a "softreset" | If no, it was a power on reset | Initialize for "real WDT reset" | Before you go in to soft reset initialize for soft reset | set WDT to minimum and do not service it
using watchdog is a great idea! thanks.