Ardbot

Still a work in progress. I'm just testing out the various subsystems (wireless, camera pan & tilt, tracks, IR distance sensor). I've attached some pictures of the pd patches i'm using to test things out - hopefully someone will find them helpful. It took awhile to figure out how to read data across the bluetooth serial port using pd but it works well.

I started with the Robotshop rover development platform kit from robotshop.com. I added the Bluetooth Bluesmirf Silver modem from sparkfun.com for the wireless goodness, and the wireless micro cam from boostervision.com.

Here are a couple more pictures - sorry about the image quality, it ain't that great:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

The cool thing about programming with pd is that it's totally visual, so with a little practice you can program without all of that tedious typing. Here's a test of the game controller - really just testing to see that pd can acquire the controller and print out the controller's capabilities to the pd console:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

this pd patch reads data from the Sharp IR sensor on the robot via the Bluetooth/Serial port link:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

There's a simple program running on the robot's Arduino controller that is polling for data from the sensor and transmitting out via the bluetooth modem.

 

At some point, I'll wire everything together and post to my blog.

 

PC interface, wireless navigation/control, live video!!

  • Actuators / output devices: 2 Hitec HS-422 Servo Motors for camera pan/tilt, 2 Solarbotics GM9 - Gear Motor 9 for tracks
  • Control method: Bluetooth, PC, Philips PC game controller
  • CPU: Arduino Duemilanove
  • Operating system: windows XP
  • Power source: 4 AA batteries, 2 9v
  • Programming language: Java, Arduino, PD (pure data)
  • Sensors / input devices: Sharp GP2D12 IR Range Sensor, 2.4 Ghz Wireless Micro Camera
  • Target environment: indoor

This is a companion discussion topic for the original entry at https://community.robotshop.com/robots/show/ardbot

Looks good so far. I would

Looks good so far. I would like to see more of it. I have the same wireless camera and want to make a pan tilt head for my YAABR robot with it. Maybe this will interfere with the bluetooth interface, because both are running at 2.4GHz. Have you tested this?

Using Pure Data to control the robot is also very interesting for me. Keep us up to date.

 

bluetooth & wireless camera

Hi - thanks for the comments. I’ve done a little testing with the video camera and sending commands to the robot via bluetooth and it seems to work…I didn’t see any interference on the video image and the commands to the camera servos were received. The documents on the Sparkfun website say that the bluetooth radio they use has Adaptive Frequency Hopping built-in…I’ve read a little on AFH and it seems to be designed for this kind of application, that is, multiple radios operating in the 2.4ghz band. This article seems to explain it pretty well

 

http://www.design-reuse.com/articles/5715/adaptive-frequency-hopping-for-reduced-interference-between-bluetooth-and-wireless-lan.html

Hello mate

Great bot, i have the same camera im planning to use on a project, i have two questions though:

1) What sort of range are you getting with the camera

2) what are you doing with the video sigal on the other end??

Im getting about 50 meters with my camera, thats line of sight. Throgh the walls of my house it goes down to 20 but ti think my walls have lead or something in because mobile phones die here.

camera range

Hi - it looks like my results are similar to yours. I put ardbot outside the house, receiver inside the house - at about 25-30m i was still getting a grainy image on the monitor.

I’m capturing the video signal on my laptop using a PD/GEM patch. At some point, I want to have a “dashboard” that is receiving the camera output and other telemetry from the robot…just for fun.

 

Thanks!

Hi

Thanks for the reply!

 

WHats a PD/GEM patch?

At the moment im using a video capture card but im having trouble getting that into java.

Pd - Gem and video capturing

Hi - Pd is Pure Data - its a graphical programming language used for electronic music and multimedia stuff, and many contributors have added libraries that could be useful for robotics. I’m new to it but so far I’ve found that it can be used to interact with the Arduino on the ardbot and it can accept input from my usb gamepad and the video camera.

GEM (Graphics Environment for Multimedia) is a 2d/3d graphics and video add-on to Pd.

Everything I learned about Pd(and some of the code i’ve appropriated) came from here: http://en.flossmanuals.net/PureData/Introduction and http://puredata.info/

I’m using a Diamond Multimedia One-touch Video Capture VC500 (cheap on Amazon) as the video capture device.

Interesting that you are trying to use java - i’ll try to capture the video using java and i’ll post what i find.

Pd examples

 


I stole this Pd code from the tutorial at en.flossmanuals.net. I found that you have to click the dialog button and configure Pd to use the NTSC_M encoding as it defaults to PAL, which doesn’t match what the video camera is sending me:

 

video-cap.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

When I start Pd, with the video capture card inserted in the USB port, the console tells me its happy with what it found (it detects the video capture device automagically) by displaying "pix_videoDS: opened device 0":

pd-console.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

clicking the topmost box in Pd with the mouse gives me the video window below:

gem-win.png

 

 

 

 

 

 

 

 

 

 

 

 

 

Now, according to the docs, I should be able to overlay 2d graphics on top of the video (i'm thinking heads up display or something).

thanks!

Java and video capturing

I’m experimenting with the java library called dsj: http://www.humatic.de/htools/dsj.htm, download from http://www.humatic.de/htools/dsj/download.htm

I imported the dsj.jar file into a new project in eclipse, set up the native library, and ran the DSJDemo sample and it worked right out of the box. the code in DSJDemo is a little…involved…I’m sure you could extract just what you need from the samples provided.

screenshots:

dsj-1.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

dsj-2.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

success:

dsj-3.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

good luck!

Thats awesome
Im looking at all this now, thanks for your help!

I wil let you know how i get on.

interference confirmed

It seems there is interference between the wireless camera (2.4ghz) and the bluetooth modem - enough that if the camera is powered on the bluetooth link disconnects at any distance more than a few feet from the base station.

I’m going to replace the bluetooth modem with anXBee radio at 900mhz and i think that should resolve any remaining issues and without major Arduino code changes. Here are the radios I plan to use, as soon as they arrive from Sparkfun:

XBee-PRO 900

and the antenna

900/1800 MHz Duck Antenna

also, to make breadboarding and connecting to the PC a little simpler, I ordered this board from Adafruit:

XBee adapter kit

I’m sure thebluetooth modem will find a home in another project :slight_smile: