Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mission:reset mission after finished #13948

Closed
wants to merge 2 commits into from

Conversation

jinchengde
Copy link
Contributor

@Antiheavy Antiheavy requested a review from dagar January 15, 2020 14:29
@Antiheavy
Copy link
Contributor

I think this makes sense, but I think @dagar and @TSC21 should comment too as they were reviewers on the original PR #10288

@Antiheavy
Copy link
Contributor

@jinchengde one concern that came up is what happens in the case of a fixed wing abort landing? The fixed wing abort landing changes the mission index to the Do_Land_Start and also switches to Hold/Loiter mode above the landing location. Is that functionality still preserved by this PR?

@jinchengde
Copy link
Contributor Author

jinchengde commented Jan 17, 2020

@jinchengde one concern that came up is what happens in the case of a fixed wing abort landing? The fixed wing abort landing changes the mission index to the Do_Land_Start and also switches to Hold/Loiter mode above the landing location. Is that functionality still preserved by this PR?

yes, Hold/Loiter mode above the landing location is still preserverd by this PR. the mission index change to the DO_LAND_START just effect if you reset the mission(switch the flight mode)

@Antiheavy
Copy link
Contributor

yes, Hold/Loiter mode above the landing location is still preserverd by this PR. the mission index change to the DO_LAND_START just effect if you reset the mission(switch the flight mode)

This is how I understand it works now:

  1. Vehicle receives Abort Landing command
  2. Vehicle automatically changes mode to Hold/Loiter at a position setpoint above the Land location
  3. Mission index is automatically changed to DO_LAND_START
  4. Vehicle climbs with wings level (0 roll angle) until safe altitude reached, then turns towards loiter location above landing.

With this PR, when the use switches back to Mission mode after being in the abort loiter, does the vehicle keep the DO_LAND_START as the mission index (it should)?

Possible edge case: what happens when the vehicle is landing, gets very close to the land waypoint and achieves/accepts the land waypoint, but the vehicle hasn't actually landed yet, then the user aborts the landing?

@jinchengde
Copy link
Contributor Author

With this PR, when the use switches back to Mission mode after being in the abort loiter, does the vehicle keep the DO_LAND_START as the mission index (it should)?

Correct, vehicle will go to the DO_LAND_START if user switch back to MISSION mode.

Possible edge case: what happens when the vehicle is landing, gets very close to the land waypoint and achieves/accepts the land waypoint, but the vehicle hasn't actually landed yet, then the user aborts the landing?

  1. vehicle hasn't landed yet but accepts the land waypoint, if user trigger abort landing, vehicle will climb up and start to loiter because vehicle hasn't detect land, if user switch back to mission, vehicle will go to DO_LAND_START.
  2. vehicle landed and user choose keep plan in vehicle, restart the mission, vehicle will start from the first waypoint of plan.

@Antiheavy
Copy link
Contributor

2\. vehicle landed and user choose keep plan in vehicle, restart the mission, vehicle will start from the first waypoint of plan.

As it works currently in Stable, if the vehicle disarms, it resets the mission. With your new PR, even if the vehicle stays armed and active after landing, if the final waypoint in the mission was "completed", it will also reset the mission upon re-entering Mission mode - is that correct? If so, I think that is good.

@jinchengde
Copy link
Contributor Author

As it works currently in Stable, if the vehicle disarms, it resets the mission. With your new PR, even if the vehicle stays armed and active after landing, if the final waypoint in the mission was "completed", it will also reset the mission upon re-entering Mission mode - is that correct? If so, I think that is good.

Correct

@Antiheavy
Copy link
Contributor

This seems like something good to discuss in the Dev Call since it potentially effects anyone who uses Mission mode.
https://discuss.px4.io/c/weekly-dev-call/px4-dev-call

@julianoes
Copy link
Contributor

This might have been resolved by #14020.

@jinchengde
Copy link
Contributor Author

actually, this is about go around and approach again for fixed wing, I record the demo to help others understand this feature
https://youtu.be/RFcheXkMZaA

@Antiheavy
Copy link
Contributor

Now you guys both have me confused. I thought this this PR is just about reseting the mission from the start if re-entering mission mode when the mission has already been completed.

@jinchengde
Copy link
Contributor Author

yes, if the flight plan without landing pattern, the behaviour is reseting the mission from the start
https://youtu.be/G2z-NYUxgRQ
but if the flight plan have landing pattern, it will reset the mission to the landing start if we trigger the abort landing

@Antiheavy
Copy link
Contributor

if the flight plan have landing pattern, it will reset the mission to the landing start if we trigger the abort landing

yes, but that feature is not part of this PR. that feature is already existing. This PR handles the case when the mission completes, but you are still "flying" (there are many of examples of when this could be the case).

I'm not sure @julianoes comment applies. Does it?

This might have been resolved by #14020.

@stale
Copy link

stale bot commented Apr 26, 2020

This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions.

@LorenzMeier
Copy link
Member

@jinchengde Would you mind rebasing this again? And could you (sorry for asking again) explain the issue you are solving?

@stale stale bot removed the stale label Jan 17, 2021
vehicle could reset mission after mission finished, change the flight mode to others and back to mission mode, no need disarm, the mission will reset.
@jinchengde
Copy link
Contributor Author

@LorenzMeier
I rebase the PR and this PR is want to solve the issue that some user want to reset the mission after it finished but no need the vehicle land.
for example, the plane will enter the loiter after mission finished, so if we wish to reset the mission, two ways.

  1. reset mission in QGC
  2. land the plane and disarm
    so this PR provide another way the change the flight mode to anyone others and back to auto mode, the mission will reset.

@junwoo091400 junwoo091400 added the Flight Controls 🦅 Anything about flight control algorithm (Navigation, Attitude control, etc) label Mar 26, 2023
@jinchengde jinchengde closed this by deleting the head repository Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Flight Controls 🦅 Anything about flight control algorithm (Navigation, Attitude control, etc)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants