This will initialize those structs with zero in all fields not set
and all fields set will only be change once to the final value not
wasting CPU time zeroing it.
This will guarantee that no non-unitialized structs will have
a trash value on from_external causing it to be sent to the
MAVLink channel without need it.
system_source - This battery status is for the brick that is
supplying VDD_5V_IN
priority - Zero based, This battery status is for the brick
that is connected to the Power controller's
N-1 priority input. V1..VN. 0 would normally be
Brick1, 1 for Brick2 etc
Battery now assigns connected from the api in the
updateBatteryStatus, as well as system_source and priority
change fmu to task
increase fmu_servo task priority to max and enable true oneshot
use lowest FMU priority which minimizes jitter
constrain oneshot updates to control group 0 events
Move RC and DL failsafe actions handling from navigator to commander (credits to @AndreasAntener)
Separate manual kill switch handling via manual_lockdown to prevent override and release of software lockdown by RC switch
Other changes:
Add failsafe tune
Fix LED blinking for Pixracer
Return back support for rc inputs in simulator but now it is configurable via cmake
clamp mixer output offset to [-.2,.2] ([-2000, 2000] in mixer file)
add 8 main PWM trim parameters
add long desc to parameters and bump minor parameter version
After I got a compiler warning for a printf format in this file
(which I cannot reproduce anymore; for some reason g++ is usually
quite happy with all the errors in this file), I fixed all 'printf'
formats to match the type of their arguments as follows:
uint8_t : %hhu
uint16_t : %hu (or %hx)
uint32_t : %u (or %x)
int16_t : %hd
int and int32_t : %d
long int : %ld
Since this file is C++, what we REALLY should be using is
ostream operator<<'s of course (type safe by design and faster
(compile time type matching, no need for format decoding)).
In order to test what happens in px4iofirmware when the FMU stops
sending PWM or control commands, I added a test mode. When the test mode
is activated, no controls are sent.
Sometimes when flashing new firmware, the IO update fails because safety
is off. In this case, we should set safety on first before putting the
IO board into bootloader mode.