RTEMS 6.1-rc5
Loading...
Searching...
No Matches
Macros

Macros

#define __HAL_FLASH_SET_LATENCY(__LATENCY__)    MODIFY_REG(FLASH->ACR, FLASH_ACR_LATENCY, (uint32_t)(__LATENCY__))
 Set the FLASH Latency.
 
#define __HAL_FLASH_GET_LATENCY()   (READ_BIT((FLASH->ACR), FLASH_ACR_LATENCY))
 Get the FLASH Latency.
 
#define __HAL_FLASH_ENABLE_IT_BANK1(__INTERRUPT__)   (FLASH->CR1 |= (__INTERRUPT__))
 Enable the specified FLASH interrupt.
 
#define __HAL_FLASH_ENABLE_IT_BANK2(__INTERRUPT__)   (FLASH->CR2 |= ((__INTERRUPT__) & 0x7FFFFFFFU))
 
#define __HAL_FLASH_ENABLE_IT(__INTERRUPT__)   __HAL_FLASH_ENABLE_IT_BANK1(__INTERRUPT__)
 
#define __HAL_FLASH_DISABLE_IT_BANK1(__INTERRUPT__)   (FLASH->CR1 &= ~(uint32_t)(__INTERRUPT__))
 Disable the specified FLASH interrupt.
 
#define __HAL_FLASH_DISABLE_IT_BANK2(__INTERRUPT__)   (FLASH->CR2 &= ~(uint32_t)((__INTERRUPT__) & 0x7FFFFFFFU))
 
#define __HAL_FLASH_DISABLE_IT(__INTERRUPT__)   __HAL_FLASH_DISABLE_IT_BANK1(__INTERRUPT__)
 
#define __HAL_FLASH_GET_FLAG_BANK1(__FLAG__)   (READ_BIT(FLASH->SR1, (__FLAG__)) == (__FLAG__))
 Checks whether the specified FLASH flag is set or not.
 
#define __HAL_FLASH_GET_FLAG_BANK2(__FLAG__)   (READ_BIT(FLASH->SR2, ((__FLAG__) & 0x7FFFFFFFU)) == (((__FLAG__) & 0x7FFFFFFFU)))
 
#define __HAL_FLASH_GET_FLAG(__FLAG__)   __HAL_FLASH_GET_FLAG_BANK1(__FLAG__)
 
#define __HAL_FLASH_CLEAR_FLAG_BANK1(__FLAG__)   WRITE_REG(FLASH->CCR1, (__FLAG__))
 Clear the specified FLASH flag.
 
#define __HAL_FLASH_CLEAR_FLAG_BANK2(__FLAG__)   WRITE_REG(FLASH->CCR2, ((__FLAG__) & 0x7FFFFFFFU))
 
#define __HAL_FLASH_CLEAR_FLAG(__FLAG__)   __HAL_FLASH_CLEAR_FLAG_BANK1(__FLAG__)
 

Detailed Description

Macro Definition Documentation

◆ __HAL_FLASH_CLEAR_FLAG_BANK1

#define __HAL_FLASH_CLEAR_FLAG_BANK1 (   __FLAG__)    WRITE_REG(FLASH->CCR1, (__FLAG__))

Clear the specified FLASH flag.

Parameters
__FLAG__specifies the FLASH flags to clear. In case of Bank 1, this parameter can be any combination of the following values:
  • FLASH_FLAG_EOP_BANK1 : End Of Program on Bank 1 flag
  • FLASH_FLAG_WRPERR_BANK1 : Write Protection Error on Bank 1 flag
  • FLASH_FLAG_PGSERR_BANK1 : Program Sequence Error on Bank 1 flag
  • FLASH_FLAG_STRBER_BANK1 : Program Alignment Error on Bank 1 flag
  • FLASH_FLAG_INCERR_BANK1 : Inconsistency Error on Bank 1 flag
  • FLASH_FLAG_OPERR_BANK1 : Operation Error on Bank 1 flag
  • FLASH_FLAG_RDPERR_BANK1 : Read Protection Error on Bank 1 flag
  • FLASH_FLAG_RDSERR_BANK1 : Read secure Error on Bank 1 flag
  • FLASH_FLAG_SNECCE_BANK1 : Single ECC Error Correction on Bank 1 flag
  • FLASH_FLAG_DBECCE_BANK1 : Double Detection ECC Error on Bank 1 flag
  • FLASH_FLAG_CRCEND_BANK1 : CRC End on Bank 1 flag
  • FLASH_FLAG_CRCRDERR_BANK1 : CRC Read error on Bank 1 flag
  • FLASH_FLAG_ALL_ERRORS_BANK1 : All Bank 1 error flags
  • FLASH_FLAG_ALL_BANK1 : All Bank 1 flags
