Commit Graph

59 Commits

Author SHA1 Message Date
david sastre f8b6d4b0ac AP_Parachute: Fix singleton panic message 2020-05-05 07:43:02 +10:00
murata 1fdcab2b5a AP_Parachute: Change the tab code to whitespace 2020-04-27 09:29:45 +09:00
Andrew Tridgell 77fab986ea AP_Parachute: default to parachute enabled 2020-01-18 13:48:48 +11:00
Andrew Tridgell d546877d3f AP_Parachute: fixed example build 2020-01-18 13:48:48 +11:00
Andrew Tridgell c3263d057f AP_Parachute: make configurable in hwdef.dat 2020-01-18 13:48:48 +11:00
Peter Barker 04c005a213 AP_Parachute: cope with change in namespace of LogEvent enum 2019-11-05 08:19:26 +08:00
Vinicius Knabben 040fa3e10a AP_Parachute: Added time check for sink rate to avoid glitches
Signed-off-by: Vinicius Knabben <viniciusknabben@hotmail.com>
2019-04-30 10:04:58 +10:00
Vinicius Knabben c710002bc9 AP_Parachute: Added parachute release at critical sink rate
Signed-off-by: Vinicius Knabben <viniciusknabben@hotmail.com>
2019-04-30 10:04:58 +10:00
Peter Barker 005ec5cd4d AP_Parachute: move responsibility for parachute deployment up 2019-02-13 09:25:27 +09:00
Peter Barker 610bcb3387 AP_Parachute: remove un-needed initialisations 2018-07-23 13:53:33 +09:00
Andrew Tridgell e798b38271 AP_Parachute: removed create() method for objects
See discussion here:

  https://github.com/ArduPilot/ardupilot/issues/7331

we were getting some uninitialised variables. While it only showed up in
AP_SbusOut, it means we can't be sure it won't happen on other objects,
so safest to remove the approach

Thanks to assistance from Lucas, Peter and Francisco
2017-12-14 08:12:28 +11:00
Lucas De Marchi 31db77e47b global: use static method to construct AP_Parachute 2017-09-26 03:01:21 +01:00
Lucas De Marchi 88dea049b4 AP_Parachute: add static create method 2017-09-26 03:01:21 +01:00
Lucas De Marchi 13d7f58036 global: use static method to construct AP_Relay 2017-09-26 03:01:21 +01:00
Patrick José Pereira 1eeea82e31 AP_Parachute: Add function to return _release_in_progress status
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2017-07-26 17:51:34 +01:00
Dr.-Ing. Amilcar Do Carmo Lucas 89a0d2aa3b AP_Parachute: Improve the PWM parameters descriptions 2017-06-06 11:06:26 +10:00
Dr.-Ing. Amilcar Do Carmo Lucas 5a2a82437a AP_Parachute: Use SI units conventions in parameter units
Follow the rules from:
http://physics.nist.gov/cuu/Units/units.html
http://physics.nist.gov/cuu/Units/outside.html
and
http://physics.nist.gov/cuu/Units/checklist.html
one further constrain is that only printable (7bit) ASCII characters are allowed
2017-05-17 18:07:25 +10:00
Pierre Kancir 7abd22a33e AP_Parachute: example fix travis warning
missing function declaration
implicit cast
some style fix
2017-04-13 19:56:16 +01:00
murata 60b63bb69e AP_Parachute: Unify from print or println to printf. 2017-01-27 18:20:22 +11:00
Andrew Tridgell 7706741b9b AP_Parachute: adapt to new RC_Channel API 2017-01-12 17:39:37 +11:00
Mathieu OTHACEHE 152edf7189 Global: remove mode line from headers
Using a global .dir-locals.el file is a better alternative than
reincluding the same emacs header in every file of the project.
2016-10-24 09:42:01 -02:00
Lucas De Marchi ae53920e5b build: don't build examples with old build system
We currently check examples are buildable with waf which doesn't need
the libraries to be specified in a make.inc file.  Having the makefiles
there is misleading since people try to build and realize the build is
broken.
2016-10-11 13:03:08 +11:00
Tom Pittenger ebe829614d AP_Parachute: set param "Enable" to be FLAG_ENABLE 2016-08-04 11:31:21 -07:00
Randy Mackay 71692044f8 AP_Parachute: resolve compile warning re init order 2016-04-22 21:32:35 +09:00
Rimvydas Naktinis df922dacfa Plane: Suppress throttle when parachute release initiated, not after release. 2016-04-21 09:53:22 -07:00
Andrew Tridgell 894e07a0bd AP_Parachute: added CHUTE_DELAY_MS parameter
on fixed wing it may take quite some time for the propeller to stop
2016-03-29 05:48:40 +11:00
Lucas De Marchi b180f3a83f AP_Parachute: replace header guard with pragma once 2016-03-16 18:40:42 +11:00
Gustavo Jose de Sousa c2e3f05dbf waf: ardupilotwaf: prefix build context methods with ap_
It helps to distinguish between things from waf and things from ardupilotwaf.
2016-01-22 20:10:29 -02:00
Gustavo Jose de Sousa 3d22490397 waf: examples: use methods from bld instead of ardupilotwaf 2016-01-22 20:10:29 -02:00
Gustavo Jose de Sousa d281067bcc waf: make example binaries be placed in 'examples' dir
This commit makes examples' wscripts use ardupilotwaf.example() instead of
ardupilot.program().
2016-01-15 16:46:41 -02:00
Lucas De Marchi a096703b06 Global: don't link with AP_Progmem
AP_Progmem is not used anymore.
2015-12-27 15:58:12 -02:00
Caio Marcelo de Oliveira Filho 6e7b73610d waf: add waf support 2015-12-03 07:54:30 +11:00
Caio Marcelo de Oliveira Filho d186704724 AP_Parachute: use millis/micros/panic functions 2015-11-20 12:33:26 +09:00
Lucas De Marchi 0c6b47e331 AP_Parachute: remove checks for HAL_BOARD_APM2 and HAL_BOARD_APM1 2015-11-04 12:14:12 +11:00
Lucas De Marchi 5244559010 Minimize AP_Progmem.h includes
Most of AP_Progmem is already gone so we can stop including it in most
of the places. The only places that need it are the ones using
pgm_read_*() APIs.

