EasyManua.ls Logo

Tera 2I386EW - Page 39

Tera 2I386EW
107 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
34
How to use this Demo Application
How to use this Demo Application
How to use this Demo Application
Introduction
WriteI2CByte(I2CADDR, CONFIG, 0x03);//Set Watch Dog Timer function
WriteI2CByte(I2CADDR, WDT_TIMER, timer);//Set Watch Dog Timer range from 0-255.
WriteI2CByte(I2CADDR, WDT_TIMER_CTL, 0x73);//Enable Watch Dog Timer in second and pulse mode
void pause(int time)
{
asm mov ah,0h; //Ah = 00 Read System Time Counter
asm int 1ah; //read time from Time Counter and store it in DX register
asm add dx,time;
asm mov bx,dx;
label:
asm int 1ah;
asm cmp bx,dx;
asm jne label;
}
WriteI2CByte(I2CADDR, WDT_TIMER_CTL, 0x00);

Table of Contents