Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Flipper-Zero/STM32CubeWB.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h')
-rw-r--r--Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h b/Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h
index f41e03a02..2e6c61a17 100644
--- a/Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h
+++ b/Drivers/STM32WBxx_HAL_Driver/Inc/stm32wbxx_hal_flash_ex.h
@@ -49,11 +49,37 @@ extern "C" {
/**
* @}
*/
+
+
+/** @defgroup FLASHEx_ECC_CPUID FLASHEx ECC CPU Identification
+ * @{
+ */
+#define FLASH_ECC_CPUID_1 0x00000000U /*!< Bus-ID of the CPU1 access causing the ECC failure. */
+#define FLASH_ECC_CPUID_2 FLASH_ECCR_CPUID_0 /*!< Bus-ID of the CPU2 access causing the ECC failure. */
+
+/**
+ * @}
+ */
/**
* @}
*/
/* Exported macro ------------------------------------------------------------*/
+/** @defgroup FLASH_ECC FLASH ECC Macros
+ * @brief macros to get Error Code Correction informations
+ * @{
+ */
+
+/**
+ * @brief Get the Bus-ID of the CPU access causing the ECC failure
+ * @retval CPUID
+ */
+#define __HAL_FLASH_ECC_CPUID() READ_BIT(FLASH->ECCR, FLASH_ECCR_CPUID)
+
+/**
+ * @}
+ */
+
/* Exported functions --------------------------------------------------------*/
/** @addtogroup FLASHEx_Exported_Functions
* @{