Skip to content

Commit

Permalink
Merge remote-tracking branch 'px4/master' into pr-sensors_accel_gyro_…
Browse files Browse the repository at this point in the history
…calibration_cleanup
  • Loading branch information
dagar committed Jun 6, 2020
2 parents 86d1311 + af5c48b commit 5611ca5
Show file tree
Hide file tree
Showing 114 changed files with 5,543 additions and 989 deletions.
27 changes: 12 additions & 15 deletions .ci/Jenkinsfile-SITL_tests
Original file line number Diff line number Diff line change
Expand Up @@ -41,39 +41,36 @@ pipeline {
mission: "FW_mission_1",
vehicle: "plane"
],

[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
// [
// name: "MC_offboard_att",
// test: "mavros_posix_tests_offboard_attctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_rpyrt",
test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
mission: "",
vehicle: "iris"
],

// [
// name: "MC_offboard_rpyrt",
// test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "Rover 1",
test: "mavros_posix_test_mission.test",
mission: "rover_mission_1",
vehicle: "rover"
],

[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
Expand Down
27 changes: 12 additions & 15 deletions .ci/Jenkinsfile-SITL_tests_ASan
Original file line number Diff line number Diff line change
Expand Up @@ -41,39 +41,36 @@ pipeline {
mission: "FW_mission_1",
vehicle: "plane"
],

[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
// [
// name: "MC_offboard_att",
// test: "mavros_posix_tests_offboard_attctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_rpyrt",
test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
mission: "",
vehicle: "iris"
],

// [
// name: "MC_offboard_rpyrt",
// test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "Rover 1",
test: "mavros_posix_test_mission.test",
mission: "rover_mission_1",
vehicle: "rover"
],

[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
Expand Down
49 changes: 30 additions & 19 deletions .ci/Jenkinsfile-SITL_tests_coverage
Original file line number Diff line number Diff line change
Expand Up @@ -15,39 +15,36 @@ pipeline {
mission: "FW_mission_1",
vehicle: "plane"
],

[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
// [
// name: "MC_offboard_att",
// test: "mavros_posix_tests_offboard_attctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_rpyrt",
test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
mission: "",
vehicle: "iris"
],

// [
// name: "MC_offboard_rpyrt",
// test: "mavros_posix_tests_offboard_rpyrt_ctl.test",
// mission: "",
// vehicle: "iris"
// ],
[
name: "Rover 1",
test: "mavros_posix_test_mission.test",
mission: "rover_mission_1",
vehicle: "rover"
],

[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
Expand All @@ -60,11 +57,25 @@ pipeline {
mission: "VTOL_mission_1",
vehicle: "tailsitter"
],
[
name: "VTOL_tiltrotor",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tiltrotor"
],
// [
// name: "MC_avoidance",
// test: "mavros_posix_test_avoidance.test",
// mission: "avoidance",
// vehicle: "iris_obs_avoid",
// run_script: "rostest_avoidance_run.sh"
// ],
// [
// name: "VTOL_tiltrotor",
// test: "mavros_posix_test_mission.test",
// mission: "VTOL_mission_1",
// vehicle: "tiltrotor"
// name: "MC_safe_landing",
// test: "mavros_posix_test_safe_landing.test",
// mission: "MC_safe_landing",
// vehicle: "iris_obs_avoid",
// run_script: "rostest_avoidance_run.sh"
// ],

]
Expand Down
4 changes: 4 additions & 0 deletions .ci/Jenkinsfile-hardware
Original file line number Diff line number Diff line change
Expand Up @@ -811,6 +811,8 @@ void statusFTDI() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-FTDI_*` --cmd "uorb top -1 -a"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-FTDI_*` --cmd "ver all"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-FTDI_*` --cmd "work_queue status"'
// stop logger
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-FTDI_*` --cmd "logger off"'
}

void statusSEGGER() {
Expand Down Expand Up @@ -872,6 +874,8 @@ void statusSEGGER() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-SEGGER_*` --cmd "uorb top -1 -a"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-SEGGER_*` --cmd "ver all"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-SEGGER_*` --cmd "work_queue status"'
// stop logger
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-SEGGER_*` --cmd "logger off"'
}

void cleanupFTDI() {
Expand Down
12 changes: 12 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,18 @@ if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE ${PX4_BUILD_TYPE} CACHE STRING "Build type" FORCE)
endif()

if((CMAKE_BUILD_TYPE STREQUAL "Debug") OR (CMAKE_BUILD_TYPE STREQUAL "Coverage"))
set(MAX_CUSTOM_OPT_LEVEL -O0)
elseif(CMAKE_BUILD_TYPE MATCHES "Sanitizer")
set(MAX_CUSTOM_OPT_LEVEL -O1)
else()
if(px4_constrained_flash_build)
set(MAX_CUSTOM_OPT_LEVEL -Os)
else()
set(MAX_CUSTOM_OPT_LEVEL -O2)
endif()
endif()

