ros_arduino_bridge on new PI robot

55 views
Skip to first unread message

KM6VV

unread,
Feb 25, 2013, 6:12:15 PM2/25/13
to hbrob...@googlegroups.com
Hi Patrick,

I was looking a your "Head Tracking using OpenCV" blog, and I remembered
that you said something like the ros_arduino_bridge package is being
used on the new PI Robot. Did I get that right?

I had just installed the pi_head_tracking_tutorial (electric) on my
(diamonback, oops?). And thought I'd look for a closer match to using
your new package. By the way, the tutorial looks like a full package.

Am I crazy to start by wanting to connect cmvision blob detection up
with your ros_arduino_bridge? I will have to modify for my RoboClaw
motor controller.

Thoughts?

Thanks in advance!

Alan KM6VV

Patrick Goebel

unread,
Feb 26, 2013, 9:38:48 AM2/26/13
to hbrob...@googlegroups.com
Hi Alan,

The head tracking on Pi Robot uses Dynamixel servos and a USB2Dynamixel
controller. It does not use the Arduino or ros_arduino_bridge at all.
The Arduino is used only as a base controller and for reading a number
of Ping and IR sensors for obstacle detection.

To use cmvision and ros_arduino_bridge to make your robot track a
colored object, you would write a node that subscribes to the
/cmvision/Blobs topic, gets the coordinates of the object (blob) you
want to track, then publishes messages on the /cmd_vel topic that are
consumed by the ros_arduino_python node to move the robot. You can read
more about how to do this (though not with cmvsion) in Chapter 11 of my
book.

--patrick

KM6VV

unread,
Feb 26, 2013, 12:06:41 PM2/26/13
to hbrob...@googlegroups.com
Hi Patrick,

OK, I thought maybe your new PI Robot used the new ros_arduino_bridge
node.

I have (for now) tilt/pan servos for the cmvision camera, which will use
standard R/C servos that I can control with the Arduino.

I think I get it on subscribing to blob, and generating tilt/pan for the
R/C servos, and then cmd_vel messages to translate into my Roboclaw
commands. I've started to read chapter 11. Too bad there's not more
about cmvision available!

At what point (if I understand correctly) do you take the camera
pointing error and send it to the platform? (If that's what you do).
Seems one would want the camera to track the target first, and then the
heading of the platform would be corrected to follow the camera's lead.
Close?

Alan KM6VV

Patrick Goebel

unread,
Feb 27, 2013, 10:11:52 AM2/27/13
to hbrob...@googlegroups.com
On 02/26/2013 09:06 AM, KM6VV wrote:
Hi Patrick,

OK, I thought maybe your new PI Robot used the new ros_arduino_bridge node.

Hi Alan,

Pi Robot *does* use the ros_arduino_bridge stack but, as I said, only for base control and reading sonar and IR sensors for obstacle avoidance.  I use a separate USB2Dynamixel controller on another USB port to control the Dynamixel pan & tilt head servos.  And from the ROS end, I use the dynamixel_motor stack to control the servos (as detailed in my book).


I have (for now) tilt/pan servos for the cmvision camera, which will use standard R/C servos that I can control with the Arduino.

Yes, you could certainly use the ros_arduino_python node to control a pair of R/C servos for pan/tilt control of the camera.  (NOTE: servo positions are specified in radians.)


At what point (if I understand correctly) do you take the camera pointing error and send it to the platform? (If that's what you do). Seems one would want the camera to track the target first, and then the heading of the platform would be corrected to follow the camera's lead.  Close?

Others can chime in here about their favorite tracking methods.  If your camera were fixed, you would simply turn the robot left/right depending on the offset of the blob from camera center.  I use "speed tracking" where you adjust the ratio of left/right wheel speeds depending on the offset of the target from the center of the FOV.   I tend to run the update loop around 5-10 Hz.

If your camera is *not* fixed (as in your case), then you could run two tracking nodes, one that manages the camera and tries to center it on the blob, and one that manages the drive motors of the robot.  The drive motor tracking would need to take into account the current pan angle of the camera when computing target offset.  Otherwise, the two nodes can run independently of one another.

--patrick

Brian Higgins

unread,
Feb 27, 2013, 11:18:04 AM2/27/13
to hbrob...@googlegroups.com

Did the notice for tonight’s meeting go out yet?

 

Brian

--
You received this message because you are subscribed to the Google Groups "HomeBrew Robotics Club" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hbrobotics+...@googlegroups.com.
To post to this group, send email to hbrob...@googlegroups.com.
Visit this group at http://groups.google.com/group/hbrobotics?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Chuck Untulis

unread,
Feb 27, 2013, 12:02:59 PM2/27/13
to hbrob...@googlegroups.com

Hi Brian,

 

Where is the meeting tonight being held?

 

Thanks

Brian Higgins

unread,
Feb 27, 2013, 12:46:23 PM2/27/13
to hbrob...@googlegroups.com

Chuck

I thought the robotic club met the last Wednesday of the month.  Maybe I am out of touch of when and where the meetings being held

 

Brian

KM6VV

unread,
Feb 27, 2013, 1:14:51 PM2/27/13
to hbrob...@googlegroups.com
Hi Patrick,

Thanks for the clarification!

I took a look at blob.h and blobs.h last night. Whew! I know I need to
include this header file in order to define the structure of the blob
topic coming from my camera. How can I find node that can subscribe to
this topic as an example? I've browsed the ROS software, but haven't
found a sample yet.

Thanks!

Alan KM6VV

On 2/27/2013 7:11 AM, Patrick Goebel wrote:
> On 02/26/2013 09:06 AM, KM6VV wrote:
>> Hi Patrick,
>>
>> OK, I thought maybe your new PI Robot used the new ros_arduino_bridge
>> node.
>
> Hi Alan,
>
> Pi Robot *does* use the ros_arduino_bridge stack but, as I said, only
> for base control and reading sonar and IR sensors for obstacle
> avoidance. I use a separate USB2Dynamixel controller on another USB
> port to control the Dynamixel pan & tilt head servos. And from the ROS
> end, I use the dynamixel_motor <http://www.ros.org/wiki/dynamixel_motor>
> stack to control the servos (as detailed in my book).
>
>

Chuck Untulis

unread,
Feb 27, 2013, 7:24:39 PM2/27/13
to hbrob...@googlegroups.com

Hi Brian,

 

The meeting is tonight at 7:00 PM. I had lunch 1225 Charlestonwith Wayne and Osman.

 

Chuck

Reply all
Reply to author
Forward
0 new messages