AnsweredAssumed Answered

STM32CubeMX Bug?

Question asked by renyuan.zheng.001 on Mar 28, 2018
Latest reply on Mar 30, 2018 by renyuan.zheng.001

Keil  5    uVision V5.14.0.0

 

"

void HAL_RTC_MspInit(RTC_HandleTypeDef* rtcHandle)
{

if(rtcHandle->Instance==RTC)
{
/* USER CODE BEGIN RTC_MspInit 0 */

/* USER CODE END RTC_MspInit 0 */
                                                                                                      LL_PWR_EnableBkUpAccess();
/* Enable BKP CLK enable for backup registers */
                                                                                    LL_APB1_GRP1_EnableClock(LL_APB1_GRP1_PERIPH_BKP);
/* RTC clock enable */
__HAL_RCC_RTC_ENABLE();
/* USER CODE BEGIN RTC_MspInit 1 */

/* USER CODE END RTC_MspInit 1 */
}
}

"

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

Build Output:

 

compiling rtc.c...
../Src/rtc.c(100): warning: #223-D: function "LL_PWR_EnableBkUpAccess" declared implicitly
LL_PWR_EnableBkUpAccess();
../Src/rtc.c(102): warning: #223-D: function "LL_APB1_GRP1_EnableClock" declared implicitly
LL_APB1_GRP1_EnableClock(LL_APB1_GRP1_PERIPH_BKP);
../Src/rtc.c(102): error: #20: identifier "LL_APB1_GRP1_PERIPH_BKP" is undefined
LL_APB1_GRP1_EnableClock(LL_APB1_GRP1_PERIPH_BKP);
../Src/rtc.c: 2 warnings, 1 error
compiling stm32f1xx_it.c...

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

 

mm

Attachments

Outcomes