updated timer.c