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

enable WV function on land/rtl/loiter/takeoff #13740

Closed
wants to merge 1 commit into from
Closed

enable WV function on land/rtl/loiter/takeoff #13740

wants to merge 1 commit into from

Conversation

xdwgood
Copy link
Contributor

@xdwgood xdwgood commented Dec 13, 2019

To fix: #13725

Copy link
Contributor

@sfuhrer sfuhrer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your PR, it seems to fix the bug. However, I'm wondering if there's a cleaner way to do it. How about setting _navigator->get_position_setpoint_triplet()->current.allow_weather_vane = true; in here instead? And similarly also in land.cpp and loiter.cpp.

Comment on lines 51 to 53

/* invalidate position setpoint by default */
_navigator->get_position_setpoint_triplet()->current.valid = false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this change needed?

Copy link
Contributor Author

@xdwgood xdwgood Dec 16, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because when I was in Gazebo simulation, I found that it was not running here.:https://github.com/PX4/Firmware/pull/13740/files#diff-ca6b0e7090d881629e9e3cd91610fb09L95

on_activation Is a virtual function

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm against this change. It's scary and I'm not sure we know all of the effects of this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@julianoes You are right, but can I just delete it instead of moving here?
Because it will not be run here(https://github.com/PX4/Firmware/pull/13740/files#diff-ca6b0e7090d881629e9e3cd91610fb09L95), it is invalid code
thanks review 😃

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done here: 5aa037a

FYI : @sfuhrer

@xdwgood xdwgood changed the title navigator: 1:Ensure default execution.2:always allow weather vane input enable WV function on land/rtl/loiter/takeoff Dec 17, 2019
Copy link
Contributor

@julianoes julianoes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From my side this looks ok but I don't know much about VTOL so I defer the review to @sfuhrer or @RomanBapst.

@sfuhrer
Copy link
Contributor

sfuhrer commented Dec 18, 2019

@xdwgood I think I've found a slightly nicer way to do it: #13761. Let me know what you think and if it solves your issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hybrid VTOL 🛩️🚁 Multirotor + Fixedwing!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants