KugleFirmware/Drivers/STM32H7xx_HAL_Driver/Src/stm32h7xx_hal_hsem.c
/**
  * @brief  Release a semaphore. 
  * @param  SemID: semaphore ID from 0 to 31   
  * @param  ProcessID: Process ID from 0 to 255 
  * @retval None
*/
@brief  Release a semaphore.
@param  SemID: semaphore ID from 0 to 31
@param  ProcessID: Process ID from 0 to 255
@retval None
@brief Release a semaphore . @param SemID : semaphore ID from 0 to 31 @param ProcessID : Process ID from 0 to 255 @retval None
void  HAL_HSEM_Release(uint32_t SemID, uint32_t ProcessID)
{  
  assert_param(IS_HSEM_SEMID(SemID));
  assert_param(IS_HSEM_PROCESSID(ProcessID));  
  HSEM->R[SemID] = ((ProcessID & HSEM_R_PROCID) | ((HAL_GetCurrentCPUID() << POSITION_VAL(HSEM_R_MASTERID)) & HSEM_R_MASTERID));
}
void HAL_HSEM_Release ( uint32_t SemID , uint32_t ProcessID ) { assert_param ( IS_HSEM_SEMID ( SemID ) ) ; assert_param ( IS_HSEM_PROCESSID ( ProcessID ) ) ; HSEM -> R [ SemID ] = ( ( ProcessID & HSEM_R_PROCID ) | ( ( HAL_GetCurrentCPUID ( ) << POSITION_VAL ( HSEM_R_MASTERID ) ) & HSEM_R_MASTERID ) ) ; }
@brief  Release a semaphore.
@brief Release a semaphore .
/* Check the parameters */ /* Clear the semaphore by writing to the R register : the MasterID , the processID and take bit = 0  */