Using nao_leds to blink LEDs
I cant seem to blink the leds on Nao using nao_leds. Does anyone knows how do I do it? I dont seem to really get the action goal stuff. Thanks
add a comment
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
I cant seem to blink the leds on Nao using nao_leds. Does anyone knows how do I do it? I dont seem to really get the action goal stuff. Thanks
This is what I worked out, but something is still missing.
import roslib; roslib.load_manifest('beginner_tutorials_naotalk')
import rospy
# Brings in the SimpleActionClient
import actionlib
import std_msgs.msg
import nao_msgs.msg
from nao_msgs.msg import *
def blink_client():
rospy.init_node("blink_client")
client = actionlib.SimpleActionClient('blink', nao_msgs.msg.BlinkAction)
client.wait_for_server()
#goal = actionlib_tutorials.msg.FibonacciGoal(colors.r=1, blink_rat_mean=1.5 ,blink_rate_sd=1.7 )
#colors=[1,2,3,4], blink_rate_mean=1.5, blink_rate_sd=1.7
goal=nao_msgs.msg.BlinkGoal(colors=(1,2,3,4), blink_rate_mean=1.5, blink_rate_sd=1.7)
#BlinkGoal.colors=[1,1,1,1]
#BlinkGoal.blink_rate_mean=1.5
#BlinkGoal.blink_rate_sd=1.7
client.send_goal(goal)
client.wait_for_result()
return client.get_result()
if __name__ == '__main__':
try:
rospy.init_node('blink_client')
result = blink_client()
print "Result:", ', '.join([str(n) for n in result.sequence])
except rospy.ROSInterruptException:
print "program interrupted before completion"
Below is the error message
AttributeError: 'int' object has no attribute 'r'
Asked: 2014-02-24 22:06:44 -0600
Seen: 254 times
Last updated: Feb 24 '14
nao_robot, how to easily make now execute something
Adding NaoQI API to PYTHONPATH (v1.12)
nao_driver and joint_states with NaoQI 1.12
Error when installing ROS for Nao robot
Package nao_remote depends on non-existent package move_base_msgs
Moving Nao Robot - enable and disable stiffness
Can't get image from nao_camera