cancel
Showing results for 
Search instead for 
Did you mean: 

CubeMX code generation issue

danielbuga9
Associate III
Posted on September 28, 2017 at 10:00

Using CubeMX with CubeL4 1.9.0, I have the following problem.

I'm using FreeRTOS with tasks defined as either weak, or external (weak is only used because the default task cannot be external for whatever reason). My weak ApplicationTask is generated as follows:

/* ApplicationTask function */

__weak void ApplicationTask(void const * argument)

{

  /* init code for USB_DEVICE */

  MX_USB_DEVICE_Init();

  /* USER CODE BEGIN ApplicationTask */

  /* Infinite loop */

  for(;;)

  {

    osDelay(1);

  }

  /* USER CODE END ApplicationTask */

}

/* USER CODE BEGIN Application */

  /* Infinite loop */

  for(;;)

  {

    osDelay(1);

  }

/* USER CODE END Application */

Notice the user code segment named Application after the actual function. This causes the generated code to not compile without deleting this 'surplus' block.

2 REPLIES 2
stm32cube-t
Senior III
Posted on October 19, 2017 at 11:39

Dear user,

This issue will be fixed in our next release 4.23.

Best regards.

Posted on November 30, 2017 at 09:10

Hello,

Just for reference, this issue was NOT fixed in 4.23.

Thanks