Reset timer interrupt when writing to compare register