Added timer code

Added timer code