cancel
Showing results for 
Search instead for 
Did you mean: 

RCC_CSR resgister libary not found on my cube generated project stm32f103cb

TARHAN SAMAH
Senior

hello i try to read registers RCC_CSR with FlagStatusRCC_GetFlagStatus (uint8_t RCC_FLAG)

but my project generated by cubemx doesnt recognize this function ,

is there an option i didnt open on cube mx , or should i download a folder ,

because i couşdn find

STM32F10x Standard Peripherals Library 3.5.0 on my project

thanks

1 ACCEPTED SOLUTION

Accepted Solutions
TARHAN SAMAH
Senior

thanks ,,

i got my registers 🙂

if(__HAL_RCC_GET_FLAG(RCC_FLAG_SFTRST))

{

//printf("\r\n software reset");

}

else if(__HAL_RCC_GET_FLAG(RCC_FLAG_PORRST))

{

//printf("\r\n power reset");

lcd_init();

}

else if(__HAL_RCC_GET_FLAG(RCC_FLAG_PINRST))

{

  //printf("\r\n pin reset");

}

else { /*printf("\r\n unknown reset ");*/  }

//// The flags must be cleared manually after use

__HAL_RCC_CLEAR_RESET_FLAGS();

it works good

View solution in original post

2 REPLIES 2
Amel NASRI
ST Employee

Hi @TARHAN SAMAH​ ,

Standard Peripheral Library isn't supported by CubeMX; It is a different development approach than the Cube.

So, you cannot use it with CubeMX or merge code based on SPL and Cube on the same project.

-Amel

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.

TARHAN SAMAH
Senior

thanks ,,

i got my registers 🙂

if(__HAL_RCC_GET_FLAG(RCC_FLAG_SFTRST))

{

//printf("\r\n software reset");

}

else if(__HAL_RCC_GET_FLAG(RCC_FLAG_PORRST))

{

//printf("\r\n power reset");

lcd_init();

}

else if(__HAL_RCC_GET_FLAG(RCC_FLAG_PINRST))

{

  //printf("\r\n pin reset");

}

else { /*printf("\r\n unknown reset ");*/  }

//// The flags must be cleared manually after use

__HAL_RCC_CLEAR_RESET_FLAGS();

it works good