Joint Plot isn't working


#1

Hello,

After starting a simulation of any experiment the Joint Plot is not working anymore. After starting the simulation there is still the message “Start the simulation to display the plot”.

I noticed when I call

rostopic echo /robot/joint_states
WARNING: no messages received and simulated time is active.
Is /clock being published?

Yes the /clock is published. And there is another topic named /joint_states which publishes name, position, velocity and efforts of each joint.

My rostopic list:

/clock
/gazebo/contact_point_data
/gazebo/link_states
/gazebo/model_states
/gazebo/parameter_descriptions
/gazebo/parameter_updates
/gazebo/set_link_state
/gazebo/set_model_state
/joint_accel
/joint_states
/robot/hollie_real_left_arm_0_joint/cmd_pos
/robot/hollie_real_left_arm_1_joint/cmd_pos
/robot/hollie_real_left_arm_2_joint/cmd_pos
/robot/hollie_real_left_arm_3_joint/cmd_pos
/robot/hollie_real_left_arm_4_joint/cmd_pos
/robot/hollie_real_left_arm_5_joint/cmd_pos
/robot/hollie_real_left_arm_6_joint/cmd_pos
/robot/hollie_real_left_hand_Finger_Spread/cmd_pos
/robot/hollie_real_left_hand_Index_Finger_Distal/cmd_pos
/robot/hollie_real_left_hand_Index_Finger_Proximal/cmd_pos
/robot/hollie_real_left_hand_Middle_Finger_Distal/cmd_pos
/robot/hollie_real_left_hand_Middle_Finger_Proximal/cmd_pos
/robot/hollie_real_left_hand_Pinky/cmd_pos
/robot/hollie_real_left_hand_Ring_Finger/cmd_pos
/robot/hollie_real_left_hand_Thumb_Flexion/cmd_pos
/robot/hollie_real_left_hand_Thumb_Helper/cmd_pos
/robot/hollie_real_left_hand_Thumb_Opposition/cmd_pos
/robot/hollie_real_left_hand_base_joint/cmd_pos
/robot/hollie_real_left_hand_f1/cmd_pos
/robot/hollie_real_left_hand_f2/cmd_pos
/robot/hollie_real_left_hand_f3/cmd_pos
/robot/hollie_real_left_hand_f4/cmd_pos
/robot/hollie_real_left_hand_f5/cmd_pos
/robot/hollie_real_left_hand_f6/cmd_pos
/robot/hollie_real_left_hand_f7/cmd_pos
/robot/hollie_real_left_hand_f8/cmd_pos
/robot/hollie_real_left_hand_index_spread/cmd_pos
/robot/hollie_real_left_hand_j12/cmd_pos
/robot/hollie_real_left_hand_j13/cmd_pos
/robot/hollie_real_left_hand_j14/cmd_pos
/robot/hollie_real_left_hand_j15/cmd_pos
/robot/hollie_real_left_hand_j16/cmd_pos
/robot/hollie_real_left_hand_j17/cmd_pos
/robot/hollie_real_left_hand_j3/cmd_pos
/robot/hollie_real_left_hand_j4/cmd_pos
/robot/hollie_real_left_hand_j5/cmd_pos
/robot/hollie_real_left_hand_middle_spread_dummy/cmd_pos
/robot/hollie_real_left_hand_ring_spread/cmd_pos
/robot/joint_states
/ros_cle_simulation/1/lifecycle
/ros_cle_simulation/cle_error
/ros_cle_simulation/logs
/ros_cle_simulation/status
/rosout
/rosout_agg

How can I fix this?

Best regards
Katharina


#2

Dear Katharina,

I had a quick look into the issues with the arm robot. It seems like, to generate the topic names arm robot has some specific plugin which is different from the rest of the robots of the platform. Joint plot is trying to read from //joint_states, but in case of arm robot it’s still being published in /joint_states. We’ve create an issue to fix the plugin https://hbpneurorobotics.atlassian.net/browse/NUIT-75. For the time being possibly you can bridge the /joint_states and /robot/joint_states using a transfer function by subscribing and publishing respectively.
Hope this helps.

