P8 and P9: Confusion and Progress

Spent a little bit of time writing python code to talk to the RoboClaw. After I got the MUX mode set correct for UART1, I could not figure out why a loop-back test was not working. If in doubt, read the reference document. It turns out I had was using the right pins on the wrong expansion header. Resoldered the serial lines for UART1 and UART2 back to P9…and it works. Personally, I think it’s even simpler to write serial byte commands in Python than using the Arduino. It should only take a few hours to come up with a simple state machine that can use the five front-facing distance sensors to do obstacle detection.

Otherwise, been a busy day buying The Boy a new bike, acquiring construction tools at the Home Despot for a project this May, and cleaning the bbq.

LS20031 and the BeagleBone

After several hours of trouble shooting, I finally got the BeagleBone and a LS20031 gps to talk.

I hooked the LS20031 to UART5 of the BeagleBone. The LS20031 has 3.3V TTL serial, so a level converter was not required. UART5 looks to be the toughest of the serial ports to use. The trick to getting UART5 RX and TX pins (37 and 38) to work, is to set them to MUX mode 4. Most of the other serial ports work in mode 0.

A second problem is the LS20031 is really picky about startup. If you have the RX or TX pins connected and power cycle, the unit does not always come back online. This is indicated by the red LED being constantly on. The only way I have found to make it power on correctly is to reset the BeagleBone. Note: I am using the 3.3V power supply from the ‘Bone.

HC-SR04 wiring harness

Tonight I started creating the four-wire harnesses for GND, VCC, TRIG, and ECHO for the $4 ultrasonic sensors. I created fie sets for each of the front-facing sensors. This will be the first test of using the Mega to gather data, then send to the BeagleBone. I verified with the maker’s of RoboClaw, that it uses 3V TTL serial. This means no level converter will be necessary to interface it with the BeagleBone.

Found an interesting open source website for SLAM: OpenSLAM. It will take some time to dig through the project and see if anything is usable.

New adventures: model #7

I’ve started a new, more ambitious robotics project. This robot is targeted for outdoor use in semi-controlled settings, but with much larger range. I’ve been conceptualizing this for about six months now.

The goal is to build a platform that:

  • can be used outside on pavement
  • provides a wide array of sensors to navigate complex environments
  • has enough computation power to play with OpenCV
  • can be internet connected for rapid development (aka BeagleBone, wifi, and Python)

Using this platform I would like to play with:

  • Outdoor navigation and obstacle avoidance
  • OpenCV
  • GPS and pre-planning algorithms
  • “mission control” software
  • infrastructure management

In the near term it will be built upon:

  • Arduino Mega
  • BeagleBone
  • RoboClaw for motor control
  • Pololu 37D motors with encoders
  • LS20031 GPS
  • CH robotics UM6 IMU
  • Adafruit TTL Camera
  • HC-SR04 Ultrasound sensors
  • IOGear GWU627 for wifi

In the longer term:

  • XBee Pro for long-range “missions”
  • Solar panel charging
  • “measurementation” sensor packages

DSC01761

DSC01760

Mounted sensors

Added an ambient light sensor to the 2WD robot and six (6!) Sharp fixed distance IR sensors to the 4WD robot.

Lynxmotion pan-tilt head

Tonight’s project was to assembled the Lynx motion pan-tilt head. This is much more robust feeling than the dagu (mini servo version). I cut some acrylic to mount a Sharp IR detector and a pololu 3DOF
compass.

Quality time with the Byvac BV4213

I found BV4213 on ebay back in early January. The 4WD dfrobot chasis has four discrete motors. All the commonly available Arduino motor shields only support two channels. The BV4213 is a solution to this. Each board is about 2.5cm square; it provides full PWM and directional motor control to two motors per board. You communicate with it using I2C. Using two of these boards, I have discrete control over all four motors and free up four pins on the primary Arudino (now a Mega…so it does not matter that much.)

A few days ago I finally got the test command on the BV4213 to return a test signal. It’s alive! Today I started writing direction and PWM commands to it. I have not yet figured out the behavior of PWM when you change its value. It seems to lag a bit. I’ll post some code when I get it cleaned up.

2WD dfrobot

Build log: tonight I soldered in 10nf disc caps on every motor: four in the 4WD dfrobot and two in the 2WD version.

I also assembled a Sharp IR distance sensor on an EXI servo from HobbyPartz.com. The EXI is maybe 1mm too wide to fit in the 2WD dfrobot hole. I think this may be because of the powder coating.