sitl: add iris_replay startup script, handle $replay_mode in sitl_run.sh

usage:
export replay_mode=ekf2
export replay=<abs_path_to_log.ulg>
make posix none
This commit is contained in:
Beat Küng
2017-03-01 14:41:04 +01:00
committed by Lorenz Meier
parent 63203625bc
commit 037280c17d
2 changed files with 21 additions and 0 deletions
+14
View File
@@ -48,6 +48,20 @@ then
model="iris" model="iris"
fi fi
# check replay mode
if [ "$replay_mode" == "ekf2" ]
then
model="iris_replay"
# create the publisher rules
mkdir -p $rootfs
publisher_rules_file="$rootfs/orb_publisher.rules"
cat <<EOF > "$publisher_rules_file"
restrict_topics: sensor_combined, vehicle_gps_position, vehicle_land_detected
module: replay
ignore_others: false
EOF
fi
if [ "$#" -lt 7 ] if [ "$#" -lt 7 ]
then then
echo usage: sitl_run.sh rc_script rcS_dir debugger program model src_path build_path echo usage: sitl_run.sh rc_script rcS_dir debugger program model src_path build_path
+7
View File
@@ -0,0 +1,7 @@
uorb start
ekf2 start --replay
logger start -e -t -b 1000 -p vehicle_attitude
sleep 0.2
replay start -m ekf2