Added preemtive removal of update flags before setting up interrupts.