As some tiltrotor systems need a certain tilt angle of their motors in oder to spin up freely,
this commit introduces an additional parameter VT_TILT_SPINUP and sets the motor tilt to
this value if disarmed or within 1s since arming.
The spinup consists of 2 phases:
1st phase fixed tilt (duration hardcoded to 1s)
2nd phase transition from spinup tilt to multicopter tilt (hardcoded to 0.5s)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
- matrix in PX4/Firmware (222e0636c4b53ea18013f2bf0d35a798fab6ae76): a32892926c
- matrix current upstream: d613055462
- Changes: a32892926c...d613055462
d613055 2020-04-06 kamilritz - Add more assignment operators for slices
976ada4 2020-03-21 Matthias Grob - Matrix: min max comments and test style
fa7153e 2020-03-21 Matthias Grob - Matrix: omit min max nan case with same result
If the user disconnects USB we reboot the system to bring it back into a nominal condition before arming. Otherwise we would either have the USB stack running without a cable connected (code running for no reason, which is violating the principle of not running unnecessary code in aviation). Or we would not allow to arm at all if USB was ever connected, which can be confusing if the system is powered off a battery.
Before _was_landed was set to the same value as the current
_land_detector.landed, thus outside of the update condition,
_was_landed && !_land_detector.landed could never be true.
This affects setting the home position, which is now set upon arming AND
upon takeoff.
If arming and already !landed, _have_taken_off_since_arming will not be set
and thus auto-disarm after 10s will be triggered (with default config).
This can only happen due to quick state changes, as land detector generally
sets landed=true if !armed.
When disconnecting USB poll returns successfully, but the read returns
-1 with ENOTCONN.
In addition this also ensures there's no busy loop when poll returns an
error.
MAVLink continues to work after reconnecting USB.
This moves the handling of the BAT%d_SOURCE param inside of the battery
library. Users of the library now pass the source instead of the flag
whether to publish. The battery library then checks if the source is
selected using the param and publishes accordingly.
Since we removed the strange system_source flag, we now need to look at
all batteries in commander.
For current estimation - I think - it makes sense to sum them up.
* fix param import transition for MC_DTERM_CUTOFF
The previous implementation did not work, as there was a check for
param_find_no_notification() returning PARAM_INVALID for IMU_DGYRO_CUTOFF,
and therefore would not call param_modify_on_import().
This moves param_modify_on_import() before the check and makes it modify
the bson node directly.
* parameters: fix param import transition when testing is enabled
BUILD_TESTING is used for unit test builds, PX4_TESTING is used to enable additional test material within PX4
Co-authored-by: Daniel Agar <daniel@agar.ca>
Previously if in a cycle only a disconnected battery status updated, the
battery health state would switch to unhealthy during that time.
Fixes intermittent 'Arming denied! Check battery' preflight failures on
v5x with 1 power module connected.