diff options
Diffstat (limited to 'Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c')
-rw-r--r-- | Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c | 29 |
1 files changed, 19 insertions, 10 deletions
diff --git a/Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c b/Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c index 3f448a983..28348b8e7 100644 --- a/Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c +++ b/Projects/P-NUCLEO-WB55.Nucleo/Examples_LL/PKA/PKA_ModularExponentiation/Src/main.c @@ -9,13 +9,12 @@ ****************************************************************************** * @attention * - * <h2><center>© Copyright (c) 2019 STMicroelectronics. - * All rights reserved.</center></h2> + * Copyright (c) 2019-2021 STMicroelectronics. + * All rights reserved. * - * This software component is licensed by ST under BSD 3-Clause license, - * the "License"; You may not use this file except in compliance with the - * License. You may obtain a copy of the License at: - * opensource.org/licenses/BSD-3-Clause + * This software is licensed under terms that can be found in the LICENSE file + * in the root directory of this software component. + * If no LICENSE file comes with this software, it is provided AS-IS. * ****************************************************************************** */ @@ -54,6 +53,7 @@ uint8_t buffer[256] = {0}; /* Private function prototypes -----------------------------------------------*/ void SystemClock_Config(void); +void PeriphCommonClock_Config(void); static void MX_GPIO_Init(void); static void MX_PKA_Init(void); /* USER CODE BEGIN PFP */ @@ -101,6 +101,9 @@ int main(void) /* Configure the system clock */ SystemClock_Config(); +/* Configure the peripherals common clocks */ + PeriphCommonClock_Config(); + /* USER CODE BEGIN SysInit */ /* USER CODE END SysInit */ @@ -128,7 +131,7 @@ int main(void) while(endOfProcess != 1); endOfProcess = 0; - /* Retreive the result and output buffer */ + /* Retrieve the result and output buffer */ PKA_Memcpy_u32_to_u8(buffer, &PKA->RAM[PKA_MODULAR_EXP_OUT_SM_ALGO_ACC1], rsa_pub_2048_modulus_len / 4); /* Compare to expected results */ @@ -150,7 +153,7 @@ int main(void) while(endOfProcess != 1); endOfProcess = 0; - /* Retreive the result and output buffer */ + /* Retrieve the result and output buffer */ PKA_Memcpy_u32_to_u8(buffer, &PKA->RAM[PKA_MODULAR_EXP_OUT_SM_ALGO_ACC1], rsa_pub_2048_modulus_len / 4); /* Compare to expected results */ @@ -212,6 +215,14 @@ void SystemClock_Config(void) /* Update CMSIS variable (which can be updated also through SystemCoreClockUpdate function) */ LL_SetSystemCoreClock(16000000); +} + +/** + * @brief Peripherals Common Clock Configuration + * @retval None + */ +void PeriphCommonClock_Config(void) +{ /* USER CODE BEGIN Smps */ /* USER CODE END Smps */ @@ -466,5 +477,3 @@ void assert_failed(uint8_t *file, uint32_t line) /* USER CODE END 6 */ } #endif /* USE_FULL_ASSERT */ - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ |