From b32b7fa9a3bfa9b0541f8c949bb129bcfbf621c6 Mon Sep 17 00:00:00 2001 From: hellschwalex Date: Tue, 19 Mar 2024 15:13:44 +0100 Subject: [PATCH] feat: first update, testing not finished --- doc/05_acting/01_acting_testing.md | 44 ++++++++++++++++++------ doc/05_acting/04_main_frame_publisher.md | 12 +++---- doc/05_acting/{ => OBSOLETE}/02_acc.md | 0 3 files changed, 39 insertions(+), 17 deletions(-) rename doc/05_acting/{ => OBSOLETE}/02_acc.md (100%) diff --git a/doc/05_acting/01_acting_testing.md b/doc/05_acting/01_acting_testing.md index 493e159e..3eeeea5f 100644 --- a/doc/05_acting/01_acting_testing.md +++ b/doc/05_acting/01_acting_testing.md @@ -1,36 +1,58 @@ -# How to test acting components +# Testing of Acting -**Summary:** This page shows ways to verify that acting components work as expected +**Summary:** This page shows ways to verify/test/tune/debug acting components. --- ## Author -Julian Graf +Alexander Hellmann ## Date -09.01.2023 +19.03.2024 +--- -* [How to test acting components](#how-to-test-acting-components) - * [Author](#author) - * [Date](#date) - * [velocity_controller](#velocitycontroller) - * [Dummys](#dummys) +- [Testing of Acting](#testing-of-acting) + - [Author](#author) + - [Date](#date) + - [Acting\_Debug\_Node](#acting_debug_node) + - [velocity\_controller](#velocity_controller) + - [Steering Controllers](#steering-controllers) + - [Dummys](#dummys) +--- + +## Acting_Debug_Node + +To test acting components independently from Perception and Planning, use the Acting_Debug_Node.py class in Acting. + +For this to work properly you have to manually disable all Planning and most of the Perception Components in your testing-branch: + +- Go to the planning.launch file (.../code/planning/launch/planning.launch) and disable every active node by commenting them out. +- Go to the perception.launch file (.../code/perception/launch/perception.launch) and disable every other node EXCEPT the Position_Publisher_Node.py and the kalman_filter.py by commenting them out. + +If you want to test/debug/tune under perfect conditions we also recommend following changes: + +- In the docker-compose.yml file (.../build/docker-compose.yml) you can switch to a developer enviroment by uncommenting the dev.launch (Line 65) and commenting the leaderboard (Line 66). +- In the dev_objects.json file (.../code/agent/config/dev_objects.json) you will find the GPS and IMU sensors. To use ideal sensors, set all noises to 0. +- In the perception.launch file, set the Position_Publisher_Node.py's pos_filter and heading_filter to None to get the ideal sensors' data (position and heading) unfiltered. + ## velocity_controller To test the velocity controller, set the parameter ```enabled``` in the acting launch-file true. Now the velocity_publisher_dummy will publish dummy target speeds. Use ```rqt_plot /carla/hero/velocity_as_float /carla/hero/max_velocity``` to visualize target and current speeds. ![image not found](./../00_assets/testing_velocity_pid.png) +## Steering Controllers + ## Dummys To test the steering controllers and the acc there are two dummys: -* the ```DummyTrajectoryPub``` publishes a simple path to test the steering controllers on, -* the ```AccDistancePublisherDummy``` publishes a dummy distances to an imaginary vehicle in front +- the ```DummyTrajectoryPub``` publishes a simple path to test the steering controllers on, +- the ```AccDistancePublisherDummy``` publishes a dummy distances to an imaginary vehicle in front To activate these dummys, make sure that they are started in the launch file and `````` is set in the launch file. diff --git a/doc/05_acting/04_main_frame_publisher.md b/doc/05_acting/04_main_frame_publisher.md index d6fa2ca7..3a0c3341 100644 --- a/doc/05_acting/04_main_frame_publisher.md +++ b/doc/05_acting/04_main_frame_publisher.md @@ -15,12 +15,12 @@ Julian Graf --- -* [Main frame publisher](#main-frame-publisher) - * [Author](#author) - * [Date](#date) - * [Main frame publisher](#main-frame-publisher-1) - * [How to use](#how-to-use) - * [Known issues](#known-issues) +- [Main frame publisher](#main-frame-publisher) + - [Author](#author) + - [Date](#date) + - [Main frame publisher](#main-frame-publisher-1) + - [How to use](#how-to-use) + - [Known issues](#known-issues) ## Main frame publisher diff --git a/doc/05_acting/02_acc.md b/doc/05_acting/OBSOLETE/02_acc.md similarity index 100% rename from doc/05_acting/02_acc.md rename to doc/05_acting/OBSOLETE/02_acc.md