timer.c from aries