micro-ROS / micro-ROS/micro_ros_setup
Continuous Serialization and Image Data Streaming
- 主要言語
- Shell
- スター
- 509
- フォーク
- 183
- 平均マージ
- 22時間 26分
- マージ済み PR(30日)
- 7
説明
## Issue template
- Hardware description: [MAX78000](https://www.analog.com/en/products/max78000.html) / Custom board
- RTOS: FreeRTOS
- Installation type: micro_ros_setup / custom static library
- Version or commit hash: Humble
Hello - I'm an engineer with Analog Devices and I've been working on micro-ros support for our microcontrollers, starting with our embedded AI micros. I've completed the port and custom transports following the excellent tutorials, so first off thank you for the great documentation and project. I would eventually like to open a PR with official part support for our [MSDK](https://analog-devices-msdk.github.io/msdk/USERGUIDE/) microcontrollers, and I'm building up a cool demo using an OpenManipulator-X running some custom object detection on our MAX78000.
Let me know if there's a better channel/repo to go through for questions. I couldn't get the Slack channel invite to work.
My current challenge is related to the topic of continuous serialization mentioned in the bottom part of [this](https://micro.ros.org/docs/tutorials/programming_rcl_rclc/micro-ROS/) tutorials page.
I'm currently publishing a `sensor_msgs/image` image successfully, but the transmissions are very slow since the message is broken up into many packets. I would like some way to continuously stream the image data instead, but still comply with the expected message framing protocol. So...
1. Is "continuous serialization" what I'm looking for?
2. The tutorial says the [ping_uros_agent](https://github.com/micro-ROS/micro-ROS-demos/blob/iron/rclc/ping_uros_agent/main.c) example shows an example for continuous serialization of image data, but I don't see it. Are there any examples for this?
3. I can sort of guess at what the APIs do based on the tutorial, but the API documentation for the `microcdr` and `continuous_serialization` modules are somewhat limited. I'm confused about what the `ucdr_alignment` functions do, and also whether it's possible stream image data row by row from the serialization callback. In the given example does writing into the ucdr buffer push the data out into the transport layer?
```C
// Implementation example:
void serialization_cb(ucdrBuffer * ucdr){
size_t len = 0;
micro_ros_fragment_t fragment;
// Serialize array size
ucdr_serialize_uint32_t(ucdr, IMAGE_BYTES);
while(len < IMAGE_BYTES){
// Wait for new image "fragment"
...
// Serialize data fragment
ucdr_serialize_array_uint8_t(ucdr, fragment.data, fragment.len); // <-- (JC): Does this go out to the transport layer?...
len += fragment.len;
}
} // ... or is the data finally sent here, when the callback returns?
```
I also have some more general suggestions/questions related to some challenges I had in developing the custom transports, and would love to contribute back to the project in any way I can.
Thank you,
Jake
コントリビューションガイド
調査の方向性
micro-ROSプログラミングチュートリアルの連続シリアライゼーションのセクションから始め、rclc/ping_uros_agent/main.cと比較してから、microcdrとcontinuous_serializationのAPIドキュメントを確認してください。バッファーとトランスポートの動作を文書化し、ucdr_alignmentを説明し、動作する画像ストリーミングの例を追加するか参照先を示せば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- c
- 領域
- embedded-iot, networking
- issue の種類
- ドキュメント
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 22/100