From 636dfdec6a77c36b1fdd10a28be4c3a8eed9963c Mon Sep 17 00:00:00 2001 From: Beniamino Pozzan Date: Sun, 19 Feb 2023 11:55:41 -0800 Subject: [PATCH] VScode: fix tasks.json and launch_sitl.json after ign -> gazebo renaming PX4_SIM model need the simulator (gz_) prefix Fix post debug task Add x500_depth, rc_cessna, standard_vtol Signed-off-by: Beniamino Pozzan --- .vscode/tasks.json | 10 +++++----- platforms/posix/Debug/launch_sitl.json.in | 7 +++++-- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 7e04d089b0..80490d515f 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -170,7 +170,7 @@ ] }, { - "label": "ign gazebo", + "label": "gazebo", "type": "shell", "options": { "cwd": "${workspaceFolder}", @@ -178,7 +178,7 @@ "IGN_GAZEBO_RESOURCE_PATH": "${workspaceFolder}/Tools/simulation/gz/models", } }, - "command": "ign gazebo -v 4 -r ${workspaceFolder}/Tools/simulation/gz/worlds/${input:gzWorld}.sdf", + "command": "gz sim -v 4 -r ${workspaceFolder}/Tools/simulation/gz/worlds/${input:gzWorld}.sdf", "isBackground": true, "presentation": { "echo": true, @@ -191,7 +191,7 @@ "close": false }, "problemMatcher": [], - "dependsOn":["ign gazebo kill"] + "dependsOn":["gazebo kill"] }, { "label": "gazebo-classic kill", @@ -211,9 +211,9 @@ "dependsOn":["px4_sitl_cleanup"] }, { - "label": "ign gazebo kill", + "label": "gazebo kill", "type": "shell", - "command": "pkill -9 -f 'ign gazebo' || true", + "command": "pkill -9 -f 'gz sim' || true", "presentation": { "echo": true, "reveal": "never", diff --git a/platforms/posix/Debug/launch_sitl.json.in b/platforms/posix/Debug/launch_sitl.json.in index 56c295fb69..2fb0a4bc6b 100644 --- a/platforms/posix/Debug/launch_sitl.json.in +++ b/platforms/posix/Debug/launch_sitl.json.in @@ -14,11 +14,11 @@ "environment": [ { "name": "PX4_SIM_MODEL", - "value": "${input:PX4_GZ_MODEL}" + "value": "gz_${input:PX4_GZ_MODEL}" } ], "externalConsole": false, - "postDebugTask": "ign gazebo kill", + "postDebugTask": "gazebo kill", "linux": { "MIMode": "gdb", "externalConsole": false, @@ -222,6 +222,9 @@ "description": "GZ vehicle model", "options": [ "x500", + "x500_depth", + "rc_cessna", + "standard_vtol", ], "default": "x500" }