June 01, 2022
Join us
Agenda
Community Announcement
Community Q&A
Project Updates
General Discussions
Weekly Overview
High priority queue
Release
Community Announcement
Dev Summit 2022!
You can purchase a virtual ticket!
2 Full Days of Workshops & Keynotes
On the first day, there will be a 300 drone light show
On the second day, there will be some yummy cakes
Community Q&A (No deep technical discussions)
Guideline for asking a Question
Specify what you are trying to achieve
Specify what environment / platform you are using
Prepare a Link or Document to help understand if possible
First, ask the question on the Slack or create a Github Issue !
If you take over 5 minutes for the question, please continue in Slack or a Github Issue.
Q.1 : Raspberry Pi Pico Issue - Vatsal
https://github.com/PX4/PX4-Autopilot/issues/19491
The fix was merged to NuttX yesterday. When will it come into effect in PX4?
https://github.com/apache/incubator-nuttx/pull/6347
Answer: Cherry-pick the changes from NuttX and open the PR to PX4
Q.2 : UAVCAN Servo Support status - Dave
PX4 does not support UAVCAN servos (at time of writing).
Q.3 : OpenMV - Patrick
PX4 Flow
Answer: Optial sensor is better than the Sonar one
Project Updates
P.1 : Precision Landing PR merge discussion - @potaito
https://github.com/PX4/PX4-Autopilot/pull/18973
Discussion topics from the PR:
What is / should be the role of navigator in general? I think we all agree that currently it is doing too much. Should it be a state machine? Or should it only be an array of mission items?
How can flight modes such as precland, orbit or follow-me become part of a mission?
If we allow custom flight modes as flight tasks to be used in missions, the flight tasks will have to contain the criteria that determine when the task is complete. For example, if the vehicle is supposed to fly orbit for three resolutions, then the orbit flight task should track this and report when it’s done.
What are AUTO modes? Is AUTO = mission? Or is AUTO a superset that contains mission along other modes?
Moved the ‘Precision Landing’ from Navigator to Flight Task
Want to discuss: “Mission triggering certain flight modes”
Currently, executing the ‘orbit’ mode in the middle of the mission for 60 seconds, and then resuming the mission is a missing feature in PX4.
Implemented ‘Main mode’ and ‘Sub mode’, to implement this.
Feedback: It would be great for the Navigator just to handle the flight modes / handle mission state machine (Thomas)
P.2 : Rewrite of the Failsafe state machine
PX4:main
← PX4:pr-failsafe-statemachine-rewrite
opened 08:08AM - 24 May 22 UTC
I was working on preflight check reporting with the events interface and wanted … to check how it could fit into the whole structure. So I came up with this:
![commander drawio](https://user-images.githubusercontent.com/281593/169977325-5cf1068e-08ad-42a9-9dc9-45599e615754.png)
The basic idea is that the arming/health checks do the GCS reporting, prevent all or individual modes from arming, and can set flags that are then used in the failsafe state machine (the checks run and report during arming as well).
This PR is about implementing the failsafe state machine part.
### Failsafe state machine
- As one of the basic requirements, there needs to be a way to generate user documentation from the code.
I ended up using Emscripten, which allows to compile the C++ code directly to webassembly and run it in the browser. So any possible failsafe combination can be checked directly, and the logic corresponds 1:1 to what runs on the vehicle.
This allows to implement arbitrary logic in the C++ code.
At the same time it is very convenient for development (testing and debugging) as well.
The condition flags are extracted from the msg file directly, and there's a minimal parameter storage. The accessed parameters are added to the UI (using the parameter json metadata).
The implementation of this PR can be tested under https://logs.px4.io/plot_app/static/failsafe_test/index.html.
Use `make run_failsafe_web_server` to build & run it locally.
- The implementation is split into a generic framework (base class) and class that implements the actual checks (this could be vehicle-specific).
- The framework maintains a set of active actions and an action becomes active when a condition is triggered. Action can have additional settings (e.g. if user takeover is allowed). The selected failsafe is then the most severe active action.
So it's well-defined what happens when multiple failsafes trigger.
Then there's fallbacks to the next option, should the desired failsafe not be available.
- clear condition: by default, when the failure condition clears, the vehicle goes back into the user intended mode. An action can change this to e.g. clear only on disarming or on mode switch.
- user takeover: the default behavior is when an action is triggered, the vehicle first goes into Hold for N seconds (configurable, and disabled for N=0), with a user notification. During that time the user cannot take over. After that the action is triggered and the user can take over by switching into any mode or moving the sticks.
- `can_run`: this is a bitset for each mode if it can be executed (basically what `main_state_transition` currently does). This is used by the failsafe state machine for mode fallback. We probably need more granularity here later on (e.g. which modes require position).
- The behavior generally matches closely what we have now, apart from generically handling multiple failsafes. It can generally be changed as we need it.
- state machine inputs: minimal state (armed, vehicle type, user intended mode, user takeover request, etc), `vehicle_status_flags` (conditions) and param configuration
- output: failsafe action (if any), updated user intended mode
- Not everything is done yet, for testing I implemented the core of the existing failsafe state machine, `set_nav_state`, user takeover and a few other things.
- I'm also suggesting to change the lockdown action to disarm.
Feedback is welcome, also unexpected or unintended behavior (there's generally various details that can be done one way or another).
Thanks to @KonradRudin & @MaEtUgR for testing & support.
Screenshot of the web sim:
![image](https://user-images.githubusercontent.com/281593/169977907-cd060eff-674f-44d3-94b9-ab3883218c6e.png)
General Discussions
D.1 :
Weekly Overview
Github
Recently updated Issues / PRs in PX4-Autopilot Link
Pull Requests
*
Issues
*
Slack
Daniel’s Null Island
Last Dev-Call
PX4 Dev Call: April 27, 2022
High priority queue
Discussion based on: High-Priority Queue · GitHub
Release
Hi Ramon,
I am interested to join - what time is this developer call?
Thanks,
Dev
1 Like
The call is at 5pm CET every Wednesday, you can see/download the calendar invite from this link Dronecode Calendar — Dronecode Foundation
Ramon,
I would like to bring up the still unanswered topic of the status of PX4 support for UAVCAN servo actuators. Online documentation states they are not supported (UAVCAN | PX4 User Guide ). Would like to confirm that is still the case and any plans to add servo support on UAVCAN vs PWM output.
Thanks,
Dave
2 Likes