froggy_lim88
Newbie level 3

hi,
i'm doing a project to display the real time clock using rabbit board thru Ithernet time. I would like to know how write. i have problem in writing it. thank u.
TF0=0;
TH0=0xf0
TL0=0x5c;
SCON = 0x50; // mode 1, 8-bit uart, enable receiver
TMOD= 0x21; //Turn timer 1 mode 2.
TH1 = 0XFA; // for 9600 baud rate 0XFD
void gettingtime()
{
if(i==0x7f)// Waiting for the 011111111 to come in as a start signal.
{
count3=0;
}
if(count3==87)// after recieved the start signal. wait for 0.2 sec to the the 1st digit.
{
dig4=i;
}
if(count3==125) //second digit.
{
dig3=i;
}
if(count3==250) //Third digit
{
dig2=i;
}
if(count3==312) // forth digit
{
dig1=i;
}
}
i'm doing a project to display the real time clock using rabbit board thru Ithernet time. I would like to know how write. i have problem in writing it. thank u.
TF0=0;
TH0=0xf0
TL0=0x5c;
SCON = 0x50; // mode 1, 8-bit uart, enable receiver
TMOD= 0x21; //Turn timer 1 mode 2.
TH1 = 0XFA; // for 9600 baud rate 0XFD
void gettingtime()
{
if(i==0x7f)// Waiting for the 011111111 to come in as a start signal.
{
count3=0;
}
if(count3==87)// after recieved the start signal. wait for 0.2 sec to the the 1st digit.
{
dig4=i;
}
if(count3==125) //second digit.
{
dig3=i;
}
if(count3==250) //Third digit
{
dig2=i;
}
if(count3==312) // forth digit
{
dig1=i;
}
}