micro-ROS / micro-ROS/micro_ros_platformio

Deserialization errors and eventual micro-ROS agent crash with best-effort publishers.

オープン
#167 コメント 6 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
Python
スター
334
フォーク
111
PR マージ指標
30日以内にマージされた PR はありません

説明

## Issue template

- Hardware description: Arduino Portenta H7
- RTOS: Mbed OS
- Installation type: PlatformIO
- Version or commit hash: Galactic, Humble (I've tried both)

#### Steps to reproduce the issue
I am running micro-ROS on an Arduino Portenta H7, communicating via UDP with a computer running ROS2. I've been testing with both Galactic and Humble (two different systems, one running Ubuntu 20 and the other 22).

I have four publishers in micro-ROS, each publishing a custom message (containing a builtin_interfaces/Time, a uint8, and two float32s) at 100 Hz using best effort QoS. I also have one publisher publishing a custom message (a builtin_interfaces/Time, and a uint8) at 1 Hz.

After the micro-ROS agent is started, communication works for some time, but deserialization errors start to appear, mostly:

```
[1736739981.033497] error | InputMessage.cpp | log_error | deserialization error | buffer:
0000: 00 00 00 00 00 00
```

and occasionally:

```
[1734728823.613239] error | InputMessage.cpp | log_error | deserialization error | buffer:
0000: 81 01 49 12 07 01 1F 00 12 AD 00 A5 3E ED 65 67 D3 90 66 22 00 00 00 01 00 00 00 00 00 00 00 00
[1734728823.615098] error | Processor.cpp | process_write_data_submessage | deserialization error processing WRITE_DATA submessage | client_key: 0x16BCCD79
```

Messages continue to publish successfully at around 100 Hz, but eventually the micro-ROS agent crashes with the following message:

```
terminate called after throwing an instance of 'eprosima::fastcdr::exception::BadParamException'
what(): Unexpected byte value in Cdr::deserialize(bool), expected 0 or 1
```

Sometimes it takes a while to crash, and other times it only takes a few minutes. I've also tried publishing with reliable QoS. In that case, the micro-ROS agent doesn't crash or have deserialization errors (at least not as quickly), but each topic is only published at about 1 Hz.

#### Expected behavior
The micro-ROS agent runs indefinitely with no deserialization errors and doesn't crash.

#### Actual behavior
Deserialization errors and crash.

Thanks!

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

まず、Arduino Portenta H7、micro-ROS agent、UDP トランスポート、カスタムメッセージ、および指定されたレートの best-effort publisher を使って問題を再現します。Fast CDR BadParamException を含め、InputMessage.cpp と Processor.cpp で報告されているデシリアライズパスを調査します。publisher が期待されるレートを維持している間、エージェントがデシリアライズエラーやクラッシュなしで無期限に動作すれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
arduino
領域
embedded-iot, networking
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
38/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。