mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-14 10:07:39 +08:00
Remove obstacle avoidance test with Gazebo classic and ROS 1
This commit is contained in:
parent
0b370ab5d3
commit
ed9111ec49
4
Makefile
4
Makefile
@ -457,10 +457,6 @@ tests_offboard: rostest
|
||||
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_offboard_posctl.test
|
||||
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_offboard_rpyrt_ctl.test
|
||||
|
||||
tests_avoidance: rostest
|
||||
@"$(SRC_DIR)"/test/rostest_avoidance_run.sh mavros_posix_test_avoidance.test
|
||||
@"$(SRC_DIR)"/test/rostest_avoidance_run.sh mavros_posix_test_safe_landing.test
|
||||
|
||||
python_coverage:
|
||||
@mkdir -p "$(SRC_DIR)"/build/python_coverage
|
||||
@cd "$(SRC_DIR)"/build/python_coverage && cmake "$(SRC_DIR)" $(CMAKE_ARGS) -G"$(PX4_CMAKE_GENERATOR)" -DCONFIG=px4_sitl_default -DPYTHON_COVERAGE=ON
|
||||
|
||||
@ -1,30 +0,0 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# @name 3DR Iris Quadrotor SITL (Obstacle Avoidance)
|
||||
#
|
||||
# @type Quadrotor Wide
|
||||
#
|
||||
|
||||
. ${R}etc/init.d/rc.mc_defaults
|
||||
|
||||
|
||||
param set-default CA_AIRFRAME 0
|
||||
|
||||
param set-default CA_ROTOR_COUNT 4
|
||||
param set-default CA_ROTOR0_PX 0.1515
|
||||
param set-default CA_ROTOR0_PY 0.245
|
||||
param set-default CA_ROTOR0_KM 0.05
|
||||
param set-default CA_ROTOR1_PX -0.1515
|
||||
param set-default CA_ROTOR1_PY -0.1875
|
||||
param set-default CA_ROTOR1_KM 0.05
|
||||
param set-default CA_ROTOR2_PX 0.1515
|
||||
param set-default CA_ROTOR2_PY -0.245
|
||||
param set-default CA_ROTOR2_KM -0.05
|
||||
param set-default CA_ROTOR3_PX -0.1515
|
||||
param set-default CA_ROTOR3_PY 0.1875
|
||||
param set-default CA_ROTOR3_KM -0.05
|
||||
|
||||
param set-default PWM_MAIN_FUNC1 101
|
||||
param set-default PWM_MAIN_FUNC2 102
|
||||
param set-default PWM_MAIN_FUNC3 103
|
||||
param set-default PWM_MAIN_FUNC4 104
|
||||
@ -1,2 +0,0 @@
|
||||
# shellcheck disable=SC2154
|
||||
mavlink start -x -u 14558 -r 4000000 -m onboard -o 14541 -p # add mavlink stream for SDK
|
||||
@ -39,8 +39,6 @@ px4_add_romfs_files(
|
||||
1012_gazebo-classic_iris_rplidar
|
||||
1013_gazebo-classic_iris_vision
|
||||
1013_gazebo-classic_iris_vision.post
|
||||
1014_gazebo-classic_iris_obs_avoid
|
||||
1014_gazebo-classic_iris_obs_avoid.post
|
||||
1015_gazebo-classic_iris_depth_camera
|
||||
1016_gazebo-classic_iris_downward_depth_camera
|
||||
1017_gazebo-classic_iris_opt_flow_mockup
|
||||
|
||||
@ -1,88 +0,0 @@
|
||||
{
|
||||
"fileType": "Plan",
|
||||
"geoFence": {
|
||||
"circles": [
|
||||
],
|
||||
"polygons": [
|
||||
],
|
||||
"version": 2
|
||||
},
|
||||
"groundStation": "QGroundControl",
|
||||
"mission": {
|
||||
"cruiseSpeed": 15,
|
||||
"firmwareType": 12,
|
||||
"hoverSpeed": 5,
|
||||
"items": [
|
||||
{
|
||||
"AMSLAltAboveTerrain": null,
|
||||
"Altitude": 4,
|
||||
"AltitudeMode": 0,
|
||||
"autoContinue": true,
|
||||
"command": 22,
|
||||
"doJumpId": 1,
|
||||
"frame": 3,
|
||||
"params": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
null,
|
||||
47.3977432,
|
||||
8.5456085,
|
||||
4
|
||||
],
|
||||
"type": "SimpleItem"
|
||||
},
|
||||
{
|
||||
"AMSLAltAboveTerrain": null,
|
||||
"Altitude": 4,
|
||||
"AltitudeMode": 0,
|
||||
"autoContinue": true,
|
||||
"command": 16,
|
||||
"doJumpId": 2,
|
||||
"frame": 3,
|
||||
"params": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
null,
|
||||
47.3977432,
|
||||
8.5458765,
|
||||
4
|
||||
],
|
||||
"type": "SimpleItem"
|
||||
},
|
||||
{
|
||||
"AMSLAltAboveTerrain": null,
|
||||
"Altitude": -1,
|
||||
"AltitudeMode": 0,
|
||||
"autoContinue": true,
|
||||
"command": 21,
|
||||
"doJumpId": 3,
|
||||
"frame": 3,
|
||||
"params": [
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
null,
|
||||
47.3977432,
|
||||
8.5458812,
|
||||
-1
|
||||
],
|
||||
"type": "SimpleItem"
|
||||
}
|
||||
],
|
||||
"plannedHomePosition": [
|
||||
47.3977419,
|
||||
8.5458854,
|
||||
487.923
|
||||
],
|
||||
"vehicleType": 2,
|
||||
"version": 2
|
||||
},
|
||||
"rallyPoints": {
|
||||
"points": [
|
||||
],
|
||||
"version": 2
|
||||
},
|
||||
"version": 1
|
||||
}
|
||||
@ -80,7 +80,6 @@ if(gazebo_FOUND)
|
||||
iris_dual_gps
|
||||
iris_foggy_lidar
|
||||
iris_irlock
|
||||
iris_obs_avoid
|
||||
iris_depth_camera
|
||||
iris_downward_depth_camera
|
||||
iris_opt_flow
|
||||
|
||||
@ -1,52 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<launch>
|
||||
<!-- Posix SITL MAVROS integration tests -->
|
||||
<!-- Test a mission -->
|
||||
<arg name="est" default="ekf2"/>
|
||||
<arg name="gui" default="false"/>
|
||||
<arg name="interactive" default="false"/>
|
||||
<arg name="mission" default="avoidance"/>
|
||||
<arg name="sdf" default="$(find avoidance)/sim/models/iris_depth_camera_3/iris_depth_camera.sdf"/>
|
||||
<arg name="vehicle" default="iris_obs_avoid"/>
|
||||
<arg name="world" default="$(find avoidance)/sim/worlds/boxes1.world"/>
|
||||
<!-- PX4 SITL and Gazebo -->
|
||||
<include file="$(find px4)/launch/posix_sitl.launch">
|
||||
<arg name="est" value="$(arg est)"/>
|
||||
<arg name="gui" value="$(arg gui)"/>
|
||||
<arg name="interactive" value="$(arg interactive)"/>
|
||||
<arg name="respawn_gazebo" value="true"/>
|
||||
<arg name="sdf" value="$(arg sdf)"/>
|
||||
<arg name="vehicle" value="$(arg vehicle)"/>
|
||||
<arg name="verbose" value="true"/>
|
||||
<arg name="world" value="$(arg world)"/>
|
||||
</include>
|
||||
<!-- MAVROS -->
|
||||
<include file="$(find mavros)/launch/node.launch">
|
||||
<arg name="pluginlists_yaml" value="$(find mavros)/launch/px4_pluginlists.yaml"/>
|
||||
<arg name="config_yaml" value="$(find local_planner)/resource/px4_config.yaml"/>
|
||||
<arg name="gcs_url" value=""/>
|
||||
<arg name="fcu_url" value="udp://:14540@localhost:14557"/>
|
||||
<arg name="tgt_system" value="1"/>
|
||||
<arg name="tgt_component" value="1"/>
|
||||
<arg name="respawn_mavros" value="true"/>
|
||||
</include>
|
||||
<!-- Transformation Publishers -->
|
||||
<node pkg="tf" type="static_transform_publisher" name="tf_front_camera"
|
||||
args="0 0 0 -1.57 0 -1.57 fcu front_camera_link 10"/>
|
||||
<node pkg="tf" type="static_transform_publisher" name="tf_right_camera"
|
||||
args="0 0 0 -3.14 0 -1.57 fcu right_camera_link 10"/>
|
||||
<node pkg="tf" type="static_transform_publisher" name="tf_left_camera"
|
||||
args="0 0 0 0 0 -1.57 fcu left_camera_link 10"/>
|
||||
<!-- Suppress console outputs -->
|
||||
<env name="ROSCONSOLE_CONFIG_FILE" value="$(find local_planner)/resource/custom_rosconsole.conf"/>
|
||||
<!-- Launch Local Planner -->
|
||||
<arg name="pointcloud_topics" default="[/camera_front/depth/points,/camera_left/depth/points,/camera_right/depth/points]"/>
|
||||
<node name="local_planner_node" pkg="local_planner" type="local_planner_node" output="screen">
|
||||
<param name="goal_x_param" value="17" />
|
||||
<param name="goal_y_param" value="15"/>
|
||||
<param name="goal_z_param" value="3" />
|
||||
<rosparam param="pointcloud_topics" subst_value="True">$(arg pointcloud_topics)</rosparam>
|
||||
</node>
|
||||
<!-- ROStest -->
|
||||
<test test-name="$(arg mission)" pkg="px4" type="mission_test.py" time-limit="300.0" args="$(arg mission).plan"/>
|
||||
</launch>
|
||||
@ -1,20 +0,0 @@
|
||||
#! /bin/bash
|
||||
|
||||
DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
|
||||
PX4_SRC_DIR=${DIR}/..
|
||||
|
||||
source /opt/ros/${ROS_DISTRO:-kinetic}/setup.bash
|
||||
mkdir -p ${PX4_SRC_DIR}/catkin_ws/src
|
||||
cd ${PX4_SRC_DIR}/catkin_ws/
|
||||
git clone -b 0.3.1 --single-branch --depth 1 https://github.com/PX4/avoidance.git src/avoidance
|
||||
|
||||
catkin init
|
||||
catkin build local_planner safe_landing_planner --cmake-args -DCMAKE_BUILD_TYPE=Release
|
||||
|
||||
source ${PX4_SRC_DIR}/catkin_ws/devel/setup.bash
|
||||
source /usr/share/gazebo/setup.sh
|
||||
|
||||
export CATKIN_SETUP_UTIL_ARGS=--extend
|
||||
export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:${PX4_SRC_DIR}/catkin_ws/src/avoidance/avoidance/sim/models
|
||||
|
||||
source $DIR/rostest_px4_run.sh "$@"
|
||||
Loading…
x
Reference in New Issue
Block a user