In case of Bank 2, this parameter can be any combination of the following values :
  • FLASH_FLAG_EOP_BANK2 : End Of Program on Bank 2 flag
  • FLASH_FLAG_WRPERR_BANK2 : Write Protection Error on Bank 2 flag
  • FLASH_FLAG_PGSERR_BANK2 : Program Sequence Error on Bank 2 flag
  • FLASH_FLAG_STRBER_BANK2 : Program Alignment Error on Bank 2 flag
  • FLASH_FLAG_INCERR_BANK2 : Inconsistency Error on Bank 2 flag
  • FLASH_FLAG_OPERR_BANK2 : Operation Error on Bank 2 flag
  • FLASH_FLAG_RDPERR_BANK2 : Read Protection Error on Bank 2 flag
  • FLASH_FLAG_RDSERR_BANK2 : Read secure Error on Bank 2 flag
  • FLASH_FLAG_SNECCE_BANK2 : Single ECC Error Correction on Bank 2 flag
  • FLASH_FLAG_DBECCE_BANK2 : Double Detection ECC Error on Bank 2 flag
  • FLASH_FLAG_CRCEND_BANK2 : CRC End on Bank 2 flag
  • FLASH_FLAG_CRCRDERR_BANK2 : CRC Read error on Bank 2 flag
  • FLASH_FLAG_ALL_ERRORS_BANK2 : All Bank 2 error flags
  • FLASH_FLAG_ALL_BANK2 : All Bank 2 flags
Return values
none

◆ __HAL_FLASH_DISABLE_IT_BANK1

#define __HAL_FLASH_DISABLE_IT_BANK1 (   __INTERRUPT__)    (FLASH->CR1 &= ~(uint32_t)(__INTERRUPT__))

Disable the specified FLASH interrupt.

Parameters
__INTERRUPT__: FLASH interrupt In case of Bank 1 This parameter can be any combination of the following values:
  • FLASH_IT_EOP_BANK1 : End of FLASH Bank 1 Operation Interrupt source
  • FLASH_IT_WRPERR_BANK1 : Write Protection Error on Bank 1 Interrupt source
  • FLASH_IT_PGSERR_BANK1 : Program Sequence Error on Bank 1 Interrupt source
  • FLASH_IT_STRBERR_BANK1 : Strobe Error on Bank 1 Interrupt source
  • FLASH_IT_INCERR_BANK1 : Inconsistency Error on Bank 1 Interrupt source
  • FLASH_IT_OPERR_BANK1 : Operation Error on Bank 1 Interrupt source
  • FLASH_IT_RDPERR_BANK1 : Read protection Error on Bank 1 Interrupt source
  • FLASH_IT_RDSERR_BANK1 : Read secure Error on Bank 1 Interrupt source
  • FLASH_IT_SNECCERR_BANK1 : Single ECC Error Correction on Bank 1 Interrupt source
  • FLASH_IT_DBECCERR_BANK1 : Double Detection ECC Error on Bank 1 Interrupt source
  • FLASH_IT_CRCEND_BANK1 : CRC End on Bank 1 Interrupt source
  • FLASH_IT_CRCRDERR_BANK1 : CRC Read error on Bank 1 Interrupt source
  • FLASH_IT_ALL_BANK1 : All Bank 1 Interrupt sources
