added mutex to timer