In some cases the header needed to be added in the .cpp since it was
removed from the .h to reduce scope. In those cases the headers were
also reordered.
2015-10-30 14:35:32 +09:00
Lucas De Marchi 20c6ffc5e3 Replace use of UARTDriver::printf_P() with UARTDriver::printf()
This also starts to show warnings on places that were already using
wrong printf format strings.
2015-10-30 14:35:25 +09:00
Lucas De Marchi 831d8acca5 Remove use of PROGMEM
Now variables don't have to be declared with PROGMEM anymore, so remove
them. This was automated with:

    git grep -l -z PROGMEM | xargs -0 sed -i 's/ PROGMEM / /g'
    git grep -l -z PROGMEM | xargs -0 sed -i 's/PROGMEM//g'

The 2 commands were done so we don't leave behind spurious spaces.

AVR-specific places were not changed.
2015-10-30 14:35:16 +09:00
Lucas De Marchi 2c38e31c93 Remove use of PSTR
The PSTR is already define as a NOP for all supported platforms. It's
only needed for AVR so here we remove all the uses throughout the
codebase.

This was automated with a simple python script so it also converts
places which spans to multiple lines, removing the matching parentheses.

AVR-specific places were not changed.
2015-10-30 14:35:04 +09:00
Andrew Tridgell aee2543b75 AP_Parachute: fixed release bug
if release() is called within 1 millisecond of update() the release
wouldn't happen
2015-10-27 16:06:34 +11:00
Andrew Tridgell 0d9715cfe8 AP_Parachute: added a released() function
used to help with throttle suppression in plane
2015-10-27 16:06:34 +11:00
Caio Marcelo de Oliveira Filho 5ad8077016 AP_Parachute: remove unnecessary board include from examples 2015-10-21 09:16:12 +11:00
Caio Marcelo de Oliveira Filho ec52df991c build: compile only the HAL files needed by the board
Instead of requiring every program to specify the HAL related modules,
let the build system do it (in practice everything we compiled depended
on HAL anyway). This allow including only the necessary files in the
compilation.
2015-10-21 09:16:07 +11:00
Caio Marcelo de Oliveira Filho 2e464a53c2 AP_HAL: make code not depend on concrete HAL implementations
The switching between different AP_HAL was happening by giving different
definitions of AP_HAL_BOARD_DRIVER, and the programs would use it to
instantiate.

A program or library code would have to explicitly include (and depend)
on the concrete implementation of the HAL, even when using it only via
interface.

The proposed change move this dependency to be link time. There is a
AP_HAL::get_HAL() function that is used by the client code. Each
implementation of HAL provides its own definition of this function,
returning the appropriate concrete instance.

Since this replaces the job of AP_HAL_BOARD_DRIVER, the definition was
removed.

The static variables for PX4 and VRBRAIN were named differently to avoid
shadowing the extern symbol 'hal'.
2015-10-21 09:16:07 +11:00
Gustavo Jose de Sousa c6eb15f443 AP_Parachute: standardize inclusion of libaries headers
This commit changes the way libraries headers are included in source files:

 - If the header is in the same directory the source belongs to, so the
 notation '#include ""' is used with the path relative to the directory
 containing the source.

 - If the header is outside the directory containing the source, then we use
 the notation '#include <>' with the path relative to libraries folder.

Some of the advantages of such approach:

 - Only one search path for libraries headers.

 - OSs like Windows may have a better lookup time.
2015-08-11 16:38:21 +10:00
Andrew Tridgell 330d8f5c3a AP_Parachute: convert example from .pde to .cpp 2015-06-01 17:07:06 +10:00
Randy Mackay 3bcd97fcd1 Parachute: increase deployment duration to 2sec 2015-05-12 22:08:20 +09:00
myly10 7bb079b348 AP_Parachute.cpp: Typo correction. 2015-02-13 16:16:10 +09:00
Randy Mackay 52ca06fc22 Parachute: fix example sketch 2015-01-28 17:15:48 +09:00
Randy Mackay 542ec29e49 Parachute: set servo or relay to off position on every update
This resolves the issue of the parachute servo's position not being
initialised to the off position due to an ordering problem of the
auxiliary servos being initialised after the parachute object.
2014-10-18 17:26:23 +09:00
Randy Mackay 06bef6e3b8 Parachute: clear release time when enabled
This resolves an issue in which the parachute could be suddenly released
when the user enabled the parachute.  The sequence that could have
caused this bad behaviour were (1) the parachute is triggered (2) the
user disables the parachute in the 0.5sec between the trigger and the
actual release, (3) the user re-enables the parachute and the old
release time from (1) is used.
2014-04-24 19:22:11 +09:00