In case of Bank 2, this parameter can be any combination of the following values:
  • FLASH_IT_EOP_BANK2 : End of FLASH Bank 2 Operation Interrupt source
  • FLASH_IT_WRPERR_BANK2 : Write Protection Error on Bank 2 Interrupt source
  • FLASH_IT_PGSERR_BANK2 : Program Sequence Error on Bank 2 Interrupt source
  • FLASH_IT_STRBERR_BANK2 : Strobe Error on Bank 2 Interrupt source
  • FLASH_IT_INCERR_BANK2 : Inconsistency Error on Bank 2 Interrupt source
  • FLASH_IT_OPERR_BANK2 : Operation Error on Bank 2 Interrupt source
  • FLASH_IT_RDPERR_BANK2 : Read protection Error on Bank 2 Interrupt source
  • FLASH_IT_RDSERR_BANK2 : Read secure Error on Bank 2 Interrupt source
  • FLASH_IT_SNECCERR_BANK2 : Single ECC Error Correction on Bank 2 Interrupt source
  • FLASH_IT_DBECCERR_BANK2 : Double Detection ECC Error on Bank 2 Interrupt source
  • FLASH_IT_CRCEND_BANK2 : CRC End on Bank 2 Interrupt source
  • FLASH_IT_CRCRDERR_BANK2 : CRC Read error on Bank 2 Interrupt source
  • FLASH_IT_ALL_BANK2 : All Bank 2 Interrupt sources
Return values
none

◆ __HAL_FLASH_ENABLE_IT_BANK1

#define __HAL_FLASH_ENABLE_IT_BANK1 (   __INTERRUPT__)    (FLASH->CR1 |= (__INTERRUPT__))

Enable the specified FLASH interrupt.

Parameters
__INTERRUPT__: FLASH interrupt In case of Bank 1 This parameter can be any combination of the following values:
  • FLASH_IT_EOP_BANK1 : End of FLASH Bank 1 Operation Interrupt source
  • FLASH_IT_WRPERR_BANK1 : Write Protection Error on Bank 1 Interrupt source
  • FLASH_IT_PGSERR_BANK1 : Program Sequence Error on Bank 1 Interrupt source
  • FLASH_IT_STRBERR_BANK1 : Strobe Error on Bank 1 Interrupt source
  • FLASH_IT_INCERR_BANK1 : Inconsistency Error on Bank 1 Interrupt source
  • FLASH_IT_OPERR_BANK1 : Operation Error on Bank 1 Interrupt source
  • FLASH_IT_RDPERR_BANK1 : Read protection Error on Bank 1 Interrupt source
  • FLASH_IT_RDSERR_BANK1 : Read secure Error on Bank 1 Interrupt source
  • FLASH_IT_SNECCERR_BANK1 : Single ECC Error Correction on Bank 1 Interrupt source
  • FLASH_IT_DBECCERR_BANK1 : Double Detection ECC Error on Bank 1 Interrupt source
  • FLASH_IT_CRCEND_BANK1 : CRC End on Bank 1 Interrupt source
  • FLASH_IT_CRCRDERR_BANK1 : CRC Read error on Bank 1 Interrupt source
  • FLASH_IT_ALL_BANK1 : All Bank 1 Interrupt sources
In case of Bank 2, this parameter can be any combination of the following values:
  • FLASH_IT_EOP_BANK2 : End of FLASH Bank 2 Operation Interrupt source
  • FLASH_IT_WRPERR_BANK2 : Write Protection Error on Bank 2 Interrupt source
  • FLASH_IT_PGSERR_BANK2 : Program Sequence Error on Bank 2 Interrupt source
  • FLASH_IT_STRBERR_BANK2 : Strobe Error on Bank 2 Interrupt source
  • FLASH_IT_INCERR_BANK2 : Inconsistency Error on Bank 2 Interrupt source
  • FLASH_IT_OPERR_BANK2 : Operation Error on Bank 2 Interrupt source
  • FLASH_IT_RDPERR_BANK2 : Read protection Error on Bank 2 Interrupt source
  • FLASH_IT_RDSERR_BANK2 : Read secure Error on Bank 2 Interrupt source
  • FLASH_IT_SNECCERR_BANK2 : Single ECC Error Correction on Bank 2 Interrupt source
  • FLASH_IT_DBECCERR_BANK2 : Double Detection ECC Error on Bank 2 Interrupt source
  • FLASH_IT_CRCEND_BANK2 : CRC End on Bank 2 Interrupt source
  • FLASH_IT_CRCRDERR_BANK2 : CRC Read error on Bank 2 Interrupt source
  • FLASH_IT_ALL_BANK2 : All Bank 2 Interrupt sources
Return values
none

◆ __HAL_FLASH_GET_FLAG_BANK1

#define __HAL_FLASH_GET_FLAG_BANK1 (   __FLAG__)    (READ_BIT(FLASH->SR1, (__FLAG__)) == (__FLAG__))

