micro-ROS / rmw_microxrcedds

RMW implementation using Micro XRCE-DDS middleware.
Apache License 2.0
30 stars 23 forks source link

High CPU usage with int32_publisher #297

Open yashi opened 1 year ago

yashi commented 1 year ago

Describe the bug Having only timers on an executor makes rmw_wait() to spin without blocking. This causes high cpu usage and it's a problem on a RTOS with threading support.

To Reproduce Just build int32_publisher from micro-ROS-demos.

Expected behaviour rclc_executor_spin() should always be a blocking call without any service, client, subscription, or timer.

System information (please complete the following information):

Additional context https://micro-ros.slack.com/archives/CNC141G0N/p1684752941054099

Acuadros95 commented 11 months ago

This is resolved by https://github.com/micro-ROS/rmw_microxrcedds/pull/305, please close when merged

yashi commented 11 months ago

Thanks for you PR.

BTW, if you have "Resolves #297" in the description of #305, this will be closed when merged. https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword