Nov 112013

So frequent readers of my blog (Hi Mom!) will remember my sumo robot competition coming up. The competition came and went and this is what happened. Last post I commented that if I had it to redo my sumo board again I would choose another motor driver IC. I spoke too loudly and Murphy heard me. After one failed repair job and one failed protoboard bot I finally got something working using the Teensy 2 and the TB6612FNG.

Where did I mess up on the custom board?
I’m not entirely sure. I had a few board level problems and a few IC troubles. First is the board it’s self, when you look at the schematics be sure to note that on the L298 I have the motor voltage and logic voltage mixed up. I pulled the pins out and soldered wires connecting to the correct spots like so.

Whats odd is before I did this one motor only worked in reverse and one worked well. After this nothing worked. I measured the current draw from the IC when the motors should be moving and got nothing out of it at all. The deadline was moving closer and I still had to finish the program logic so I decided to just build one on protoboard. So now I have two nice $50 coasters and one “art”. At least until I fix it.

It was also my first go at a big board like this and ended up getting some components way too close to each other. 3D view might have helped in this case.

Plan: F

I named my robot Plan F because if this last ditch resort didn’t work, I’d get an F.  Here it is with the chips and with out.

The board is really just a mother board or signal card. I wanted to reuse the Teensy or the motor control IC later so I stuck them on some headers. 

I have no idea what the rating for the motors is I just used a 9volt and made my base from 1/8th inch aluminum with a plexiglass top plate to set the brains on.  I did fairly well with my little sumo. First place in the smart robot portion and third over all. I even went up against some of the heavy weight bots and did fairly well. I didn’t win simply because they have so much more weight than me.

Files and etc.

Schematics, and board layout can be found there. Posted as is, errors and all. Use at own risk.  You can also find the sourcecode on Github

robotbattle from Digitalundernet . on Vimeo.

Oct 192013

Sumo robots are pretty fun. Not to be confused with that robot show that was inexplicably on Comedy Central for some time. Sumo robots are small (generally) fully autonomous machines that have one simple goal. To push the opponent out of the arena. We also have a weight limit to deal with, for the small “Smart bots” like I’m building we have 1lb to play with while the larger ‘bots get a generous 4lbs. I’ve got a sumo competition coming up in 5  weeks time and wanted to start making my own. I could simply go the Arduino route and get a shield and be on my way, but I want to go a bit further. So I’ve made my own sumo board. Its essentially a AVR 328p (Brains for the arduino) in SMD form factor with an H-Bridge.

An H bridge is built with four switches (solid-state or mechanical). When the switches S1 and S4  are closed  a positive voltage will be applied across the motor. By opening S1 and S4 switches and closing S2 and S3 switches, this voltage is reversed, allowing reverse operation of the motor.

S1 S2 S3 S4 Result
1 0 0 1 Motor moves right
0 1 1 0 Motor moves left
0 0 0 0 Motor free runs
0 1 0 1 Motor brakes
1 0 1 0 Motor brakes
1 1 0 0 Shoot-through
0 0 1 1 Shoot-through
1 1 1 1 Shoot-through

Enter the SN754410, the most common and familiar H bridge IC. 1A per channel, internal ESD protection and thermal shut down. Its a really nice chip and super easy since most of the circuitry is self contained. Just check out the pin outs. Pin 1 enables motors 1 and 2, and 9 enables 3,4. VCC2 down on pin 8 is where you apply the power for the motors, so VCC1 enables the chip while it uses VCC2 to drive the motors. Neat and tidy. However it didnt preform so well for me. It limited to one amp and when I measured the current draw with a different chip I was getting 3 amps. So the SN754410 worked for me but the motors were so slow.

I just so happened to have a L298 sitting around and tried that. The L298 is the big brother to the Sn754410. 4 amps per channel, 46 volt input supply. This thing is a beast with complexity to match. The Sn754410 has the advantage of ESD protection, and current sense built in. The L298 does not. So you have to add two diodes on each line (for a total of 8 ) to suppress current transients when switching directions.

If the contest wasn’t so close I would have explored other options. Today I received a TB6612FNG Dual Motor Driver from Pololu. The TB6612 uses MOSFETS for switching rather than BJT’s like in the L298 and SN754410. This means that the TB6612 is more efficient, letting more current pass to the motors and less being taken up by the logic circuitry.  It also has the advantage of internal ESD protection like the SN754410. In the end I chose the L298 because it delivered more current to the motors, even from the 9v battery I was using, than the SN754410; but if I did it over again I’d use this new driver IC I got. Plus this new chip doesn’t need a heat sink which would help with weight.


