Problem: _mag_device_id is used to get the correct rotation matrix for each
mag. But on POSIX, _mag_device_id was always 0, leading to invalid rotation
matrices.
This resulted in stale mag error messages (rot matrix=0 ==> mag data=0).
_mag_device_id was 0 because there are no /dev/magX devices (eg. on RPi),
thus the mag driver could not be opened.
This patch does: get the device id from the uorb topic instead. We still
need the device handle on certain platforms to apply the calibration params
and to check if the mag is internal or external.
Problem left: on POSIX, the check for external mag does not work.
Add CMake target for strip since these changes break adb_upload_to_bebop.
GCC users should add the cross compiler bin path to PATH (location of arm-linux-gnueabihf-g++).
Clang user should do the following:
* set CMAKE_CXX_COMPILER to clang++ by providing -DCMAKE_CXX_COMPILER=clang++ to cmake
* get GCC cross compiler - needed because Clang does not ship a CRT
* create a symlink for clang and clang++ in GCC cross compiler bin dir.
* add GCC bin dir to PATH
Signed-off-by: Nicolae Rosia <nicolae.rosia@gmail.com>
The previous approach would work with old low-end sensors, but with new high-end sensors we get a lot of false alarms on the bench. Relaxing the check to only apply pre-arm will ensure its now only run when the user intents to take off, at which point the airframe should be with pitot covers off in the field.
* update ecl to latest
* EKF2_GPS_DELAY change default 200ms -> 110ms
- 110msec is more representative of what most users are flying
* EKF2_ASP_DELAY change default 200ms -> 100ms
The EKF is relatively insensitive to airspeed sensor delays and the effective delay is installation specific, so it has been set to a value that does not cause the data buffers to be longer than is required to accomodate GPS delays.