add time counter.