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

AC_Fence: A circular fence with a radius of 0 meters is ignored #27094

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

muramura
Copy link
Contributor

@muramura muramura commented May 18, 2024

I am developing an application for vehicles that support MAVLINK messages. I have discovered different behaviors in the setting of circular fences. I want to ignore circles with a radius of 0 meters. By ignoring circles with a radius of 0 meters, I can standardize the processing with vehicles other than ArduPilot.

AFTER
Screenshot from 2024-05-18 23-13-29

Screenshot from 2024-05-18 23-13-36

BEFORE
Screenshot from 2024-05-18 22-11-23

@rmackay9 rmackay9 requested a review from peterbarker May 20, 2024 00:58
@rmackay9
Copy link
Contributor

rmackay9 commented May 20, 2024

I guess the advantage of supporting this is that it allows an external system to essentially disable a fence without removing it from the list.

The downside is that it introduces an edge case that we will need to be careful of in the flight code. The flight code may or may not be ignoring circular fences with zero radius.

TBH, I'm not sure it's a good idea to make this change. External systems should be able to enable/disable in other ways which don't increase the complexity of the flight code.

@muramura
Copy link
Contributor Author

@rmackay9 san.
I'm modifying the process for adding circle fences so that only those with a positive radius are registered.

Screenshot from 2024-05-21 06-29-08

@peterbarker
Copy link
Contributor

I'm really confused by this - we're enforcing different rules for the fence in different places, which is just really rather odd.

And patching in "write_fence" is very strange.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants