8752 Commits

Author SHA1 Message Date
Beat Küng
23d278cc43 sensors temp compensation: minor cleanup 2017-01-19 19:24:52 +01:00
Beat Küng
f38843278d voted_sensors_update: make msl_pressure static const 2017-01-19 19:24:52 +01:00
Beat Küng
e1ff6af792 mc_att_control_main: initialize _sensor_corrections properly 2017-01-19 19:24:52 +01:00
Beat Küng
535b1ea0dd voted_sensors_update: simplify accel & gyro poll methods 2017-01-19 19:24:52 +01:00
Beat Küng
7d5cd02c70 mc_att_control_main: fix bound check for gyro instance 2017-01-19 19:24:52 +01:00
Beat Küng
bbd47389e0 voted_sensors_update: fix copy paste naming mistake 2017-01-19 19:24:52 +01:00
Beat Küng
0765ed552c sensor_correction.msg rename {gyro,accel,baro}_select to match uORB convention 2017-01-19 19:24:52 +01:00
Lorenz Meier
00d26b75e9 MC att control: Harden against incorrect indices 2017-01-19 19:24:52 +01:00
Lorenz Meier
905c091f8c MAVLink receiver: Use fake device ID 2017-01-19 19:24:52 +01:00
Paul Riseborough
eac6dfed3c mc_att_control: Sync attitude loops to gyro data
Sync the attitude controller to the raw gyro data to remove the latency in the rate loops caused by the sensor and estimator modules.
Attitude data latency will increase as it will be from the previous EKF update, however attitude loops are less latency sensitive.
Thermal compensation and bias data will be from the previous frame.
2017-01-19 19:24:52 +01:00
Paul Riseborough
0485c2b94a sensors: add baro pressure temperature compensation and reporting 2017-01-19 19:24:52 +01:00
Paul Riseborough
0ba31b521c uavcan: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough
677616ed83 mavlink: Populate baro device ID
TODO - use unique HW ID
2017-01-19 19:24:52 +01:00
Paul Riseborough
c2fc283fdb sensors: Update single axis temp comp method to 5th order
This allows future use with baro sensors that require a higher fit order
2017-01-19 19:24:52 +01:00
Paul Riseborough
f8cef1e9ab attitude_estimator_q: populate control state gyro bias data
Populate with zeros.
TODO provide estimate.
2017-01-19 19:24:52 +01:00
Paul Riseborough
27e6f07485 ekf2: publish control state gyro bias data 2017-01-19 19:24:52 +01:00
Paul Riseborough
63f032832f Add prototype IMU temperature compensation
Enabled using TC_A_ENABLE and TC_G_ENABLE parameters
Disabled by default.
IMU offsets and scale factors for selected sensor published to sensor_correction topic
TODO Parameter storage method is cumbersome
2017-01-19 19:24:52 +01:00
Matthias Grob
db581fa5e8 mc_pos_control: hotfix for possible thrust below minimum thrust setting
Hotfix after a crash because of a heavily negative desired thrust that got clipped to 0 by the mixer.
0 thrust meant no more attitude tracking.
2017-01-19 18:05:57 +01:00
Beat Küng
e7db0ed098 test_mixer & mixer: use memmove instead of memcpy
Both, src & dst use the same array, thus potentially overlapping.
Behavior of memcpy in that case is undefined.
2017-01-18 18:23:42 +01:00
Chris Lovett
33a307873a Enable rc mode change switch to override offboard mode. This is a safety feature, in case offboard control goes crazy, user can always regain control by switching modes to stabilize, or alt hold or position hold, however they have configured the mode change RC switch. 2017-01-18 18:15:58 +01:00
Sander Smeets
ba10db06c2 Code formatting 2017-01-17 03:14:26 -08:00
Sander Smeets
d0dad4ad7d Indenting 2017-01-17 03:14:26 -08:00
Sander Smeets
de039ca870 VTOL back transition acceptance radius calculation 2017-01-17 03:14:26 -08:00
Lorenz Meier
7fd06ee913 MAVLLink simulator interface: Simulate minimum airspeed noise 2017-01-16 08:26:37 -08:00
Lorenz Meier
b8598c4407 Sensors: Adjust airspeed fail checks 2017-01-16 08:26:37 -08:00
Lorenz Meier
a13082bfed commander: Widen pre-flight check for airspeed 2017-01-16 08:26:37 -08:00
wangxdflight
67c3102db4 updated to remove a compilation flag check as orb_exists() is already supported 2017-01-16 08:25:58 -08:00
wangxdflight
b693e29d64 enable px4 flight for excelsior(legacy) 2017-01-16 08:25:58 -08:00
Lorenz Meier
12767c8538 MC position controller: Stop holding position once ground contact is established.
This ensures the system does not tip over on landings. Tested in SITL with a GPS drift model.
2017-01-16 08:25:26 -08:00
Matthias Grob
5b54d78128 land detector: changed minimum throttle threshold to have useful landing detection in real world scenarios 2017-01-16 08:25:26 -08:00
Matthias Grob
39f9647291 mc_pos_control: fixed float literals and commented calculations 2017-01-16 08:25:26 -08:00
Matthias Grob
f95fb0f20f land detector: commented takeoff throttle values for each mode 2017-01-16 08:25:26 -08:00
Matthias Grob
5f3cbbbbc2 mc_pos_control: changed thrust calculation to 3D projection onto body z axis
until now the desired thrust was simply the absolute value of the thrust setpoint vector
but a multicopter is only capable of producing thrust in its (negative) body z axis
this leads to excess thrust during attitude tracking errors

