improved timer precision (changed the used function)