From cdfef7d48019d379aa84803c760d1c477f9d8914 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Wed, 17 May 2023 16:32:31 +0200 Subject: [PATCH 01/27] subm: added mocap_bridge --- .gitmodules | 3 +++ src/mocap_bridge | 1 + 2 files changed, 4 insertions(+) create mode 160000 src/mocap_bridge diff --git a/.gitmodules b/.gitmodules index 80a5413..5cda464 100644 --- a/.gitmodules +++ b/.gitmodules @@ -46,3 +46,6 @@ [submodule "src/mavlink-gbp-release"] path = src/mavlink-gbp-release url = https://github.com/aau-cns/mavlink-gbp-release.git +[submodule "src/mocap_bridge"] + path = src/mocap_bridge + url = https://github.com/aau-cns/mocap_bridge.git diff --git a/src/mocap_bridge b/src/mocap_bridge new file mode 160000 index 0000000..f8a62a8 --- /dev/null +++ b/src/mocap_bridge @@ -0,0 +1 @@ +Subproject commit f8a62a84d36db892ac098315957eb11b0f7bda13 From b66612e62e7dcc1f0ea4fffa1f16d821aaaed480 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Tue, 30 May 2023 11:24:43 +0200 Subject: [PATCH 02/27] fix: issue with recording script --- .../configs/global/fs_vars.env | 4 ++ .../record_scripts/record_full.sh | 43 +++++++++++++++---- 2 files changed, 39 insertions(+), 8 deletions(-) diff --git a/src/flightstack/flightstack_bringup/configs/global/fs_vars.env b/src/flightstack/flightstack_bringup/configs/global/fs_vars.env index a88500e..203d040 100755 --- a/src/flightstack/flightstack_bringup/configs/global/fs_vars.env +++ b/src/flightstack/flightstack_bringup/configs/global/fs_vars.env @@ -1,5 +1,9 @@ #!/usr/bin/env bash +# path related variables +export FS_SCRIPTS_PATH=$(rospack find flightstack_scripts) +export FS_VARS_FILE=$(rospack find flightstack_bringup)/configs/global/fs_vars.env + # object tracking related variables export FS_OPTITRACK_OBJECT_NAME="cnsuav" diff --git a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh index 6251a35..f537017 100755 --- a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh +++ b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh @@ -48,11 +48,12 @@ path_media="" DEV1_CAM_NODELET_MANAGER="record_dev1_manager" DEV2_CAM_NODELET_MANAGER="record_dev2_manager" -B_CAMS_START_MANAGER=true +B_CAMS_START_MANAGER=false # booleans (flags) B_USE_ROSBAG_RECORD=false B_DEBUG_ON=false +B_DRY_RUN=false ################################################################################ # Help # @@ -75,7 +76,9 @@ print_help(){ echo "" echo " -b use 'rosbag record' instead of the flight stack's" echo " 'nodlet recorder'" - echo " -c use 'nodelet_manager' for standard recording settings" + echo " -c use 'nodelet_manager' for camera recording settings" + echo " -s enable starting of camera recording manager" + echo " -n dry-run" echo " -v enable detailed debug output" echo "" echo " -h print this help" @@ -103,7 +106,7 @@ fi OPTIND=$((OPTIND+1)); # parse flags -while getopts hvbcl:m:p: flag +while getopts hvsnbcl:m:p: flag do case "${flag}" in l) path_local=${OPTARG};; @@ -111,10 +114,12 @@ do p) bag_name=${OPTARG};; c) DEV1_CAM_NODELET_MANAGER="nodelet_manager"; - DEV2_CAM_NODELET_MANAGER="nodelet_manager"; - B_CAMS_START_MANAGER=false;; + DEV2_CAM_NODELET_MANAGER="nodelet_manager";; + + s) B_CAMS_START_MANAGER=true;; b) B_USE_ROSBAG_RECORD=true;; + n) B_DRY_RUN=true;; v) B_DEBUG_ON=true;; h) print_help;; @@ -143,6 +148,12 @@ if [ ! -d "${path_media}" ]; then mkdir -p ${path_media} fi +################################################################################ +# GET GLOBAL VARS # +################################################################################ + +source ${FS_VARS_FILE} + ################################################################################ # SETUP TOPIC GROUPS # ################################################################################ @@ -219,6 +230,13 @@ ${px4_topics[@]} ${FS_RECORD_ADD_DEV1_SENSOR[@]} ) +if [ ${B_DEBUG_ON} == true ]; then + echo "sensor additions: ${#FS_RECORD_ADD_DEV1_SENSOR[@]}" + for entry in ${FS_RECORD_ADD_DEV1_SENSOR[@]}; do + echo "${entry}" + done +fi + ### Nodes group_mod1_nodes=( ${autonomy_topics[@]} @@ -234,6 +252,13 @@ group_mod1_cams=( ${FS_RECORD_ADD_DEV1_CAM[@]} ) +if [ ${B_DEBUG_ON} == true ]; then + echo "cam additions: ${#FS_RECORD_ADD_DEV1_CAM[@]}" + for entry in ${FS_RECORD_ADD_DEV1_CAM[@]}; do + echo "${entry}" + done +fi + # generate final list of topics for recording - dev1 if [ ${B_USE_ROSBAG_RECORD} == true ]; then @@ -503,7 +528,7 @@ else start_manager:=${B_CAMS_START_MANAGER} nodelet_manager_name:=${DEV1_CAM_NODELET_MANAGER} nodelet_name:=record_dev1_cams - rosbag_path:=${path_local} rosbag_prefix:=${bag_name}_mod1_cams + rosbag_path:=${path_media} rosbag_prefix:=${bag_name}_mod1_cams rosbag_topics:=[${topics_mod1_cams%,}]" ) fi @@ -528,10 +553,12 @@ echo "" # execute recording in bkg for cmd in "${RECORD_CMD_ARR[@]}"; do - if [ ${B_DEBUG_ON} == true ]; then + if [ ${B_DEBUG_ON} == true ] || [ ${B_DRY_RUN} == true ]; then echo -e "${COL_DEB}executing: ${cmd}${NC}" fi - ${cmd} & + if [ ${B_DRY_RUN} != true ]; then + ${cmd} & + fi done if [ ${B_DEBUG_ON} = true ]; then From 37296ad384f4dfaadae71b411bed53b091244232 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 5 Oct 2023 14:39:36 +0200 Subject: [PATCH 03/27] fix: added exec check for create_bringup --- scripts/create_bringup.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/create_bringup.sh b/scripts/create_bringup.sh index e6ca7c9..6b75f77 100755 --- a/scripts/create_bringup.sh +++ b/scripts/create_bringup.sh @@ -98,6 +98,15 @@ WORKSPACE_SRC=${PATH_WS}/${CONFIG_NAME}_cws/src PACKAGE_DIR=${PATH_WS}/${CONFIG_NAME}_cws/src/${CONFIG_NAME} BRINGUP_DIR=${PATH_WS}/${CONFIG_NAME}_cws/src/${CONFIG_NAME}/${CONFIG_NAME}_bringup +# check if executed in correct folder +if [ ! -d 'scripts' ]; then + echo "${COL_ERR}No 'scripts' folder found, please execute this script in the root directory of the flightstack_cws.${NC}" + exit 1; +elif [ ! -f 'scripts/create_bringup.sh' ] + echo "${COL_ERR}No 'create_bringup' script found within the './scripts' folder, please execute this script in the root directory of the flightstack_cws.${NC}" + exit 1; +fi + # create directory and copy template mkdir -p ${PACKAGE_DIR} rsync -avPh $(pwd)/src/flightstack/template_config/ ${PACKAGE_DIR} From 31c6bef49e2bc6119cf8ddc7678f26fbcb51008d Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 5 Oct 2023 14:40:13 +0200 Subject: [PATCH 04/27] subm: updated mission sequencer --- .../flightstack_scripts/record_scripts/record_full.sh | 2 ++ src/mission_sequencer | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh index f537017..d650bb9 100755 --- a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh +++ b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh @@ -183,6 +183,8 @@ autonomy_topics=( ms_topics=( "/mission_sequencer/waypoint_list" +"/mission_sequencer/get_waypoint_list" +"/mission_sequencer/waypoint_reached" "/mavros/setpoint_position/local" "/mavros/setpoint_position/global" "/mavros/state" diff --git a/src/mission_sequencer b/src/mission_sequencer index 33ad1a3..f7a0fa7 160000 --- a/src/mission_sequencer +++ b/src/mission_sequencer @@ -1 +1 @@ -Subproject commit 33ad1a3644093fe8d09d2d200851895ccbe3c612 +Subproject commit f7a0fa7897ea94db52d080fba41561127276a520 From caae5133e900e5ab0a91db6c413d0e1ea9ef0227 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 5 Oct 2023 14:51:41 +0200 Subject: [PATCH 05/27] add: added option to have RS device locally or on second device Closes #10. --- .../driver_scripts/rs_check.sh | 33 ++++++++++++++----- .../driver_scripts/rs_restart.sh | 24 ++++++++++---- 2 files changed, 42 insertions(+), 15 deletions(-) diff --git a/src/flightstack/flightstack_scripts/driver_scripts/rs_check.sh b/src/flightstack/flightstack_scripts/driver_scripts/rs_check.sh index 67a94da..a6ef569 100755 --- a/src/flightstack/flightstack_scripts/driver_scripts/rs_check.sh +++ b/src/flightstack/flightstack_scripts/driver_scripts/rs_check.sh @@ -9,20 +9,37 @@ # in the LICENSE file. No license in patents is granted. # # You can contact the author at -# and +# and . # this bash script adheres to linux exit codes # see https://tldp.org/LDP/abs/html/exitcodes.html for further information -# echo "[BASH - RS] checking sensor - Realsense" +RS_IS_REMOTE=false +RS_DEV_IP="10.42.0.102" +RS_DEV_USER="flightstack" + + +if [ ${RS_IS_REMOTE} == true ]; then + # echo "[BASH - RS] checking sensor - Realsense" + RS_CHECK="$(ssh ${RS_DEV_USER}@${RS_DEV_IP} 'rs-enumerate-devices')" + # echo "[BASH - RS] status: ${RS_CHECK}" + + # check if device is found in lsusb + RS_ID="8087:0b37" + RS_STATUS="$(ssh ${RS_DEV_USER}@${RS_DEV_IP} 'lsusb' | grep ${RS_ID})" + # echo "[BASH - RS] status: ${RS_STATUS}" +else + # echo "[BASH - RS] checking sensor - Realsense" + RS_CHECK="$(rs-enumerate-devices)" + # echo "[BASH - RS] status: ${RS_CHECK}" + + # check if device is found in lsusb + RS_ID="8087:0b37" + RS_STATUS="$(lsusb | grep ${RS_ID})" + # echo "[BASH - RS] status: ${RS_STATUS}" +fi -RS_CHECK="$(rs-enumerate-devices)" -# echo "[BASH - RS] status: ${RS_CHECK}" -# check if device is found in lsusb -RS_ID="8087:0b37" -RS_STATUS="$(ssh core@10.42.0.102 'lsusb' | grep ${RS_ID})" -# echo "[BASH - RS] status: ${RS_STATUS}" case $RS_STATUS in "") diff --git a/src/flightstack/flightstack_scripts/driver_scripts/rs_restart.sh b/src/flightstack/flightstack_scripts/driver_scripts/rs_restart.sh index 449f4e0..7e28baf 100755 --- a/src/flightstack/flightstack_scripts/driver_scripts/rs_restart.sh +++ b/src/flightstack/flightstack_scripts/driver_scripts/rs_restart.sh @@ -14,12 +14,22 @@ # this bash script adheres to linux exit codes # see https://tldp.org/LDP/abs/html/exitcodes.html for further information -# restart realsense hub -# ssh core@10.42.0.102 'sudo uhubctl -a off --delay 2 -e -R -l2 -p1' -# command by chris -#ssh core@10.42.0.102 'sudo uhubctl --action cycle --location 2' -ssh core@10.42.0.102 'sudo uhubctl --action cycle --location 2 -R --delay 5' -sleep 5 -ssh core@10.42.0.102 'rs-enumerate-devices' +RS_IS_REMOTE=false +RS_DEV_IP="10.42.0.102" +RS_DEV_USER="flightstack" + +if [ ${RS_IS_REMOTE} == true ]; then + # restart realsense hub + # ssh core@10.42.0.102 'sudo uhubctl -a off --delay 2 -e -R -l2 -p1' + # command by chris + #ssh core@10.42.0.102 'sudo uhubctl --action cycle --location 2' + ssh ${RS_DEV_USER}@${RS_DEV_IP} 'sudo uhubctl --action cycle --location 2 -R --delay 5' + sleep 5 + ssh ${RS_DEV_USER}@${RS_DEV_IP} 'rs-enumerate-devices' +else + sudo uhubctl --action cycle --location 2 -R --delay 5 + sleep 5 + rs-enumerate-devices +fi exit 0 From e0688059717976e541e4d7eb6d4ce29d73ba49ac Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 5 Oct 2023 14:55:42 +0200 Subject: [PATCH 06/27] fix: removed trailing '/' for topic names Allows usage of ROS namespaces in launchfile --- .../launch/fs_operator.launch | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/flightstack/flightstack_bringup/launch/fs_operator.launch b/src/flightstack/flightstack_bringup/launch/fs_operator.launch index c591d23..bb9b90f 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_operator.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_operator.launch @@ -22,21 +22,21 @@ You can contact the authors at , - - - - - - - + + + + + + + - - - - - - + + + + + + From 77b86dfc3b7209a6b44ce5e8a04900dc6d8a72c1 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 5 Oct 2023 14:58:06 +0200 Subject: [PATCH 07/27] add: updates to px4 launchfile for more params --- .../launch/fs_sensors.launch | 15 ++++++--- .../launch/individual/px4.launch | 31 +++++++++++++++++-- 2 files changed, 38 insertions(+), 8 deletions(-) diff --git a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch index 02b7913..7a411a3 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch @@ -1,6 +1,6 @@ - - - - + + + + + + @@ -29,6 +31,9 @@ You can contact the authors at , + + + diff --git a/src/flightstack/flightstack_bringup/launch/individual/px4.launch b/src/flightstack/flightstack_bringup/launch/individual/px4.launch index 6f7f7a9..90a5ec7 100644 --- a/src/flightstack/flightstack_bringup/launch/individual/px4.launch +++ b/src/flightstack/flightstack_bringup/launch/individual/px4.launch @@ -1,6 +1,6 @@ + + + + + + + + + + + + + + + + + + + + + + From 2be7ccea7bd82391a611e3d8f0f8b4ee146219dd Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Fri, 6 Oct 2023 10:45:57 +0200 Subject: [PATCH 08/27] subm: updated modules for autonomy and toland --- src/autonomy_engine | 2 +- src/toland_flight | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/autonomy_engine b/src/autonomy_engine index faade34..4ffd7da 160000 --- a/src/autonomy_engine +++ b/src/autonomy_engine @@ -1 +1 @@ -Subproject commit faade344b119dcca82f6f27b8502deb8a9d6c045 +Subproject commit 4ffd7da96692fa995b00d79c7a12107257cd72ab diff --git a/src/toland_flight b/src/toland_flight index 20dd57f..917e7e9 160000 --- a/src/toland_flight +++ b/src/toland_flight @@ -1 +1 @@ -Subproject commit 20dd57f321f657506616be4eacf5e9cf35059fa9 +Subproject commit 917e7e9c0eb0c646dd06a3d8c1103d24fdfdca03 From 7d597fe0db6288476f18b8ac87e78ca52c8ca2a0 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Fri, 6 Oct 2023 17:36:01 +0200 Subject: [PATCH 09/27] fix: fixed issue with mission sequencer --- src/mission_sequencer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mission_sequencer b/src/mission_sequencer index f7a0fa7..80397b6 160000 --- a/src/mission_sequencer +++ b/src/mission_sequencer @@ -1 +1 @@ -Subproject commit f7a0fa7897ea94db52d080fba41561127276a520 +Subproject commit 80397b6a4e5beb6477d7fbb4d1f9cb84e0bece8a From a33188ea1314d1a910289205600923945e9fe491 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Wed, 11 Oct 2023 15:48:12 +0200 Subject: [PATCH 10/27] subm: updated MaRS to latest dev --- src/mars_ros | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mars_ros b/src/mars_ros index 58b1e99..d1b152d 160000 --- a/src/mars_ros +++ b/src/mars_ros @@ -1 +1 @@ -Subproject commit 58b1e99621ce921bb5a55511235ed239f85493da +Subproject commit d1b152d21ace9b98e44d29bf1edf14e5e3af6923 From 7dff713f9b19fdc05b75c8c48e9e6d863525ba70 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Fri, 20 Oct 2023 13:46:19 +0200 Subject: [PATCH 11/27] fix: removed error message from rsync test As error is in some cases expected, hence the test, removed the msg from displaying. --- .../store_scripts/safe_merge_data_single_dev.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh b/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh index 5ad5d4b..415fe5b 100755 --- a/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh +++ b/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh @@ -136,12 +136,13 @@ RSYNC_CMD="rsync -rptgoDL" # check if rsync is permited with these options to destdir echo "testing rsync" >> /tmp/rsync_test.log -${RSYNC_CMD} /tmp/rsync_test.log ${DIR_NAME}/ +${RSYNC_CMD} /tmp/rsync_test.log ${DIR_NAME}/ 2> /dev/null if [ $? -eq 0 ]; then # rsync succeeded, remove test file rm -rf ${DIR_NAME}/rsync_test.log else # failed rsync, change to simpler version, fewer permitions + echo -e "${COL_WARN}rsync test failed, changing to simpler version${NC}" RSYNC_CMD="rsync -rpDL -A --no-perms" # remove test file, if exists From a3072fcf80dc559c630cc51968d127d16c48985a Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 12 Oct 2023 17:08:04 +0200 Subject: [PATCH 12/27] subm: updated watchdog with minor topic naming fix --- src/ros_watchdog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ros_watchdog b/src/ros_watchdog index c62b5a4..d1b696c 160000 --- a/src/ros_watchdog +++ b/src/ros_watchdog @@ -1 +1 @@ -Subproject commit c62b5a4db49914ba910eaa1e8575ba48376d1d4a +Subproject commit d1b696c789756a4f07faff8c3c46daf826d58427 From 528b6a593e6fe0c31de0ea61a3fd984e3e2b8d24 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 12 Oct 2023 17:08:38 +0200 Subject: [PATCH 13/27] add: launchfile changes to account for namespace --- .../launch/fs_estimation.launch | 17 +++--- .../launch/fs_namespace.launch | 53 +++++++++++++++++++ .../launch/fs_navigation.launch | 9 +++- .../launch/fs_operator.launch | 35 +++++++----- .../launch/fs_recording.launch | 51 ++++++++++-------- .../launch/fs_safety.launch | 23 ++++++-- .../launch/fs_sensors.launch | 5 ++ 7 files changed, 144 insertions(+), 49 deletions(-) create mode 100644 src/flightstack/flightstack_bringup/launch/fs_namespace.launch diff --git a/src/flightstack/flightstack_bringup/launch/fs_estimation.launch b/src/flightstack/flightstack_bringup/launch/fs_estimation.launch index 9e50f3d..6054e91 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_estimation.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_estimation.launch @@ -14,6 +14,11 @@ You can contact the authors at , + + + + + @@ -22,12 +27,12 @@ You can contact the authors at , - - - - - - + + + + + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_namespace.launch b/src/flightstack/flightstack_bringup/launch/fs_namespace.launch new file mode 100644 index 0000000..c21cf71 --- /dev/null +++ b/src/flightstack/flightstack_bringup/launch/fs_namespace.launch @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_navigation.launch b/src/flightstack/flightstack_bringup/launch/fs_navigation.launch index 09eed89..7b6b09b 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_navigation.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_navigation.launch @@ -14,6 +14,11 @@ You can contact the authors at , + + + + + @@ -37,8 +42,8 @@ You can contact the authors at , - - + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_operator.launch b/src/flightstack/flightstack_bringup/launch/fs_operator.launch index bb9b90f..f0a258f 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_operator.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_operator.launch @@ -14,6 +14,11 @@ You can contact the authors at , + + + + + @@ -22,21 +27,22 @@ You can contact the authors at , - - - - - - - + + + + + + + + - - - - - - + + + + + + @@ -45,7 +51,7 @@ You can contact the authors at , - + @@ -76,6 +82,7 @@ You can contact the authors at , + diff --git a/src/flightstack/flightstack_bringup/launch/fs_recording.launch b/src/flightstack/flightstack_bringup/launch/fs_recording.launch index 2dd343b..dc927ce 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_recording.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_recording.launch @@ -13,27 +13,32 @@ You can contact the authors at , - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_safety.launch b/src/flightstack/flightstack_bringup/launch/fs_safety.launch index bdf3d98..aee93f0 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_safety.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_safety.launch @@ -14,6 +14,11 @@ You can contact the authors at , + + + + + @@ -28,17 +33,22 @@ You can contact the authors at , + + + + + - - - + + + - + @@ -50,6 +60,11 @@ You can contact the authors at , + + + + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch index 7a411a3..e63a151 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch @@ -19,6 +19,11 @@ You can contact the authors at , + + + + + From 98d7cb94e3fd7fa54b26f6b259a3f54ad1636b12 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Fri, 20 Oct 2023 13:45:42 +0200 Subject: [PATCH 14/27] maint: update of templates for namespace config --- .../launch/fs_namespace.launch | 37 +++++++++++-- .../launch/fs_navigation.launch | 13 +++++ .../launch/template_estimation.launch | 2 +- .../launch/template_namespace.launch | 53 +++++++++++++++++++ .../launch/template_navigation.launch | 2 +- .../launch/template_operator.launch | 2 +- .../launch/template_recording.launch | 2 +- .../launch/template_safety.launch | 2 +- .../launch/template_sensors.launch | 2 +- 9 files changed, 106 insertions(+), 9 deletions(-) create mode 100644 src/flightstack/template_config/template_bringup/launch/template_namespace.launch diff --git a/src/flightstack/flightstack_bringup/launch/fs_namespace.launch b/src/flightstack/flightstack_bringup/launch/fs_namespace.launch index c21cf71..4b58f9d 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_namespace.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_namespace.launch @@ -12,42 +12,73 @@ You can contact the author at --> - - + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/flightstack/flightstack_bringup/launch/fs_navigation.launch b/src/flightstack/flightstack_bringup/launch/fs_navigation.launch index 7b6b09b..364e27c 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_navigation.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_navigation.launch @@ -45,6 +45,19 @@ You can contact the authors at , + + + + + + + + + + + + + diff --git a/src/flightstack/template_config/template_bringup/launch/template_estimation.launch b/src/flightstack/template_config/template_bringup/launch/template_estimation.launch index 8e3ba3c..1c28427 100644 --- a/src/flightstack/template_config/template_bringup/launch/template_estimation.launch +++ b/src/flightstack/template_config/template_bringup/launch/template_estimation.launch @@ -1,6 +1,6 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/flightstack/template_config/template_bringup/launch/template_navigation.launch b/src/flightstack/template_config/template_bringup/launch/template_navigation.launch index ccde691..43f8c81 100644 --- a/src/flightstack/template_config/template_bringup/launch/template_navigation.launch +++ b/src/flightstack/template_config/template_bringup/launch/template_navigation.launch @@ -1,6 +1,6 @@ - - - - - + + + + + + + diff --git a/src/ros_watchdog b/src/ros_watchdog index d1b696c..04ec32e 160000 --- a/src/ros_watchdog +++ b/src/ros_watchdog @@ -1 +1 @@ -Subproject commit d1b696c789756a4f07faff8c3c46daf826d58427 +Subproject commit 04ec32e983615da7106212b7c8c36fbe8ac0dd5c From a69c8cfa95a54bfa8ba66bdf5bdd208d87e34dc9 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Fri, 20 Oct 2023 14:39:53 +0200 Subject: [PATCH 16/27] subm: fixed issue with namespace in datarecorder --- src/data_recorder | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data_recorder b/src/data_recorder index 9c02347..073bf10 160000 --- a/src/data_recorder +++ b/src/data_recorder @@ -1 +1 @@ -Subproject commit 9c0234717dca76ac3734d86ec230646ec1ac56bc +Subproject commit 073bf10aa381c316e0db819dbc81fe606a0cbf21 From 402d04297a61311c7e62cda5494b56d2ae64ef4b Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Wed, 20 Dec 2023 12:08:27 +0100 Subject: [PATCH 17/27] fix: template issue of not having FS_VARS variable Bugfix: 2023.12.20/7ddc76b2-6f80-4c4c-ab32-fa195325609d --- .../flightstack_bringup/configs/global/fs_vars.env | 2 +- .../template_bringup/configs/global/template_vars.env | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/flightstack/flightstack_bringup/configs/global/fs_vars.env b/src/flightstack/flightstack_bringup/configs/global/fs_vars.env index 203d040..7ea02b2 100755 --- a/src/flightstack/flightstack_bringup/configs/global/fs_vars.env +++ b/src/flightstack/flightstack_bringup/configs/global/fs_vars.env @@ -18,7 +18,7 @@ export FS_RECORD_ADD_DEV1_SENSOR=() export FS_RECORD_ADD_DEV1_CAM=() # e.g. these topics require the installation of the matrixvision driver # see https://github.com/ethz-asl/matrixvision_camera -# export FS_RECORD_ADD_DEV1_CMAS=( +# export FS_RECORD_ADD_DEV1_CAM=( # "/camera/image_raw" # "/camera/camera_info" # ) diff --git a/src/flightstack/template_config/template_bringup/configs/global/template_vars.env b/src/flightstack/template_config/template_bringup/configs/global/template_vars.env index 46e8aa3..f393025 100644 --- a/src/flightstack/template_config/template_bringup/configs/global/template_vars.env +++ b/src/flightstack/template_config/template_bringup/configs/global/template_vars.env @@ -1,5 +1,9 @@ #!/usr/bin/env bash +# path related variables +export FS_SCRIPTS_PATH=$(rospack find flightstack_scripts) +export FS_VARS_FILE=$(rospack find template_bringup)/configs/global/template_vars.env + # object tracking related variables export FS_OPTITRACK_OBJECT_NAME="cnsuav" @@ -14,7 +18,7 @@ export FS_RECORD_ADD_DEV1_SENSOR=() export FS_RECORD_ADD_DEV1_CAM=() # e.g. these topics require the installation of the matrixvision driver # see https://github.com/ethz-asl/matrixvision_camera -# export FS_RECORD_ADD_DEV1_CMAS=( +# export FS_RECORD_ADD_DEV1_CAM=( # "/camera/image_raw" # "/camera/camera_info" # ) From dfcf8cd3d024f4e48764aaf476d5ee4afd6a0d8a Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 29 Feb 2024 13:55:39 +0100 Subject: [PATCH 18/27] subm: updated autonomy engine for aux --- src/autonomy_engine | 2 +- src/flightstack/flightstack_bringup/launch/fs_operator.launch | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/autonomy_engine b/src/autonomy_engine index 4ffd7da..b43b1a5 160000 --- a/src/autonomy_engine +++ b/src/autonomy_engine @@ -1 +1 @@ -Subproject commit 4ffd7da96692fa995b00d79c7a12107257cd72ab +Subproject commit b43b1a571f602301121e97ff283f3b6afde54f7a diff --git a/src/flightstack/flightstack_bringup/launch/fs_operator.launch b/src/flightstack/flightstack_bringup/launch/fs_operator.launch index f0a258f..d236ff2 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_operator.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_operator.launch @@ -66,6 +66,7 @@ You can contact the authors at , + @@ -112,6 +113,7 @@ You can contact the authors at , + From 938c2fd6a1527122a24b6c834be8f0db4a8b83d7 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Tue, 26 Mar 2024 13:23:48 +0100 Subject: [PATCH 19/27] fix: removed folder creation in case of .tar.gz storing --- .../store_scripts/safe_merge_data_single_dev.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh b/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh index 415fe5b..6db79af 100755 --- a/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh +++ b/src/flightstack/flightstack_scripts/store_scripts/safe_merge_data_single_dev.sh @@ -138,15 +138,17 @@ RSYNC_CMD="rsync -rptgoDL" echo "testing rsync" >> /tmp/rsync_test.log ${RSYNC_CMD} /tmp/rsync_test.log ${DIR_NAME}/ 2> /dev/null if [ $? -eq 0 ]; then - # rsync succeeded, remove test file + # rsync succeeded, remove test file and dir if empty rm -rf ${DIR_NAME}/rsync_test.log + rmdir ${DIR_NAME} 2> /dev/null else # failed rsync, change to simpler version, fewer permitions echo -e "${COL_WARN}rsync test failed, changing to simpler version${NC}" RSYNC_CMD="rsync -rpDL -A --no-perms" - # remove test file, if exists + # remove test file, if exists and dir if empty rm -rf ${DIR_NAME}/rsync_test.log + rmdir ${DIR_NAME} 2> /dev/null fi if [ ${B_DEBUG_ON} = true ]; then From bf4dce3e0219ff551a7a8c5728d5e01b2e7daa74 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Tue, 26 Mar 2024 13:56:46 +0100 Subject: [PATCH 20/27] add: more topics for recording --- .../flightstack_scripts/record_scripts/record_full.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh index d650bb9..cc8ea28 100755 --- a/src/flightstack/flightstack_scripts/record_scripts/record_full.sh +++ b/src/flightstack/flightstack_scripts/record_scripts/record_full.sh @@ -165,9 +165,14 @@ px4_topics=( "/mavros/global_position/raw/gps_vel" "/mavros/global_position/raw/satellites" "/mavros/imu/static_pressure" +"/mavros/imu/diff_pressure" "/mavros/imu/temperature_imu" +"/mavros/imu/temperature_baro" "/mavros/motor_speeds/speed" "/mavros/battery" +"/mavros/rc/in" +"/mavros/rc/out" +"/mavros/rc/override" ) mocap_vehicle_topics=( @@ -179,6 +184,8 @@ autonomy_topics=( "/autonomy/response" "/autonomy/logger" "/toland/is_landed" +"/toland_detector/is_landed" +"/toland_detector/is_takeoff" ) ms_topics=( From 54b31f995de768614eda6405324fba5c1b34a82c Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Wed, 27 Mar 2024 20:07:45 +0100 Subject: [PATCH 21/27] fix: added missing params to saftey.launch --- src/flightstack/flightstack_bringup/launch/fs_safety.launch | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/flightstack/flightstack_bringup/launch/fs_safety.launch b/src/flightstack/flightstack_bringup/launch/fs_safety.launch index fb9ff97..d7ee3d0 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_safety.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_safety.launch @@ -46,6 +46,8 @@ You can contact the authors at , + + @@ -83,6 +85,8 @@ You can contact the authors at , + + From 75bc83aa410776b06f88a16c050d0f4743700dce Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 11 Apr 2024 13:52:23 +0000 Subject: [PATCH 22/27] add: development setup for vscode --- .devcontainer/development/devcontainer.json | 19 ++++++ .vscode/c_cpp_properties.json | 24 +++++++ .vscode/settings.json | 74 +++++++++++++++++++++ 3 files changed, 117 insertions(+) create mode 100644 .devcontainer/development/devcontainer.json create mode 100644 .vscode/c_cpp_properties.json create mode 100644 .vscode/settings.json diff --git a/.devcontainer/development/devcontainer.json b/.devcontainer/development/devcontainer.json new file mode 100644 index 0000000..3b5e3f9 --- /dev/null +++ b/.devcontainer/development/devcontainer.json @@ -0,0 +1,19 @@ +{ + "name": "Development Container", + "image": "aaucns/flightstack-vscode:dev", + "runArgs": [ + "--privileged", + "--network=host", + "--pid=host" + ], + "containerEnv": { + "DISPLAY": "${localEnv:DISPLAY}" + }, + "workspaceMount": "source=${localWorkspaceFolder},target=/home/vscode/${localWorkspaceFolderBasename},type=bind", + "workspaceFolder": "/home/vscode/${localWorkspaceFolderBasename}", + "mounts": [ + "source=/tmp/.X11-unix,target=/tmp/.X11-unix,type=bind", + "source=${localEnv:HOME}${localEnv:USERPROFILE}/.bash_aliases,target=/home/vscode/.bash_aliases,type=bind", + "source=${localEnv:HOME}${localEnv:USERPROFILE}/.ssh,target=/home/vscode/.ssh,type=bind" + ] +} \ No newline at end of file diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json new file mode 100644 index 0000000..dd4b7af --- /dev/null +++ b/.vscode/c_cpp_properties.json @@ -0,0 +1,24 @@ +{ + "configurations": [ + { + "browse": { + "databaseFilename": "${default}", + "limitSymbolsToIncludedHeaders": false + }, + "includePath": [ + "/opt/ros/noetic/include/", + "/usr/include/", + "${workspaceFolder}/devel/include", + "${workspaceFolder}/build/", + "${workspaceFolder}/src/**/include/" + ], + "name": "ROS", + "intelliSenseMode": "gcc-x64", + "compilerPath": "/usr/bin/gcc", + "cStandard": "gnu11", + "cppStandard": "c++17", + "configurationProvider": "b2.catkin_tools" + } + ], + "version": 4 +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..3ad0136 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,74 @@ +{ + "files.associations": { + "cctype": "cpp", + "cstddef": "cpp", + "cstdlib": "cpp", + "cstring": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "*.tcc": "cpp", + "compare": "cpp", + "concepts": "cpp", + "cstdint": "cpp", + "map": "cpp", + "set": "cpp", + "unordered_map": "cpp", + "unordered_set": "cpp", + "vector": "cpp", + "exception": "cpp", + "algorithm": "cpp", + "functional": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "random": "cpp", + "string": "cpp", + "string_view": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "utility": "cpp", + "initializer_list": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "new": "cpp", + "ostream": "cpp", + "sstream": "cpp", + "stdexcept": "cpp", + "streambuf": "cpp", + "typeinfo": "cpp", + "strstream": "cpp", + "bitset": "cpp", + "chrono": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "complex": "cpp", + "condition_variable": "cpp", + "cstdarg": "cpp", + "cstdio": "cpp", + "ctime": "cpp", + "deque": "cpp", + "list": "cpp", + "fstream": "cpp", + "iomanip": "cpp", + "limits": "cpp", + "mutex": "cpp", + "optional": "cpp", + "ratio": "cpp", + "system_error": "cpp", + "thread": "cpp", + "typeindex": "cpp", + "variant": "cpp" + }, + "python.autoComplete.extraPaths": [ + "${workspaceFolder}/devel/lib/python3/dist-packages", + "/opt/ros/noetic/lib/python3/dist-packages" + ], + "python.analysis.extraPaths": [ + "${workspaceFolder}/devel/lib/python3/dist-packages", + "/opt/ros/noetic/lib/python3/dist-packages" + ], + "cmake.configureOnOpen": false +} \ No newline at end of file From d4b3c400d6c9397f3611e821dbfcff4763673290 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Thu, 11 Apr 2024 13:54:22 +0000 Subject: [PATCH 23/27] subm: fix issue in mission_sequencer --- src/mission_sequencer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mission_sequencer b/src/mission_sequencer index 80397b6..dcb8f50 160000 --- a/src/mission_sequencer +++ b/src/mission_sequencer @@ -1 +1 @@ -Subproject commit 80397b6a4e5beb6477d7fbb4d1f9cb84e0bece8a +Subproject commit dcb8f50fb9e93ca3fe4f6b22e81a47c2848eadc8 From 714fba96f1cf1a864ab86ec07758fc4083610b6f Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Mon, 15 Apr 2024 13:26:36 +0000 Subject: [PATCH 24/27] add: parameter to allow automatic respawning of mavros --- .../launch/fs_sensors.launch | 2 ++ .../launch/template_sensors.launch | 18 ++++++++++-------- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch index e63a151..2885eb2 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch @@ -19,6 +19,7 @@ You can contact the authors at , + @@ -39,6 +40,7 @@ You can contact the authors at , + diff --git a/src/flightstack/template_config/template_bringup/launch/template_sensors.launch b/src/flightstack/template_config/template_bringup/launch/template_sensors.launch index 5266b60..ab8cad5 100644 --- a/src/flightstack/template_config/template_bringup/launch/template_sensors.launch +++ b/src/flightstack/template_config/template_bringup/launch/template_sensors.launch @@ -13,10 +13,11 @@ You can contact the authors at , - - - - + + + + + @@ -24,10 +25,11 @@ You can contact the authors at , - - - - + + + + + From 85052a0c6d87b4705ff87404f34ec9599090c250 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Tue, 8 Oct 2024 09:34:46 +0000 Subject: [PATCH 25/27] add: remapping for pos. ctrl based on optitrack --- .../launch/fs_sensors.launch | 10 ++-- .../launch/individual/fs_posctrl.launch | 51 +++++++++++++++++++ .../individual/optitrack_aau_dronehall.launch | 9 ++-- .../record_scripts/record_full.sh | 2 + 4 files changed, 66 insertions(+), 6 deletions(-) create mode 100644 src/flightstack/flightstack_bringup/launch/individual/fs_posctrl.launch diff --git a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch index 2885eb2..5c20c6e 100644 --- a/src/flightstack/flightstack_bringup/launch/fs_sensors.launch +++ b/src/flightstack/flightstack_bringup/launch/fs_sensors.launch @@ -27,9 +27,11 @@ You can contact the authors at , - - - + + + + + @@ -45,6 +47,8 @@ You can contact the authors at , + + diff --git a/src/flightstack/flightstack_bringup/launch/individual/fs_posctrl.launch b/src/flightstack/flightstack_bringup/launch/individual/fs_posctrl.launch new file mode 100644 index 0000000..9b0c2a6 --- /dev/null +++ b/src/flightstack/flightstack_bringup/launch/individual/fs_posctrl.launch @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/flightstack/flightstack_bringup/launch/individual/optitrack_aau_dronehall.launch b/src/flightstack/flightstack_bringup/launch/individual/optitrack_aau_dronehall.launch index 1d369f7..f167055 100644 --- a/src/flightstack/flightstack_bringup/launch/individual/optitrack_aau_dronehall.launch +++ b/src/flightstack/flightstack_bringup/launch/individual/optitrack_aau_dronehall.launch @@ -18,8 +18,10 @@ and . - - + + + + @@ -42,7 +44,8 @@ and . - + + Date: Tue, 29 Oct 2024 17:53:39 +0000 Subject: [PATCH 26/27] subm: updated autonomy engine --- src/autonomy_engine | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/autonomy_engine b/src/autonomy_engine index b43b1a5..d121cc8 160000 --- a/src/autonomy_engine +++ b/src/autonomy_engine @@ -1 +1 @@ -Subproject commit b43b1a571f602301121e97ff283f3b6afde54f7a +Subproject commit d121cc8bee3781372146af9d2ad861f5abddde2e From 0c9ab80c4de58d7d044c31c09bee171537eeada4 Mon Sep 17 00:00:00 2001 From: Martin Scheiber Date: Tue, 29 Oct 2024 17:55:30 +0000 Subject: [PATCH 27/27] minor: devcontainer update --- .devcontainer/development/devcontainer.json | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.devcontainer/development/devcontainer.json b/.devcontainer/development/devcontainer.json index 3b5e3f9..c7fffa9 100644 --- a/.devcontainer/development/devcontainer.json +++ b/.devcontainer/development/devcontainer.json @@ -15,5 +15,12 @@ "source=/tmp/.X11-unix,target=/tmp/.X11-unix,type=bind", "source=${localEnv:HOME}${localEnv:USERPROFILE}/.bash_aliases,target=/home/vscode/.bash_aliases,type=bind", "source=${localEnv:HOME}${localEnv:USERPROFILE}/.ssh,target=/home/vscode/.ssh,type=bind" - ] + ], + "customizations": { + "vscode": { + "extensions": [ + "ms-vscode.cpptools-extension-pack" + ] + } + } } \ No newline at end of file