ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You have:

vel = JointVelocity
vel.velocity = [Float32(0.1),Float32(0.2),Float32(0.1),Float32(0.1),Float32(0.1),Float32(0.1),Float32(0.1)]

Where you try to feet the velocity values in the JointVelocity class itself. What you want is to create an object first (Note the braces):

vel = JointVelocity()
vel.velocity = [...]

Also you usually don't need to cast to Float32, so you can simply write

vel.velocity = [0.1, 0.2, 0.1, 0.1, 0.1, 0.1, 0.1]

You have:

vel = JointVelocity
vel.velocity = [Float32(0.1),Float32(0.2),Float32(0.1),Float32(0.1),Float32(0.1),Float32(0.1),Float32(0.1)]

Where you try to feet the velocity values in the JointVelocity class itself. What you want is to create an object instance first (Note the braces):

vel = JointVelocity()
vel.velocity = [...]

Also you usually don't need to cast to Float32, so you can simply write

vel.velocity = [0.1, 0.2, 0.1, 0.1, 0.1, 0.1, 0.1]