From 225ff7a17f38e1b4c4703b07d4675c94be127516 Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 10:49:50 +0100
Subject: [PATCH 1/6] Rename humanoid_league_speaker to bitbots_tts
---
.../bitbots_tts}/README.md | 0
.../bitbots_tts/bitbots_tts}/__init__.py | 0
.../bitbots_tts/bitbots_tts/tts.py | 0
.../bitbots_tts}/config/speaker_config.yaml | 0
.../bitbots_tts}/docs/_static/logo.png | Bin
.../bitbots_tts}/docs/conf.py | 0
.../bitbots_tts}/docs/index.rst | 0
.../bitbots_tts/launch/tts.launch | 0
.../bitbots_tts}/package.xml | 0
.../bitbots_tts/resource/bitbots_tts | 0
.../bitbots_tts}/scripts/send_text.py | 0
.../bitbots_tts}/setup.cfg | 0
.../bitbots_tts}/setup.py | 0
13 files changed, 0 insertions(+), 0 deletions(-)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/README.md (100%)
rename {humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker => bitbots_misc/bitbots_tts/bitbots_tts}/__init__.py (100%)
rename humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker/speaker.py => bitbots_misc/bitbots_tts/bitbots_tts/tts.py (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/config/speaker_config.yaml (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/docs/_static/logo.png (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/docs/conf.py (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/docs/index.rst (100%)
rename humanoid_league_misc/humanoid_league_speaker/launch/speaker.launch => bitbots_misc/bitbots_tts/launch/tts.launch (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/package.xml (100%)
rename humanoid_league_misc/humanoid_league_speaker/resource/humanoid_league_speaker => bitbots_misc/bitbots_tts/resource/bitbots_tts (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/scripts/send_text.py (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/setup.cfg (100%)
rename {humanoid_league_misc/humanoid_league_speaker => bitbots_misc/bitbots_tts}/setup.py (100%)
diff --git a/humanoid_league_misc/humanoid_league_speaker/README.md b/bitbots_misc/bitbots_tts/README.md
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/README.md
rename to bitbots_misc/bitbots_tts/README.md
diff --git a/humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker/__init__.py b/bitbots_misc/bitbots_tts/bitbots_tts/__init__.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker/__init__.py
rename to bitbots_misc/bitbots_tts/bitbots_tts/__init__.py
diff --git a/humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker/speaker.py b/bitbots_misc/bitbots_tts/bitbots_tts/tts.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/humanoid_league_speaker/speaker.py
rename to bitbots_misc/bitbots_tts/bitbots_tts/tts.py
diff --git a/humanoid_league_misc/humanoid_league_speaker/config/speaker_config.yaml b/bitbots_misc/bitbots_tts/config/speaker_config.yaml
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/config/speaker_config.yaml
rename to bitbots_misc/bitbots_tts/config/speaker_config.yaml
diff --git a/humanoid_league_misc/humanoid_league_speaker/docs/_static/logo.png b/bitbots_misc/bitbots_tts/docs/_static/logo.png
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/docs/_static/logo.png
rename to bitbots_misc/bitbots_tts/docs/_static/logo.png
diff --git a/humanoid_league_misc/humanoid_league_speaker/docs/conf.py b/bitbots_misc/bitbots_tts/docs/conf.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/docs/conf.py
rename to bitbots_misc/bitbots_tts/docs/conf.py
diff --git a/humanoid_league_misc/humanoid_league_speaker/docs/index.rst b/bitbots_misc/bitbots_tts/docs/index.rst
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/docs/index.rst
rename to bitbots_misc/bitbots_tts/docs/index.rst
diff --git a/humanoid_league_misc/humanoid_league_speaker/launch/speaker.launch b/bitbots_misc/bitbots_tts/launch/tts.launch
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/launch/speaker.launch
rename to bitbots_misc/bitbots_tts/launch/tts.launch
diff --git a/humanoid_league_misc/humanoid_league_speaker/package.xml b/bitbots_misc/bitbots_tts/package.xml
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/package.xml
rename to bitbots_misc/bitbots_tts/package.xml
diff --git a/humanoid_league_misc/humanoid_league_speaker/resource/humanoid_league_speaker b/bitbots_misc/bitbots_tts/resource/bitbots_tts
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/resource/humanoid_league_speaker
rename to bitbots_misc/bitbots_tts/resource/bitbots_tts
diff --git a/humanoid_league_misc/humanoid_league_speaker/scripts/send_text.py b/bitbots_misc/bitbots_tts/scripts/send_text.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/scripts/send_text.py
rename to bitbots_misc/bitbots_tts/scripts/send_text.py
diff --git a/humanoid_league_misc/humanoid_league_speaker/setup.cfg b/bitbots_misc/bitbots_tts/setup.cfg
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/setup.cfg
rename to bitbots_misc/bitbots_tts/setup.cfg
diff --git a/humanoid_league_misc/humanoid_league_speaker/setup.py b/bitbots_misc/bitbots_tts/setup.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_speaker/setup.py
rename to bitbots_misc/bitbots_tts/setup.py
From 82821f647bcb577cee4db2fb6a04365de5081a0a Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 11:26:03 +0100
Subject: [PATCH 2/6] Fix naming and add caching
---
.../bitbots_ros_control/launch/ros_control.launch | 2 +-
bitbots_lowlevel/bitbots_ros_control/package.xml | 2 +-
bitbots_misc/bitbots_tts/README.md | 7 -------
.../config/{speaker_config.yaml => tts_config.yaml} | 0
bitbots_misc/bitbots_tts/launch/tts.launch | 8 ++++----
bitbots_misc/bitbots_tts/package.xml | 4 ++--
bitbots_misc/bitbots_tts/setup.cfg | 4 ++--
bitbots_misc/bitbots_tts/setup.py | 4 ++--
.../bitbots_hcm/bitbots_hcm/hcm_dsd/decisions/pickup.py | 2 +-
.../bitbots_hcm/bitbots_hcm/humanoid_control_module.py | 2 +-
bitbots_motion/bitbots_hcm/package.xml | 2 +-
bitbots_motion/bitbots_hcm/scripts/pause.py | 2 +-
sync_includes_wolfgang_nuc.yaml | 2 +-
13 files changed, 17 insertions(+), 24 deletions(-)
delete mode 100644 bitbots_misc/bitbots_tts/README.md
rename bitbots_misc/bitbots_tts/config/{speaker_config.yaml => tts_config.yaml} (100%)
diff --git a/bitbots_lowlevel/bitbots_ros_control/launch/ros_control.launch b/bitbots_lowlevel/bitbots_ros_control/launch/ros_control.launch
index 0391567a2..072944150 100644
--- a/bitbots_lowlevel/bitbots_ros_control/launch/ros_control.launch
+++ b/bitbots_lowlevel/bitbots_ros_control/launch/ros_control.launch
@@ -27,7 +27,7 @@
-
+
diff --git a/bitbots_lowlevel/bitbots_ros_control/package.xml b/bitbots_lowlevel/bitbots_ros_control/package.xml
index d1eaee3fe..e7362bfed 100644
--- a/bitbots_lowlevel/bitbots_ros_control/package.xml
+++ b/bitbots_lowlevel/bitbots_ros_control/package.xml
@@ -27,7 +27,7 @@
controller_manager
dynamixel_workbench_toolbox
hardware_interface
- humanoid_league_speaker
+ bitbots_tts
pluginlib
rclcpp
realtime_tools
diff --git a/bitbots_misc/bitbots_tts/README.md b/bitbots_misc/bitbots_tts/README.md
deleted file mode 100644
index 757a78a97..000000000
--- a/bitbots_misc/bitbots_tts/README.md
+++ /dev/null
@@ -1,7 +0,0 @@
-If you get an import error from the following line:
- from humanoid_league_speaker.cfg import speaker_paramsConfig
-Do from catkin directory:
- cp src/humanoid_league_misc/humanoid_league_speaker/cfg/speaker_paramsConfig.cfg devel/lib/python2.7/dist-packages/humanoid_league_speaker/cfg
-And rebuild.
-
-I don't know why this problem exists.
diff --git a/bitbots_misc/bitbots_tts/config/speaker_config.yaml b/bitbots_misc/bitbots_tts/config/tts_config.yaml
similarity index 100%
rename from bitbots_misc/bitbots_tts/config/speaker_config.yaml
rename to bitbots_misc/bitbots_tts/config/tts_config.yaml
diff --git a/bitbots_misc/bitbots_tts/launch/tts.launch b/bitbots_misc/bitbots_tts/launch/tts.launch
index e5c792088..5f3f78bb5 100644
--- a/bitbots_misc/bitbots_tts/launch/tts.launch
+++ b/bitbots_misc/bitbots_tts/launch/tts.launch
@@ -1,6 +1,6 @@
-
-
-
+
+
+
-
\ No newline at end of file
+
diff --git a/bitbots_misc/bitbots_tts/package.xml b/bitbots_misc/bitbots_tts/package.xml
index be4db8c03..1b91e5396 100644
--- a/bitbots_misc/bitbots_tts/package.xml
+++ b/bitbots_misc/bitbots_tts/package.xml
@@ -1,9 +1,9 @@
- humanoid_league_speaker
+ bitbots_tts
2.0.0
- The humanoid_league_speaker package provides an easy way to do audio speech output via espeak.
+ The bitbots_tts package provides an easy way to do audio speech output via a text to speach engine.
Messages send to the /speak topic are queued and spoken in another thread depending on their priority.
This can be used for debug but also for inter robot communication with natural language.
diff --git a/bitbots_misc/bitbots_tts/setup.cfg b/bitbots_misc/bitbots_tts/setup.cfg
index 5ff8ed032..902ac0ff9 100644
--- a/bitbots_misc/bitbots_tts/setup.cfg
+++ b/bitbots_misc/bitbots_tts/setup.cfg
@@ -1,4 +1,4 @@
[develop]
-script_dir=$base/lib/humanoid_league_speaker
+script_dir=$base/lib/bitbots_tts
[install]
-install_scripts=$base/lib/humanoid_league_speaker
+install_scripts=$base/lib/bitbots_tts
diff --git a/bitbots_misc/bitbots_tts/setup.py b/bitbots_misc/bitbots_tts/setup.py
index 7d6cecef5..301de3cc5 100644
--- a/bitbots_misc/bitbots_tts/setup.py
+++ b/bitbots_misc/bitbots_tts/setup.py
@@ -2,7 +2,7 @@
from setuptools import find_packages, setup
-package_name = "humanoid_league_speaker"
+package_name = "bitbots_tts"
setup(
name=package_name,
@@ -19,7 +19,7 @@
scripts=["scripts/send_text.py"],
entry_points={
"console_scripts": [
- "speaker = humanoid_league_speaker.speaker:main",
+ "tts = bitbots_tts.tts:main",
],
},
)
diff --git a/bitbots_motion/bitbots_hcm/bitbots_hcm/hcm_dsd/decisions/pickup.py b/bitbots_motion/bitbots_hcm/bitbots_hcm/hcm_dsd/decisions/pickup.py
index f6569d999..0e33bb10e 100644
--- a/bitbots_motion/bitbots_hcm/bitbots_hcm/hcm_dsd/decisions/pickup.py
+++ b/bitbots_motion/bitbots_hcm/bitbots_hcm/hcm_dsd/decisions/pickup.py
@@ -1,4 +1,4 @@
-from humanoid_league_speaker.speaker import speak
+from bitbots_tts.tts import speak
from bitbots_hcm.hcm_dsd.decisions import AbstractHCMDecisionElement
diff --git a/bitbots_motion/bitbots_hcm/bitbots_hcm/humanoid_control_module.py b/bitbots_motion/bitbots_hcm/bitbots_hcm/humanoid_control_module.py
index dcfba872e..c3cda8855 100755
--- a/bitbots_motion/bitbots_hcm/bitbots_hcm/humanoid_control_module.py
+++ b/bitbots_motion/bitbots_hcm/bitbots_hcm/humanoid_control_module.py
@@ -5,11 +5,11 @@
import rclpy
from ament_index_python import get_package_share_directory
+from bitbots_tts.tts import speak
from bitbots_utils.utils import get_parameters_from_ros_yaml
from builtin_interfaces.msg import Time as TimeMsg
from diagnostic_msgs.msg import DiagnosticArray, DiagnosticStatus
from dynamic_stack_decider.dsd import DSD
-from humanoid_league_speaker.speaker import speak
from rcl_interfaces.msg import Parameter as ParameterMsg
from rclpy.duration import Duration
from rclpy.executors import MultiThreadedExecutor
diff --git a/bitbots_motion/bitbots_hcm/package.xml b/bitbots_motion/bitbots_hcm/package.xml
index 40e25f4d0..f447d5b28 100644
--- a/bitbots_motion/bitbots_hcm/package.xml
+++ b/bitbots_motion/bitbots_hcm/package.xml
@@ -24,7 +24,7 @@
bitbots_utils
dynamic_stack_decider
geometry_msgs
- humanoid_league_speaker
+ bitbots_tts
pybind11-dev
python3-numpy
python3-transforms3d
diff --git a/bitbots_motion/bitbots_hcm/scripts/pause.py b/bitbots_motion/bitbots_hcm/scripts/pause.py
index 74302bb85..1651060fb 100755
--- a/bitbots_motion/bitbots_hcm/scripts/pause.py
+++ b/bitbots_motion/bitbots_hcm/scripts/pause.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
import rclpy
-from humanoid_league_speaker.speaker import speak
+from bitbots_tts.tts import speak
from rclpy.node import Node
from std_msgs.msg import Bool
diff --git a/sync_includes_wolfgang_nuc.yaml b/sync_includes_wolfgang_nuc.yaml
index 82b1fcc85..dbf330cbc 100644
--- a/sync_includes_wolfgang_nuc.yaml
+++ b/sync_includes_wolfgang_nuc.yaml
@@ -14,6 +14,7 @@ include:
- bitbots_robot_description
- bitbots_teleop
- bitbots_tf_listener
+ - bitbots_tts
- bitbots_utils
- system_monitor
- bitbots_motion:
@@ -40,7 +41,6 @@ include:
- bitbots_ball_filter
- bitbots_robot_filter
- humanoid_league_misc:
- - humanoid_league_speaker
- humanoid_league_team_communication
- lib:
- audio_common
From 008d5f1d89ac9c27f424028cae1154ce93a5f51d Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 11:48:54 +0100
Subject: [PATCH 3/6] Rename team comm
---
.gitignore | 4 +-
.../bitbots_bringup/launch/highlevel.launch | 2 +-
.../launch/visualization.launch | 5 +-
.../bitbots_containers/hlvs/Dockerfile | 2 +-
.../docs/manual/testing/testing.rst | 46 +-----------------
.../CMakeLists.txt | 11 ++---
.../bitbots_team_communication}/__init__.py | 0
.../communication.py | 0
.../converter/__init__.py | 0
.../message_to_team_data_converter.py | 4 +-
.../converter/robocup_protocol_converter.py | 6 +--
.../converter/state_to_message_converter.py | 2 +-
.../humanoid_league_team_communication.py | 10 ++--
.../config/team_comm_marker.rviz | 0
.../config/team_communication_config.yaml | 0
.../docs/_static/logo.png | Bin
.../docs/conf.py | 0
.../docs/index.rst | 0
.../launch/team_comm.launch | 4 +-
.../launch/team_comm_standalone.launch | 4 +-
.../launch/team_comm_test_marker.launch | 11 +++++
.../package.xml | 4 +-
.../scripts/show_team_comm.py | 0
.../scripts/team_comm.py | 7 +++
.../scripts/team_comm_test_marker.py | 0
.../scripts/test_team_comm.py | 0
.../scripts/tmux_testing_setup.zsh | 8 +--
bitbots_team_communication/setup.cfg | 4 ++
.../setup.py | 2 +-
.../test/__init__.py | 0
.../test_message_to_team_data_converter.ambr | 0
.../test_robocup_protocol_converter.ambr | 0
.../test_state_to_message_converter.ambr | 0
.../test_message_to_team_data_converter.py | 4 +-
.../test_robocup_protocol_converter.py | 13 ++---
.../test_state_to_message_converter.py | 6 +--
.../wolfgang_robocup_api/scripts/start.sh | 4 +-
.../.gitignore | 1 -
.../launch/team_comm_test_marker.launch | 11 -----
.../scripts/team_comm.py | 7 ---
.../setup.cfg | 4 --
sync_includes_wolfgang_nuc.yaml | 3 +-
workspace.repos | 2 +-
43 files changed, 70 insertions(+), 121 deletions(-)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/CMakeLists.txt (84%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/__init__.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/communication.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/converter/__init__.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/converter/message_to_team_data_converter.py (95%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/converter/robocup_protocol_converter.py (91%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/converter/state_to_message_converter.py (99%)
rename {humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication => bitbots_team_communication/bitbots_team_communication}/humanoid_league_team_communication.py (95%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/config/team_comm_marker.rviz (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/config/team_communication_config.yaml (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/docs/_static/logo.png (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/docs/conf.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/docs/index.rst (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/launch/team_comm.launch (54%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/launch/team_comm_standalone.launch (64%)
create mode 100644 bitbots_team_communication/launch/team_comm_test_marker.launch
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/package.xml (89%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/scripts/show_team_comm.py (100%)
create mode 100755 bitbots_team_communication/scripts/team_comm.py
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/scripts/team_comm_test_marker.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/scripts/test_team_comm.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/scripts/tmux_testing_setup.zsh (67%)
create mode 100644 bitbots_team_communication/setup.cfg
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/setup.py (82%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/__init__.py (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/__snapshots__/test_message_to_team_data_converter.ambr (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/__snapshots__/test_robocup_protocol_converter.ambr (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/__snapshots__/test_state_to_message_converter.ambr (100%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/test_message_to_team_data_converter.py (94%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/test_robocup_protocol_converter.py (79%)
rename {humanoid_league_misc/humanoid_league_team_communication => bitbots_team_communication}/test/converter/test_state_to_message_converter.py (97%)
delete mode 100644 humanoid_league_misc/humanoid_league_team_communication/.gitignore
delete mode 100644 humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_test_marker.launch
delete mode 100755 humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm.py
delete mode 100644 humanoid_league_misc/humanoid_league_team_communication/setup.cfg
diff --git a/.gitignore b/.gitignore
index 314ea06dc..be8ecd54c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -221,5 +221,7 @@ doku/*
/lib/
# Path to the protocol buffer definitions, which are a diffrerent repository and managed by vcstool
-/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/RobocupProtocol
+/bitbots_team_communication/bitbots_team_communication/RobocupProtocol
+# Protobuf generated file
+/bitbots_team_communication/bitbots_team_communication/robocup_extension_pb2.py
diff --git a/bitbots_misc/bitbots_bringup/launch/highlevel.launch b/bitbots_misc/bitbots_bringup/launch/highlevel.launch
index bf87c6d92..78b0b0624 100644
--- a/bitbots_misc/bitbots_bringup/launch/highlevel.launch
+++ b/bitbots_misc/bitbots_bringup/launch/highlevel.launch
@@ -40,7 +40,7 @@
-
+
diff --git a/bitbots_misc/bitbots_bringup/launch/visualization.launch b/bitbots_misc/bitbots_bringup/launch/visualization.launch
index fc9f3bead..ef1afa501 100644
--- a/bitbots_misc/bitbots_bringup/launch/visualization.launch
+++ b/bitbots_misc/bitbots_bringup/launch/visualization.launch
@@ -34,10 +34,7 @@
-
-
-
-
+
diff --git a/bitbots_misc/bitbots_containers/hlvs/Dockerfile b/bitbots_misc/bitbots_containers/hlvs/Dockerfile
index 73015f7f7..2affe1c26 100644
--- a/bitbots_misc/bitbots_containers/hlvs/Dockerfile
+++ b/bitbots_misc/bitbots_containers/hlvs/Dockerfile
@@ -61,7 +61,7 @@ ADD https://www.timeapi.io/api/Time/current/zone?timeZone=UTC /tmp/build-time
RUN cd src/bitbots_main && \
make pull-all && \
rm -rf lib/udp_bridge bitbots_misc/bitbots_containers \
- humanoid_league_visualization dynamic_stack_decider/dynamic_stack_decider_visualization bitbots_lowlevel \
+ lib/dynamic_stack_decider/dynamic_stack_decider_visualization bitbots_lowlevel \
bitbots_wolfgang/wolfgang_pybullet_sim lib/DynamixelSDK lib/dynamixel-workbench \
bitbots_misc/bitbots_basler_camera lib/pylon-ros-camera && \
sed -i '/plotjuggler/d' bitbots_motion/bitbots_quintic_walk/package.xml && \
diff --git a/bitbots_misc/bitbots_docs/docs/manual/testing/testing.rst b/bitbots_misc/bitbots_docs/docs/manual/testing/testing.rst
index 0353a6b01..e3990f5f3 100644
--- a/bitbots_misc/bitbots_docs/docs/manual/testing/testing.rst
+++ b/bitbots_misc/bitbots_docs/docs/manual/testing/testing.rst
@@ -59,47 +59,6 @@ Starting (starts)
The next step is to check if the package actually starts without crashing instantly with an obvious error.
A part of this is that a launch file exists.
-Testing in Visualization (tested_viz)
-----------------------------------------
-
-The easiest real test if the software works is in visualization with fake data/commands and then to look at the output.
-For this you can also use real data that was recorded in a rosbag.
-
-For this, it is important to be aware of your own testing bias.
-Humans tend to test their own software for exactly the use cases they had in mind during programming.
-However it is important to explicitly check all possibilities.
-This means especially to test for edge cases and on robustness, e.g., testing with wrong data and against other parts of the software stack that crash.
-A good method for this is to let someone else test your software, someone who was not involved in the programming of it.
-
-This method is essentially used to prevent errors from happening and less to see how well something works.
-The tests in this stage can be done via multiple methods:
-
-Input
-^^^^^^^^^^^
-
-1. ros2 topic pub
-2. RViz interactive marker
- 1. Path planning: inbuilt Navigation goal in RViz
- 2. behavior: humanoid_league_interactive_marker
-3. special test scripts:
- 1. walking: bitbots_teleop
- 2. behavior: sim_gamestate (in gamecontroller package)
-4. rosbags
-
-Output
-^^^^^^^^^^^^
-
-1. ros2 topic echo
-2. RViz marker
- 1. Object detection: humanoid_league_rviz_marker
- 2. Walking: published its own markers
-3. RViz robot model
- 1. you might need to make the joint commands into joint_state (bitbots_bringup motor_goals_viz_helper.py)
-4. special visualization tools for rqt
- 1. DSD: dynamic_stack_decider_visualization
- 2. Object Detection: humanoid_league_relative_rqt
- 3. Vision: bitbots_vision_tools
-
Testing in Simulation
------------------------------------------------
@@ -139,8 +98,7 @@ Conclusion
1. Each package has to be tested on its own
1. compiles
2. starts
- 3. using visualization
- 4. using simulation
- 5. on the real robot
+ 3. using simulation
+ 4. on the real robot
2. test packages pairwise
3. test the complete stack (integration)
diff --git a/humanoid_league_misc/humanoid_league_team_communication/CMakeLists.txt b/bitbots_team_communication/CMakeLists.txt
similarity index 84%
rename from humanoid_league_misc/humanoid_league_team_communication/CMakeLists.txt
rename to bitbots_team_communication/CMakeLists.txt
index d4b7de9e7..d6965a5bd 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/CMakeLists.txt
+++ b/bitbots_team_communication/CMakeLists.txt
@@ -1,5 +1,5 @@
cmake_minimum_required(VERSION 3.5)
-project(humanoid_league_team_communication)
+project(bitbots_team_communication)
find_package(ament_cmake REQUIRED)
find_package(ament_cmake_python REQUIRED)
@@ -16,18 +16,17 @@ find_package(bitbots_docs REQUIRED)
find_package(Protobuf REQUIRED)
protobuf_generate_python(
- PROTO_PY
- humanoid_league_team_communication/RobocupProtocol/robocup_extension.proto)
+ PROTO_PY bitbots_team_communication/RobocupProtocol/robocup_extension.proto)
add_custom_target(
- humanoid_league_team_communication ALL
+ bitbots_team_communication ALL
DEPENDS ${PROTO_PY}
COMMENT "Generating protobuf")
add_custom_command(
- TARGET humanoid_league_team_communication
+ TARGET bitbots_team_communication
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy ${PROTO_PY}
- ${CMAKE_SOURCE_DIR}/humanoid_league_team_communication
+ ${CMAKE_SOURCE_DIR}/bitbots_team_communication
COMMENT "Copying protobuf to source dir")
enable_bitbots_docs()
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/__init__.py b/bitbots_team_communication/bitbots_team_communication/__init__.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/__init__.py
rename to bitbots_team_communication/bitbots_team_communication/__init__.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/communication.py b/bitbots_team_communication/bitbots_team_communication/communication.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/communication.py
rename to bitbots_team_communication/bitbots_team_communication/communication.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/__init__.py b/bitbots_team_communication/bitbots_team_communication/converter/__init__.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/__init__.py
rename to bitbots_team_communication/bitbots_team_communication/converter/__init__.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/message_to_team_data_converter.py b/bitbots_team_communication/bitbots_team_communication/converter/message_to_team_data_converter.py
similarity index 95%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/message_to_team_data_converter.py
rename to bitbots_team_communication/bitbots_team_communication/converter/message_to_team_data_converter.py
index 8da775b91..1dd4b0fe2 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/message_to_team_data_converter.py
+++ b/bitbots_team_communication/bitbots_team_communication/converter/message_to_team_data_converter.py
@@ -4,7 +4,7 @@
from geometry_msgs.msg import PoseWithCovariance
from numpy import double
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import RobotRelative, RobotRelativeArray, TeamData
@@ -22,8 +22,6 @@ def convert(self, message: Proto.Message, team_data: TeamData) -> TeamData:
team_data.robot_position = self.convert_robot_pose(message.current_pose)
team_data.ball_absolute = self.convert_ball_pose(message.ball)
- # @TODO: change TeamData field/type to robots
- # see: https://github.com/bit-bots/humanoid_league_misc/issues/125
team_data.robots = self.convert_robots(message.others, message.other_robot_confidence)
team_data.robots.header = team_data.header
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/robocup_protocol_converter.py b/bitbots_team_communication/bitbots_team_communication/converter/robocup_protocol_converter.py
similarity index 91%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/robocup_protocol_converter.py
rename to bitbots_team_communication/bitbots_team_communication/converter/robocup_protocol_converter.py
index 52b6e8c16..68cb2eb3d 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/robocup_protocol_converter.py
+++ b/bitbots_team_communication/bitbots_team_communication/converter/robocup_protocol_converter.py
@@ -2,10 +2,10 @@
from soccer_vision_attribute_msgs.msg import Robot as RobotAttributes
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import RobotRelative, Strategy
-from humanoid_league_team_communication.converter.message_to_team_data_converter import MessageToTeamDataConverter
-from humanoid_league_team_communication.converter.state_to_message_converter import StateToMessageConverter
+from bitbots_team_communication.converter.message_to_team_data_converter import MessageToTeamDataConverter
+from bitbots_team_communication.converter.state_to_message_converter import StateToMessageConverter
class TeamColor(IntEnum):
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/state_to_message_converter.py b/bitbots_team_communication/bitbots_team_communication/converter/state_to_message_converter.py
similarity index 99%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/state_to_message_converter.py
rename to bitbots_team_communication/bitbots_team_communication/converter/state_to_message_converter.py
index 5c6e2f75b..056c73dd7 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/converter/state_to_message_converter.py
+++ b/bitbots_team_communication/bitbots_team_communication/converter/state_to_message_converter.py
@@ -8,7 +8,7 @@
from rclpy.time import Time
from soccer_vision_3d_msgs.msg import Robot, RobotArray
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import Strategy
diff --git a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/humanoid_league_team_communication.py b/bitbots_team_communication/bitbots_team_communication/humanoid_league_team_communication.py
similarity index 95%
rename from humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/humanoid_league_team_communication.py
rename to bitbots_team_communication/bitbots_team_communication/humanoid_league_team_communication.py
index 16b776f74..d11bc16ab 100755
--- a/humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/humanoid_league_team_communication.py
+++ b/bitbots_team_communication/bitbots_team_communication/humanoid_league_team_communication.py
@@ -21,19 +21,19 @@
from tf2_geometry_msgs import PointStamped, PoseStamped
from tf2_ros import Buffer, TransformException
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import Strategy, TeamData
-from humanoid_league_team_communication.communication import SocketCommunication
-from humanoid_league_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
+from bitbots_team_communication.communication import SocketCommunication
+from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
class HumanoidLeagueTeamCommunication:
def __init__(self):
- self._package_path = get_package_share_directory("humanoid_league_team_communication")
+ self._package_path = get_package_share_directory("bitbots_team_communication")
self.node = Node("team_comm", automatically_declare_parameters_from_overrides=True)
self.logger = self.node.get_logger()
- self.logger.info("Initializing humanoid_league_team_communication...")
+ self.logger.info("Initializing bitbots_team_communication...")
params_blackboard = get_parameters_from_other_node(
self.node, "parameter_blackboard", ["bot_id", "team_id", "team_color"]
)
diff --git a/humanoid_league_misc/humanoid_league_team_communication/config/team_comm_marker.rviz b/bitbots_team_communication/config/team_comm_marker.rviz
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/config/team_comm_marker.rviz
rename to bitbots_team_communication/config/team_comm_marker.rviz
diff --git a/humanoid_league_misc/humanoid_league_team_communication/config/team_communication_config.yaml b/bitbots_team_communication/config/team_communication_config.yaml
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/config/team_communication_config.yaml
rename to bitbots_team_communication/config/team_communication_config.yaml
diff --git a/humanoid_league_misc/humanoid_league_team_communication/docs/_static/logo.png b/bitbots_team_communication/docs/_static/logo.png
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/docs/_static/logo.png
rename to bitbots_team_communication/docs/_static/logo.png
diff --git a/humanoid_league_misc/humanoid_league_team_communication/docs/conf.py b/bitbots_team_communication/docs/conf.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/docs/conf.py
rename to bitbots_team_communication/docs/conf.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/docs/index.rst b/bitbots_team_communication/docs/index.rst
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/docs/index.rst
rename to bitbots_team_communication/docs/index.rst
diff --git a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm.launch b/bitbots_team_communication/launch/team_comm.launch
similarity index 54%
rename from humanoid_league_misc/humanoid_league_team_communication/launch/team_comm.launch
rename to bitbots_team_communication/launch/team_comm.launch
index c6ff979c4..2bb22f9c4 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm.launch
+++ b/bitbots_team_communication/launch/team_comm.launch
@@ -3,8 +3,8 @@
-
-
+
+
diff --git a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_standalone.launch b/bitbots_team_communication/launch/team_comm_standalone.launch
similarity index 64%
rename from humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_standalone.launch
rename to bitbots_team_communication/launch/team_comm_standalone.launch
index 1f30efbf7..b3a092a71 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_standalone.launch
+++ b/bitbots_team_communication/launch/team_comm_standalone.launch
@@ -6,8 +6,8 @@
-
-
+
+
diff --git a/bitbots_team_communication/launch/team_comm_test_marker.launch b/bitbots_team_communication/launch/team_comm_test_marker.launch
new file mode 100644
index 000000000..d688e7034
--- /dev/null
+++ b/bitbots_team_communication/launch/team_comm_test_marker.launch
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/humanoid_league_misc/humanoid_league_team_communication/package.xml b/bitbots_team_communication/package.xml
similarity index 89%
rename from humanoid_league_misc/humanoid_league_team_communication/package.xml
rename to bitbots_team_communication/package.xml
index 40388bf6d..038c2c1f0 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/package.xml
+++ b/bitbots_team_communication/package.xml
@@ -1,9 +1,9 @@
- humanoid_league_team_communication
+ bitbots_team_communication
3.0.0
- The humanoid_league_team_communication package provides a ROS wrapper for the Protobuf RoboCup protocol.
+ The bitbots_team_communication package provides a ROS wrapper for the Protobuf RoboCup protocol.
This is the standard communication protocol developed by the NUbots.
Joern Griepenburg
diff --git a/humanoid_league_misc/humanoid_league_team_communication/scripts/show_team_comm.py b/bitbots_team_communication/scripts/show_team_comm.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/scripts/show_team_comm.py
rename to bitbots_team_communication/scripts/show_team_comm.py
diff --git a/bitbots_team_communication/scripts/team_comm.py b/bitbots_team_communication/scripts/team_comm.py
new file mode 100755
index 000000000..f1376f6cd
--- /dev/null
+++ b/bitbots_team_communication/scripts/team_comm.py
@@ -0,0 +1,7 @@
+#!/usr/bin/env python3
+
+import sys
+
+from bitbots_team_communication.bitbots_team_communication import main
+
+sys.exit(main())
diff --git a/humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm_test_marker.py b/bitbots_team_communication/scripts/team_comm_test_marker.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm_test_marker.py
rename to bitbots_team_communication/scripts/team_comm_test_marker.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/scripts/test_team_comm.py b/bitbots_team_communication/scripts/test_team_comm.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/scripts/test_team_comm.py
rename to bitbots_team_communication/scripts/test_team_comm.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/scripts/tmux_testing_setup.zsh b/bitbots_team_communication/scripts/tmux_testing_setup.zsh
similarity index 67%
rename from humanoid_league_misc/humanoid_league_team_communication/scripts/tmux_testing_setup.zsh
rename to bitbots_team_communication/scripts/tmux_testing_setup.zsh
index a1725c0dc..dd6cf059e 100755
--- a/humanoid_league_misc/humanoid_league_team_communication/scripts/tmux_testing_setup.zsh
+++ b/bitbots_team_communication/scripts/tmux_testing_setup.zsh
@@ -1,7 +1,7 @@
#!/usr/bin/env zsh
session="TeamComm"
-pkg="humanoid_league_team_communication"
+pkg="bitbots_team_communication"
run_tmux_session() {
session_running="$(tmux list-sessions | grep $session)"
@@ -17,11 +17,11 @@ run_tmux_session() {
# run required launch files in order
tmux send-keys -t "$session:Base" "rl bitbots_utils base.launch" Enter
- tmux send-keys -t "$session:Launch" "rl humanoid_league_team_communication team_comm.launch" Enter
+ tmux send-keys -t "$session:Launch" "rl bitbots_team_communication team_comm.launch" Enter
# start test publisher/subscriber
- tmux send-keys -t "$session:Test.top" "rr humanoid_league_team_communication test_team_comm.py" Enter
- tmux send-keys -t "$session:Test.bottom" "rr humanoid_league_team_communication show_team_comm.py" Enter
+ tmux send-keys -t "$session:Test.top" "rr bitbots_team_communication test_team_comm.py" Enter
+ tmux send-keys -t "$session:Test.bottom" "rr bitbots_team_communication show_team_comm.py" Enter
fi
tmux attach-session -t "$session:Test"
diff --git a/bitbots_team_communication/setup.cfg b/bitbots_team_communication/setup.cfg
new file mode 100644
index 000000000..bf74a5f51
--- /dev/null
+++ b/bitbots_team_communication/setup.cfg
@@ -0,0 +1,4 @@
+[develop]
+script_dir=$base/lib/bitbots_team_communication
+[install]
+install_scripts=$base/lib/bitbots_team_communication
diff --git a/humanoid_league_misc/humanoid_league_team_communication/setup.py b/bitbots_team_communication/setup.py
similarity index 82%
rename from humanoid_league_misc/humanoid_league_team_communication/setup.py
rename to bitbots_team_communication/setup.py
index c32cdd8ae..c7defe03d 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/setup.py
+++ b/bitbots_team_communication/setup.py
@@ -1,6 +1,6 @@
from setuptools import find_packages, setup
-package_name = "humanoid_league_team_communication"
+package_name = "bitbots_team_communication"
setup(
name=package_name,
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/__init__.py b/bitbots_team_communication/test/__init__.py
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/test/__init__.py
rename to bitbots_team_communication/test/__init__.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_message_to_team_data_converter.ambr b/bitbots_team_communication/test/converter/__snapshots__/test_message_to_team_data_converter.ambr
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_message_to_team_data_converter.ambr
rename to bitbots_team_communication/test/converter/__snapshots__/test_message_to_team_data_converter.ambr
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_robocup_protocol_converter.ambr b/bitbots_team_communication/test/converter/__snapshots__/test_robocup_protocol_converter.ambr
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_robocup_protocol_converter.ambr
rename to bitbots_team_communication/test/converter/__snapshots__/test_robocup_protocol_converter.ambr
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_state_to_message_converter.ambr b/bitbots_team_communication/test/converter/__snapshots__/test_state_to_message_converter.ambr
similarity index 100%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/__snapshots__/test_state_to_message_converter.ambr
rename to bitbots_team_communication/test/converter/__snapshots__/test_state_to_message_converter.ambr
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_message_to_team_data_converter.py b/bitbots_team_communication/test/converter/test_message_to_team_data_converter.py
similarity index 94%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/test_message_to_team_data_converter.py
rename to bitbots_team_communication/test/converter/test_message_to_team_data_converter.py
index 83ef9a82e..e98bedd7c 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_message_to_team_data_converter.py
+++ b/bitbots_team_communication/test/converter/test_message_to_team_data_converter.py
@@ -1,9 +1,9 @@
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
import pytest
-from humanoid_league_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
from std_msgs.msg import Header
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import RobotRelative, Strategy, TeamData
+from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
own_team_id = 1
own_team_color = TeamColor(own_team_id)
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_robocup_protocol_converter.py b/bitbots_team_communication/test/converter/test_robocup_protocol_converter.py
similarity index 79%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/test_robocup_protocol_converter.py
rename to bitbots_team_communication/test/converter/test_robocup_protocol_converter.py
index 0734ddec6..b71aa41d6 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_robocup_protocol_converter.py
+++ b/bitbots_team_communication/test/converter/test_robocup_protocol_converter.py
@@ -1,10 +1,11 @@
from unittest.mock import MagicMock
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
import pytest
-from humanoid_league_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
from soccer_vision_attribute_msgs.msg import Robot as RobotAttributes
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
+from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
+
own_team_color = TeamColor.BLUE
@@ -55,13 +56,9 @@ def protocol_converter() -> RobocupProtocolConverter:
@pytest.fixture
def to_message_mock(mocker) -> MagicMock:
- return mocker.patch(
- "humanoid_league_team_communication.converter.robocup_protocol_converter.StateToMessageConverter"
- )
+ return mocker.patch("bitbots_team_communication.converter.robocup_protocol_converter.StateToMessageConverter")
@pytest.fixture
def from_message_mock(mocker) -> MagicMock:
- return mocker.patch(
- "humanoid_league_team_communication.converter.robocup_protocol_converter.MessageToTeamDataConverter"
- )
+ return mocker.patch("bitbots_team_communication.converter.robocup_protocol_converter.MessageToTeamDataConverter")
diff --git a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_state_to_message_converter.py b/bitbots_team_communication/test/converter/test_state_to_message_converter.py
similarity index 97%
rename from humanoid_league_misc/humanoid_league_team_communication/test/converter/test_state_to_message_converter.py
rename to bitbots_team_communication/test/converter/test_state_to_message_converter.py
index a768fa176..44d3b7ebd 100644
--- a/humanoid_league_misc/humanoid_league_team_communication/test/converter/test_state_to_message_converter.py
+++ b/bitbots_team_communication/test/converter/test_state_to_message_converter.py
@@ -1,6 +1,5 @@
from unittest.mock import Mock
-import humanoid_league_team_communication.robocup_extension_pb2 as Proto # noqa: N812
import numpy
import pytest
from game_controller_hl_interfaces.msg import GameState
@@ -15,15 +14,16 @@
Twist,
Vector3,
)
-from humanoid_league_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
-from humanoid_league_team_communication.humanoid_league_team_communication import HumanoidLeagueTeamCommunication
from rclpy.time import Time
from soccer_vision_3d_msgs.msg import Robot, RobotArray
from soccer_vision_attribute_msgs.msg import Confidence
from soccer_vision_attribute_msgs.msg import Robot as RobotAttributes
from std_msgs.msg import Header
+import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import Strategy
+from bitbots_team_communication.bitbots_team_communication import HumanoidLeagueTeamCommunication
+from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
own_team_id = 1
own_team_color = TeamColor(own_team_id)
diff --git a/bitbots_wolfgang/wolfgang_robocup_api/scripts/start.sh b/bitbots_wolfgang/wolfgang_robocup_api/scripts/start.sh
index d98029caa..4a2d9ba05 100755
--- a/bitbots_wolfgang/wolfgang_robocup_api/scripts/start.sh
+++ b/bitbots_wolfgang/wolfgang_robocup_api/scripts/start.sh
@@ -59,10 +59,10 @@ if [[ ! -d "$UTILS_DIR" ]]; then
exit 2
fi
-TEAM_COMM_DIR=$COLCON_PREFIX_PATH/humanoid_league_team_communication/share/humanoid_league_team_communication
+TEAM_COMM_DIR=$COLCON_PREFIX_PATH/bitbots_team_communication/share/bitbots_team_communication
if [[ ! -d "$TEAM_COMM_DIR" ]]; then
- echo "Could not find humanoid_league_team_communication!"
+ echo "Could not find bitbots_team_communication!"
exit 2
fi
diff --git a/humanoid_league_misc/humanoid_league_team_communication/.gitignore b/humanoid_league_misc/humanoid_league_team_communication/.gitignore
deleted file mode 100644
index c1da6f902..000000000
--- a/humanoid_league_misc/humanoid_league_team_communication/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-humanoid_league_team_communication/robocup_extension_pb2.py
diff --git a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_test_marker.launch b/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_test_marker.launch
deleted file mode 100644
index 34c76143b..000000000
--- a/humanoid_league_misc/humanoid_league_team_communication/launch/team_comm_test_marker.launch
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm.py b/humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm.py
deleted file mode 100755
index e926827a6..000000000
--- a/humanoid_league_misc/humanoid_league_team_communication/scripts/team_comm.py
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/usr/bin/env python3
-
-import sys
-
-from humanoid_league_team_communication.humanoid_league_team_communication import main
-
-sys.exit(main())
diff --git a/humanoid_league_misc/humanoid_league_team_communication/setup.cfg b/humanoid_league_misc/humanoid_league_team_communication/setup.cfg
deleted file mode 100644
index aed8a1a75..000000000
--- a/humanoid_league_misc/humanoid_league_team_communication/setup.cfg
+++ /dev/null
@@ -1,4 +0,0 @@
-[develop]
-script_dir=$base/lib/humanoid_league_team_communication
-[install]
-install_scripts=$base/lib/humanoid_league_team_communication
diff --git a/sync_includes_wolfgang_nuc.yaml b/sync_includes_wolfgang_nuc.yaml
index dbf330cbc..599fba0e4 100644
--- a/sync_includes_wolfgang_nuc.yaml
+++ b/sync_includes_wolfgang_nuc.yaml
@@ -32,6 +32,7 @@ include:
- bitbots_localization
- bitbots_localization_handler
- bitbots_path_planning
+ - bitbots_team_communication
- bitbots_vision
- bitbots_wolfgang:
- wolfgang_animations
@@ -40,8 +41,6 @@ include:
- bitbots_world_model:
- bitbots_ball_filter
- bitbots_robot_filter
- - humanoid_league_misc:
- - humanoid_league_team_communication
- lib:
- audio_common
- bio_ik
diff --git a/workspace.repos b/workspace.repos
index 3eaa3fb13..4f1002572 100644
--- a/workspace.repos
+++ b/workspace.repos
@@ -1,5 +1,5 @@
repositories:
- humanoid_league_misc/humanoid_league_team_communication/humanoid_league_team_communication/RobocupProtocol:
+ bitbots_team_communication/bitbots_team_communication/RobocupProtocol:
type: git
url: git@github.com:bit-bots/RobocupProtocol.git
lib/dynamic_stack_decider:
From 357d53c1b865e6c03a5fa4e3bc6b0c54b9c5f22c Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 12:18:08 +0100
Subject: [PATCH 4/6] Rename main team comm file
---
...league_team_communication.py => bitbots_team_communication.py} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename bitbots_team_communication/bitbots_team_communication/{humanoid_league_team_communication.py => bitbots_team_communication.py} (100%)
diff --git a/bitbots_team_communication/bitbots_team_communication/humanoid_league_team_communication.py b/bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py
similarity index 100%
rename from bitbots_team_communication/bitbots_team_communication/humanoid_league_team_communication.py
rename to bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py
From 1d18b878ee3b8693b913be8f2f81c13fc6173edf Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 12:18:35 +0100
Subject: [PATCH 5/6] testing script fixes
---
.../scripts/show_team_comm.py | 2 +-
.../scripts/test_team_comm.py | 5 ++++-
.../scripts/tmux_testing_setup.zsh | 13 ++++++-------
3 files changed, 11 insertions(+), 9 deletions(-)
diff --git a/bitbots_team_communication/scripts/show_team_comm.py b/bitbots_team_communication/scripts/show_team_comm.py
index 80c96c7d4..14e137f6b 100755
--- a/bitbots_team_communication/scripts/show_team_comm.py
+++ b/bitbots_team_communication/scripts/show_team_comm.py
@@ -105,7 +105,7 @@ def generate_string(self, data: TeamData):
lines.append(f" y: {round(data.ball_absolute.pose.position.y, 3):<4}")
lines.append(f" x_cov: {round(data.ball_absolute.covariance[0], 3):<4}")
lines.append(f" y_cov: {round(data.ball_absolute.covariance[7], 3):<4}")
- lines.append(f"Obstacles found: {len(data.obstacles.obstacles)}")
+ lines.append(f"Robots found: {len(data.robots.robots)}")
lines.append("Strategy")
lines.append(f" Role: {self.roles[data.strategy.role]:<9}")
lines.append(f" Action: {self.actions[data.strategy.action]:<15}")
diff --git a/bitbots_team_communication/scripts/test_team_comm.py b/bitbots_team_communication/scripts/test_team_comm.py
index 53d37c014..d392b3309 100755
--- a/bitbots_team_communication/scripts/test_team_comm.py
+++ b/bitbots_team_communication/scripts/test_team_comm.py
@@ -7,6 +7,7 @@
import rclpy
from game_controller_hl_interfaces.msg import GameState
from geometry_msgs.msg import Point, Pose, PoseWithCovariance, PoseWithCovarianceStamped, Quaternion, TransformStamped
+from rclpy.qos import QoSDurabilityPolicy, QoSProfile
from soccer_vision_3d_msgs.msg import Robot, RobotArray
from soccer_vision_attribute_msgs.msg import Robot as RobotAttributes
from tf2_ros import StaticTransformBroadcaster
@@ -51,7 +52,9 @@ def base_footprint_transform():
node = rclpy.create_node("test_team_comm")
tf_static_broadcaster = StaticTransformBroadcaster(node)
- gamestate_pub = node.create_publisher(GameState, "gamestate", 1)
+ gamestate_pub = node.create_publisher(
+ GameState, "gamestate", qos_profile=QoSProfile(depth=1, durability=QoSDurabilityPolicy.TRANSIENT_LOCAL)
+ )
strategy_pub = node.create_publisher(Strategy, "strategy", 1)
ball_pub = node.create_publisher(PoseWithCovarianceStamped, "ball_position_relative_filtered", 1)
position_pub = node.create_publisher(PoseWithCovarianceStamped, "pose_with_covariance", 1)
diff --git a/bitbots_team_communication/scripts/tmux_testing_setup.zsh b/bitbots_team_communication/scripts/tmux_testing_setup.zsh
index dd6cf059e..877e939c8 100755
--- a/bitbots_team_communication/scripts/tmux_testing_setup.zsh
+++ b/bitbots_team_communication/scripts/tmux_testing_setup.zsh
@@ -10,18 +10,16 @@ run_tmux_session() {
tmux new-session -d -s "$session"
# window/pane setup
- tmux rename-window -t "$session:1" "Launch"
- tmux new-window -t "$session:2" -n "Test"
+ tmux rename-window -t "$session:0" "Launch"
+ tmux new-window -t "$session:1" -n "Test"
tmux split-window -h
- tmux new-window -t "$session:3" -n "Base"
# run required launch files in order
- tmux send-keys -t "$session:Base" "rl bitbots_utils base.launch" Enter
- tmux send-keys -t "$session:Launch" "rl bitbots_team_communication team_comm.launch" Enter
+ tmux send-keys -t "$session:Launch" "rl bitbots_team_communication team_comm_standalone.launch" Enter
# start test publisher/subscriber
- tmux send-keys -t "$session:Test.top" "rr bitbots_team_communication test_team_comm.py" Enter
- tmux send-keys -t "$session:Test.bottom" "rr bitbots_team_communication show_team_comm.py" Enter
+ tmux send-keys -t "$session:Test.left" "rr bitbots_team_communication test_team_comm.py" Enter
+ tmux send-keys -t "$session:Test.right" "rr bitbots_team_communication show_team_comm.py" Enter
fi
tmux attach-session -t "$session:Test"
@@ -35,4 +33,5 @@ trap kill_session INT
cd "$COLCON_WS"
colcon build --symlink-install --packages-up-to "$pkg"
+source install/setup.zsh
run_tmux_session
From 2b4847084441292d9e40fdcfd88be924d40e4e57 Mon Sep 17 00:00:00 2001
From: Florian Vahl <7vahl@informatik.uni-hamburg.de>
Date: Wed, 31 Jan 2024 12:20:03 +0100
Subject: [PATCH 6/6] Rename main class
---
.../bitbots_team_communication/bitbots_team_communication.py | 4 ++--
.../test/converter/test_state_to_message_converter.py | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py b/bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py
index d11bc16ab..8a185f89e 100755
--- a/bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py
+++ b/bitbots_team_communication/bitbots_team_communication/bitbots_team_communication.py
@@ -27,7 +27,7 @@
from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
-class HumanoidLeagueTeamCommunication:
+class TeamCommunication:
def __init__(self):
self._package_path = get_package_share_directory("bitbots_team_communication")
self.node = Node("team_comm", automatically_declare_parameters_from_overrides=True)
@@ -240,7 +240,7 @@ def get_current_time(self) -> Time:
def main():
rclpy.init(args=None)
- HumanoidLeagueTeamCommunication()
+ TeamCommunication()
if __name__ == "__main__":
diff --git a/bitbots_team_communication/test/converter/test_state_to_message_converter.py b/bitbots_team_communication/test/converter/test_state_to_message_converter.py
index 44d3b7ebd..5fd888a4d 100644
--- a/bitbots_team_communication/test/converter/test_state_to_message_converter.py
+++ b/bitbots_team_communication/test/converter/test_state_to_message_converter.py
@@ -22,7 +22,7 @@
import bitbots_team_communication.robocup_extension_pb2 as Proto # noqa: N812
from bitbots_msgs.msg import Strategy
-from bitbots_team_communication.bitbots_team_communication import HumanoidLeagueTeamCommunication
+from bitbots_team_communication.bitbots_team_communication import TeamCommunication
from bitbots_team_communication.converter.robocup_protocol_converter import RobocupProtocolConverter, TeamColor
own_team_id = 1
@@ -305,7 +305,7 @@ def state_with_gamestate(state):
@pytest.fixture
def state():
- state = Mock(HumanoidLeagueTeamCommunication)
+ state = Mock(TeamCommunication)
state.player_id = 2
state.team_id = own_team_id
state.gamestate = None