Teleport ======== **Motion controller which changes instantly robot pose (position and orientation)** This actuator teleports the robot to the absolute position and orientation with respect to the origin of the Blender coordinate reference. Angles are expected in radians. .. note:: Coordinates are given with respect to the origin of Blender's coordinate axis. .. cssclass:: properties morse-section Configuration parameters for Teleport ------------------------------------- *No configurable parameter.* .. cssclass:: fields morse-section Data fields ----------- This actuator reads these datafields at each simulation step: - ``x`` (float, initial value: ``initial robot X position``) X coordinate of the destination, in meter - ``y`` (float, initial value: ``initial robot Y position``) Y coordinate of the destination, in meter - ``z`` (float, initial value: ``initial robot Z position``) Z coordinate of the destination, in meter - ``yaw`` (float, initial value: ``Initial robot yaw``) Rotation of the robot around Z axis, in radian - ``pitch`` (float, initial value: ``Initial robot pitch``) Rotation of the robot around Y axis, in radian - ``roll`` (float, initial value: ``Initial robot roll``) Rotation of the robot around X axis, in radian *Interface support:* - :tag:`ros` as `geometry_msgs/Pose `_ (:py:mod:`morse.middleware.ros.read_pose.PoseReader`) - :tag:`socket` as straight JSON deserialization (:py:mod:`morse.middleware.socket_datastream.SocketReader`) - :tag:`yarp` as yarp::Bottle (:py:mod:`morse.middleware.yarp_datastream.YarpReader`) - :tag:`moos` as PoseReader (:py:mod:`morse.middleware.moos.pose.PoseReader`) .. cssclass:: services morse-section Services for Teleport --------------------- - ``get_properties()`` (blocking) Returns the properties of a component. - Return value a dictionary of the current component's properties - ``rotate(roll, pitch, yaw)`` (blocking) Rotates the actuator owner by the given (roll,pitch,yaw). This is a **relative** rotation. - Parameters - ``roll``: roll rotation, in radians - ``pitch``: (default: 0.0) pitch rotation, in radians - ``yaw``: (default: 0.0) yaw rotation, in radians - ``translate(x, y, z)`` (blocking) Translate the actuator owner by the given (x,y,z) vector. This is a **relative** displacement. - Parameters - ``x``: X translation, in meter - ``y``: (default: 0.0) Y translation, in meter - ``z``: (default: 0.0) Z translation, in meter - ``set_property(prop_name, prop_val)`` (blocking) Modify one property on a component - Parameters - ``prop_name``: the name of the property to modify (as shown the documentation) - ``prop_val``: the new value of the property. Note that there is no checking about the type of the value so be careful - Return value nothing - ``get_configurations()`` (blocking) Returns the configurations of a component (parsed from the properties). - Return value a dictionary of the current component's configurations .. cssclass:: examples morse-section Examples -------- The following examples show how to use this component in a *Builder* script: .. code-block:: python from morse.builder import * # adds a default robot (the MORSE mascott!) robot = Morsy() # creates a new instance of the actuator teleport = Teleport() # place your component at the correct location teleport.translate(, , ) teleport.rotate(, , ) robot.append(teleport) # define one or several communication interface, like 'socket' teleport.add_interface() env = Environment('empty') .. cssclass:: files morse-section Other sources of examples +++++++++++++++++++++++++ - `Source code <../../_modules/morse/actuators/teleport.html>`_ - `Unit-test <../../_modules/base/teleport_testing.html>`_ *(This page has been auto-generated from MORSE module morse.actuators.teleport.)*