2023年9月7日木曜日

Eclipse eCALを動かしてみる

Eclipse eCALを動かしてみる

eCALとは

eCAL
とはEclipse SDV Projectの1プロジェクト。

ハイパフォーマンスでスケーラブルなpub/subミドルウェア。
マルチプラットフォームサポート(Windows/Linux)

付属アプリケーションとして以下が提供されている。

  • Monitor
  • Recorder
  • Player

以下プロトコルをサポート

  • Google Protobuf
  • CapnProto
  • Flatbuffers

ROS2と接続できるようにRMW(ROSMiddleWare)をサポート

やったこと

  • eCALの環境構築。
  • 同一コンテナ内でProtobufでPub/Subの動作確認

動作確認環境

xxxx@penguin:~/$ hostnamectl 
   Static hostname: penguin
         Icon name: computer-container
           Chassis: container
        Machine ID: xxxxx
           Boot ID: xxxxx
    Virtualization: lxc
  Operating System: Debian GNU/Linux 11 (bullseye)
            Kernel: Linux 5.15.112-19404-g55fe7e355056
      Architecture: arm64

環境構築

Dockerfileを作成

FROM ubuntu:20.04

# https://github.com/eclipse-ecal/ecal


RUN apt-get update && apt-get upgrade   \
      && apt-get -y install software-properties-common  \
      && add-apt-repository ppa:ecal/ecal-latest  \
      && apt-get update   \
      && apt-get -y install ecal  \
      && apt-get -y install vim cmake g++ libprotobuf-dev protobuf-compiler

ビルド

> docker build -t eCAL_sample . 

動作確認

コンテナ起動して、受信プログラムを実行

> docker run -it -v data:/data eCAL_sample bash

>root@febee21d92e6:/# ecal_sample_person_rec
^

別ターミナルで同一コンテナに入る。

> docker exec -it [container_id] bash

>root@febee21d92e6:/# ecal_sample_person_snd

送受信のプログラムが動作し始める。

実装

> apt-get install cmake g++ libprotobuf-dev protobuf-compiler

protcol bufferで送受信するプログラムを実装。
実装内容は以下参照。

https://eclipse-ecal.github.io/ecal/getting_started/hello_world_proto.html

以下簡単に処理内容を記載する。





今後確認してみること

参考

0 件のコメント:

コメントを投稿