- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are there any registers that can be used to transfer data from before a watchdog reset to after?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have tested bob's advice, and verify it make sense after wdt reset.
#define __no_init __attribute__((section(".noinit")))
uint32 mydata[2]__no_init ={1,3};
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The IC will not clear the RAM, but it need to re-initialize the ram after the reset.
Every register will initialize after a watchdog reset.
Or you can describe what do you want to do.
If someone has another opinion, welcome to discuss.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
One way will be to save data in internal flash or external flash/ram.
There is a compiler directive (not much time to investigate). Try
#define __no_init __attribute__ ((section (".noinit")))
and later:
uint32 MyData[50] __no_init;
Problem might be to check whether data is valid (after a power-down)
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have tested bob's advice, and verify it make sense after wdt reset.
#define __no_init __attribute__((section(".noinit")))
uint32 mydata[2]__no_init ={1,3};