Question Regarding Setting Global Target Setpoints


Based on the API definition for the Global Position Setpoint service from the navigation module, it should be possible to give the target destination in lat/long/rel_alt. However, when testing this I am seeing that shortly after defining the target setpoint with this api, the navigation module is actually translating this to a target setpoint in the local coordinate frame and sending that. Is this intended behavior?


Yes. That is exactly what is happening. Not all autopilots provide the feature to accept position setpoints in global frame (lat/lng). Hence, we convert the setpoints to local frame and send it to autopilots.


Thank you for the confirmation. While testing, I saw that across different trials where the drone was picked up and placed in different starting locations, upon giving it the same target location in lat/long it actually was inaccurate and would miss the target destination. Is there a way to define the target location in lat/long and actually send that, rather than the local setpoint? I know missions are one way, but mavros also supports this (using mavros/setpoint_raw/global topic) so I am wondering if this can be done with flytos


Hi @mbaldwin,

sorry for the delayed response.

Yes. FlytOS does expose /flytos/mavros/setpoint_raw/global topic, and one can use it to send global position setpoints.

I am anyway working on this issue and should release a new FlytOS version ( fixing the standard position_set_global API ) by the end of this week.