one important use case is:
trying to land with minimal thrust in NED z axis against gravity
but the position controller still correcting some small horizontal estimation errors
then this prevents unwanted thrust in a completely wrong direction
2017-01-16 08:25:26 -08:00
Julian Oes
d63db203ba mc_pos_control: don't publish attitude sp 2x 2017-01-16 08:25:26 -08:00
Matthias Grob
7ab2958757 land_detector: added takeoff throttle threshold
if we control manually and are still landed, we want to stay idle until the pilot rises the throttle
2017-01-16 08:25:26 -08:00
Matthias Grob
5529023ec1 mc_pos_control: added feed forward hover thrust
the velocity controller was misusing the integral part to account for the constant gravitational force offset
the hover throttle from the parameter is now is now directly used as feed forward for the thrust in world z direction
the integrator compensates for inaccurate paarameter but should now be idealy zero
2017-01-16 08:25:26 -08:00
Lorenz Meier
50002a0ff6 Update EEKF2 to match ecl updates 2017-01-15 01:57:38 -08:00
Lorenz Meier
1c42cea28e MAVLink: Ignore bogus mission item requests silently 2017-01-15 01:47:10 +01:00
Lorenz Meier
d1fcd8dd8e Fix code style for mavlink main 2017-01-14 07:47:03 -08:00
Lorenz Meier
521b89b1ce MAVLink: Protect against illegal length indication of RTCM data 2017-01-14 07:47:03 -08:00
Lorenz Meier
1549f5a5d1 sdlog2: Fix string termination 2017-01-14 07:47:03 -08:00
Lorenz Meier
3eb7caba4f MAVLink param handling: Exclude Coverity false positives 2017-01-14 07:47:03 -08:00
Lorenz Meier
fc2970b309 Helicopter mixer: Fix out of bounds checks 2017-01-14 07:47:03 -08:00
Lorenz Meier
4939e42c0f MAVLink main: Fix resource leak for non-NuttX cases 2017-01-14 07:47:03 -08:00
Lorenz Meier
1155a4725b PX4IO: Fix mixer load corner case in string termination 2017-01-14 07:47:03 -08:00
Daniel Agar
df5d0ba8b9 airspeed cal more descriptive error message (#6324) 2017-01-13 17:26:27 -05:00
Andreas Antener
338804606a Fixed-wing: allow mission takeoff 2017-01-13 00:18:08 -08:00
David Sidrane
79d682e740 Master uavcan mainline (#6313)
* Update libuavcan to upstream master with PX4 contrib for NuttX 7.16+

* Release any 64B blocks not needed by usavcan after FW server is stopped.

  We simply call the srrink methode after the server stop.
  See https://github.com/PX4/Firmware/pull/3005#issue-111885687
  for backgound
2017-01-12 13:28:38 -10:00
David Sidrane
ba2efff70f Updated libuavcan submodule with upstream ci fix.
This commit does not effect PX4 it just points to a commit
   that fixes a CI failure introduced in the changes upstrem to
   support the nuttx upgrade to 7.16+
2017-01-12 10:53:48 -08:00
Lorenz Meier
a8902472e4 Params: Fix the description text
The MAIN and AUX outputs had the same description which could confuse users.
2017-01-12 02:40:56 +01:00