Skip to main content
SalPaz
Associate II
March 9, 2020
Solved

What are the differences begin user begin sections 1 to 4. (Generated by Cube MX, IDE). Which types of codes should be written there and why there is four different (or more) user code begin sections?

  • March 9, 2020
  • 1 reply
  • 3162 views

This just looks like a comment but it seems a code outside these comment have different affect.

/* USER CODE BEGIN 1 */

/* USER CODE END 1 */

This topic has been closed for replies.
Best answer by SalPaz

I have found the answer to myself.

The user code sections that are between two comment lines are dedicated to write the code inside the lines. Anycode written outside of these sections will be removed in case of anychange at CubeIDE interface (*.ioc)

1 reply

SalPaz
SalPazAuthorBest answer
Associate II
May 18, 2020

I have found the answer to myself.

The user code sections that are between two comment lines are dedicated to write the code inside the lines. Anycode written outside of these sections will be removed in case of anychange at CubeIDE interface (*.ioc)