74 Commits

Author SHA1 Message Date
Gautier Hattenberger ade23ab09c [flight plan] add a max_speed attribute to fp instruction (#3387)
This is only for the rotorcraft firmware at the moment, and it is
replacing the explicit call to guidance_h_SetMaxSpeed to simplify the
flight plans.
2024-10-04 08:53:30 +02:00
Gautier Hattenberger cea5c644e5 [flight plan] add on_enter and on_exit functions for nav block (#3385)
The functions passed to the attributes 'on_enter' and 'on_exit' will be
called once every time the flight plan state machine enters or leaves a
block, even if the block change is requested by the operator or if it is
caused by an exception.
It allows to properly activate and then disable services related to a
specific block.
Another good side effect is that the block and stage index are now
private and can't be modified by external modules. Old variables
nav_block and nav_stage can still be used as read-only.

Based on the work from:
Baptiste Pollien, Christophe Garion, Gautier Hattenberger, Pierre Roux, Xavier Thirioux.
A Verified UAV Flight Plan Generator. 2023 IEEE/ACM 11th International Conference on Formal Methods in Software Engineering (FormaliSE),
May 2023, Melbourne, Australia. pp.130-140, 10.1109/FormaliSE58978.2023.00021
2024-10-04 08:52:57 +02:00
Gautier Hattenberger 51e43fb67d Collection of changes after IMAV2024 (#3370)
- update airframe and add competition flight plans
- fix flight plan DTD
- mag params for Bristol
- add a set_expo function (might be weak) for digital cam driver
- fix tag tracking for simulation, add getter functions
- add option to skip initial circle in nav survey
- fix jevois driver parsing
2024-09-28 14:54:49 +02:00
Gautier Hattenberger bbcb166d37 [nav] remove nav_manual mode (#3234)
This mode is not really used and not even recommended. It is also not
implemented in all firmwares. If a direct call to stabilization command
is needed, it should be done with a specific function but not from a
builtin instruction from the flight plan.

It was discussed in #3208, but not applyied because of nav_heli_spinup.
A new h_mode 'NONE' allows to disable guidance and stabilization while in
NAV mode, which allows to set directly the commands.
2024-02-05 09:40:09 +01:00
Gautier Hattenberger 2ac79b3430 [nav] add a guided instruction for the flight plan
It allows (for rotorcraft) to use all the possibilities of the guided
mode from a single instruction in the flight plan, but without leaving
the NAV mode as it was done before. Thus all capabilities of the FP are
still accessible.
2022-10-15 23:56:09 +02:00
Fabien-B 3a47240aa8 [Flight plan] Add support for LTP waypoints. (#2676) 2021-03-24 18:28:23 +01:00
Gautier Hattenberger 5e041b5090 [nav] selectable navigation functions from flight plan (#2585) 2020-09-21 14:38:56 +02:00
Kirk Scheper e84ff368c2 Add rangesensor module (#2158)
* added rangesensors to gazebo model and NPS
* added module to handle the range sensors
* added sender IDS and added to abi messages
* added abi message to flight plan guided
2017-11-06 17:16:13 +01:00
Gautier Hattenberger da5c424ada [flight_plan] add binding to ABI messages from flight plan (#2106)
This feature allows to create an automatic binding to a ABI message
while specifying the list of variable names ('_' are ignored).
A local (static) variable is updated to the latest value each time a new
message is received and it can be read in any flight plan instruction.

Example of usage:

 <variables>
  <abi_binding name="VELOCITY_ESTIMATE" vars="_, vx, vy, vz, _"/>
 </variables>

please not the in this example, the first and the last variable are
ignored but the number of variable must match the number of fields in
ABI messages description (conf/abi.xml).

An extra attribute 'id' allows to set a specific sender ID (by default
ABI_BROADCAST).
2017-08-23 13:18:37 +02:00
Gautier Hattenberger 34f5730bc6 [flightplan] add pre and post calls at stage level (#1900)
this can help for issues like #1882
2016-10-12 22:24:44 +02:00
Christophe De Wagter 4acd680ccf [flight_plan] remerber last block, and return either to beginning of last block or continue last block (#1885) 2016-10-12 11:35:14 +02:00
podhrmic 2d23f5fc87 renamed geofence_max_agl to geofence_max_height 2016-07-27 12:59:36 -07:00
Michal Podhradsky 3373596088 Updated geofencing (#1802)
* Added geofence_max_agl and related checks

* Proper geofence checks in nav_geofence
2016-07-14 16:53:36 -07:00
Michal Podhradsky 050b406855 Updated safety behaviors (#1664)
* Fixed aircraft IDs for new airframe

* Flight plan safety improvements

* Make DATALINK_LOST_TIME optional

* Fixed in compilation

* Updated safety behavior vol II.

* Added the same behavior for rotorcraft

* Renamed variables

* Unified home mode exceptions in one file

* Fixed code style, changed to static inline

* Added inside_home_sector check for rotorcraft

* Renamed from home_mode_XXX to geofence_XXX to better reflect the functionality
Check for geofence_max_alt > ground_alt + security_height

* Fixed travis to compile with unsigned packages (#1689)
2016-05-26 17:41:17 -07:00
Felix Ruess 0e4c2c9233 [flight plans] add call_once alias (#1675)
- `<call_once fun="x"/>` is an alias for `<call fun="x" loop="false"/>`

The idea is to make it easier and more clear how to call functions that do not return a bool and should only be called once.
2016-05-24 17:51:13 +02:00
Freek van Tienen a9e9be2dab [heli][flight_plans] Heli Spinup routine and flight plan mode manual (#1606) 2016-04-26 10:49:58 +02:00
Gautier Hattenberger 993818bdd6 [modules] display warnings when module or its options are loaded twice 2016-02-25 23:23:00 +01:00
Gautier Hattenberger c697449e98 [modules] allow to load modules from a flight plan 2016-02-17 23:11:03 +01:00
Gautier Hattenberger 579fdf4acd [flight_plan] allow variable declaration from flight plan
- can be used localy in the flight plan to avoid adding new variables in
  the base code when it can be avoided
- with appropriate attributes, will generate a settings accessible from
  the GCS
2016-02-05 00:36:18 +01:00
Gautier Hattenberger 04a5c08033 [flight_plan] support dynamic sectors
update in GCS to be done
2015-06-08 01:15:52 +02:00
Gautier Hattenberger 295714793d [gen_fligtplan] 'call' statement can be configured to loop and/or break
default behavior:
- the function is called until returning FALSE (same as before)
- at the end of the call, go to next stage immediately (new)

this is related to #830
2014-11-06 14:43:24 +01:00
Gautier Hattenberger 524205cbf8 [nav] exceeding_time on segment
Add an 'exceeding_time' attribute to 'go' and 'path' blocks that tells how
many seconds the plane should fly after the end of the segment before
completing it.
It is equivalent to giving a negative 'approaching_time' (and these two
attributes are of course not compatible with each other).
In addition some math functions in nav are forced to float.
2014-04-01 17:55:29 +02:00
Gautier Hattenberger cc10e482d7 [flight_plan] update DTD for until attribute with call and survey 2013-07-15 16:21:59 +02:00
Gautier Hattenberger c42477d02d [home] home mode height can be set different from security height 2012-09-03 11:11:11 +02:00
Gautier Hattenberger 5b7b37804a [fp] add until attribute to go block in flight plans 2012-08-29 17:01:37 +02:00
Stephen Dwyer baaa5d2199 removed some attributes of element OVAL that were defined twice 2012-05-26 08:44:43 +02:00
Gautier Hattenberger 6abd9087c5 [dtd] some fixing in module and flight_plan DTD 2012-05-26 00:15:09 +02:00
Gautier Hattenberger 78e382023f add feature to group strip buttons verticaly with attribute "group" in settings and flight plans 2010-10-19 15:39:07 +00:00
Anton Kochevar e04ecbde18 Added alt to eight and oval calls, dont see a reason why you shouldnt be able to set these. 2010-01-23 03:09:24 +00:00
Pascal Brisset 327a789e83 add until attribute to stay stage 2009-09-12 21:26:46 +00:00
Gautier Hattenberger 0d30d46f21 add height option in flight plans 2009-09-03 11:50:22 +00:00
Pascal Brisset 8cd9cc267f add sectors, header to procedures
add color to sectors
2009-08-30 19:32:58 +00:00
Pascal Brisset fbf08ab5c4 remove translation and rotation of procedures 2009-08-28 16:26:47 +00:00
Pascal Brisset 483210b267 Add "path" instruction preprocessed into "go" instructions 2009-08-13 17:16:53 +00:00
Pascal Brisset bc9ee9626c key shortcut example 2009-06-30 22:24:33 +00:00
Pascal Brisset b8be87ef30 vmode attributes in oval 2009-01-19 13:40:44 +00:00
OSAM-UAV Team 571c9a1459 Removed bungee takoff 2009-01-07 18:36:35 +00:00
Pascal Brisset e7c4fae678 lat and lon attributes allowed in waypoint definitions 2008-12-06 10:18:07 +00:00
OSAM-UAV Team a213f57be7 New bungee launch function added 2008-12-04 21:48:12 +00:00
Pascal Brisset 5bd89406d5 pre_call, post_call added in blocks; pitch (in degrees) fixed 2008-02-28 08:50:23 +00:00
Pascal Brisset 4e9999a440 cam control removed 2008-02-26 10:24:54 +00:00
Pascal Brisset a1dffbffe1 nav for tl 2008-01-28 02:29:12 +00:00
Pascal Brisset 1f537bfaaa qfu now optional in flight plans 2007-11-06 16:24:58 +00:00
Pascal Brisset a090d024b3 Icons in strips 2007-10-09 07:18:51 +00:00
Pascal Brisset 03970d82e1 At least 3 corners in a sector 2007-09-26 07:08:01 +00:00
Pascal Brisset 4ddaf18b42 Handling of convex, clockwise described, sectors 2007-09-08 13:42:40 +00:00
Pascal Brisset da930d5c48 West-East survey 2007-04-23 20:15:49 +00:00
Pascal Brisset 7e0975ee5e navigation on Ovals (Anton's code) 2006-11-27 13:04:34 +00:00
Pascal Brisset 137c3904b8 *** empty log message *** 2006-11-14 21:26:00 +00:00
Pascal Brisset c4a6727e8f *** empty log message *** 2006-10-27 16:13:00 +00:00