From d5c0b68ceb68cb616ce095d219f99f50061bc809 Mon Sep 17 00:00:00 2001 From: Alex Davies Date: Thu, 14 Nov 2024 13:57:35 -0400 Subject: [PATCH] Also show model topics in rot_topics tab --- guiTools/spiri_sdk_guitools/sim_drone.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/guiTools/spiri_sdk_guitools/sim_drone.py b/guiTools/spiri_sdk_guitools/sim_drone.py index eeedf70..c7f3d2b 100644 --- a/guiTools/spiri_sdk_guitools/sim_drone.py +++ b/guiTools/spiri_sdk_guitools/sim_drone.py @@ -89,6 +89,7 @@ class Robot: robots.add(self) #Ros doesn't like dashes in node names self.robot_name = f"{self.robot_type}_{self.sysid}".replace("-","_") + self.world_name = "citadel_hill" async def ui_containers(self, element): docker_elements = {} @@ -137,7 +138,7 @@ class Robot: scroll_area.clear() #Filter for topics that start with self.robot_name for topic in node_dummy.get_topic_names_and_types(): - if topic[0].startswith(f"/{self.robot_name}/"): + if topic[0].startswith(f"/{self.robot_name}/") or topic[0].startswith(f"/world/{self.world_name}/model/{self.robot_name}/"): ui.label(topic[0]) await asyncio.sleep(10)