cheers,
Hossain


#3

Hello Hossain,

Thank you for your answer and your solution.
I also tested the Joint Plot with the i cub robot and it doesn’t work. The /robot/joint_states topic do not echo anything, too.

rostopic echo /robot/joint_states
WARNING: no messages received and simulated time is active.

Is /clock being published?
rostopic echo /clock
clock:
secs: 160
nsecs: 613000000

I’ve found the needed states in the topic robot/joints of i cub and they are echo the right parameters.
A few days ago the Joint Plots where shown on both robots. So maybe there is something wrong just on my PC? May you have any idea what it could be?

here the rostopic list of i cub

/clock
/gazebo/contact_point_data
/gazebo/link_states
/gazebo/model_states
/gazebo/parameter_descriptions
/gazebo/parameter_updates
/gazebo/set_link_state
/gazebo/set_model_state
/robot/eye_tilt/pos
/robot/eye_tilt/vel
/robot/eye_vergence/pos
/robot/eye_vergence/vel
/robot/eye_version/pos
/robot/eye_version/vel
/robot/icub_model/left_eye_camera/camera_info
/robot/icub_model/left_eye_camera/image_raw
/robot/icub_model/left_eye_camera/image_raw/compressed
/robot/icub_model/left_eye_camera/image_raw/compressed/parameter_descriptions
/robot/icub_model/left_eye_camera/image_raw/compressed/parameter_updates
/robot/icub_model/left_eye_camera/image_raw/compressedDepth
/robot/icub_model/left_eye_camera/image_raw/compressedDepth/parameter_descriptions
/robot/icub_model/left_eye_camera/image_raw/compressedDepth/parameter_updates
/robot/icub_model/left_eye_camera/image_raw/theora
/robot/icub_model/left_eye_camera/image_raw/theora/parameter_descriptions
/robot/icub_model/left_eye_camera/image_raw/theora/parameter_updates
/robot/icub_model/left_eye_camera/parameter_descriptions
/robot/icub_model/left_eye_camera/parameter_updates
/robot/icub_model/right_eye_camera/camera_info
/robot/icub_model/right_eye_camera/image_raw
/robot/icub_model/right_eye_camera/image_raw/compressed
/robot/icub_model/right_eye_camera/image_raw/compressed/parameter_descriptions
/robot/icub_model/right_eye_camera/image_raw/compressed/parameter_updates
/robot/icub_model/right_eye_camera/image_raw/compressedDepth
/robot/icub_model/right_eye_camera/image_raw/compressedDepth/parameter_descriptions
/robot/icub_model/right_eye_camera/image_raw/compressedDepth/parameter_updates
/robot/icub_model/right_eye_camera/image_raw/theora
/robot/icub_model/right_eye_camera/image_raw/theora/parameter_descriptions
/robot/icub_model/right_eye_camera/image_raw/theora/parameter_updates
/robot/icub_model/right_eye_camera/parameter_descriptions
/robot/icub_model/right_eye_camera/parameter_updates
/robot/joint_states
/robot/joints
/robot/l_ankle_pitch/pos
/robot/l_ankle_pitch/vel
/robot/l_ankle_roll/pos
/robot/l_ankle_roll/vel
/robot/l_arm_ft_sensor/pos
/robot/l_arm_ft_sensor/vel
/robot/l_elbow/pos
/robot/l_elbow/vel
/robot/l_foot_ft_sensor/pos
/robot/l_foot_ft_sensor/vel
/robot/l_hip_pitch/pos
/robot/l_hip_pitch/vel
/robot/l_hip_roll/pos
/robot/l_hip_roll/vel
/robot/l_hip_yaw/pos
/robot/l_hip_yaw/vel
/robot/l_knee/pos
/robot/l_knee/vel
/robot/l_leg_ft_sensor/pos
/robot/l_leg_ft_sensor/vel
/robot/l_shoulder_pitch/pos
/robot/l_shoulder_pitch/vel
/robot/l_shoulder_roll/pos
/robot/l_shoulder_roll/vel
/robot/l_shoulder_yaw/pos
/robot/l_shoulder_yaw/vel
/robot/l_wrist_pitch/pos
/robot/l_wrist_pitch/vel
/robot/l_wrist_prosup/pos
/robot/l_wrist_prosup/vel
/robot/l_wrist_yaw/pos
/robot/l_wrist_yaw/vel
/robot/left_eye_pan/pos
/robot/left_eye_pan/vel
/robot/neck_pitch/pos
/robot/neck_pitch/vel
/robot/neck_roll/pos
/robot/neck_roll/vel
/robot/neck_yaw/pos
/robot/neck_yaw/vel
/robot/r_ankle_pitch/pos
/robot/r_ankle_pitch/vel
/robot/r_ankle_roll/pos
/robot/r_ankle_roll/vel
/robot/r_arm_ft_sensor/pos
/robot/r_arm_ft_sensor/vel
/robot/r_elbow/pos
/robot/r_elbow/vel
/robot/r_foot_ft_sensor/pos
/robot/r_foot_ft_sensor/vel
/robot/r_hip_pitch/pos
/robot/r_hip_pitch/vel
/robot/r_hip_roll/pos
/robot/r_hip_roll/vel
/robot/r_hip_yaw/pos
/robot/r_hip_yaw/vel
/robot/r_knee/pos
/robot/r_knee/vel
/robot/r_leg_ft_sensor/pos
/robot/r_leg_ft_sensor/vel
/robot/r_shoulder_pitch/pos
/robot/r_shoulder_pitch/vel
/robot/r_shoulder_roll/pos
/robot/r_shoulder_roll/vel
/robot/r_shoulder_yaw/pos
/robot/r_shoulder_yaw/vel
/robot/r_wrist_pitch/pos
/robot/r_wrist_pitch/vel
/robot/r_wrist_prosup/pos
/robot/r_wrist_prosup/vel
/robot/r_wrist_yaw/pos
/robot/r_wrist_yaw/vel
/robot/right_eye_pan/pos
/robot/right_eye_pan/vel
/robot/torso_pitch/pos
/robot/torso_pitch/vel
/robot/torso_roll/pos
/robot/torso_roll/vel
/robot/torso_yaw/pos
/robot/torso_yaw/vel
/ros_cle_simulation/1/lifecycle
/ros_cle_simulation/cle_error
/ros_cle_simulation/logs
/ros_cle_simulation/status
/rosout
/rosout_agg

best regards
Katharina


#4

Dear Katharina,

You’re right. It seems that in few of the template experiments the joint_state pass-through transfer function is not valid with the current Topic naming system. To be honest, due to the custom implementation of the plugins the joint topics are in bit of chaos. Please ensure that you have and are pulishing your joint information to //joint_states, because that is what the frontend is trying to find the data for the plot. You can do it by publishing the content of the original topic using a TF. For arm robot something like following should work:

from sensor_msgs.msg import JointState
@nrp.MapRobotSubscriber("joints", Topic("/joint_states", JointState))
@nrp.Neuron2Robot(Topic('/robot/joint_states', JointState))
def joint_states_passthrough(t, joints):
    return joints.value

for exp with icub (assuming “icub” is the robotId in the bibi and exc)

from sensor_msgs.msg import JointState
@nrp.MapRobotSubscriber("joints", Topic("/icub/joints", JointState))
@nrp.Neuron2Robot(Topic('/icub/joint_states', JointState))
def joint_states_passthrough(t, joints):
    return joints.value

Same goes for the any other robot. We hope to generalize these inconsistencies in the code asap.

Cheers,
Hossain


#5

Hello,

Thank you so much it works.

Best regards Katharina