added sleep to timer