Checks whether the specified FLASH flag is set or not.

Parameters
__FLAG__specifies the FLASH flag to check. In case of Bank 1 This parameter can be one of the following values :
  • FLASH_FLAG_BSY_BANK1 : FLASH Bank 1 Busy flag
  • FLASH_FLAG_WBNE_BANK1 : Write Buffer Not Empty on Bank 1 flag
  • FLASH_FLAG_QW_BANK1 : Wait Queue on Bank 1 flag
  • FLASH_FLAG_CRC_BUSY_BANK1 : CRC module is working on Bank 1 flag
  • FLASH_FLAG_EOP_BANK1 : End Of Program on Bank 1 flag
  • FLASH_FLAG_WRPERR_BANK1 : Write Protection Error on Bank 1 flag
  • FLASH_FLAG_PGSERR_BANK1 : Program Sequence Error on Bank 1 flag
  • FLASH_FLAG_STRBER_BANK1 : Program Alignment Error on Bank 1 flag
  • FLASH_FLAG_INCERR_BANK1 : Inconsistency Error on Bank 1 flag
  • FLASH_FLAG_OPERR_BANK1 : Operation Error on Bank 1 flag
  • FLASH_FLAG_RDPERR_BANK1 : Read Protection Error on Bank 1 flag
  • FLASH_FLAG_RDSERR_BANK1 : Read secure Error on Bank 1 flag
  • FLASH_FLAG_SNECCE_BANK1 : Single ECC Error Correction on Bank 1 flag
  • FLASH_FLAG_DBECCE_BANK1 : Double Detection ECC Error on Bank 1 flag
  • FLASH_FLAG_CRCEND_BANK1 : CRC End on Bank 1 flag
  • FLASH_FLAG_CRCRDERR_BANK1 : CRC Read error on Bank 1 flag
In case of Bank 2 This parameter can be one of the following values :
  • FLASH_FLAG_BSY_BANK2 : FLASH Bank 2 Busy flag
  • FLASH_FLAG_WBNE_BANK2 : Write Buffer Not Empty on Bank 2 flag
  • FLASH_FLAG_QW_BANK2 : Wait Queue on Bank 2 flag
  • FLASH_FLAG_CRC_BUSY_BANK2 : CRC module is working on Bank 2 flag
  • FLASH_FLAG_EOP_BANK2 : End Of Program on Bank 2 flag
  • FLASH_FLAG_WRPERR_BANK2 : Write Protection Error on Bank 2 flag
  • FLASH_FLAG_PGSERR_BANK2 : Program Sequence Error on Bank 2 flag
  • FLASH_FLAG_STRBER_BANK2 : Program Alignment Error on Bank 2 flag
  • FLASH_FLAG_INCERR_BANK2 : Inconsistency Error on Bank 2 flag
  • FLASH_FLAG_OPERR_BANK2 : Operation Error on Bank 2 flag
  • FLASH_FLAG_RDPERR_BANK2 : Read Protection Error on Bank 2 flag
  • FLASH_FLAG_RDSERR_BANK2 : Read secure Error on Bank 2 flag
  • FLASH_FLAG_SNECCE_BANK2 : Single ECC Error Correction on Bank 2 flag
  • FLASH_FLAG_DBECCE_BANK2 : Double Detection ECC Error on Bank 2 flag
  • FLASH_FLAG_CRCEND_BANK2 : CRC End on Bank 2 flag
  • FLASH_FLAG_CRCRDERR_BANK2 : CRC Read error on Bank 2 flag
Return values
Thenew state of FLASH_FLAG (SET or RESET).

◆ __HAL_FLASH_GET_LATENCY

#define __HAL_FLASH_GET_LATENCY ( )    (READ_BIT((FLASH->ACR), FLASH_ACR_LATENCY))

Get the FLASH Latency.

Return values
FLASHLatency The value of this parameter depend on device used within the same series

◆ __HAL_FLASH_SET_LATENCY

#define __HAL_FLASH_SET_LATENCY (   __LATENCY__)     MODIFY_REG(FLASH->ACR, FLASH_ACR_LATENCY, (uint32_t)(__LATENCY__))

Set the FLASH Latency.

Parameters
__LATENCY__FLASH Latency The value of this parameter depend on device used within the same series
Return values
none