diff --git a/conf/airframes/tudelft/rotwing5.xml b/conf/airframes/tudelft/rotwing5.xml
index ea1d23db85..06fce5ec16 100644
--- a/conf/airframes/tudelft/rotwing5.xml
+++ b/conf/airframes/tudelft/rotwing5.xml
@@ -158,9 +158,7 @@
-
-
-
+
diff --git a/conf/airframes/tudelft/rotwing6.xml b/conf/airframes/tudelft/rotwing6.xml
index aac4b6abb7..3469af594f 100644
--- a/conf/airframes/tudelft/rotwing6.xml
+++ b/conf/airframes/tudelft/rotwing6.xml
@@ -158,9 +158,7 @@
-
-
-
+
diff --git a/conf/airframes/tudelft/rotwing_25kg_common.xml b/conf/airframes/tudelft/rotwing_25kg_common.xml
index 3415ab283e..b2be3088d7 100644
--- a/conf/airframes/tudelft/rotwing_25kg_common.xml
+++ b/conf/airframes/tudelft/rotwing_25kg_common.xml
@@ -2,7 +2,7 @@
-
+
diff --git a/conf/airframes/tudelft/rotwing_7kg_common.xml b/conf/airframes/tudelft/rotwing_7kg_common.xml
index 732152f307..712661f4a9 100644
--- a/conf/airframes/tudelft/rotwing_7kg_common.xml
+++ b/conf/airframes/tudelft/rotwing_7kg_common.xml
@@ -1,7 +1,6 @@
-
@@ -56,7 +55,8 @@
-
+
+
@@ -72,7 +72,7 @@
-
+
@@ -116,13 +116,13 @@
-
+
-
+
@@ -162,7 +162,7 @@
-
+
@@ -192,7 +192,7 @@
-
+
diff --git a/conf/airframes/tudelft/rotwing_v3b.xml b/conf/airframes/tudelft/rotwing_v3b.xml
index 647d1a14ae..1c819c5c12 100644
--- a/conf/airframes/tudelft/rotwing_v3b.xml
+++ b/conf/airframes/tudelft/rotwing_v3b.xml
@@ -106,7 +106,6 @@
-
@@ -159,7 +158,7 @@
-
+
@@ -262,7 +261,7 @@
-
+
@@ -271,7 +270,7 @@
-
+
@@ -280,7 +279,7 @@
-
+
@@ -289,7 +288,7 @@
-
+
@@ -298,7 +297,7 @@
-
+
@@ -307,7 +306,7 @@
-
+
@@ -318,7 +317,7 @@
-
+
@@ -370,7 +369,7 @@
-
+
@@ -395,7 +394,8 @@
- Location, airspace and weather
- Check the RC battery
- Check tail connection
- - Check wings taped and secured
+ - Check all four wing bolts present and tightened
+ - Check wing power and CAN lines connected
- Inspect airframe condition
- Check attitude and heading
- Airspeed sensor calibration
@@ -403,15 +403,14 @@
- Automated actuator check
- Check flight plan
- Switch to correct flight block
- - Switch on drone tag
- Switch on camera
- Announce flight to other airspace users
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3d.xml b/conf/airframes/tudelft/rotwing_v3d.xml
index cfe86ed57c..e2839946ea 100644
--- a/conf/airframes/tudelft/rotwing_v3d.xml
+++ b/conf/airframes/tudelft/rotwing_v3d.xml
@@ -457,8 +457,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3e.xml b/conf/airframes/tudelft/rotwing_v3e.xml
index b3c5f0668b..dee2968ee0 100644
--- a/conf/airframes/tudelft/rotwing_v3e.xml
+++ b/conf/airframes/tudelft/rotwing_v3e.xml
@@ -419,8 +419,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3f.xml b/conf/airframes/tudelft/rotwing_v3f.xml
index 2b1b72b58d..9b94108ceb 100644
--- a/conf/airframes/tudelft/rotwing_v3f.xml
+++ b/conf/airframes/tudelft/rotwing_v3f.xml
@@ -403,8 +403,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3g.xml b/conf/airframes/tudelft/rotwing_v3g.xml
index 571c947792..c0c1b52337 100644
--- a/conf/airframes/tudelft/rotwing_v3g.xml
+++ b/conf/airframes/tudelft/rotwing_v3g.xml
@@ -416,8 +416,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3h.xml b/conf/airframes/tudelft/rotwing_v3h.xml
index 7eca142ecf..9dd7d26bd5 100644
--- a/conf/airframes/tudelft/rotwing_v3h.xml
+++ b/conf/airframes/tudelft/rotwing_v3h.xml
@@ -71,7 +71,7 @@
-
+
@@ -403,8 +403,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3i.xml b/conf/airframes/tudelft/rotwing_v3i.xml
index 739be0c00d..7c714a4941 100644
--- a/conf/airframes/tudelft/rotwing_v3i.xml
+++ b/conf/airframes/tudelft/rotwing_v3i.xml
@@ -452,8 +452,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3j.xml b/conf/airframes/tudelft/rotwing_v3j.xml
index 97615f0862..8a9a7152b1 100644
--- a/conf/airframes/tudelft/rotwing_v3j.xml
+++ b/conf/airframes/tudelft/rotwing_v3j.xml
@@ -455,8 +455,8 @@
-
-
+
+
diff --git a/conf/airframes/tudelft/rotwing_v3k.xml b/conf/airframes/tudelft/rotwing_v3k.xml
index 05610f90aa..7857fabf97 100644
--- a/conf/airframes/tudelft/rotwing_v3k.xml
+++ b/conf/airframes/tudelft/rotwing_v3k.xml
@@ -430,8 +430,8 @@
-
-
+
+
diff --git a/conf/autopilot/rotorcraft_rotwing.xml b/conf/autopilot/rotorcraft_rotwing.xml
new file mode 100644
index 0000000000..bae377d503
--- /dev/null
+++ b/conf/autopilot/rotorcraft_rotwing.xml
@@ -0,0 +1,268 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/conf/flight_plans/tudelft/rotwing_EHVB.xml b/conf/flight_plans/tudelft/rotwing_EHVB.xml
index f8b4c0bf1c..dc5bc95e7d 100644
--- a/conf/flight_plans/tudelft/rotwing_EHVB.xml
+++ b/conf/flight_plans/tudelft/rotwing_EHVB.xml
@@ -133,31 +133,32 @@
-
-
+
+
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
-
+
+
+
-
-
-
-
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
-
-
+
+
diff --git a/conf/flight_plans/tudelft/rotwing_generic.xml b/conf/flight_plans/tudelft/rotwing_generic.xml
new file mode 100644
index 0000000000..6debb93d54
--- /dev/null
+++ b/conf/flight_plans/tudelft/rotwing_generic.xml
@@ -0,0 +1,235 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/conf/joystick/tudelft/rotwing_taranis_x9d_plus.xml b/conf/joystick/tudelft/rotwing_taranis_x9d_plus.xml
new file mode 100644
index 0000000000..158f2f33b2
--- /dev/null
+++ b/conf/joystick/tudelft/rotwing_taranis_x9d_plus.xml
@@ -0,0 +1,43 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/conf/modules/math.xml b/conf/modules/math.xml
index 41f9ad1505..9d5110d20c 100644
--- a/conf/modules/math.xml
+++ b/conf/modules/math.xml
@@ -24,6 +24,7 @@
+
@@ -36,7 +37,7 @@
+
-
diff --git a/conf/modules/rotwing_state.xml b/conf/modules/rotwing_state.xml
index 9af4f76bb8..2fa1399479 100644
--- a/conf/modules/rotwing_state.xml
+++ b/conf/modules/rotwing_state.xml
@@ -12,6 +12,7 @@
+
diff --git a/conf/simulator/jsbsim/aircraft/rotwing3.xml b/conf/simulator/jsbsim/aircraft/rotwing3.xml
index 2dbaafe22e..eb9c60cf74 100644
--- a/conf/simulator/jsbsim/aircraft/rotwing3.xml
+++ b/conf/simulator/jsbsim/aircraft/rotwing3.xml
@@ -121,47 +121,47 @@
fcs/front_motor
- 18
+ 22.0
fcs/right_motor
- 18
+ 22.0
fcs/back_motor
- 18
+ 22.0
fcs/left_motor
- 18
+ 22.0
fcs/pusher
- 18
+ 30.0
fcs/elevator
- 54
+ 50.0
fcs/rudder
- 54
+ 50.0
fcs/aileron
- 54
+ 50.0
fcs/flap
- 54
+ 50.0
@@ -321,7 +321,7 @@
fcs/front_motor_lag
- 7.643508703
+ 6.36958
@@ -340,7 +340,7 @@
fcs/right_motor_lag
- 7.643508703
+ 6.36958
@@ -359,7 +359,7 @@
fcs/back_motor_lag
- 7.643508703
+ 6.36958
@@ -378,7 +378,7 @@
fcs/left_motor_lag
- 7.643508703
+ 6.36958
@@ -825,7 +825,7 @@
aero/qbar-psf
47.9
- 0.0453
+ 0.108
0.224808943
diff --git a/conf/userconf/tudelft/conf.xml b/conf/userconf/tudelft/conf.xml
index 53db29d588..8d759b4332 100644
--- a/conf/userconf/tudelft/conf.xml
+++ b/conf/userconf/tudelft/conf.xml
@@ -544,7 +544,7 @@
airframe="airframes/tudelft/rotwing_v3b.xml"
radio="radios/crossfire_sbus.xml"
telemetry="telemetry/highspeed_rotorcraft.xml"
- flight_plan="flight_plans/tudelft/rotwing_EHVB.xml"
+ flight_plan="flight_plans/tudelft/rotwing_generic.xml"
settings="settings/rotorcraft_basic.xml"
settings_modules="modules/air_data.xml modules/airspeed_ms45xx_i2c.xml modules/airspeed_uavcan.xml modules/approach_moving_target.xml modules/eff_scheduling_rotwing.xml modules/ekf_aw.xml modules/electrical.xml modules/follow_me.xml modules/gps.xml modules/gps_ublox.xml modules/guidance_indi_hybrid.xml modules/guidance_rotorcraft.xml modules/imu_common.xml modules/imu_heater.xml modules/ins_ekf2.xml modules/lidar_tfmini.xml modules/logger_sd_chibios.xml modules/nav_hybrid.xml modules/nav_rotorcraft.xml modules/parachute.xml modules/pfc_actuators.xml modules/preflight_checks.xml modules/rotwing_state.xml modules/stabilization_indi.xml modules/sys_id_auto_doublets.xml modules/sys_id_doublet.xml modules/target_pos.xml"
gui_color="red"
diff --git a/sw/airborne/modules/nav/ground_detect.c b/sw/airborne/modules/nav/ground_detect.c
index 1b4c9aa714..a3d4ad7431 100644
--- a/sw/airborne/modules/nav/ground_detect.c
+++ b/sw/airborne/modules/nav/ground_detect.c
@@ -40,6 +40,10 @@
#endif
#endif
+#ifndef GROUND_DETECT_SPECIFIC_THRUST_THRESHOLD
+#define GROUND_DETECT_SPECIFIC_THRUST_THRESHOLD -5.0
+#endif
+
#include "pprzlink/messages.h"
#include "modules/datalink/downlink.h"
@@ -103,7 +107,7 @@ void ground_detect_periodic()
// Detect ground based on AND of all triggers
if ((fabsf(vspeed_ned) < 5.0)
- && (spec_thrust_down > -5.0)
+ && (spec_thrust_down > GROUND_DETECT_SPECIFIC_THRUST_THRESHOLD)
&& (fabsf(accel_filter.o[0]) < 2.0)
#if USE_GROUND_DETECT_AGL_DIST
&& (agl_dist_valid && (agl_dist_value_filtered < GROUND_DETECT_AGL_MIN_VALUE))
diff --git a/sw/airborne/modules/nav/waypoints.c b/sw/airborne/modules/nav/waypoints.c
index 862dde09c4..8bd7073178 100644
--- a/sw/airborne/modules/nav/waypoints.c
+++ b/sw/airborne/modules/nav/waypoints.c
@@ -33,11 +33,16 @@ struct Waypoint waypoints[NB_WAYPOINT];
#if PERIODIC_TELEMETRY
#include "modules/datalink/telemetry.h"
+#include "math/pprz_random.h"
static void send_wp_moved(struct transport_tx *trans, struct link_device *dev)
{
static uint8_t i;
i++;
+
+ // Randomness added for multiple transport devices
+ if (rand_uniform() > 0.02) { i++; }
+
if (i >= nb_waypoint) { i = 0; }
pprz_msg_send_WP_MOVED_ENU(trans, dev, AC_ID,
&i,
diff --git a/sw/ground_segment/python/rotwing_mon/rotwing_viewer.py b/sw/ground_segment/python/rotwing_mon/rotwing_viewer.py
index 7dc98527cc..77fe5cff45 100644
--- a/sw/ground_segment/python/rotwing_mon/rotwing_viewer.py
+++ b/sw/ground_segment/python/rotwing_mon/rotwing_viewer.py
@@ -25,7 +25,6 @@ import math
import datetime
import numpy as np
import pyttsx3
-import re
engine = pyttsx3.init()
PPRZ_HOME = os.getenv("PAPARAZZI_HOME", os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(__file__)),