set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug;Release;RelWithDebInfo;MinSizeRel;Coverage;AddressSanitizer;UndefinedBehaviorSanitizer")
message(STATUS "cmake build type: ${CMAKE_BUILD_TYPE}")

Expand Down
145 changes: 73 additions & 72 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,78 +8,79 @@ pipeline {

parallel {

stage('Catkin build on ROS workspace') {
agent {
docker {
image 'px4io/px4-dev-ros-melodic:2020-04-01'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'ls -l'
sh '''#!/bin/bash -l
echo $0;
mkdir -p catkin_ws/src;
cd catkin_ws;
git -C ${WORKSPACE}/catkin_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
git clone --recursive ${WORKSPACE}/catkin_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
git -C ${WORKSPACE}/catkin_ws/src/Firmware fetch --tags;
source /opt/ros/melodic/setup.bash;
export PYTHONPATH=/opt/ros/$ROS_DISTRO/lib/python2.7/dist-packages:/usr/lib/python2.7/dist-packages:/usr/local/lib/python2.7/dist-packages;
catkin init;
catkin build -j$(nproc) -l$(nproc);
'''
// test if the binary was correctly installed and runs using 'mavros_posix_silt.launch'
sh '''#!/bin/bash -l
echo $0;
source catkin_ws/devel/setup.bash;
rostest px4 pub_test.launch;
'''
}
post {
always {
sh 'rm -rf catkin_ws'
}
failure {
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.xml, .ros/**/*.log')
}
}
options {
checkoutToSubdirectory('catkin_ws/src/Firmware')
}
}

stage('Colcon build on ROS2 workspace') {
agent {
docker {
image 'px4io/px4-dev-ros2-dashing:2020-04-01'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'ls -l'
sh '''#!/bin/bash -l
echo $0;
unset ROS_DISTRO;
mkdir -p colcon_ws/src;
cd colcon_ws;
git -C ${WORKSPACE}/colcon_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
git clone --recursive ${WORKSPACE}/colcon_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
git -C ${WORKSPACE}/colcon_ws/src/Firmware fetch --tags;
source /opt/ros/bouncy/setup.sh;
source /opt/ros/melodic/setup.sh;
colcon build --event-handlers console_direct+ --symlink-install;
'''
}
post {
always {
sh 'rm -rf colcon_ws'
}
}
options {
checkoutToSubdirectory('colcon_ws/src/Firmware')
}
}
// TODO: temporarily disabled 2020-06-03 waiting on mavlink update
// stage('Catkin build on ROS workspace') {
// agent {
// docker {
// image 'px4io/px4-dev-ros-melodic:2020-04-01'
// args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
// }
// }
// steps {
// sh 'ls -l'
// sh '''#!/bin/bash -l
// echo $0;
// mkdir -p catkin_ws/src;
// cd catkin_ws;
// git -C ${WORKSPACE}/catkin_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
// git clone --recursive ${WORKSPACE}/catkin_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
// git -C ${WORKSPACE}/catkin_ws/src/Firmware fetch --tags;
// source /opt/ros/melodic/setup.bash;
// export PYTHONPATH=/opt/ros/$ROS_DISTRO/lib/python2.7/dist-packages:/usr/lib/python2.7/dist-packages:/usr/local/lib/python2.7/dist-packages;
// catkin init;
// catkin build -j$(nproc) -l$(nproc);
// '''
// // test if the binary was correctly installed and runs using 'mavros_posix_silt.launch'
// sh '''#!/bin/bash -l
// echo $0;
// source catkin_ws/devel/setup.bash;
// rostest px4 pub_test.launch;
// '''
// }
// post {
// always {
// sh 'rm -rf catkin_ws'
// }
// failure {
// archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.xml, .ros/**/*.log')
// }
// }
// options {
// checkoutToSubdirectory('catkin_ws/src/Firmware')
// }
// }
//
// stage('Colcon build on ROS2 workspace') {
// agent {
// docker {
// image 'px4io/px4-dev-ros2-dashing:2020-04-01'
// args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
// }
// }
// steps {
// sh 'ls -l'
// sh '''#!/bin/bash -l
// echo $0;
// unset ROS_DISTRO;
// mkdir -p colcon_ws/src;
// cd colcon_ws;
// git -C ${WORKSPACE}/colcon_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
// git clone --recursive ${WORKSPACE}/colcon_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
// git -C ${WORKSPACE}/colcon_ws/src/Firmware fetch --tags;
// source /opt/ros/bouncy/setup.sh;
// source /opt/ros/melodic/setup.sh;
// colcon build --event-handlers console_direct+ --symlink-install;
// '''
// }
// post {
// always {
// sh 'rm -rf colcon_ws'
// }
// }
// options {
// checkoutToSubdirectory('colcon_ws/src/Firmware')
// }
// }

stage('Style check') {
agent {
Expand Down
Loading

0 comments on commit 5611ca5

Please sign in to comment.