pka.c 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. /**
  2. ******************************************************************************
  3. * @file pka.c
  4. * @brief This file provides code for the configuration
  5. * of the PKA instances.
  6. ******************************************************************************
  7. * @attention
  8. *
  9. * <h2><center>&copy; Copyright (c) 2020 STMicroelectronics.
  10. * All rights reserved.</center></h2>
  11. *
  12. * This software component is licensed by ST under Ultimate Liberty license
  13. * SLA0044, the "License"; You may not use this file except in compliance with
  14. * the License. You may obtain a copy of the License at:
  15. * www.st.com/SLA0044
  16. *
  17. ******************************************************************************
  18. */
  19. /* Includes ------------------------------------------------------------------*/
  20. #include "pka.h"
  21. /* USER CODE BEGIN 0 */
  22. /* USER CODE END 0 */
  23. PKA_HandleTypeDef hpka;
  24. /* PKA init function */
  25. void MX_PKA_Init(void)
  26. {
  27. hpka.Instance = PKA;
  28. if (HAL_PKA_Init(&hpka) != HAL_OK)
  29. {
  30. Error_Handler();
  31. }
  32. }
  33. void HAL_PKA_MspInit(PKA_HandleTypeDef* pkaHandle)
  34. {
  35. if(pkaHandle->Instance==PKA)
  36. {
  37. /* USER CODE BEGIN PKA_MspInit 0 */
  38. /* USER CODE END PKA_MspInit 0 */
  39. /* PKA clock enable */
  40. __HAL_RCC_PKA_CLK_ENABLE();
  41. /* USER CODE BEGIN PKA_MspInit 1 */
  42. /* USER CODE END PKA_MspInit 1 */
  43. }
  44. }
  45. void HAL_PKA_MspDeInit(PKA_HandleTypeDef* pkaHandle)
  46. {
  47. if(pkaHandle->Instance==PKA)
  48. {
  49. /* USER CODE BEGIN PKA_MspDeInit 0 */
  50. /* USER CODE END PKA_MspDeInit 0 */
  51. /* Peripheral clock disable */
  52. __HAL_RCC_PKA_CLK_DISABLE();
  53. /* USER CODE BEGIN PKA_MspDeInit 1 */
  54. /* USER CODE END PKA_MspDeInit 1 */
  55. }
  56. }
  57. /* USER CODE BEGIN 1 */
  58. /* USER CODE END 1 */
  59. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/