ADSP-BF537 Blackfin Processor Hardware Reference
17-9
Watchdog Timer
Programming Examples
shows how to configure the watchdog timer so that it resets
the chip when it expires. At startup, the code evaluates whether the recent
reset event has been caused by the watchdog. Additionally, the example
sets the
NOBOOT
bit to prevent the memory from being rebooted.
Listing 17-1. Watchdog Timer Configuration
#include <defBF534.h>
#define WDOGPERIOD 0x00200000
.section L1_code;
.global _reset;
_reset:
...
/* optionally, test whether reset was caused by watchdog */
p0.h=hi(SWRST);
p0.l=lo(SWRST);
r6 = w[p0] (z);
CC = bittst(r6, bitpos(RESET_WDOG));
if !CC jump _reset.no_watchdog_reset;
/* optionally, warn at system level or host device here */
_reset.no_watchdog_reset:
/* optionally, set NOBOOT bit to avoid reboot in case */
p0.h=hi(SYSCR);
p0.l=lo(SYSCR);
r0 = w[p0](z);
bitset(r0,bitpos(NOBOOT));
w[p0] = r0;
Summary of Contents for Blackfin ADSP-BF537
Page 42: ...Contents xlii ADSP BF537 Blackfin Processor Hardware Reference ...
Page 90: ...Development Tools 1 32 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 138: ...Programming Examples 4 26 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 340: ...SDC Programming Examples 6 84 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 606: ...Programming Examples 9 94 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 660: ...Programming Examples 10 54 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 720: ...Electrical Specifications 11 60 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 840: ...Programming Examples 13 42 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 876: ...Programming Examples 14 36 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 938: ...Programming Examples 15 62 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 958: ...Programming Examples 17 12 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 986: ...Programming Examples 18 28 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 1162: ...G 26 ADSP BF537 Blackfin Processor Hardware Reference ...
Page 1218: ...Index I 56 ADSP BF537 Blackfin Processor Hardware Reference ...