Ros Unity
[REP Index][REP Source]
| REP: | 103 |
|---|---|
| Title: | Standard Units of Measure and Coordinate Conventions |
| Author: | Tully Foote, Mike Purvis |
| Status: | Active |
| Type: | Informational |
| Content-Type: | text/x-rst |
| Created: | 07-Oct-2010 |
| Post-History: | 31-Dec-2014 |
With the chosen setup, Unity showed systematic and nonsystematic errors in the end-position of predefined paths. A SLAM case study presented the possibility to use Unity in combination with SLAM algorithms on ROS. It was possible to implement other algorithms and simulate required sensors for data acquisition in Unity.
Contents
Ros Unity Point
- On the other hand, ROS can provide clear software structure and simultaneous operation between hardware devices for actual UAVs. By developing data transmitting interface and necessary sensor.
- ROS is a set of packages you install on Ubuntu (Ubuntu being the actual OS). Ubuntu is a flavor of Linux Unity specifically supports already. What support from Unity are you looking for here specifically? I'd try the experimental roscs client library for C#.
- Units
- Coordinate Frame Conventions
This REP provides a reference for the units and coordinate conventionsused within ROS.
Inconsistency in units and conventions is a common source ofintegration issues for developers and can also lead to softwarebugs. It can also create unnecessary computation due to dataconversion. This REP documents the standard conventions for ROS inorder to lessen these issues.
The scope of potential robotics software is too broad to require allROS software to follow the guidelines of this REP. However, choosing differentconventions should be well justified and well documented.
For example, there are domains where the default conventions are notappropriate. Interstellar lengths are not appropriately measured inmeters, and space-oriented libraries may wish to choose a differentconvention. There are other exceptions that different domains may wishto address.
We have chosen to standardize on SI units. These units are the mostconsistent international standard. SI units are maintained by BureauInternational des Poids et Mesures. [1] There is good documentationon Wikipedia for International System Of Units[2]
Base Units
These are the base units which are commonly used
| Quantity | Unit |
|---|---|
| length | meter |
| mass | kilogram |
| time | second |
| current | ampere |
Derived Units
SI defines seven base units and many derived units. If you are not usingSI base units, you should use SI-derived units.
Good documentation can be found on Wikipedia about SI derived units[3]
Commonly used SI-derived units in ROS are:
| Quantity | Unit |
|---|---|
| angle | radian |
| frequency | hertz |
| force | newton |
| power | watt |
| voltage | volt |
| temperature | celsius |
| magnetism | tesla |
All coordinate frames should follow these conventions.
Chirality
All systems are right handed. This means they comply with the right hand rule[4].
Ros Unity
Axis Orientation
In relation to a body the standard is:
- x forward
- y left
- z up
For short-range Cartesian representations of geographic locations, use theeast north up[5] (ENU) convention:
- X east
- Y north
- Z up
To avoid precision problems with large float32 values, it is recommended tochoose a nearby origin such as your system's starting position.
Suffix Frames
In the case of cameras, there is often a second frame defined with a'_optical' suffix. This uses a slightly different convention:

- z forward
- x right
- y down
For outdoor systems where it is desirable to work under thenorth east down[6] (NED) convention, define an appropriately transformedsecondary frame with the '_ned' suffix:
- X north
- Y east
- Z down
Rotation Representation
There are many ways to represent rotations. The preferred order is listed below, along with rationale.
- quaternion
- Compact representation
- No singularities
- rotation matrix
- No singularities
- fixed axis roll, pitch, yaw about X, Y, Z axes respectively
- No ambiguity on order
- Used for angular velocities
- euler angles yaw, pitch, and roll about Z, Y, X axes respectively
- Euler angles are generally discouraged due to having 24 'valid'conventions with different domains using different conventions bydefault.
By the right hand rule, the yaw component of orientation increases as the child framerotates counter-clockwise, and for geographic poses, yaw is zero when pointing east.
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 makethe appropriate transformations before publishing standard ROS messages.
Covariance Representation
Linear
Angular
Six Dimensional
| [1] | Bureau International des Poids et Mesures(http://www.bipm.org/en/home/) |
| [2] | http://en.wikipedia.org/wiki/International_System_of_Units |
| [3] | http://en.wikipedia.org/wiki/SI_derived_units |
| [4] | http://en.wikipedia.org/wiki/Right-hand_rule |
| [5] | http://en.wikipedia.org/wiki/Geodetic_datum#Local_east.2C_north.2C_up_.28ENU.29_coordinates |
| [6] | http://en.wikipedia.org/wiki/North_east_down |
Ros Unity3d
This document has been placed in the public domain.
Brief Description
My main objective is to simulate a robotic arm with gripper on a mobile platform using Unity. I want the robot to be capable of picking up and placing objects in the environment using physics and friction, not by making the object a child of the gripper or fixing it to the gripper. I will go into further detail of the issue I'm having below, but basically I cannot figure out an easy way to use ros_control with Unity. Specifically, I want to use a joint_trajectory_controller to control a robot arm in Unity so that it will be able to follow position, velocity, and acceleration trajectories to pick up an object.
I am using two computers:
Ros# Unity Wiki
- Windows 10 64bit desktop running Unity 2019.3 with ROS-sharp
- Ubuntu 16.04 64bit, Linux kernel 4.15.0-106-generic with ROS kinetic and Gazebo 7
Ros Unity Map
Detailed Description
To accomplish my goal listed above, I have been following various tutorials on how to achieve the same thing in Gazebo. Initially I was following a Husky navigation tutorial since Husky will be the physical robot I will have access to eventually, and being able to control a mobile robot with waypoint markers seemed like a good place to start. Getting the demo to work in Gazebo was pretty straight forward, so I started modifying the launch files to launch the ROS-sharp rosbridge_websocket instead of Gazebo. However, I eventually realized that the cmd_vel commands sent to Gazebo in the demo could not be translated by ROS-sharp in Unity. I believe this is because a diff_drive_controller, which accepts these commands, is used to control Husky in the demo through some plugin adapter in Gazebo. My understanding is that no such 'plugin' exists in ROS-sharp for Unity to use ros_control. Fortunately, the diff_drive_controller was not too hard to understand, and someone had already written a script to subscribe to cmd_vel and translate to motor velocities here in appendix C. After a few more tweaks and scripting, I had the Husky navigation tutorial running in Unity.
I was pretty excited about getting that to work, but my elation was short lived after I realized how much more difficult it would be to accomplish the same task for an arm and gripper. I could not find a straight forward tutorial that would allow me to simulate a Husky with an arm and gripper in Gazebo, so eventually I settled on simulating the TIAGo robot since it has all of the capabilities I need, good documentation, and a demo that demonstrates everything I'm looking for. After finding the joint_trajectory_controller which I believe is the controller I would need to rewrite in ROS-sharp, I realized that reverse engineering this controller would be much more difficult. I am unfamiliar with how to create quintic splines from position, velocity, and acceleration, and am not even sure what the arm controller is doing considering it is a position_controller yet PID gains are specified and the goal trajectory is given in terms of ...(more)
Ros Unity Bridge
