implemented interrupts for control