Welcome to Will's Robotic Adventures. This site details many of my robot projects and hopefully you will find them useful and informative for making your own ideas come to life. If Mini Sumo is your thing, check out BiBimBot. If you're interested in Line Following or Beacon Sensors take a look at Bot-Choy. Or if you're just interested in a super LED light show, check out the Aquarium Light project.
Surfing Thingiverse one day I came across a unique planetary gearbox design that could achieve high gear ratios in a relatively compact arrangement. The original design was done in a 3D modeling program called OpenSCAD. I started playing with the gearbox design and wondering if this could be combined with a small brushless DC motor for use on a robot. After refining the design a bit I came up with an arrangement that just might work.
The housing, wheel hub and the two ring gears would all need to be 3D printed while the ball bearings and the sun and planet gears were parts I found on eBay. I had the parts printed at Shapeways and the gearbox works pretty well in my initial testing. The two internal ring gears were printed from High Definition Acrylate while the other parts were made of Strong and Flexible Nylon.
The parts used for this build are:
I decided to look into OLED screens as an improvement to the poor visibility of the Nokia 5110 LCD. Adafruit has a nice selection but most of their larger monochrome OLEDs had been out of stock for over a month. I found a 128x64 pixel 2.42" diagonal screen on eBay which was half the price and claimed compatibility with the same SSD1306 driver that the Adafruit Library supports. Not knowing when Adafruit would have them back in stock, I took a chance on the eBay equivalent and was pleasantly surprised!
The screen looks great and the carrier board is smaller than the Adafruit version. I loaded the Adafruit GFX and SSD1306 libraries and ran the test sketch on an Arduino Uno. The screen lit up on the first try using hardware SPI. I intend to put this screen on a robot, so it is important that the screen can be updated quickly. Looking at the example code in the Adafruit library, there is a display.display() function call which sends out the screen buffer over SPI. Without any tweaking to the library or example code, it took ~2.95 milli-seconds to update the full display which is about as fast as an Arduino can run. Kudos to Adafruit for a library well done, I just wish they had the screens in stock so I could have supported their efforts!
Every time I think about making upgrades to Bot-Choy, the death spiral begins. First its just a new and lighter chassis made from ABS instead of aluminum, then a few minor tweaks to the code, add a small screen with a menu system, add some Sharp IR sensors, upgrade the VNH5019 motor driver to something that can do locked anti-phase..., pretty soon it starts to sound like a whole new robot! I've decided to not do anything drastic to Bot-Choy and save my energy for the next Polyathlon entry. I'd hate for next November to roll around and be half-way done with some heavy upgrades and end up with nothing to compete.
I'd like the new robot to have a screen and some input buttons. That would let me tweak control settings without having to recompile and upload new code so often while testing. I want a graphical screen instead of a character screen so that while the bot is running, I can have it display a map of what it sees which will help tremendously with debugging. The cheapest graphical screen I could find was the 84x48 pixel monochrome LCD used on the old Nokia phones - they are available on eBay for around $5 including shipping. At first I thought the screen I received was broken, but after playing with the contrast and bias settings the picture became visible. This type of screen is generally recommend to be used with a 4MHz SPI clock, but I hooked it up to an Arduino Mega and found it still worked at 8MHz. After tweaking some of the settings in a library I found, I was able to update the whole screen, writing 4032 bytes in just over 1.2 milliseconds. Adafruit has some nice monochrome OLED screens with 128x64 pixels that are much more expensive but are much more visible. That's roughly twice the number of pixels as the Nokia 84x48 screens so probably 2.5 milliseconds to update which is still doable.
Next question - Could I instead have a remote control unit with a screen and stream the whole screen to the remote control over a wireless connection?
I had an idea to make a traction control system for a Mini Sumo robot. When pushing a competitor, if the tires start spinning, there will be a transition from static friction to kinetic friction, which is almost always lower. In order to maintain maximum traction and maximum pushing force, I could compare the speed of both tires on the same side of the robot, and if one starts spinning faster than the other, the voltage to the faster tire could be decreased until both tires were running at the same speed.
In the photo above, I was experimenting with measuring motor speed using back EMF. In between PWM pulses, the motor acts like a generator, and the voltage generated on the motor terminals is proportional to the rotational speed of the motor. I used a differential op-amp circuit with a gain of 1/10 to measure the voltage. Each input to the differential amplifier was connected to one of the motor terminals, and the reference voltage was set to approximately 2.5 volts with a resistor divider. The output of the op-amp was routed to an analog pin on the Arduino Nano, as was the reference voltage. By measuring the op-amp output voltage and the reference voltage and subtracting the two, I could know the direction of the motor as well as the speed. The parts used were: Arduino Nano, DRV8833 Dual H-Bridge driver from Pololu, LF351 op-amp, and a 75:1 micro metal gear motor from Pololu.
For my next experiment I plan to duplicate this circuit, measuring the speed of two motors independently. Then I could change the speed of the second motor based upon the measured speed of the first motor. In theory, if I grab the shaft of the first motor to slow it down, the micro-controller should sense this and slow the speed of the second motor in response.