Commit Graph

18758 Commits

Author SHA1 Message Date
baumanta f611eddadd unadvertise publishers in the destructor 2018-11-20 14:11:33 +01:00
Matthias Grob 81ec6c5b1e ColisionAvoidance: move instantiation to FlightTask 2018-11-20 14:11:33 +01:00
Matthias Grob 7e276bc163 CollisionAvoidance: move activation logic to library 2018-11-20 14:11:33 +01:00
baumanta 27dc60a419 Improve comments 2018-11-20 14:11:33 +01:00
baumanta ce7dc85450 Change wrong comment 2018-11-20 14:11:33 +01:00
baumanta db514fe441 Add a collision avoidance library which uses range data 2018-11-20 14:11:33 +01:00
David Sidrane 1d12827408 Commander:Replace color based LED manipulators with logical ones. 2018-11-19 14:32:47 -05:00
David Sidrane fbc143dc55 sitl:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on sitl
2018-11-19 14:32:47 -05:00
David Sidrane 05ea187b1d px4nucleoF767ZI-v1:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4nucleoF767ZI-v1
2018-11-19 14:32:47 -05:00
David Sidrane b37675fa76 px4fmu-v5:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4fmu-v5
2018-11-19 14:32:47 -05:00
David Sidrane 26026b5d39 px4fmu-v4pro:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4fmu-v4pro
2018-11-19 14:32:47 -05:00
David Sidrane 735830a483 px4fmu-v4:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4fmu-v4
2018-11-19 14:32:47 -05:00
David Sidrane 90106c1fd2 px4fmu-v2:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4fmu-v2
2018-11-19 14:32:47 -05:00
David Sidrane e40a0839e9 px4-stm32f4discovery:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4-stm32f4discovery
2018-11-19 14:32:47 -05:00
David Sidrane 03aae61395 px4-same70xplained-v1:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on px4-same70xplained-v1
2018-11-19 14:32:47 -05:00
David Sidrane 42a8a6ffac omnibus-f4sd:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on omnibus-f4sd
2018-11-19 14:32:47 -05:00
David Sidrane 1da0021be9 nxphlite-v3:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on nxphlite-v3
2018-11-19 14:32:47 -05:00
David Sidrane a12f26aee0 mindpx-v2:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on mindpx-v2
2018-11-19 14:32:47 -05:00
David Sidrane 3c6539257f crazyflie:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on crazyflie
2018-11-19 14:32:47 -05:00
David Sidrane e960978296 auav-x21:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on auav-x21
2018-11-19 14:32:47 -05:00
David Sidrane aa30560d68 aerofc-v1:Added Logical BOARD specific LED mapping
Define the logical LED that are uses on aerofc-v1
2018-11-19 14:32:47 -05:00
David Sidrane 96ba6c1174 sitl led:Support logical LED operations in commander
add support for all the LEDS to support
   BOARD_HAS_CONTROL_STATUS_LEDS
2018-11-19 14:32:47 -05:00
David Sidrane 0a1dd24af6 omnibus-f4sd:led clean up code and prevent out of bounds indexing 2018-11-19 14:32:47 -05:00
David Sidrane dc29820bd9 Document the LED colors used 2018-11-19 14:32:47 -05:00
David Sidrane 98394afcc7 board common:Define default CONTROL_STATUS LED mapping
This commit is the groundwork to fix the power LED
   blinking on V5

   Background:
   ----------
   Early boards only had an AMBER LED that was used to
   indicate a High Load condition.

   This change defines the new logical inteface
   the LED_<color> should not be used in application
   code moving forward, only the minipulator macros
   should be used.

       Logical usage             Legacy default
      ------------------------+-------------
       BOARD_OVERLOAD_LED     | LED_RED

   Later boards defined BOARD_HAS_CONTROL_STATUS_LEDS
   and added the use of a BLUE and GREEN LED that were
   used as follows:

   Logical usage             Legacy default
      ------------------------+-------------
       BOARD_ARMED_LED        | LED_BLUE
       BOARD_ARMED_STATE_LED  | LED_GREEN

   With this PR a board may now define _only_ a subset
   the leds and map them at the board level to the
   color LED it wants to use.

       Logical usage             Legacy default
      ------------------------+-------------
       BOARD_OVERLOAD_LED     | LED_RED
    when BOARD_HAS_CONTROL_STATUS_LEDS is defined
       BOARD_ARMED_LED        | LED_BLUE
       BOARD_ARMED_STATE_LED  | LED_GREEN

   If any of the BOARD_{OVERLOAD|ARMED|ARMED_STATE}_LED are not
   defined. The code output generates a null action for that
   LED.
