@@ -80,7 +80,7 @@ In the `core/stage_1_boot.cpp` file of your board (located in `miosix-kernel/mio
To do this you will have to write the following code, which contains some magic related to [GCC name mangling](https://en.wikipedia.org/wiki/Name_mangling), in a `.cpp` file.
> :warning: **RESET THE INTERRUPT PENDING BIT REGISTER in your IRQHandler, otherwise you will enter an infinite loop.**
> :warning: **RESET THE INTERRUPT PENDING BIT REGISTER in your IRQHandler, otherwise you will enter an infinite loop. This is because otherwise the interrupt would remain in ```pending``` state and triggered again and again and again....and again...**
> :warning: **DON'T USE BLOCKING OR "HEAVY" FUNCTIONS (e.g. *printf()*) inside your interrupt. Remember that the CPU will stall for the whole time it will execute your IRQHandler. Most of the times, the only thing you will need in your IRQHandler is to set a global variable or to operate with registers.**
> :warning: **RESET THE INTERRUPT PENDING BIT REGISTER in your IRQHandler, otherwise you will enter an infinite loop. Consider that pending bits are ```rc_w1``` bits, which means that in order to reset them you have to write 1, not 0. In this case an OR operation cannot be used : if the current pending register (PR) value is ```0101``` and we want to reset the least significant bit we would do ```0101 OR 0001```. The result of the operation is still ```0101```, but writing ```0101``` to the PR register would reset both the bits that where set to 1, not only the bit we were interested into!!! Resetting pending bits just requires and assignment operation using the provided macros.**
## References
*[RM0090, Reference Manual - Section 9, System Configuration Controller](https://www.st.com/resource/en/reference_manual/dm00031020-stm32f405-415-stm32f407-417-stm32f427-437-and-stm32f429-439-advanced-arm-based-32-bit-mcus-stmicroelectronics.pdf)