since position control is not already provided by the Dronecode SDK and I would really like to have it in my “toolbox”, I decided to add it in the Dronecode OFFBOARD commands.
I have already successfully added the position commands for the NED frame (I will be glad to share the code if you’re interested) and I am now trying to add the position commands for the BODY frame. But it seems to me that frame is ignored by the position control.
Looking inside the PX4 code, I found that the OFFBOARD commands are handled in the method
Inside this method, the only reference to a
frame is the
Does it mean that the offboard position control always overrides the frame to NED? Is it possible to command displacements in BODY frame?
Good question, sorry I didn’t get back to you earlier. I think we should support both but it’s probably true that some things are missing on the PX4 and/or SDK side. I hope I’ll get to this some day. Until then PRs welcome .
any news about an eventual “set_position_ned” method for the Offboard class?
That would indeed be nice, status is here:
thank you for the update. In the meantime, I made my local branch with the “position_ned” functions.
I am sorry I didn’t share them on github, I was quite in a hurry. Anyway, they seem to work pretty well.
You can find the files here: https://drive.google.com/open?id=1_8xzgTPq88-a2Hi74yR13dIO6b5R7OFS
Here’s git status output:
I hope they can be of help to make these functionalities available for everyone soon.
I would really appreciate a pull request
Arrrg, I knew you would have said that… But it’s just a few lines of code
Should I refer to this guide? https://help.github.com/en/articles/creating-a-pull-request
Can I push just the code or unit test, etc. are required too?