Trying to publish to joint with python script
Here is my script
#!/usr/bin/env python3
import rospy
from std_msgs.msg import String
import rospy
from std_msgs.msg import Float64
def talker():
pub = rospy.Publisher('/rx150/wrist_rotate_controller/command', Float64, queue_size=10)
rospy.init_node('rx150_talker', anonymous=True)
rate = rospy.Rate(10)
while not rospy.is_shutdown():
position = -1.0
rospy.loginfo(position)
pub.publish(position)
rate.sleep()
if __name__ == '__main__':
try:
talker()
except rospy.ROSInterruptException:
pass
When executing this script the gazebo simulated robot doesn't respond to the joint command I give.
The simulated robot however does respond to this command when I type it in the terminal:
rostopic pub -1 /rx150/wrist_angle_controller/command std_msgs/Float64 "data: -1.0"