Welcome to the third development blog for my Pi Wars competition robot project – AverageBot!
If you missed the first two devblogs, check them out here.
It’s been another busy week for AverageBot. With hundreds of ideas spinning around my head every day, I’ve been easily distracted from the basic goal – a robot that moves!
I managed to run a quick pre-made test Python file this week, but I still haven’t played with a single line of code myself yet. I’ve been somewhat distracted by the physical build of the robot rather than the movement and controls, but we’re very, very close to that part now.
However, the progress I have made is all part of building a sturdy, stable and accurate AverageBot, which I’m sure will make the coding effort a lot easier.
Let me give you a round-up of my week…including all sorts of fun with Inkscape and laser cutters!
Last week I showed you the new batteries I had received from RS Components – 4x 7.2V 2000mAh 6-cell packs.
These battery packs came with terminals ready for the connector of my choice, which was full size Tamiya RC terminals mostly due to the fact that I already have an RC battery charging station.
I was a bit nervous at the thought of soldering directly on to the terminals – would touching the 7.2V positive end make something go bang? Perhaps this would be the end of the Average Man, who would then just be known as the ‘Dead Man’?
A few tweets with fellow makers assured me I’d be just fine, and after a slightly edgy soldering session I had successfully crafted two of my four packs:
A quick test with the multimeter and my soldering performance was confirmed – 7.56V – they work!
Now I know they look a bit strange, but it’s almost by design. The Tamiya connectors came with a certain length of cable, so I had to find a way to work with these. I wanted the connectors to be available at each side to keep everything tidy, so wiring them this way worked a treat:
So I now have a motor controller, motors and batteries. I could have fired them up for a bit of early testing, but I wasn’t quite happy with something…
This was the most enjoyable part of my robot build this week.
My original chassis was being made of 3mm plywood panels I had lying around. However, the problem with going all ‘DIY’ on these panels was that my heavy drill just couldn’t be totally accurate with the tiny holes I required (blame the tools why don’t you Average Man…).
This caused the holes for the motor mounts to be a bit inconsistent. I noticed this when looking at the tracks from a certain angle – they had a very slight twist in them and just didn’t look right.
I couldn’t live with that, so I fired up Inkscape. A few months back I had attended a short introduction to laser cutting session at MakersCafe – a local ‘makers cafe’ about 20 minutes from my office – which had showed me the basics on designing with Inkscape for laser cutters.
This, combined with some self-teaching using Google, and I had something a bit like this:
I decided to get my panel designs made, even though I was convinced that something would be wrong. I jumped on to RazorLab.co.uk and uploaded my design, which surprisingly gave me an instant price quote.
It was much cheaper than I thought, and I had the option of picking up my file rather than paying postage, so I entered my card details and got very excited!
The next day I popped in to the cafe, picked up my panels, and rushed home to assemble them.
To my surprise everything seemed to fit perfectly:
This was always going to be a draft cut just to see how my design files worked out. I’ve since made a couple of new versions after adding holes for switches and line sensors, and increasing the screw size and tension gap for my tracks. There will probably be another version before I call this project complete.
Engraving is a fun feature to play with as well. Initially I just used outline engraving, but I’m now tinkering with ‘raster fill engraving’ which kind of burns in a scratched surface inside your text to make it stand out a bit more. This works a lot better on the smoked black acrylic I’m using:
I have to add a massive thanks here to Hazim and Robbie (“Batman & Robin” says Hazim) at MakersCafe.
Not only is the RazorLab online system easy and affordable, the guys in the cafe were really accommodating and even showed me how to save material (and therefore money) by placing my panels next to each other to minimise cut time and wastage. They also wrapped my remaining material to use next time. Top lads!
Terminal Block & Wiring
The terminal block arrived this week, which allowed me to connect all the wires on my robot.
As I mentioned before, I’m using this to save any hassle trying to connect different thickness wires together. There are many ways to achieve this, but using a terminal block seemed easy with the added benefit of a bit of flexibility vs other methods.
I also used the terminal block to fit my switches this week. Again, this was a nice easy way of doing it.
After dismantling AverageBot so many times, the traditional cross-head M3 screws were getting a little rounded off and messy. I ordered some allen bolts to replace the worn out M3s, as they should hold up a bit better, and generally look a lot nicer too.
I also ordered a bunch of spacers with threaded tops, to allow me to easily add a third layer if required (I may do this as a bit of a protection layer for the Pi). Watch this space…
Remember the snazzy steel SR-04 mount I showed you last week? Minor update – I fitted it:
Whilst making the latest chassis plates, I added holes for the line sensors to be mounted. I didn’t do much research on where to mount them and how far apart, but they’re on now which means I can have a play with them at some point and see how it goes. I can always get another lower panel cut if need be.
I mentioned lasers last week but was quite vague. Let me explain…
Whilst looking through eBay, I came across some little cheap laser modules. I thought these would be handy for ‘something’ but wasn’t sure what. After further eBay’ing I came across these:
These are cross-hair style laser units, which I thought would come in really handy for the skittles competition, or any of the challenges that require some kind of straight driving.
Where and how to mount these is the next challenge. I don’t think anyone makes a mount, so maybe I’ll get on TinkerCAD and 3D print one?
I mentioned in the opening paragraph that I managed to get the robot moving this week for a trial run. I wanted to test that the batteries, wiring, motors, tracks, Pi and everything else were all working together. There are a lot of individual parts to making a robot so I’m sure things can easily go wrong.
The motor controller I bought came with a few handy test scripts, so I loaded up the motor test and crossed my fingers. Here’s the result (and excited tweet):
— Average Maker (@Average_Maker) September 27, 2015
Yes it does wheelies! It was a lot faster than I assumed it would be, and whilst the turning was a bit ‘iffy’, it still managed to get there in the end, so that’s an improvement to the original AverageBot that I made back in May. At one point during testing a track slipped off so things aren’t perfect just yet.
I’ve since updated the chassis to improve track tension and movement with the idler wheel mounts, and I’ll be reviewing those changes soon to see if thing are working a bit better. A few fellow makers suggested playing with the turn code (PWM etc) so I’ll take a look at that too.
Well I’ve avoided the task of coding for another whole week, but I think that’s as far as I can put it off.
Next week I’m loading up with caffeine and tackling basic robot control, borrowing code from the test files and tweaking it to my liking. I’ll probably have to sort out the turning as an initial priority though.
I’m still unsure on what to use as a control device, especially considering the WiFi clashes and issues from the last competition. I’ll continue with basic WiFi SSH for testing, but I’ll need to find something more suitable – perhaps a PS3 controller via bluetooth?
I also need to give some thought to LEDs. Whilst I might not win the “Jim Darby prize for blinkiness”, I’d like to have some ‘AverageGlow’.
Lastly, another big thanks to everyone on Twitter for their help and advice again this week.
Until next time…