micro-ROS / micro-ROS/micro_ros_setup

When ros2 creates a new topic, the CPU usage is high

未关闭
#757 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
Shell
星标
509
派生
183
平均合并
22 小时 26 分钟
30 天内合并 PR
7

描述

- Hardware description: N/A
- RTOS: Freertos
- Installation type: micro_ros_setup
- Version or commit hash: humble

Steps to reproduce the issue
1. Start micro_ros_agent through ros2 launch;
2. htop -p `pidof micro_ros_agent` to check the change of CPU usage
3. Publish a message through ros2 topic pub /avoidance_status std_msgs/msg/UInt8 "{data: 0}", and you will find that the CPU usage soars from 7% to 30%, and then falls back to a stable state of 7%;
4. Create a publishing topic through rclcpp, only create it once, send at 20hz frequency for 30s, stop for 3min, and then send again..., the CPU usage only changes when starting the node, and there is no fluctuation during the middle operation.

Is there any way to solve this problem? If the CPU is insufficient, the main controller will not be able to run.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

通过 ros2 launch 启动 micro_ros_agent,使用 htop 监控其进程,并使用所示的 ros2 topic pub 命令创建 topic,以复现该报告。将 CPU 峰值与 rclcpp 发布的情况进行比较,并跟踪 micro_ros_agent 中的 topic 创建路径。确定原因且创建 topic 不再导致报告中所述的过高 CPU 使用率,即视为完成。

由索引模型根据 Issue 内容生成。

评估

领域
embedded-iot, performance, robotics
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
需要澄清
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。