Question: what is the difference between a subroutine and an interrupt-service routine?
Answer: The big difference is that you know where the subroutine runs (because you call it). ... Simply, a subroutine is code you write and call as required, an interrupt is system bound and cannot be called by the user but occurs when something happens (sources are hardware, software and CPU) that requires immediate attention.