1 /* USER CODE BEGIN Header */ 2 /** 3 ****************************************************************************** 4 * @file hw_pka.h 5 * @author GPM WBL Application Team 6 * @brief This file contains all the functions prototypes for PKA stm32wb09 7 ****************************************************************************** 8 * @attention 9 * 10 * Copyright (c) 2024 STMicroelectronics. 11 * All rights reserved. 12 * 13 * This software is licensed under terms that can be found in the LICENSE file 14 * in the root directory of this software component. 15 * If no LICENSE file comes with this software, it is provided AS-IS. 16 * 17 ****************************************************************************** 18 */ 19 /* USER CODE END Header */ 20 21 /* Define to prevent recursive inclusion -------------------------------------*/ 22 #ifndef HW_PKA_H 23 #define HW_PKA_H 24 25 #ifdef __cplusplus 26 extern "C" { 27 #endif 28 29 /* Includes ------------------------------------------------------------------*/ 30 #include <stdint.h> 31 32 /** @defgroup HW_PKA PKA Manager 33 * @{ 34 */ 35 36 /** @defgroup HW_PKA_Exported_Types Exported Types 37 * @{ 38 */ 39 /** 40 * @} 41 */ 42 43 /** @defgroup HW_PKA_Exported_Constants Exported Constants 44 * @{ 45 */ 46 /** 47 * @} 48 */ 49 50 /** @defgroup HW_PKA_Exported_Macros Exported Macros 51 * @{ 52 */ 53 /** 54 * @} 55 */ 56 57 /** @defgroup HW_PKA_Exported_Functions Exported Functions 58 * @{ 59 */ 60 #if defined STM32WB09 61 void HW_PKA_WriteSingleInput( uint32_t index, int size, const uint32_t* word ); 62 #elif defined STM32WB05 63 void HW_PKA_WriteSingleInput( uint32_t index, uint32_t word ); 64 #endif 65 66 #if defined STM32WB09 67 void HW_PKA_ReadSingleOutput( uint32_t index, uint32_t* out); 68 #elif defined STM32WB05 69 uint32_t HW_PKA_ReadSingleOutput( uint32_t index ); 70 #endif /* STM32WB09 elif STM32WB05 */ 71 72 #if defined(STM32WB06) || defined(STM32WB07) 73 ErrorStatus HW_PKA_SetData(uint8_t dataType, uint32_t* srcData); 74 ErrorStatus HW_PKA_GetData(uint8_t dataType, uint8_t* dataTarget); 75 ErrorStatus HW_PKA_VerifyProcess(void); 76 #endif 77 78 void HW_PKA_WriteOperand( uint32_t index, int size, const uint32_t* in ); 79 void HW_PKA_ReadResult( uint32_t index, int size, uint32_t* out ); 80 uint8_t HW_PKA_PowerSaveLevelCheck(void); 81 void HW_PKA_Init(void); 82 void HW_PKA_IRQHandler(void); 83 /** 84 * @} 85 */ 86 87 /** 88 * @} 89 */ 90 91 #ifdef __cplusplus 92 } 93 #endif 94 95 #endif /* HW_PKA_H */ 96