Klein Bot

Kleins, robots, electricity

Blog

Octowobble Returns

Posted by Klein on July 6, 2011 at 9:21 PM Comments comments (0)

We're back! Octowobble is getting ready for the 2011 Atlanta Robot Rally. Stay tuned on this channel for further updates.

Techno Vest

Posted by Klein on February 13, 2011 at 12:46 AM Comments comments (1)

I am going to a Techno contra dance in a week or so, and I've been working on something suitably techno for that event.The concept is a music driven flashing vest. I had hopes of synching the flashing display with the music beat, but that's proven hard to implement on the Arduino, so I've scaled back a bit.


There's not much to show for the code exploration and breadboarding, but I've put up some pics of layout options in the Lilypad Vest album.


BTW, if you're interested in following the technical bits on beat detection, I started a thread on AVRFreaks.



Countdown: 57 hours

Posted by Klein on October 20, 2010 at 8:52 PM Comments comments (0)

Octowobble was nowhere near ready for his coming out at the local robot club last night, so he's being schooled on the workbench tonight. It may be a late one -- he's been very bad.


I did get some good tips on things to try.The best route was to switch from "simple anti-phase PWM" to sign and direction control.


With anti-phase PWM, you peg the PWM ("speed") pin high, and alternate the direction pin quickly. If it's forward half the time and back the other, the net power to the motor is zero. As the PWM balance shifts, so does the average power and the motor turns. The theory is that the ~500 Hz PWM from the Arduino is insufficient to properly drive the input pin.


I've switched a driver to sign and direction. This is an easy change, just un-tied the PWM from V+ and brought it out to an Arduino pin. I'm tweaking the software and testing is about to begin.


Update:

Did you know that if you comment out code, it doesn't run? For instance, if the code that actually writes to the motor driver pins is commented out and replaced with Serial.print commands, then the motors never actually turn, and there might actually be nothing wrong with the driver.


Further Update:

It works! I'm now switching to work on the beacon detector. I can't rely on their beacon since I've never had a chance to test against it, so I'm cobbling together one of my own.

Line sensor success

Posted by Klein on October 11, 2010 at 9:53 AM Comments comments (0)

Thanks to Ben at Pololu for posting line sensor code for their QTR that's compatible with the Arduino. I was starting to get a bit panicky.


Ben's post is here

http://forum.pololu.com/viewtopic.php?f=6&t=1546&p=14515#p14380


And here's theupdated library

http://www.pololu.com/docs/0J19


I verified this with my Seeeduino (v1.1 "8/23/2008"). I edited the header for 6 pins on port D, and no emitter control. (Pins 0 and 1 are used for Serial communication, so I'm leaving them out.)


NUM_SENSORS   6     // number of sensors used

#define EMITTER_PIN   QTR_NO_EMITTER_PIN

 

PololuQTRSensorsRC qtrrc((unsigned char[]) {2, 3, 4, 5, 6, 7}, NUM_SENSORS, TIMEOUT, EMITTER_PIN);


QTR Line Sensor - not working

Posted by Klein on October 2, 2010 at 10:21 PM Comments comments (0)

No luck getting the line sensor going. I'm asking for help from The Internet. I'm posting pictures of my setup and my code here, and posting my questions out there.


/

The setup:

Seeeduino pins 0 to 7 to QTR pins 1 to 8, respectively.

QTR enable pin unconnected.


Pictures in the photo gallery

connections to Seeduino

connections to QTR

IR LEDs are on


I verified 4.92v at Vcc on the QTR.

I verified continuity on each sensor connection


/

The code:


#include <PololuQTRSensors.h>

PololuQTRSensorsRC qtr((unsigned char[]) {0, 1, 2, 3, 4, 5, 6, 7},  8 );

void setup()
{ int i;
  for (i = 0; i < 250; i++) // make the calibration take about 5 seconds
  { qtr.calibrate();
    delay(20);
  }
}

void loop()
{ unsigned int sensors[8]; // an array to hold sensor values

  qtr.read(sensors);
  Serial.print(sensors[0]);
  Serial.print("\t");
  Serial.print(sensors[1]);
  Serial.print("\t");
  Serial.print(sensors[2]);
  Serial.print("\t");
  Serial.print(sensors[3]);
  Serial.print("\t");
  Serial.print(sensors[4]);
  Serial.print("\t");
  Serial.print(sensors[5]);
  Serial.print("\t");
  Serial.print(sensors[6]);
  Serial.print("\t");
  Serial.print(sensors[7]);
  Serial.println();
}

Results:

After 5 seconds of (presumed) calibration, the code returns only "4000"s. I'm presuming that these are timeouts. A different version of the program using readLine returned only 0 for line position.


Update:

I got a prompt update from (Site Admin) Ben at the Pololu forum. No direct fix, but confirmation that it's not me. There's also some example code (with lots of room for improvement) at the primary forum thread.

QTR Setup

Posted by Klein on October 1, 2010 at 8:01 AM Comments comments (0)

I made a few cables and soldered some pins to the Pololu QTR line sensor ( www.pololu.com/catalog/product/961 ) last night, and moved upstairs to sit in the easy chair and try to get the the Seeeduino to talk to the QTR. Initial results are negative, but I was happy just to get things connected, and to get a skeleton program with the QTR library running.



Plan B continued

Posted by Klein on September 28, 2010 at 11:14 AM Comments comments (0)

Based on some good feedback from Dale Heatherington in Atlanta, I ordered the 18200 H bridge drivers yesterday afternoon -- two for the bot, two for backups, and one to burn up during testing.


Wouldn't you know, though, I went digging around in the scrap circuit board piles last night and found a little stash of old RC car boards, including motor drivers, and specifically another Fast Traxx board. Apparently, I've been down this track before; this board was stripped down to just the minimum bridge components already. I think I'll still go with the 18200's, since they give me one pin control per motor, and I'd really like to free up some pins on the Arduino.


In the meantime, I might try to wire up an old bridge, just to get Octowobble moving.

Entry to Robot Rally

Posted by Klein on September 3, 2010 at 12:56 PM Comments comments (0)

Robot Rally Registration

Form Name: Robot Rally Registration

Date of Submission: Fri, 03 Sep 2010 10:58:25 -0600

Your server: www.botlanta.org

IP address of person using form: 216.79.95.56

URL of page containing form: http://www.botlanta.org/home/robot-rally/registration

FormBuilder version: 0.5.3

Name : Tim and Ben Klein

Mailing Address:

Phone :

Email :

URL : http://kleinbot.webs.com/

Site Name : Klein Bot

Robot's Name : Octowobble

Contest: Polyathlon

Processor Type : AVR (Arduino)

Navigation: IR Bumpers,Beacon,Other

Other Nav Systems: reflectance line sensor, wheel motor encoders, IR range finder

Robot Info: Tim and Ben are father and son, who have a lot of interest in robots, but not much experience actually building them. We have brought robots to the Robot Rally in the past (pictures at http://www.ayershome.org/~eric/robots/bugbrain/ ), but this will be the first year that we're submitting a robot to the contest. Octowobble will be our second working robot.Octowobble, is named because of an early design decision to have an octagonal body shape. The 'wobble' part was added because it sounds good. The robot will be made primarily from salvaged materials -- Roomba wheels, a FastTraxx H-bridge, a surplus aluminum sign, and parts salvaged from our first working robot -- an Arduino, and a Sharp IR range finder.