I was approached recently by Dr Patricia Charlton to conceive, design and build 30 ‘interactive conference badges’ for an AI Summer School here at The Open University she was organising in association with The Institute of Coding. The brief was literally that…. brief! Some discussion defined that something was required that would record a student’s progress as they completed the activities over the duration of the course.
So, it needs to be….
Something that can visually display progress
Small enough to hang around your neck
Long enough battery life
At this point, I did some experiments with the Pi Zero but it was cost rather than size that scratched this one this time. So, it was time to go to the dark side!…. Arduino Nano here we go (Sorry, loyal Pi fans!)
I recently designed and ran a QR based treasure hunt at the OU which was extremely successful and we often commented that doing similar but using NFC tags would be very cool. So…. what if we built badges with NFC readers / writers…. Oooh… and cool Neopixels to light it up!
We also wanted to tie in the badge to The Open University, The Institute of Coding and the fact that it’s the OU’s 50th birthday this year. For the outline design for the badge we quickly realised that the OU logo was a beautiful form factor so we began to see what we could fit inside it.
I did the initial design in OpenScad (as usual, I just find it works so well for my needs)
I then started to experiment to see how components could be laid out inside the badge.
Once I was happy with the concept, and was satisfied that it was practical, we went from prototype… to production.
The cases were printed by Kevin Dewar in the Rapid Prototyping lab here at the OU – thanks Kev!
I then started the long process of the assembly of the internal components for each badge.
Yes. I did this 30 times…
I also designed stickers for the front of the badge to give it a really nice finish. I was *really* pleased with the way these came out.
The organiser, Trish (Dr. Charlton!), then came up trumps and managed to source custom OU 50th Birthday lanyards for the finishing touch which makes the badges look really very cool (imho, of course!)
The finished badges…..
There were seven challenges over the two days of the course and the badge is designed to change colour after a specific challenge is completed and the badge is tapped on an NFC marker. The students were given the badge to take away and were also given an additional blank NFC key fob with instructions and code for hacking the badge in their own time.
And here’s a final test to make sure they all work before they were given out to the students!
This has been a fun, if at times stressful, project. The difference between prototype and production is *enormous* – I’m fairly certain I know where my skill sets lie!
So, if you were at Pi Wars this weekend you may have been lucky enough to pick up the awesome Pi Wars 2019 badge made by Gareth over at 4Tronix
This brilliantly cool little device is actually an Arduino micro controller, a 5×5 LED matrix, 4 push buttons and a light sensor all in one package. The code that currently runs the badge is available on GitHub HERE
But, if you’ve never used an Arduino before it can be a little confusing what to do if you want to start playing around with it.
So, here’s a quick guide to setting up what you need, and then changing the display to show your name.
A PiWars 2019 Badge (No, really!)
A data capable USB – microUSB cable (Make sure it’s one that provides data transfer and not just power)
A laptop / PC (The following is for Windows based machines – for Mac / Linux the configuration of USB-serial will be different but everything else remains the same)
First, plug the badge into your laptop or PC using the USB cable. The badge will power up and run the program that’s already installed on it, scrolling ‘Pi Wars 2019’ on the display.
On your PC, you’ll see ‘Installing device…’ message displayed
Now wait. And wait.
You should eventually see ‘USB COM x successfully installed’. This means USB port is now correctly configured as a serial port and the Arduino software will be able to see it. Make a note of this number – you’ll need it soon!
When you run the Arduino IDE, it’ll show the following screen:
This is a blank ‘sketch’ which is the name for an Arduino program. Programs are written in a language called ‘Processing’ and if you’re used to your Raspberry Pi and using Python or Scratch it’s a bit different. It’s a ‘compiled’ language which means that the (almost!) human readable code you see is translated into the actual bits and bytes that the microcontroller (the Arduino) can understand. This compiled code is then uploaded to the Arduino and once that’s done you can turn it on and off and the program will still be stored and will run whenever you turn it on.
So – to start making changes, firstly we need to make sure that the Arduino IDE can see your badge correctly and is ready to program it.
Under the Tools menu, scroll down to ‘Ports’ and make sure this is set to the same COM port that was created when you plugged the badge in. (It will usually be COM4 or COM5)
Next, again in Tools menu, scroll down to Boards, and then select Arduino / Genuino UNO.
Lastly, back to Tools menu, scroll down to Programmer and select ArdunioISP
Your IDE and badge are now set up and ready to be re-programmed!
(Thanks to Gareth at 4Tronix for confirming these settings!)
Then, in the Arduino IDE click File – Open and open the badge.ino file you just downloaded.
You should now see the following displayed:
This is the sketch that’s already been compiled and uploaded to the badge. If you scroll approximately 1/3 of the way down you will see where the ‘User code and defines’ section starts which looks like this:
// User variables and defines
byte mode; // Defines the display mode: Static, Scrolling characters, animation, dynamic
int cycle=0; // Variable to count rate of scrolling
#define CYCLERATE 300
#define SCROLLRATE 100
#define ANIRATE 100
#define PIXELS 1
#define NUM_LEDS 14
#define BRIGHT 80
String text1 = “0123456789”;
String text2 = ” PiWars 2019 “;
int offset=0; // offset from start of character. Used in scrolling
int L1 = A3, L2 = 10; // Left Motor Drive pins
int R1 = 11, R2 = A4; // Right Motor Drive pins
‘String text2’ is the variable which stores the scrolling text that is currently displayed when the badge is turned on.
Change this to your name – or anything you like!
Next, go to the Sketch menu – and click Verify / Compile.
You may well then get the following error! (If not – skip this section)
This error means a library needed to run the LEDs is not installed. Fortunately this is easy to fix. Go to the Sketch menu > Include Library > Manage Libraries.
Search for FastLED in the search box which should then show the following screen:
Install the FastLED by Daniel Garcia library which should be the top result. Now if you compile the sketch again it should compile successfully.
Finally, in the Sketch menu click on upload and your updated program will now be compiled and uploaded to your badge. The badge will turn off briefly and when it turns on again your new text will now be scrolling brightly for you!
There is LOADS more that can be done with this little board, if you search through the code, you’ll see where the buttons are defined and how these can be used to do lots of different things – there’s also the light sensor on the eye that also adds another dimension….
So, this is what happened when I bought a cute robot, pulled its head off, and replaced its brains with a Raspberry Pi!
I had some time off over Christmas, which means I end up with time to do fun stuff like hacking toy robots, then making fun movies made with hacked toy robots….
This started I went to a favourite store of mine in London just before Christmas (please note other large toy stores are available!) where I found this very cute, fairly dumb, but remarkably not that overpriced, robot kit. How could I not take it home?
This particular version is called a ‘Tobbie’ but it is a generic kit that I’ve now seen marketed under several different names ranging in price from £15-40 for an identical item.
The actual kit took only an hour or so to put together but several things struck me during the build. Firstly, the actual quality of the components was really good for a cheap toy kit.
The 100+ piece kit – my idea of Friday night heaven!
Also, the head turning and walking movement is all done with just two motors. The mechanism means the direction the head is facing determined the direction of travel. It is an elegantly simple motion and as it’s only two motors, that makes the possibility for hacked control much more straightforward.
A quick look inside during the build…..
The legs just snap together and build up into this really lovely mechanism….
So what you end up with is a *really* cool, but not very bright little robot. It does IR follow / avoid and that’s about it.
From Tobbie – to Zobbie!
I think we can all see where this is going.
It took about 0.5 seconds of playing with the original to realise I was, of course going to have to see how we could improve on its abilities. It became really apparent that a Pi Zero, power, DC/DC regulator etc. weren’t going to fit inside that head… so it was going to have to go….
You have to ‘unbuild’ the kit almost all the way back to the start, this then allows for removal of the head which conveniently then just leaves the wires for the two motors exposed.
I built this from parts I had at home, there are a myriad ways of doing this in terms of controllers etc but I used the following for this build:
Here’s an early test layout to check sizing of components.
I designed a fairly simple head to replace the existing one that could hold all of the components and a battery. I then designed a new face that uses a Pimoroni Blink to add moody eyes. There is also a Pi Camera module mounted between its eyes and I’ve just been adding autonomous control using OpenCV.
Small paper covers work really well to diffuse the Blinkt and make the eyes glow!…
I then used two (fake!) Lego blocks to make nice simple mounts for the new head…
Which I then just glued in place and fed the motor wires up through from the body.
There is a boot switch mounted on the back of its head. On boot it runs in manual mode which uses a PS3 controller connected over Bluetooth. The control code is largely based on the sample code provided by PiBorg for their ZeroBorg board. I also followed their setup for the PS3 controller as this can be problematic and their method has always worked for me. The colour of the eyes can be changed with the shoulder buttons and the overall control and mechanical motion is really lovely.
This has been a really fun project to work on thus far. I’m keeping going with the autonomous coding, I want to take Zobbie to Pi Wars in March where hopefully it’ll be able to complete a couple of the challenges (just for fun! – I’m not competing this time round!)
If you want to have a go yourself, the 3D printing stl file for the head can be found on Thingiverse HERE
I’ve been playing around with Nintendo WiiMote controllers and the Raspberry Pi for a couple of years, there’s a well used Python library called cwiid (which, after much discussion, we finally realised it’s pronounced ‘seaweed’). Mark C. from Cotswold Jam has built at least a dozen remote controlled bots that use a this set up and we’ve taken the balloon popping spectacular that is ‘Micro Pi-noon’ which uses these bots to many events in the last twelve months.
The WiiMote itself is basically a very nice package of buttons and sensors and the Python library means, with the onboard bluetooth dongle on the Raspberry Pi 3, you can get your hands on all that lovely data in real time.
All of the demos and examples I’ve seen use the WiiMote to control something, usually a small bot using the buttons as controls. But, it does have another trick up its sleeve. A quick glance at the end of the WiiMote reveals a standard looking IR controller type piece of dark plastic. Tucked away behind this however, is a full camera. The sensor bar that is supplied with the Wii contains two blocks of five IR LEDs and the camera is used to detect the position of, and distance between, these two blocks to calculate the controller’s position relative to the screen. This is what allows the controller to be used as a mouse pointer when set up with the Wii.
Sadly, the Cwiid library is no longer actively supported and I’d done a fair amount of searching and found nothing that had used the IR data from the WiiMote although I was fairly certain this data was being exposed via the Cwiid library. After a few trials and by dumping all the data from the WiiMote I found the IR data (wonderfully buried as a list of dictionaries!) and worked out how to extract it. This gives a fairly different x / y position value from a screen resolution x / y value so some conversion is required. Additionally, depending on the position of the controller, only one set of LEDs on the sensor bar may be visible so this must be accounted for too.
I then wrote an initial Pygame script to mimic a cursor using the WiiMote and from there it wasn’t a great leap of imagination to…
GIANT DIGITAL GRAFFITI!
This is my (frankly rather poor) first effort – but it still looks pretty damn cool when it’s 10 feet wide!
I was originally going to build a actual fake spray can but due to time constraints went for a far simpler option. As it transpires this actually makes it far easier for someone else to replicate.
Enough already – show me the goods!
So – to build your own Giant Digital Graffiti Wall you’ll need the following:
Raspberry Pi 3B+ running latest version of Rasbian Stretch
Wii sensor bar
DC/DC power converter
Projector or large screen TV
30mm square mirror
3D Printed holder (link to stl file below) – or a lump of Blu-Tac works ok-ish!
The Wii sensor bar and controllers can be picked up really cheaply I’ve found, just shop around. Your local car boot sale is a great place to look! I’ve been paying around £3-5 for a controller and £5-10 for a sensor bar.
Set up the WiiMote controller and Cwiid
*Make sure your Pi is connected to the internet.*
Open a terminal and make sure you’re up to date by entering:
sudo apt-get update
sudo apt-get upgrade
Next, install the bluetooth library:
sudo apt-get install bluetooth
And the Python Cwiid library:
sudo apt-get install python-cwiid
Check the Bluetooth service is running:
sudo service bluetooth status
If everything is running as is should be you’ll get a message confirming this. If not, just reboot the Pi.
Next, grab your WiiMote, press buttons 1 and 2 together. Whilst the LEDs are flashing, type:
And hit enter, which will produce something like the following:
01:A2:33:D6:12:A3 Nintendo RVL-CNT-01
Make a note of the left portion which is the MAC address of your WiiMote, you’ll need to enter this in the Python code to pair the WiiMote to the Raspberry Pi.
That’s the WiiMote set up and ready!
Set up sensor bar
The Wii sensor bar runs at 7.8v – which is annoyingly non-standard so the easiest way to accomplish this is with a 12v DC power supply and a DC/DC converter. Just cut the Nintendo plug off the end and then wire up to the output of the DC/DC converter. The Nintendo wires are *thin* so I added a blob of hot glue over the terminals to ensure everything stayed in place. I’d also recommend boxing the whole board rather than leaving it on the carpet!
(Photo taken through front camera on my phone so you can see the LED array.)
Make a ‘Spray Can’
I wanted to make something that was easy to make but would use the feel of the WiiMote to replicate a spray can. Holding the controller vertically and using the trigger to ‘spray’ felt most natural so I used OpenScad to design a holder that simply slides over the end of the WiiMote.
And then by attaching a 30mm square mirror to the holder, the controller can then be held vertically and the camera still detects the full LED array very well. This does of course invert the x coordinates, which took some head scratching to figure out in the code. I ordered a bunch of these little mirrors from eBay for about 50p each. (Note to self – check quantities contained in each packet before ordering five packets!)
The completed attachment.
And in place….
You can download the stl file to print the holder from my Thingiverse account HERE
Download the Digital Graffiti Python code and graphics
The Python code, the two images used and full instructions on how to use the program are available on my GitHub repo. Download the code with the following command in the terminal:
The code needs to run in Python 2.7 as cwiid is not supported in Python 3.
In the terminal type:
When Python opens, navigate to the newly created digital_graffiti folder and open digital_graffiti_1080p.py
Before you run the program for the first time, you will need to edit the code at line 51 to enter the MAC address for your WiiMote controller. Once you’ve done this and the sensor bar is positioned centrally in front of your screen, you should be all set up and ready to draw! Full instructions are provided in the digital_graffiti folder. Open the digital_graffiti_keys.png image to see all the controls used.
When you run the program, ‘Connecting to can’ will be displayed on the screen. Press buttons 1 and 2 on your WiiMote at the same time to connect to the Pi. The main drawing screen will then be displayed.
Some notes about usage.
The current ‘brush’ size, colour, and shape is displayed in the bottom left corner of the screen.
The sensor array is more accurate when the controller is pointing closer to the centre of the screen, the very far left and right edges of the screen can produce some anomalous results!
It works best if the controller is 6-15ft away from the sensor bar. Closer than this and accuracy will drop.
We used this set up at a recent Knowledge Makers event at the Open University. We used a projector and had really successful results – and the screen image was about 10ft wide!
Here’s us testing it out before the main event – it all got a bit Jackson Pollack…
The code is ‘hard-coded’ to a screen resolution of 1920 x 1080 at the moment due to how we were using it. I originally ran this on a Pi 3 and it got pretty toasty after 20 minutes usage! It is highly recommended therefore to run this on a 3B+
There’s loads more room for improvements; extra brushes / effects, fill / bucket, select etc etc….
So today I got angry. Really angry. I was in a pissy mood anyway, was checking Yahoo Mail when I saw the following click-baity headline….
Actually, that’s quite interesting. Except the link takes you to the following page, which is actually an advert for ‘Bitcoin Trader’ – and quick bit of Googling will quickly reveal that it’s an out and out scam.
And certainly nothing to do with Seth Fiegerman or CNN.
It didn’t take long to find the original version of that image either. It’s from the Grand Challenges meeting in London on October 26, 2016.
So, Yahoo is taking money from fraudsters for paid advertising. And these fraudsters are using high profile brand names to sucker vulnerable and naive people in to parting with money they can undoubtedly ill-afford to lose.
The link to the site is here if you wanted to look: http://magjunky.com/2018/07/05/bill-gates-gives-4-6bn-to-charity-in-biggest-donation-since-2000/
The domain registration details are, of course, masked. The UK police will only act on evidence of a crime. Once someone has been ripped off, then they will act. But the chances of the perpetrators being U.K. based, or even locatable makes prosecution unlikely in the extreme.
I wish I had an answer to how this can be solved. Hopefully by bringing attention to this particular piece of scum-baggery something can be done to take this one down.
Life is rather full on right now. And so is preparation for Pi Wars 2018. A completely new job and change of direction, a move to a new city and about 6 weeks of travelling all in the last year has meant that preparations for Pi Wars have taken longer than hoped (when do they ever not!) I was equally pleased and somewhat mortified to have been selected to compete again this time round, competition for a place was fierce, with 76 teams eventually lucky enough to make the start line.
After last year’s fairly disastrous outing, managing to compete in only 3 events, I wanted to start early and eradicate the source of my frustrations – power issues and controller issues. I also wanted to address the problems with the ultra-cool but ultra-slidey mecanum wheels. And the motor controller issues. And the sensor issues. And the wiring issues. Ummmm.
So, whilst it may look fairly similar, X-Bot has indeed undergone a significant transformation in terms of what’s under the hood. Pretty much *everything* has either been replaced, rewired or removed! This is hopefully going to be obvious not only in terms of reliability but also controllability.
Ok…. so last’s year’s wiring ‘loom’ was more of a wiring nest – as several folks kindly pointed out (I’m looking at you, Brian)….
I wanted to clean up the power supply and all of the wiring and start again from scratch. I looked at Li-Po but the investment cost to get started was fairly eye- watering. I also wanted to ditch the 5v buck converter I’d been using as I am suspicious of the reliability of these devices to say the least (see earlier blog post for full details) I’ve successfully used the ‘powerbank’ type USB battery packs to run Pi projects (including my first Pi Wars bot) and never had an issue so, in this case, the mantra became stick with what you know.
The transformation process begins….. (That’s just a little bit neater!)
I genuinely couldn’t believe the amount of wiring I was actually able to remove and still have a fully functioning bot when it was all put back together. I’ve now repeatedly tested this new setup and had literally zero power issues or reboots etc. I am using the ZeroBorg controller to power the four motors (which have also been upgraded) and a Rock Candy controller to replace the PS3 one from last year – another source of potential issues gone!
I’ve also mounted a Pi camera for the autonomous challenges, currently on a temporary lego / blutac mount until I can get time to design and 3D print a proper one. With upgraded motors, cleaned up wiring, reliable power supply and controller I am hopeful that the renewed and revamped X-Bot will at least be reliable enough to compete on the day.
Behold… the scrubbed up X-Bot.
Let’s get grippy….
One of the other things sorely lacking on the original X-Bot was a degree of controllability. Whilst the mecanum wheels are incredibly effective in terms of movement, they actually had very little grip which meant manual challenges were… challenging, and autonomous tasks were made significantly harder.
The original rollers. After hours of trials with different coverings, these proved the most long lasting and effective – wrapped in self-amalgamating plumber’s tape..
I have a confession. My new role at the Open University comes with distinct perks. One of these is access to the awesomely equipped ‘fab lab’ with a range of mouth-watering maker / engineering kit. One particular delight is an industrial strength 3D that can print in a range of materials. At the same time :-O
I will be forever indebted to Kevin, the chap who runs the lab, as he printed some uber-grippy new rollers for me. They have a solid ABS core and a rubber ‘tyre’ surround. They have a load more traction than the previous rollers which really aids both manual and autonomous driving.
Such grip. Many rollers….
Introducing…. X-Bot 360!
One of the other things previously missing was something that I am sorely lacking myself, a sense of direction (just ask my wife – she has literally stopped me walking off a cliff whilst reading a map, boldly declaring that this was, of course, the correct way back to car.) To that end I looked into the scarily mathematical world of the IMU. These incredibly tiny devices combine magnetometer, gyroscope and accelerometer into one board. Combining the outputs of these three readings, and using some incredibly complex mathematics and things called ‘kalman filters’, these boards can give a bot a guide to where it’s pointing with some degree of accuracy. I’d done some experimenting a while ago with a board called a BerryIMU but had not had a lot of success getting reliable readings from it. Whether this was me or the supplied Python library, I am still not sure. I then found the superbly geekily titled BNO055 from the ever reliable Adafruit (but seriously – who uses ‘o’s and ‘0’s in the same product ID?!)
Do you know the way to Pi Wars? – this little thing does!
It’s taken a fair while and a lot of tweaking to tune the motors to start and stop effectively in time with the readings from the IMU, something that’s critical for exact 90 and 180 degree turns. I’m really pleased with the results thus far, thankfully as the board was probably one of the most expensive individual parts at around £35.00
One the main structure of the bot was complete, I started planning the add-ons for the new challenges and also getting OpenCV installed for the Rainbow challenge – but that, as they say, is another story.
Next time – new challenges… new add-ons.. and *$%&*#ing OpenCV!
Well, six months after the fact, I believe I may have located the source of the pretty disastrous issues I had at the last Pi Wars. I actually managed to complete just three of the seven events so it was all a bit heartbreaking tbh.
I had severe issues using a PS3 controller and I fully believed that to be the issue and therefore have looked at moving away from this to another controller type for next time round. The Rock Candy PS3 controllers come highly recommended by Brian Corteil (aka @CannonFodder) who has used them to great effect, in fact winning – twice!
So, you may have seen FRED-209, my new Pi powered Nerf Tank. This uses same ZeroBorg motor controller and I had it linked to an original PS3 controller. I’ve tested extensively in the week and then this Saturday I took it to Cotswold Jam and bam… the controller fails. Niet… Zip… Diddly. Can’t get it to connect, then if it does it drops after a few seconds.
This is *identical* to the behaviour X-Bot exhibited at Pi Wars. So much discussion ensues as to the cause. I know of several other folks who also had issues with these controllers last time round. However, Brian C. lent me a Rock Candy one to test and this also showed exact same behaviour. The RC ones are 2.4ghz and the PS3 ones are Bluetooth so still wasn’t sure if it was radio interference of some kind. Another good guess was noisy DC motors causing problems.
But… I think we have a winner. This DC-DC converter board is a damn liar…
I recently recommended this type of thing having seen similar at Pi Wars last time. I now conclusively retract that recommendation! I used a similar board last time , without a read out, and I believe this suffers from the same issue.
Note the difference in alleged and actual voltage….
This difference is not enough to shut the Pi down, but it is enough to mean power hungry peripherals, say a bluetooth dongle for example, are just enough to make the power dip enough that the USB experiences issues and that kills the controller.
If this were the only problem then simply setting it higher to start off with would solve the problem. We did crank it up to 5.18v on the multimeter which may be getting a little hot for the Pi, but it then ran flawlessly for the rest of the day at Cotswold Jam with loads of people giving FRED-209 a good hammering.
I do though believe there is good reason to suspect that the setting on the board drifts over time. Whether this is vibration from the pot moving the micro screw that you use to set the output voltage or something else, it does seem to change. This is regardless of the state of the batteries being used.
So, I am now hunting for a DC-DC board that sticks out a guaranteed 5v that can be relied one. Core Robotics have one in the pipeline but it’s not available yet. I’d be interested to hear from other teams who used these or similar boards or PS3 controllers last time and also experienced issues.
This one’s been a while in the making, I’ve had a whole summer of fun putting it together. Tbh I can’t remember what first inspired the idea for this. I’ve been wondering about Nerf guns for a while (another amazing thing that wasn’t around when I was a youngster) My main thought was ‘can you use a servo to trigger it?’
Turns out you can
Flushed with initial success, things got out of hand remarkably quickly….
Whilst a fun idea, it obviously wasn’t going to fly that way so I decided I’d see if I could design a ‘Nerf Tank’ from the ground up. I’ve use the ZeroBorg controller again from Pi Borg and a PS3 controller (despite one dying on me at PiWars!) I chose this as the base as I have working controller code and I wanted to focus on the actual 3D design and build this time so I could complete in time for the next Cotswold Raspberry Jam.
The Nerf in the pic above is the Elite Stryfe, about £15 from various places. Or – your local car booty for a whole lot less! ..
I pretty rapidly disassembled it to get a good understanding of the innards. Turns out it’s two flywheels that actual push the dart out and a fairly simple push mechanism to give it a shove. Hmmm… two motors – and a servo. This could work!
I then got OpenSCAD out again, still my favourite 3D design tool, I love its overall simplicity and the fact you can do fairly complex shapes in just a few lines of code (without having to learn what a zillion buttons do) I drew out a basic design for the chassis and I made larger versions of the same motor mounts I made for the PiWars bot.
This is the original chassis I designed, combined with the gorgeous chunky wheels I found on eBay. Sadly the motors turned out not to have enough grunt to move the thing so a rapid and somewhat disappointing switch was made to the Rover 5 chassis you can see in the final version (which was also an eBay find) Also in the below picture is the design for the tilt mechanism which would eventually be controlled by two of the shoulder buttons on the PS3 controller.
Here’s the completed barrel and mechanism box, you can see the servo mounted underneath which attaches to a nice simple pusher. Printing the lid was fairly tricky as it and the box are the largest single pieces I’ve printed at 24cm long. The lid also required a lot of support material which was a bit of a bugger to remove cleanly as it covered such a large surface area.
And flinger bit….
I had to tweak a couple of dimensions on the box to make sure everything lined up nicely but it went together really quite quickly in the end.
You’ll notice this version is black. And really quite poorly printed. After two crappy results I finally worked out something pretty important. Cheap PLA isn’t worth the saving. I spent many hours trying to work out why the results were so poor when previously the printer had been excellent. Turns out it wasn’t calibration, or heat settings, or bed temperature – just naff filament. It works ok on smaller items but the moment you try and print something larger you’ll run into all sorts of problems with warping, lifting and delamination.
I therefore binned the black, and splashed out on some shiny orange (flouro red was the as described colour but hmm…) I also had to redesign the bottom plate to fit onto the Rover 5 chassis. It doesn’t look as good as it did on the chunky wheels but hey, it works.
I’m planing to take this to Cotswold Jam so thought it may be a good idea to give the kids something to aim at (apart from each other!) So – evil alien hordes it is. I’ve also rigged up a Pimoroni Blinkt, the lovely little 8 LED board. This works as a visual countdown, starting with all green LEDs and then one going from green to red every 15 seconds. The plan is to mark out an arena and then the player has two minutes to knock down as many targets as possible and then return to base before time runs out.
Doing a little target practice with the finished build…
(Apologies for rough quality of video – it was downsampled during upload to youtube for some reason.)
I’ll put the STL files for the chassis and the Nerf cannon on Thingiverse when I get some time later this week, I’ll also upload the controller code to GitHub.
I’ve got some future plans for this chap too. Adding a camera and web interface controller seems like the logical next step – and guaranteed to cause remote mayhem! Further to that, I’ve started experimenting recently with OpenCV so am very interested in adding a level of autonomy / target detection. Hopefully FRED-209 will be slightly better behaved than his namesake!
Thanks for reading – pop along to Cotswold Jam on 23rd September if you want to have a play – there’ll be prizes for the highest scores!
While I’ve had the last few months to freak out about having no motors and therefore essentially no bot, I’ve had plenty of time to try and distract myself and design and build a range of add ons to cope with some fairly stiff challenges in this year’s competition.
I built a 4-way sensor rig from standard ultrasonic sensors. The wiring is pretty um… intense, but it does work and reads distance in all directions. I’ll be using this for the straight line speed test and the maze.
The wiring maze begins…..
All wired up….
I’ve also got a mount for the line sensors sorted and the code working nicely for that (fingers crossed this works on the day!). I’ve also got a simple holder for the golf challenge, although I suspect there may be far sneakier / trickier hazards than this will cope with! :/ The one on the left is the clamp for Pi Noon… Looking forward to that one.
Skittles was great fun last year, and my ‘ball cannon’ worked well enough, sadly my driving let me down and I knocked the ball away from the bot and fluffed a shot. The ‘collect the ball’ component of the challenge has forced me to come up with something to avoid this completely this time round.
The simple arm / servo arrangement should prevent the ball rolling away, and the spring in the tube has enough kick to give the ball a good whack!
Armed and (slightly) dangerous…
I’ve got the bot driving properly and the mecanum wheels are performing really well – such a relief at this point. I’m now (slowly) working on the autonomous challenges and rapidly running out of time. Going to be a frantic dash to the finish line. I reckon I’ll get there
I’ve got a bot that can compete and even with all the difficulties I faced, I’ve learnt so much again through the the build and it’s been really fantastic to be involved in Pi Wars again. I love the social camaraderie, particularly on Twitter. Very much looking forward to seeing old faces and new next weekend.
I’ll be there for both days, do come and say hello. I’ll be the one with the panicked look cos his bot just * shot out the door / took out a small child / knee-capped Eben Upton (*delete as applicable)