Skip to content
This repository has been archived by the owner on May 18, 2023. It is now read-only.

Commit

Permalink
Merge pull request autowarefoundation#6 from tier4/rename_pathnode_to…
Browse files Browse the repository at this point in the history
…_tilde

Rename pathnode to tilde
  • Loading branch information
y-okumura-isp authored Feb 24, 2022
2 parents c401387 + 53fb76a commit 4950f5d
Show file tree
Hide file tree
Showing 64 changed files with 343 additions and 1,191 deletions.
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
/src/pathnode_vis/pathnode_vis/__pycache__/
__pycache__
/build/
/install/
/log/
/*npy
/*/*npy
/src/analysis/__pycache__/
/src/pathnode_vis/test/__pycache__/
44 changes: 22 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
PathNode sample
TildeNode sample
===

## Description
Expand All @@ -7,11 +7,11 @@ PoC of deadline detection framework

## Contents

| src/ | about |
|-----------------|------------------------------------------------------|
| pathnode | deadline detection framework |
| pathnode_sample | samples including talker, relay, listener and so on. |
| path_info_msg | FW internal msg |
| src/ | about |
|--------------|------------------------------------------------------|
| tilde | deadline detection framework |
| tilde_sample | samples including talker, relay, listener and so on. |
| tilde_msg | FW internal msg |

## Build

Expand All @@ -22,30 +22,30 @@ colcon build --symlink-install

## Run samples

The pathnode_samples are implemented as ROS2 components.
The tilde_samples are implemented as ROS2 components.

### simple relay

Typical sample is the topic flow such as `/talker -> /relay1 -> /relay2 -> /listener`.

```
# term1: talker talks to `/talker`
ros2 component standalone pathnode_sample pathnode_sample::Talker -r chatter:=talker
ros2 component standalone tilde_sample tilde_sample::Talker -r chatter:=talker
# term2: relay `/talker` -> `/relay1`
ros2 component standalone pathnode_sample pathnode_sample::Relay -r in:=talker -r out:=relay1
ros2 component standalone tilde_sample tilde_sample::Relay -r in:=talker -r out:=relay1
# (no output)
# term3: relay: `relay1` -> `relay2`
ros2 component standalone pathnode_sample pathnode_sample::Relay -r in:=relay1 -r out:=relay2
ros2 component standalone tilde_sample tilde_sample::Relay -r in:=relay1 -r out:=relay2
# (no output)
# term4: relay: `relay2` -> `listener`
ros2 component standalone pathnode_sample pathnode_sample::Relay -r in:=relay2 -r out:=listener
ros2 component standalone tilde_sample tilde_sample::Relay -r in:=relay2 -r out:=listener
# (no output)
# term5: listener subscribes `/listener`
ros2 component standalone pathnode_sample pathnode_sample::Listener -r chatter:=listener
ros2 component standalone tilde_sample tilde_sample::Listener -r chatter:=listener
# [INFO] [1631063086.571361319] [listener]: I heard: [Hello World: 32]
# [INFO] [1631063087.571401747] [listener]: I heard: [Hello World: 33]
```
Expand Down Expand Up @@ -80,10 +80,10 @@ Optionally, each callback can sleep for `wait_msec` [ms].

```
# talker
ros2 component standalone pathnode_sample pathnode_sample::Talker -r chatter:=talker
ros2 component standalone tilde_sample tilde_sample::Talker -r chatter:=talker
# relay_node1
ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
ros2 component standalone tilde_sample tilde_sample::RelayWithPath \
-r __node:=relay_node1 \
-r in:=talker -r out:=relay1 \
-p is_first:=true \
Expand All @@ -95,7 +95,7 @@ ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
# relay_node22
ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
ros2 component standalone tilde_sample tilde_sample::RelayWithPath \
-r __node:=relay_node2 \
-r in:=relay1 -r out:=relay2 \
-p is_first:=false \
Expand All @@ -106,7 +106,7 @@ ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
-p wait_msec:=0
# relay_node3
ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
ros2 component standalone tilde_sample tilde_sample::RelayWithPath \
-r __node:=relay_node3 \
-r in:=relay2 -r out:=listener \
-p is_first:=false \
Expand All @@ -117,12 +117,12 @@ ros2 component standalone pathnode_sample pathnode_sample::RelayWithPath \
-p wait_msec:=0
# listener
ros2 component standalone pathnode_sample pathnode_sample::Listener -r chatter:=listener
ros2 component standalone tilde_sample tilde_sample::Listener -r chatter:=listener
```

## Test of long callbacks

To check executor behaviors, we can use `pathnode_sample::SampleMultiCallback`.
To check executor behaviors, we can use `tilde_sample::SampleMultiCallback`.

It has the following callbacks:
- three subscription callbacks `sub1` - `sub3`
Expand All @@ -142,14 +142,14 @@ In default, all subscription callbacks and timers wake up every 1[s] and send me

```
# talker
ros2 component standalone pathnode_sample pathnode_sample::Talker -r chatter:=sub1
ros2 component standalone pathnode_sample pathnode_sample::Talker -r chatter:=sub2
ros2 component standalone pathnode_sample pathnode_sample::Talker -r chatter:=sub3
ros2 component standalone tilde_sample tilde_sample::Talker -r chatter:=sub1
ros2 component standalone tilde_sample tilde_sample::Talker -r chatter:=sub2
ros2 component standalone tilde_sample tilde_sample::Talker -r chatter:=sub3
# sample_multi_callback
ros2 run rclcpp_components component_container_mt
ros2 component load /ComponentManager pathnode_sample pathnode_sample::SampleMultiCallback \
ros2 component load /ComponentManager tilde_sample tilde_sample::SampleMultiCallback \
-p sub1_wait_ms:=5000
# If you want check each callback pub, do like these
Expand Down
2 changes: 1 addition & 1 deletion doc/latency_viewer.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Latency Viewer はあるセンサー入力からのレンテンシの表示ツ
PubInfo を利用して DAG を遡ることで、注目しているトピックからセンサーまで全てのパスにおけるレイテンシを確認できます。
vmstat や top の様に定期的にレイテンシ情報が更新されます。

起動方法やオプションについては [ビシュアライズツールの README](../src/pathnode_vis/README.md) をご覧下さい。
起動方法やオプションについては [ビシュアライズツールの README](../src/tilde_vis/README.md) をご覧下さい。

## 出力例

Expand Down
2 changes: 1 addition & 1 deletion doc/mechanism.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ PubInfo はメイントピックの publish 時と同時に送信されるメタ
メッセージ定義は以下の通りです。
※ TODO: ファイル名やデータ構造はリファクタ予定

[PubInfo.msg](../src/path_info_msg/msg/PubInfo.msg)
[PubInfo.msg](../src/tilde_msg/msg/PubInfo.msg)

- Header:
- header
Expand Down
21 changes: 0 additions & 21 deletions src/pathnode/README.md

This file was deleted.

168 changes: 0 additions & 168 deletions src/pathnode/include/pathnode/path_node.hpp

This file was deleted.

Loading

0 comments on commit 4950f5d

Please sign in to comment.