2021-05-23 3:57 AM
Hi,
Using the P NUCLEO WB 55 with STM32WB .
Encountered with below code, regarding HSE tuning, in workshop tutorial.
A reference was given to An5024.
This code does not exist in my example project, BLE Heart Rate RTOS,
generated with STM32Cube 6.2.0 , FW_WB V1.11.0.
Should I add it manually?
Will this benefit my current working environment above?
Code:
/* 1 */
#include "otp.h"
/* 2 */
#warning “Following code is valid only for P-NUCLEO-WB55 boards and should be reimplemented depending on the target HW and HSE capacitor tuning value storage location.“
OTP_ID0_t * p_otp;
/* Read and use HSE_Tuning from OTP */
p_otp = (OTP_ID0_t *) OTP_Read(0);
if (p_otp)
{
LL_RCC_HSE_SetCapacitorTuning(p_otp->hse_tuning);
}Solved! Go to Solution.
2021-05-28 9:35 AM
Hello @Community member ,
yes, you should add this even if it was not in the CubeMX output.
Actually you should also check the relevant examples from the STM32 Cube Package:
Rgds,
Jarda
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2021-05-28 9:35 AM
Hello @Community member ,
yes, you should add this even if it was not in the CubeMX output.
Actually you should also check the relevant examples from the STM32 Cube Package:
Rgds,
Jarda
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
We’re moving the ST Community to a new platform to give you a better and more reliable community experience.