I should note that the Delta Robot is on a temporary hiatus as I work on this. I need to rebuild the body and my Arduino wont work with the Motor Shield. The servos are on pins 30,31, and 32. I dont have 32 pins on the Arduino Duemilanove.

Sep 302013

I’ve been interested in Delta robots for some time now, a while back I even found academic research papers into the subject and made a rather crude model of one.  As you can tell from the photo the first draft design of the delta is very poor. The servos are not nearly strong enough to do anything useful and it has no biceps not giving the robot the leverage it needs. Further more I neglected to read that a bare arduino (I had no shields) can only run two servos at a time. So when I loaded up my delta robot sketch I got a lot of binding.

Skip ahead a year and I’ve recently acquired a Chipkit motorshield (acquired in this case means on loan from my teacher). I’ve also got three new standard size servos and templates for the end effector and biceps. I’m going to make a drawing delta robot like Sketchy. At this current time the robot will work with a PS2 joystick, kinda. Still some issues related to the mechanical hardware of the unit. I’ll be making more posts to show my progress




Check out this video of an industrial delta bot in action.

Jun 172012

Last night I started working on a servo tester using the 555 timer. As I am doing more with servos as of late I felt a stand alone servo tester would serve me well in the future. Schematics and board art will be uploaded later in the week when I can finish it and tweak a few things. Today after work I decided I should add a transistor to the schematic for larger servos and loads. It worked. A bit too well in fact. You can see the damage in the pictures below

As you can see the transistor worked. A bit too well. I can only guess at the voltages but it was a bit intense. Loud pops, lots of smoke and bubbled plastic. Its ok I suppose. That servo was starting to annoy me.

Jun 062012

You see them all the time from fresh faced EE students looking to power their new arduinos and LED’s. The simple computer power supply hacked and forged into a fixed output power supply for a range of very common voltages. Which is exactly why I did the same thing. I like my design, rather than trying to cram it all into the PSU case I attached a piece of bent Lexan to the underside of the case and brought all the wires out. I’ve got all the common voltages, and this supply has two different 12v outputs. Later on I may open it back up and throw an LM317 on that second rail for a variable voltage.

I didn’t take any pictures of the bending process but its stupidly simple. Find where you want the bend and add about 1/4 inch (6.4 mm for my metric friends). Then place the sheet in a vice and use a heat gun to heat the joint up. Keep the heat even or the plastic will bubble and ruin. Eventually the weight of the Lexan will cause it to bend at the vice. Just hold it in place for a minute until it cools.

Mar 102012

Yesterday I went to my local Hamfest and picked up a few Z80 Processors and other goodies. While reading the datasheet I noticed something. If the data lines for the z80 are held in an active low state I will send the CPU a series of NOP (No-Operation) commands. A quick glance on the internet confirmed this and I quickly breadboarded a prototype. I used a manual pulsar as the clock source, tied data lines down and sent the four least significant bits of the address lines out to some LED’s.


When the CPU came up I was able to pulse and the CPU went through the reset cycle. This is great, I know the z80 works and I’m taking my first steps toward building a computer.

I’ll build a dedicated clock and RTC next.

Feb 202012

“Ever tried. Ever failed. No matter. Try again. Fail again. Fail better.” – Samuel Beckett (Westward Ho)


I’ve spent a long time trying to etch my own boards only to end up with a pile of mush on my copper clad. My main issue is getting the board hot enough to melt the resist off the transfer paper and onto the copper. Recently I’ve tried it all paper, photo paper, magazine paper, and the list goes on. I’ve tried preheating my board, using the iron for a longer period of time (Which just happened to transfer the ink onto the copper but melted it too much and ended up with an usable trace).

I wanted something simple and easy to try so a few weeks back I saw a hackaday post about LiPo battery chargers that plugged into the USB port. In the comments I found this version which I liked because it had the USb port built in. So I set to work. I tried preheating again with my hot air gun and got the board scorching hot. Laid my piece of transparency down and started ironing. A few minutes of that and I blasted it again with the heat gun until the plastic peeled away and left the ink on the board. FINALLY! After so long I did it. The actual etching its self was trivial, and I got my first real attempt at soldering SMD parts. However until the resistors (That I’ve been waiting on for two months) get here I can’t do much more with this board.