2019-11-18 08:14 AM
Hi,
I want to deactivate all interrupts during a short period.
I'm using
__disable_irq();
however, it says, that this can only be used in privilege mode. If I use this function my board crashes. I want to look up the privilege level, but the RM at page 3055 is not clear enough, how I can access those bits. can someone please help.
2019-11-18 08:25 AM
Perhaps ST's Programming Manual would be a better source, or even ARM's Technical Reference Manual?
Look at how some of the RTOS (FreeRTOS or CMSIS RTOS, or whatever) manage such things, or perhaps better yet semaphore/mutex methods of protecting stuff and arbitrating access to resources.