started work on lib/timer; and some housekeeping