micro_ros_stm32cubemx_utils icon indicating copy to clipboard operation
micro_ros_stm32cubemx_utils copied to clipboard

not create rclc_support_init(&support, 0, NULL, &allocator);

Open guillehb21 opened this issue 1 year ago • 3 comments

Hello there , I have a problem when creating nodes, they are not being created or I don't know what could be happening. It's the first time I'm using ROS2 on a microcontroller. I tried using debugging to find the issue. In debug mode, the program runs fine until this line: image . If I click on the next step, it jumps to a file called "task" and goes into a loop. image I don't know what might be happening. My "agente_ws" looks like this: image . The code is the same as the example, and I don't know what could be happening. Thank you very much in advance. I'm using ROS2 Iron, and the board is an STM32 Nucleo H743ZI2.

guillehb21 avatar Jul 14 '23 17:07 guillehb21

Hi, I have not so much experience but certainly the rclc_support_init() function seems to have serious problems at least on STM32 devices. Is the function called inside a task? If so, make sure you have at least 3000 words heap for this task. I assume that looping in prvCheckTasksWaitingTermination() is caused because you rclc_support_init() function does not run as expected and hangs in an endless loop. Your FreeRTOS takes over and is continously updating all other resources. So that is nothing special from my point of view.

Best Regards Markus

DrMarkusKrug avatar Aug 01 '23 07:08 DrMarkusKrug