title: STM32CubeMx: How to add your own "USER CODE BEGIN / END" section?
body: <p>I have a project where I need to add a few lines to one of the generated C files. However, the place where I want to add the change does not have a "USER CODE BEGIN / END" section. So whenever, I regenerate code, the changes are overwritten. I tried adding my own user code section as shown  below but even that got overwritten. It seems, CubeMX is looks for a predefined set of USER CODE blocks, and overwrites everything else. </p>
  
  <pre><code>/* USER CODE BEGIN 8 */
  
  /* USER CODE END 8 */
  </code></pre>
  
  <p>I would like to be able to define my own user code blocks so that I can write custom code in places where CubeMX has not already provided a user code block.</p>