ros2--服务接口

发布于:2024-07-23 ⋅ 阅读:(129) ⋅ 点赞:(0)

std_msgs/msg/Header

# Standard metadata for higher-level stamped data types.
# This is generally used to communicate timestamped data
# in a particular coordinate frame.

# Two-integer timestamp that is expressed as seconds and nanoseconds.
#stamp--时间戳,两个成员:秒和纳秒
builtin_interfaces/Time stamp
        int32 sec
        uint32 nanosec

# Transform frame with which this data is associated.
#
string frame_id

作用:

sensor/msg/JointState

# This is a message that holds data to describe the state of a set of torque controlled joints.
#
# The state of each joint (revolute or prismatic) is defined by:
#  * the position of the joint (rad or m),
#  * the velocity of the joint (rad/s or m/s) and
#  * the effort that is applied in the joint (Nm or N).
#
# Each joint is uniquely identified by its name
# The header specifies the time at which the joint states were recorded. All the joint states
# in one message have to be recorded at the same time.
#
# This message consists of a multiple arrays, one for each part of the joint state.
# The goal is to make each of the fields optional. When e.g. your joints have no
# effort associated with them, you can leave the effort array empty.
#
# All arrays in this message should have the same size, or be empty.
# This is the only way to uniquely associate the joint name with the correct
# states.

std_msgs/Header header
        builtin_interfaces/Time stamp
                int32 sec
                uint32 nanosec
        string frame_id

string[] name
float64[] position
float64[] velocity
float64[] effort

- `string[] name`:机器人关节的名称,为一个字符串数组;

- `float64[] position`:机器人关节的位置,为一个双精度浮点数数组;

- `float64[] velocity`:机器人关节的速度,为一个双精度浮点数数组;

- `float64[] effort`:机器人关节的力/扭矩,为一个双精度浮点数数组。


网站公告

今日签到

点亮在社区的每一天
去签到