2018-11-19 14:32:47 -05:00
Daniel Agar bba475aca1 logger limit trajectory_setpoint rate 2018-11-19 09:59:22 -05:00
Daniel Agar 48ba88eaf0 pwm_out_sim add mixer saturation status publication (#10866) 2018-11-16 16:42:20 -05:00
Paul Riseborough 3ee596284d ecl: Magnetic declination use improvements
Fixes bugs causing learned or GEO lookup declination to not be used in some circumstances.

https://github.com/PX4/ecl/pull/518
https://github.com/PX4/ecl/pull/520
2018-11-16 10:25:59 -05:00
TSC21 05d9932f6c logger: limit vehicle_*_odometry topics to 30hz on default logging 2018-11-16 09:44:32 +01:00
TSC21 2c111222cf logger: fix vision topics naming 2018-11-16 09:44:32 +01:00
bresch 7779c0bd69 MPC - Update velocity integrator definition 2018-11-15 22:08:00 +01:00
bresch d852ce20e6 MPC - Increase max velocity integral gain to 3.0 2018-11-15 22:08:00 +01:00
bresch 0863e95a2c Add "Tracking Anti-Reset Windup" in velocity PID controller 2018-11-15 22:08:00 +01:00
Julian Oes d7c34ddee4 mavlink: fix yawing to North for LOITER_TIME (#10828)
* mavlink: yaw should wrap at 2 pi, not pi
* mavlink: use newer rad/deg conversion
2018-11-13 14:32:40 -05:00
Beat Küng b3afa6ddac mc_pos_control: fix task activation failure for Transition 2018-11-13 09:30:18 +01:00
Beat Küng 330941c1fc FlightTaskManualAltitude: initialze yaw setpoint with NAN
Also update some comments.

In case we activate the task and don't have a locked yaw, we should
initialize the yaw setpoint with NAN to avoid any abrupt changes.
2018-11-13 09:30:18 +01:00
Beat Küng 2b7d3bd088 flight tasks: move weather vane yaw handler from Altitude to Position task 2018-11-13 09:30:18 +01:00
Beat Küng c9e52d4386 MPC_MAN_TILT_MAX: increase max limit from 90 to 180 degrees
This is especially useful for testing (the vehicle must behave correctly
even at high tilt angles).
2018-11-13 09:30:18 +01:00
Beat Küng adf1fea554 mc_att_control: fix for Rattitude mode
When switching back from rate to attitude control, the code depended on a
vehicle_control_mode topics update, but the publication frequency of that
is low. So the switch was noticeably delayed.
2018-11-13 09:30:18 +01:00
Beat Küng 36ee0297ee FlightTask.hpp: minor code cleanup 2018-11-13 09:30:18 +01:00
Beat Küng ca7acae904 mc stabilized mode: move from mc_pos_control to mc_att_control
- better in terms of dependencies:
  - the position controller code depended on position topics for yaw
  - mc_pos_control does not have to be run for Stabilized mode
- the code path is much simpler, and thus less error prone. This is
  especially important since Stabilized is often used as a fail-safe flight
  mode.
2018-11-13 09:30:18 +01:00
Beat Küng f31f63fff7 mc_att_control: use orb_publish_auto
use nullptr for instance to make sure we always get the first instance.
2018-11-13 09:30:18 +01:00
Beat Küng 00c2086dd6 mc_pos_control: simplify weathervane logic 2018-11-13 09:30:18 +01:00
Beat Küng 1946f043f1 mc_pos_control: print active flight task for 'mc_pos_control status' cmd 2018-11-13 09:30:18 +01:00
Beat Küng e7e06dfe38 fix mc_pos_control: disable flight tasks if none of them should be running
Previously when switching e.g. from stabilized from acro, the stabilized
flight task kept running and publishing setpoints.
Luckily it caused no problems, but the log showed arbitrary attitude
setpoints.
2018-11-13 09:30:18 +01:00
bresch f590137525 Fix HIL
Revert "pwm_out_sim lazily publish actuator_outputs"

This reverts commit bcad940a9f.
2018-11-12 19:21:15 +01:00
Daniel Agar 4e2bf27da6 FlightTaskAuto set WaypointType from position setpoint types 2018-11-11 10:21:41 -05:00
Daniel Agar 246b879aea require MODULE_NAME 2018-11-10 13:52:34 -05:00
Beat Küng e91db7b4d2 uORBDeviceNode: move flags from SubscriberData to UpdateIntervalData
As there is only one bit used in 'flags', and it is only used in case
update_interval is not null, we can move the bit to UpdateIntervalData.

The size of UpdateIntervalData does not increase (on 32 bit).

Reduces RAM usage by 3.6KB (tested on a Pixracer).
2018-11-07 19:45:53 +08:00
bresch 90cee2d5ea Manual Smoth Vel - Override reActivate to not reset Z axis (prevented takeoff) 2018-11-06 22:17:00 +01:00