Hallo,
I'm using 28035 device and I need to distinguish between a POR and a watchdog reset.
Following the datasheet all seems easy, just read the WDFLAG after reset, but on my bench WDFLAG seems never to be set. After all resets WDFLAG value is zero.
I learnt in the community that many members had problems with WDFLAG management. Is it reliable or not?
By the way, I'm using the Eva Board with ControlCard and USB docking station and have measured the XRS low time as 56.2 microseconds, that should be short enough to guarantee the WDFLAG setting.
I list here the code used to read WDFLAG.
Can anyone tell me if I'm doing something wrong?
code_start:
LB wd_disable ;Branch to watchdog disable code
;end codestart section
.text
wd_disable:
SETC OBJMODE ;Set OBJMODE for 28x object code
;;; Reading WDFLAG of WDCR
;;; ---------------------------------------
MOVZ DP, #7029h>>6 ;Set data page for WDCR register
AND AL, @7029h, #0080h ;WDCR AND WDFLAG mask
SB reset_por, EQ ;<<<--- my software ever jumps here, even after a watchdog reset due to a WDCHK manipulation
LB CheckFStartAppl