Skip to content

Commit

Permalink
Add GeoPoseStamped interface for REP-147
Browse files Browse the repository at this point in the history
* This clarifies a standard way to publish global pose of a vehicle
* Add another example to REP-103 to remove ambiguity

Signed-off-by: Ryan Friedman <[email protected]>
  • Loading branch information
Ryan Friedman committed Sep 12, 2024
1 parent f87e1db commit 02bfa52
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 4 deletions.
8 changes: 5 additions & 3 deletions rep-0103.rst
Original file line number Diff line number Diff line change
Expand Up @@ -168,12 +168,15 @@ There are many ways to represent rotations. The preferred order is listed below,
default.

By the right hand rule, the yaw component of orientation increases as the child frame
rotates counter-clockwise, and for geographic poses, yaw is zero when pointing east.
rotates counter-clockwise.
For geographic poses, yaw is zero when pointing east, and is thus 90 degrees when the
vehicle is facing north.

This requires special mention only because it differs from a traditional compass bearing,
This requires special mention only because it differs from a traditional `compass bearing`_,
which is zero when pointing north and increments clockwise. Hardware drivers should make
the appropriate transformations before publishing standard ROS messages.

.. _compass bearing: https://en.wikipedia.org/wiki/Bearing_(navigation)

Covariance Representation
-------------------------
Expand Down Expand Up @@ -207,7 +210,6 @@ References
.. [1] Bureau International des Poids et Mesures
(http://www.bipm.org/en/home/)
Copyright
=========

Expand Down
48 changes: 47 additions & 1 deletion rep-0147.rst
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,9 @@ A higher level view of the system uses the following abstraction.
Coordinate Frames
=================

It is expected that users of this interface will also follow the coordinate frame conventions layed out in REP 105 [#rep105]_.
It is expected that users of this interface will also follow the coordinate frame conventions layed out in REP 105 [#REP105]_.
As mentioned in REP 103 [#REP103]_, if using the NED convention, the frame ID must end in ``_ned``.
If unspecified, ENU can be assumed.

Proposed Interfaces
===================
Expand Down Expand Up @@ -341,6 +343,33 @@ To send a series of goals a list of GlobalPositions can be used.
nav_msgs/GlobalPosition[] waypoints


Pose Reporting
------------------

An aerial vehicle can share its geographic pose via ``geographic_msgs/GeoPoseStamped`` [#geoposestamped]_.
The position coordinates should follow WGS-84 [#wgs84]_.

EGM2008 [#egm]_ can be assumed as the altitude datum unless otherwise stated.
If and when EGM2020 is released, this REP can be updated.
Take caution integrating GPS data and terrain data as they frequently use different datums.

The orientation field follows REP 103's [#REP103]_ recommendation. The orientation is the transform from the
local tangent plane [#ltpc]_ to the body frame.

A vehicle flying facing east will have a unit identity quaternion for its orientation.

x,y,z=0, w=1

.. image:: rep-0147/geopose-default-orientation.png

Remember that per REP 103 [#REP103]_, when the orientation is decomposed to its yaw component,
this yaw value is NOT equal to the traditional compass bearing.

In the situation that the position is known but orientation it not known, or vise versa,
the unknown fields should be populated with ``NaN`` to avoid Null Island [#null_island]_.

TODO add link to ArduPilot test code for orientation.

Currently Unspecified
---------------------

Expand Down Expand Up @@ -960,6 +989,9 @@ References
.. [#twiststamped] geometry_msgs/TwistStamped
(http://docs.ros.org/api/geometry_msgs/html/msg/TwistStamped.html)
.. [#rep103] REP 103: Standard Units of Measure and Coordinate Conventions
(http://www.ros.org/reps/rep-0103.html)
.. [#rep105] REP 105: Coordinate Frames for Mobile Platforms
(http://www.ros.org/reps/rep-0105.html)
Expand All @@ -978,6 +1010,20 @@ References
.. [#ss_trigger] ``std_srvs/Trigger``
(http://docs.ros.org/melodic/api/std_srvs/html/srv/Trigger.html)
.. [#geoposestamped] odometry
(https://docs.ros.org/en/api/geographic_msgs/html/msg/GeoPoseStamped.html)
.. [#egm] Earth Gravity Model
(https://en.wikipedia.org/wiki/Earth_Gravitational_Model)
.. [#wgs84] WGS 84
(https://en.wikipedia.org/wiki/World_Geodetic_System#WGS84)
.. [#ltpc] Local Tangent Plane coordinates
(https://en.wikipedia.org/wiki/Local_tangent_plane_coordinates)
.. [#null_island] Null Island
(https://en.wikipedia.org/wiki/Null_Island)
Copyright
=========
Expand Down
Binary file added rep-0147/geopose-default-orientation.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 02bfa52

Please sign in to comment.