added timer.c and modified timer.h