AAEON AEC-6511 User Manual

Page 39

Advertising
background image

E m b e d d e d C o n t r o l l e r

A E C - 6 5 1 1

Appendix A Programming the Watchdog Timer

A-7

A.2 W83627DHG Watchdog Timer Initial Program

Example: Setting 10 sec. as Watchdog timeout interval

;///////////////////////////////////////////////////////////////////////////////////////////////

Mov dx,2eh

;Enter W83627DHG config mode

Mov al,87h

(out 87h to 2eh twice)

Out dx,al

Out dx,al

;///////////////////////////////////////////////////////////////////////////////////////////////

Mov al,07h

Out dx,al

Inc dx

Mov al,08h

;Select Logical Device 8 (GPIO Port

2)

Out dx,al

;///////////////////////////////////////////////////////////////////////////////////////////////

Dec dx

Mov al,30h

;CR30 (GP20~GP27)

Out dx,al

Inc dx

Mov al,01h

;Activate GPIO2

Out dx,al

Advertising