Category Archives: Robotics

Build season is over!

I spent the past six weeks in the chaotic design and development of the Tail of the Monkey, Team 846′s entry in this year’s FIRST competition. While we haven’t had a chance to test quite all the functionality we want to have, the robot is bagged and prepared for shipping–hopefully we’ll be able to finish things up at the New York Regional this March.

In the meanwhile, a picture:

Read More Leave a Comment

February 23, 2012

Categories:

Robotics

Moved to GitHub

Due to various reasons, not the least of which was a desire to make my code easier to access for those who want to see it, I’ve decided to move my ROS repository from my own server to GitHub.

It can be viewed here: https://github.com/rbtying/Companion-Cube

Read More Leave a Comment

December 1, 2011

Categories:

Robotics

Simple Arduino Robot Control

One of the simplest bits of functionality that is useful for small-scale robotics is the ability to control robots over the serial port, which can easily be made wireless using Pololu Wixels, XBee, bluetooth, or any other wireless serial connection. Since the Arduino Serial Monitor only sends out messages rather slowly, and it’s usually nice to have a fast response from computer to robot, I wrote a short Java application that handles the communication for you.

Download here:

Robot Controller
Source code is released into the public domain, but if you use it, I’d appreciate it if you cite me somewhere (Robert Ying).

You’ll also need to have the appropriate rxtx native library in the same folder as the jar file when running it—you can download that here

Corresponding Arduino Code:

void setup() {
  Serial.begin(115200);
}

// method that sets motor speeds from -255 to 255
// corresponding to full reverse and full forward
void setLeftMotor(int speed);
void setRightMotor(int speed);

byte nextByte() {
  unsigned long start = millis();
  while (millis() - start < 100) {
    if (Serial.available()) {
      return Serial.read();
    }
  }
  return 0x00;
]

void loop() {
  while (Serial.available()) {
    switch(Serial.read()) {
      case 0xC1: setLeftMotor(2 * nextByte()); break;
      case 0xC2: setLeftMotor(-2 * nextByte()); break;
      case 0xC5: setRightMotor(2 * nextByte()); break;
      case 0xC6: setRightMotor(-2 * nextByte()); break;
      default: setLeftMotor(0); setRightMotor(0); break;
    }
  }
}
Read More Leave a Comment

November 30, 2011

Categories:

Robotics, software

A sneak peek…

A sneak peek at upcoming developments:

Read More Leave a Comment

November 19, 2011

Categories:

Robotics

Update: Wheels!

The Companion Cube—with new wheels!

I finished up the wheel replacement today with a pair of Vex Omniwheels, which have little rollers on them to allow movement perpendicular to the way they’re mounted, thus resolving the previous shearing force problems.

An Omniwheel

Unfortunately, since my motor shafts are 6mm single-flat and the Vex wheels are designed for 0.125″ square, I had to drill the wheels out a bit to make it work. Lacking a drill press, I made do with a slightly smaller drill bit, a hand drill, and a rotary tool, adding in a few screws to adjust the fit and to lock the wheel against the single flat. Although there were some mistakes, I think it turned out rather well:

Closeup of the left side of the robot

Closeup of the right side of the robot

The larger wheels get over bumps more easily, and they make it faster, both to turn and to drive—the omniwheels are especially helpful while turning, as they allow me to treat the system as a two-wheel system at the back instead of a four-wheel system like it actually is.

Read More Leave a Comment

September 30, 2011

Categories:

Robotics