teach-ict.com logo

THE education site for computer science and ICT

3. Interrupt

There is another way to get the CPU to react to events in a timely manner. Rather than having the CPU ask whether it needs to jump in and do something, the CPU is told directly to stop what it's doing and perform a specific task. This is called an 'interrupt'.


Interrupt is a signal for the CPU to stop what it is doing and instead carry out the interrupt task. Once the task is complete, the CPU goes back to what it was doing.

The CPU is running its current program and an interrupt arrives. The interrupt comes with a 'priority' label, telling the CPU how important the task is. If the interrupt has a higher priority than the current process, the CPU will suspend its task and jump to the related 'interrupt service routine' (ISR) - the task that the interrupt is asking the CPU to carry out. This is shown below.

Interrupt Service Routine

Once the interrupt task is complete, the CPU jumps back to the point in the program where the interrupt event occurred.


Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: What is software polling