Now check the interrupt vector table of STM8S003 below:
You’ll find this table not in the reference manual but in the device’s datasheet. This table varies with
devices and so be sure of correct datasheet. The DISCO board’s button is connected to PB7 and so
clearly, we will need IRQ4, i.e. EXTI1 or PORTB external interrupts. All external interrupts on GPIOB
pin are masked in this vector address.
Please note that codes that use peripheral interrupts need stm8s_it.h and stm8s_it.c files. Therefore,
add them if you are to use interrupts.