
void main(void)
{
    
/*----------setup interrupts-----------*/
    EA=1;    // enable interrupts
    ET1=1;    // Enable the Timer 1 overflow interrupt
/*-------------------------------------*/
/*----------- setup timers -------------*/
    TMOD=0x10|0x01;    // timer 1 & 0 both in mode 1, 16 bit timer
    
    TH1 = SOFT_RTC_TH1_RELOAD;            //50ms with 11.0592 MHz
    TL1 = SOFT_RTC_TL1_RELOAD;            //will be 49.9664 ms for (76,31)
/*-------------------------------------*/

    TR1    = 1;                //run software RTC

    LCD_init();
    UART_init();

    while(1)
    {   .
        .  //other stuff 
        keyboard_handler();
        .
        .
    }    // while(1)
}    // main()