Difficulties in visual tracking in Ros-by-example book
Hi Rossers
I am stack over the flow, I need help plz, I don't know where I am mistaken.
I have Phantomx pincher robotic arm (with 5 dynamixel 12ax servos) connected with arbotix-m board, I am using ros indigo.
I am following this ros-by-example tutorial and this repo. In order to control the first servo (id = 1) based on the motion of coloured object that should be detected by webcam. I want the servo's id 1 rotate when the object is not in the centre of x-axis. For now, I want to get one servo rotating first, then I will consider y-axis for another servo.
The tutorial explains how to control the motion of the pan and tilt head servos. I am trying to consider the pan servo with my first servo.
I did the following :-
1- To get the video stream and detect the object based on colour and send the topic /roi
which contains object's position.
roslaunch rbx1_vision usb_cam.launch
roslaunch rbx1_vision camshift.launch
2- To fire up the arbotix-m,
roslaunch rbx1_dynamixels arbotix.launch
I can also see the arm in rviz, and I can move the servo (id 1) individually rostopic pub -1 /head_pan_joint/command std_msgs/Float64 -- 1.0
, it moves in rviz as well, it means there's real connection with the actual arm.
3- To launch the head tracking node (which should be my first servo tracking node, since I consider the pan_head_joint
is my servo id 1). This video shows the demo for the tutorial work.
roslaunch rbx1_dynamixels head_tracker.launch
I got this out put
[INFO] [WallTime: 1508448519.996313] Waiting for joint controllers services...
When I run rostopic info /head_pan_joint/command
I can see head_pan_joint
is already ok.
imr@IMR-PC:~$ rostopic info /head_pan_joint/command
Type: std_msgs/Float64
Publishers:
* /head_tracker (http://localhost:38610/)
Subscribers:
* /arbotix (http://localhost:41637/)
And my first servo is not moving, I do not know where I am mistaken, what to check with the third step as I mentioned above, I guess there's some thing wrong there. Please tell me !!