EasyManuals Logo

STMicroelectronics STM32WL5 Series User Manual

STMicroelectronics STM32WL5 Series
1450 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #377 background imageLoading...
Page #377 background image
RM0453 Rev 5 377/1450
RM0453 Hardware semaphore (HSEM)
385
Figure 35. Interrupt state diagram
The procedure to get an interrupt when a semaphore becomes free is described hereafter.
Try to lock semaphore x
If the semaphore lock is obtained, no interrupt is needed.
If the semaphore lock fails:
Clear pending semaphore x interrupt status for the interrupt line in HSEM_CnICR.
Re-try to lock the semaphore x again:
If the semaphore lock is obtained, no interrupt is needed (semaphore has been
freed between first try to lock and clear semaphore interrupt status).
If the semaphore lock fails, enable the semaphore x interrupt in HSEM_CnIER.
On semaphore x free interrupt, try to lock semaphore x
If the semaphore lock is obtained:
Disable the semaphore x interrupt in HSEM_CnIER.
Clear pending semaphore x interrupt status in HSEM_CnICR.
If the semaphore x lock fails:
Clear pending semaphore x interrupt status in HSEM_CnICR.
Try again to lock the semaphore x:
If the semaphore lock is obtained (semaphore has been freed between first try to
lock and semaphore interrupt status clear), disable the semaphore interrupt in
HSEM_CnIER.
MS40533V3
Semaphore x
locked
Semaphore x free
WRITE
(COREID & PROCID & LOCK = 0)
Interrupt
Semaphore x
Enabled
Interrupt
Semaphore x
MaskedStatus = 1 & Interrupt generated
Interrupt
Semaphore x
Status = 1
Yes
No

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the STMicroelectronics STM32WL5 Series and is the answer not in the manual?

STMicroelectronics STM32WL5 Series Specifications

General IconGeneral
BrandSTMicroelectronics
ModelSTM32WL5 Series
CategoryMicrocontrollers
LanguageEnglish

Related product manuals