28 August 2014
Take some Avatar: The Last Airbender iconography.
Take some fluorescent perspex.
Take a laser cutter.
Create your own phone charms to show your Air Nomad or Water Tribe affiliations.
26 August 2014
This is an utterly ridiculous knitting project.
I bought an LED plant pot from Lidl. And I knew I wouldn’t put an actual plant in it, because that just seemed pointless - I’m rarely outside at night, it would never be on.
So I knew I was going to EMF Camp this year, and I knew that having little random lights is always a lot of fun, and I had a small collection of fibre optic hair clips from The Glow Company because of my Teddy Lupin doll project, so I started goofing around and here you go, a cactus with fibre optics in the flowers.
I did think about putting the fibre optics throughout the cactus so that it would have “spines”, but I knitted them in the round, and it would’ve been impossible to properly get it all sorted.
I think that I might do it again, with one knitted flat, so that I can fit the fibre optics into the spines.
25 August 2014
24 August 2014
23 August 2014
22 August 2014
As a child growing up in the 1970s, I had no idea of what the future held. I didn’t know if Mr Benn would be able to get back from his adventures, or if Scooby Doo could catch the Evil Swamp Monster, or even if we were going through the round or square window in PlaySchool. But there were some things about the future that was pretty certain. We would all have robot butlers, go on holiday to the moon and drive electric cars!
So, as I drove to work this morning in my electric car, wondering when my moon tickets would drop through the letterbox, I realised that maybe, just maybe, I am already in the future
The car itself is a 2013 Chevrolet Volt Extended Range Electric Vehicle (E-REV). There is quite a large choice of electric vehicle on the roads in the UK right now, and, just like petrol cars, come in a range of sizes, styles and prices to suit different people. They don’t all work the same way, or use the same technology, and what may be perfect for one person might not work at all well for someone else. For example, a Nissan Leaf is battery only, quick to charge but only has a range of 80 miles or so. Hybrids like the Toyota Prius, have a engine and a motor and can run on either and will charge the battery when running on petrol.
I have covered almost 2500 miles in just over 2 months, and most people I talk to seem interested in how it works both technically and practically for me, and why I went for this kind of car. It is an excellent car that suits me well, but it does have limitations and downsides that mean it might not be for everyone.
Firstly, it is an Extended Range Electric Vehicle. That is, it runs on an electric motor from battery power, but it also has a petrol engine that can run a generator to keep the battery from running flat. Unlike a hybrid, the petrol engine does not drive the car. Normally, the battery is charged up from home which gives me range of about 40-50 miles before the engine needs to kick in. As my daily commute is around 18 miles each way, and I’ve not been on any long journeys since getting the car, the engine has not been needed, or even started.
(Except once. I got in the car and a message on the dashboard informed me that due to the infrequent use of the engine it needs to be run for a 10 minute maintenance schedule. I guess that makes sense to ensure nothing seizes and all the fluids are pumped around a bit. And 10 mins of petrol use over 2500 miles (so far) still seems very low!)
Charging the car is very easy. It comes with an adapter that will plug in to any UK 13A plug socket. This runs at 6A by default and will fully charge the battery from flat in around 8 hours. It can be overridden to run at 10A, or 6 hours to charge. Thanks to a government scheme though, I have had a dedicated charge point fitted free, and this runs at 16A, taking about 4 hours to fully charge.
There are electric charge points dotted around all over the place, most of which are free, some are cheap and others less so. These range from most IKEA branches, some supermarkets, city car parks, motorway services, hotels and other places. They are often run by different companies and have one or more of the common 4 charging sockets and charge at different rates of power. Although I have free access cards for a couple of companies charging posts, so far I have not used (or needed) any.
Some other electric vehicles, particularly the battery only ones have much more powerful charges built in to them, so can charge at 32A, 63A or 125A. This makes sense for en-route charging if you need to drive somewhere beyond the limit of your battery. The Chevrolet Volt, though, takes too long to charge for this to be practical. Effectively, you get a maximum of about 12 miles range per hour of charge, which makes it suitable for destination charging. Unless, of course, I wanted to stop for 4 hours every 40-50 miles!
As I said earlier, though, my daily commute is about 36 miles round trip, so that has been covered on battery only since getting the car. Some evenings I pop out, and some weekends I take much longer trips. So far, plugging in when I get home for an hour or so has covered all the evening trips, but sooner or later I will be heading down to Essex or further afield. For a trip like this, the first 40+ miles will be purely electric, with the remainder of the journey having the engine running.
As you can imagine, the engine is a small efficient unit. Because it is not driving the car, the speed it runs at is controlled for efficiency of charging, and I can expect to get over 50mpg from it. Still not too shabby for a big car like this.
So, how much does it cost to run then? Well, I’m glad you asked. It has worked out around 3.4p per mile based on the cost of electricity to charge it up. That is around £1.25 per day to commute to work and back. By comparison, the same journey in my LPG PT Cruiser (which wasn’t too efficient, but the fuel was cheap) cost around £7 per day. If I’d been running that car on petrol, it would have been over £13. Then, of course, there’s the car tax which is zero! And, because of less engine wear and less break usage (regenerative breaking used whenever possible) services costs are lower too.
But I bet it is slow. What is it like to drive? Actually, it’s quick. Amazingly quick. I mean, really quick. Even in “normal” mode, it takes off from the lights quicker than most cars out there, and in “sport” mode, it can outpace a rocket! And, unlike a convention engine that has a gearbox to make use of its sweet spot of power, an electric motor has torque available to it whatever the speed. And with the exception of a little bit of tyre noise and wind noise at higher speed, it is completely silent! It is so quiet actually, that I am beginning to listen to the background noises and interference in most of the pod casts I listen to!
Oh, and don’t get me started on gadgets. Well, ok, yes, it has gadgets. Lots of them. Sure, regular stuff like CD \ DVD player, electrically heated seats, sat nav, Bluetooth etc. But also touch screen display, DAB radio, rear view reversing camera, hard drive for MP3s. My favourite one, however, is preconditioning; Before you leave in the morning, whilst the car is still plugged in, the heaters and window demist can be triggered. So, not only do you come out of the house to a nice warm car (or a cool car in the summer), but it doesn’t affect the electric range as this was done from the mains supply! Genius!
Despite the fact that electric cars have been around for years (If the Toyota Prius was human, it would be getting its GCSE results next year!), things have still got a long way to go before everyone drives an electric vehicle. The infrastructure isn’t yet as commonplace as it needs to be. The range of all cars except the Tesla S will mean compromises for most people. Initial purchase price is still too high compared to a dinosaur fuelled equivalent.
But, one by one, we will all get to the future. For me personally, I am really pleased that I am living in the future already, although just a little bit sad that my robot butler must have hidden my moon tickets!
17 August 2014
Recently I’ve read a few posts about other peoples working environments, office setups, man caves or work benches. I’ve also had a couple of people ask about mine, since I tweeted about the redecoration and overhaul of my old “spare room” as it transformed in to “Man Cave 2.0″. I had intended to write it up when it was finished anyway, although, even now, 9 months later, it is still not finished, I am begining to realise that it will never actually be finished but will evolve and morph over time.
So, this is a look at the overall design and some of the finer detail in to my Man Cave 2.0 as it stands in August 2014
So, obviously the PC is at the heart of things in here. Well, actually, the PC itself is tucked right away in the furthest corner under the desk as I hardly ever touch it. Instead, though, I have the power switch mounted just below the monitor screen shelf and have a selection of USB ports wired in to convenient locations.
Under the monitor shelf is some LED lighting – nothing too fancy, just white, along with an 8-way extension socket. I’ve not filled them all up simutaneously just yet… but I’m sure I will do one day! Under the desk itself is the same set up of LEDs and power sockets.
Above the shelf is the cable modem, router, external hard drive, speakers. That corner of the desk is just far enough out of reach that I wouldn’t want to use it for anything I need to get to regularly, but just close enough to reset a router or plug in a new cable on the occasions I need to.
The desk itself is HUGE! 2.4m by 1.2m at its widest, although most of it is 800mm deep due to the shaped cut-out that was flipped over to make the shelf. The key to it though is versatility. The centre section is multi-use, depending if I just need space to spread out, or add an Ikea breadboard for soldering or messy stuff, or add a cutting mat for more delicate things.
No good workbench is without a power supply. This one is a converted ATX PSU for 3v3, 5v, 12v, -12v, and USB power output too. Thanks to re-innovation for that.
Storage solutions help me fill this small room with just soooo much crap. Of course, Really Useful Boxes help with this storage!
A couple of Ikea units, a shelf, and what appears to be randomly placed drawers, boxes, cupboards and display booths are all within handy reach behind me. I’ve tried to keep similar things together and labelled, and so far that seems to be working well. Can you see the little HP Micro Server lurking there?
This is where new electronic projects are born. And old ones go to die. And unfinished ones go to sleep. There’s a good selection of components, PCBs, prototyping stuff
Every couple of years I need to update my Cisco certifications, and over the years I have managed to get myself quite a reasonable collection of hardware for building my own labs. Before the renovation I was limited to only a few devices per lab.
The old Toshiba Satellite laptop is about 15 years old, but still great for connecting in to the Cisco colsole ports and running a few basic applications. It is also the only machine I still have with a parallel port, so it’s still needed for my eprom programmer. I have a 12U floor standing rack on casters which holds all the heavier Cisco equipment…
And another 14U of rack framework built in to two support legs. When the wiring is complete there will be a 24 port patch panel in each one as well as one under the monitors so I will be able to connect anything to anything. It will also come in handy for keeping me warm in winter :-)
Oh, and no Man Cave would be complete without a Leggy Lampshade for providing optimal lighting just where it’s required!
For bigger, more mechinical stuff, there is still my garage, and that might feature in a blog post at a later date. Surfice to say, there’s most of the tools I need in there, but for anything else, Nottingham Hackspace is open 24/7!
15 August 2014
Wind speeds are very site-dependant - with topology, ground roughness and other factors affecting the local wind speed. Knowing the wind speed and frequency of the wind speed at a particular location allows us to make a more accurate resource assessment.
An accurate resource assessment is required for ensuring the wind turbines are sited correctly - in locations where they will generate the maximum energy.
This project was to develop a low-cost, low-power wind speed monitoring unit. This has mainly been developed for use in remote rural locations with a specific application to small wind turbines for international development projects.
Some of you may remember that last year , after a regretful decision to ‘upgrade’ from Windows 7 to Windows 8 I decided to jump ship and switch over to Linux. Ubuntu 13.04 to be precise. I blogged about the install process here, and my first thoughts after a week here, with the intention of regular posts whenever something goes really good or really bad.
So, it’s 14 months later, and basically things have gone pretty good. Sure, there’s some things that aren’t just how I like them with Windows, but other bits that just seem to work really well. In defence of my lax blogging, I’d just say that I got on and used the computer as I expected I would. I got tripped up a couple of times, but Google and AskUbuntu.com always seem to put me back on the right track.
I have expanded my Linux network too. I was donated an old netbook last year that now runs Ubuntu 13.04 for an hourly Twitter job. The plan had been to test it on the netbook then set up a Raspberry Pi to run it, but the netbook is surplus, capable, cheap to run and it works – so why change. I have also bought myself a little HP server which I put Ubuntu Server 13.10 on, along with OwnCloud. This works like DropBox, and synchronises files between my main PC, phone, tablet, work computer and is available to me (albeit slowly) anywhere on the internet.
All in all, things have been ticking over quite nicely. Life has been happy in Linux land… until recently!
I’ve been off work this week recovering from an operation. This has given me more spare time than I normally have, although it also limits how long I’ve been able to concentrate on things. I know that’s probably a bad combination, but, hey, lets go with what I’ve got!
So, a few days ago I thought it would be cool to “upgrade” to a retro looking terminal like this nice Swordfish90 one. Seems fairly straight forward, but I quickly came in to troubles when some of the required packages were unavailable or were untrusted. Lots of 404 errors. Oh well, just one of those things that looks easy on the internet but is actually more involved. Never mind, it would have been nice, but isn’t really required.
Later, I SSH’d on to the netbook and noticed that it said there were security updates to be applied and a new distro was available. I didn’t really want to upgrade the whole distro, but would feel happier knowing the security stuff has been applied. Sadly, I was unable to install the security patches as the same 404 errors were occurring. Ok, maybe it’s time to upgrade the distro then. This actually went very smoothly. “do-release-upgrade” quite happily took me from Ubuntu 13.04 to 13.10, and after a reboot, it tells me there is another new distro – 14.04 – that I can upgrade to. Yeah, well, in for a penny, in for a pound. I run that and all seems good.
Well, it seemed good. The hourly task was still running. For a while. A reboot got it going again. The following day I woke up to find that my broadband was down, so it had missed a few more of these tasks. Can’t blame the upgrade for that though. A restart got it back online, and in the last couple of days it has only missed a couple or so tasks – compared to missing none for the previous 4 months. Seems like too much of a coincidence, but I suspect there’s something in the upgrade that didn’t go too smoothly.
I guess the OwnCloud server should really be running the latest release of Ubuntu too, so last night I did a “do-release-upgrade” on that machine. This was already running 13.10 so only 1 upgrade was needed and this went really well. The only problem was that afterwards OwnCloud wasn’t running. Seeing how this is the whole raison d’etre for this machine this was a bit of an issue. It seems like the upgrade overwrote the Apache config files that tell it where the OwnCloud web pages are served from. Random poking about and looking at files made me appreciate just how little I understand about what makes this box tick. My data was still there though, so eventually I decided to download and install the latest release of OwnCloud. Something clever in it realised an older version was already installed, so it asked if I wanted to upgrade, I said yes, and suddenly everything works just as it did before! Hurrah!
So, this just leaves my desktop PC running Ubuntu 13.04. When I installed this last year it was the latest release and all was good. I could have installed an older version, 12.04, at the time which had come out a year earlier, but had Long Term Support (LTS). I didn’t appreciate the difference at the time between a LTS release and a non-LTS release, but this has been hammered home to me in the last couple of days. My version, 13.04, was released in April 2013 (see how the version numbers work now?), and had 9 months support. In October, another non-LTS release, 13.10 came out, which I should have upgraded to between October and January. Then, after the LTS release 14.04 came out, I would have had 2 months to upgrade to that. This page shows the Ubuntu releases quite nicely
But I didn’t. I have missed 2 upgrade cycles, and upgrading isn’t looking like a viable option for me right now. I certainly can’t run the upgrade online as all of the repositories are unavailable. I could download and burn myself a 13.10 DVD which I think will give me the upgrade option, and then do the same for 14.04 – However, with my experiences so far on the other 2 machines (which only have 1 task each), I worry about breaking 14 months worth of getting this computer to just the way I like it.
Probably the sensible option is to back up all my stuff and do a clean install to 14.04. Copy back all my data and reinstall all the programs I’ve got used to. But I know that adjusting to a “new” computer can be a slow and painful experience, and I doubt I’ll be able to find half the stuff again.
If I’m doing a complete reinstall, there’s a strong temptation to go back to Windows 7. Life seemed simple then, and I knew what I was doing.
Alternatively, I procrastinate, put off the inevitable, and carry on with 13.04. It works, and pretty much does what I want. Ok, I would like to add a pdf printer and a cool retro looking terminal program, but without the repositories being available that isn’t something I can do. Over time this is going to become more and more of a problem.
Hmmm… to be continued
14 August 2014
Every year people build amazing things and install them all over the site. Here’s a rundown of some of the projects coming to EMF this year.
Behind the bar you’ll find a robotic barman in the form of an ex-laboratory robot arm mounted on a mobility scooter. It’ll try and serve you drinks, but we can’t promise it won’t throw them at you instead.
A Tune On A Stick
Somewhere on-site you’ll find a lighthouse-like structure making strange noises. It plays a tune while spinning around - what it plays depends on who is nearby. Find some friends and try standing around it in a circle.
Giant Pixel Sign
A giant interactive sign made up of 900 RGB LEDS controllable from your web browser, lurking somewhere in the dark. Upload your own artwork, or your favourite gif!
Desperate for some Club Mate but don’t want to move? Call the Robobutler! He’ll trundle across the site and deliver you a tasty beverage, hopefully without destroying tents in his rush to do your bidding.
A large forest of radiant “trees”. As you move through the·grid it senses your presence and initiates a ripple of light & clicks, however it will be used in several ways - expect a multiplayer maze amongst other things!
Giant Ride-on Duck
The folks from Tog in Dublin have built a giant duck you can drive around. We don’t know why, but we want a go anyway. https://vine.co/v/M0rAKu2TllX
This giant arrow will spend all weekend tirelessly pointing at the current location of the International Space Station. Unfortunately there will be no visible ISS passes during EMF, so (time permitting) an interface is planned to allow pointing at other astronomical points of interest.
The buggy that almost self-destructed hauling things around EMF in 2012 has been repaired and is better than ever, with a new trailer for hauling your equipment around and a smattering of ridiculous addons. Internet-connected golf cart anyone?
Back by popular demand the retro gaming tent has ballooned in size! Expect to find full-size arcade cabinets, pinball, and every retro console you can think of.
Adding to our list of autonomous vehicles is BigHak, a giant ridable version of the Big Trak toy you may have had as a child. Either drive it manually, or program it Big Trak-style with the accompanying phone app - we have a prize for the first person to successfully program it to navigate to the bar from their tent!
Somewhere in the Nottinghack village you’ll find a two meter long automatic bar. Choose a drink from the menu, insert a glass at one end and get a cocktail down the other - even down to the tiny umbrella and slice of lemon. https://www.youtube.com/watch?v=5t8FkHKf_Bs
Balloons floating high above the site listen for noise and tell one another how loud it is. As the pings move between them they pulse with colour, lighting up colourfully in waves across the site.
In 2012 we had a giant hammock made from fishing nets - in 2014 we’ll have an even bigger one!
24 kites mounted on a long cable - once the wind gets up the arch takes off! As the weekend progresses they’ll be being decorated as an ongoing workshop.
The LHS Bikeshed
The LHS Bikeshed is a 3 player starship disaster simulator in a caravan. Players are trained to fly the ship and then given a short scenario that inevitably ends up with them being exploded, burned, suffocated or smeared across the surface of a planet. Find three friends and set off into the galaxy!
An amazing sea of fish that respond to touch. Individual fish light up and move, before spreading colour, light and motion through the entire SHOAL. The fish tell their friends what’s happening and a motor means all the fish can swim in the same direction, or turn to face someone who has come to play!
Pacman! On a Sphere!
A version of Pacman that is played on an actual real-world sphere. The pac-man player must run around the projected sphere trying to find all the pills, whilst up to another four players play the ghosts trying to hunt him down!
The Nuclear Poker Bunker
A half-size Hexayurt Quad Dome, within which people play Nuclear Poker, a card game designed to teach Generals too young to remember the Cold War about Mutually Assured Destruction.
A chance to sit out in the night air and quietly enjoy flickering images from the past. A small antique box contains a projector filled with silent films from Archive.org - sit, be calm, and watch films for as long as you like.
Two pedal power generators powering a small sound system, a bubble machine and LED lights in the evening. Get some exercise!
Hidden in the villages is a large umbrella adorned with meteorological equipment, generating a weather-related soundscape and light show for those standing underneath.
The Marvellous Booze Fogger
A device for the turning of alcoholic spirits into the most inhalable of mists, pleasing to the tongue and satisfying to the mind. A very certain panacea for the ills of the soul and a solution for those tired of the sorrows and trials of day to day living. It is most shiny: http://imgur.com/a/kWPU4
Are you bringing an amazing project to EMF this year? Let us know! firstname.lastname@example.org
So, um, I’m doing the Kinematocinegraph. I’ve done a lot of work on the recipes for Cocktail Barbot. And I’ve been there for the Marvellous Booze Fogger.
I’m not saying that EMF Camp is going to be awesome, but it is TOTALLY GOING TO BE AWESOME.
12 August 2014
I saw these HyperQBS from Geobender.com and thought they were very cool so I decided to make one. A 3D model was made, flattened using Pepakura and Laser cut for quick assembly, then it was glued and taped to turn it into a hexaflexagon thingy, I even wrote an instructable about it if you'd like to make your own.
11 August 2014
I’d love to be a history blogger, or even just an infrastructure blogger I’m endlessly interested in the story of Continue reading
I was asked to propose a few ideas for group projects on the product design and manufacturing engineering course at Nottingham University.
I proposed a few projects and two of them were taken on by small groups. These projects have been designed and built over the course of a year and I went to see the end results at the end of year show.
There were two projects taken on: a portable pedal generator and a traveling work station.
Here are some photos and details of the final projects. A big thanks to the eight students involved in these projects.
I've been messing around with some 32 x 8 LED displays - as I have been wanting to create graphics. These LED displays are from Sure Electronics are available for around $13 and use the HT1632 LED driver IC, with an SPI-like control.
I have designed a new circuit board which plugs directly onto the back of these displays and contains a ATMEGA328 with the Arduino bootloader, a real time clock, a temperature sensor and a couple of input switches.
The notes here show the device in action and how I created some bespoke graphics for the displays.
Here is a post about what you can do in an afternoon or two with a whole load of electronics stuff lying around.
It is designed to fit in to those 150W halogen light holders and I had managed to find one of those as well.
I wanted to do something fun with it so decided to make a wirelessly controlled LED lamp which can be used to change the room ambiance, or to signify some form of data (anything from room temperature to number of emails to read).
10 August 2014
08 August 2014
Introduction For a Nottingham Hackspace project, I was asked if I could measure the RPM of a motor. “Sure!”, I said. What was really needed was quickly bodging together a beam-break circuit and connecting it to an oscilloscope. This would … Continue reading
06 August 2014
While the main body is a breeze to work out, the border has some slight editing problems, because the written instructions don’t match up with the charted instructions which don’t match up with the chart key. But once you figure it all out, it is awfully lovely.
I’m delighted with it, but I have some weird issues with giant loops appearing on the wrong side on occasion - I can only think that I need to sort out my tension something fierce.
BarBot passed a milestone today, making its first mix drink. I define this as fluids from more than one type of dispenser: optic and pressure tap system. Garnish dispensers were also used in the recipe, stirring and adding a delicious eraser and wooden lemon slice simulation disc.
As can be seen in the video, the firmware is being operated manually – individual commands like move to dispenser 6 [G8] and dispense from tap number 2 [MD2] are typed into a serial console and interpretted by the test firmware running on an Arduino Mega 2560. In the finished system such commands will be generated by a Raspberry Pi which runs the database / admin / ordering software and sent to the Arduino by serial.
Things are on track for an interesting public debut on the 16th August when we’re doing a fundraising event at Nottinghack (18:00 – 21:00). Money raised will go towards buying ingredients for EMF Camp where we plan to give away 200 cocktails for participants.
05 August 2014
Lasercut servo arms, now nearly all made up (still waiting for delivery of one more servo). Three of the servos are connected to the optics in this video.
04 August 2014
I was recently commissioned to make a large version of my photo frame tree, and this was indeed significantly larger. This tree features 8x 6"x4" photo frames and 1x 12"x8" photo frame The backing tree was 9mm thick and cut on the large laser cutter at Nottingham Hackspace (I can't wait till my new big laser arrives, currently docking in Felixstowe). The individual leaves were made from 1.5mm thick walnut. The custom engraving on the trunk features the customers initials and the date they met, the frame was made for their 5th (wooden) wedding anniversary
The whole tree measures 900m tall and 1000mm wide, which makes it the largest thing I've ever posted and boy didn't the post office love me that day.
I guess this is kind of a follow up to my Retro Challenge posts, as it was thoughts that stemmed from teaching myself Assembly Language for my Z80 project. Essentially it is a comparison between programming in the 70′s and today against building with Lego in the 70s and today.
But before I get stuck in, can you identify this famous TV family from a few crude Lego bricks?
Yes, it is, of course The Simpsons. And whilst I take issue at the range of colours used (two shades of blue? And green? We never had green Lego bricks when I was growing up. Now get off my lawn!), this simple representation and a little bit of imagination represents the cartoon family pretty well. Although in the early days there was more of a range of brick shapes and sizes, and even generic people, this could have been built back in the day – before The Simpsons was born.
Anyway, jump forward to 2014, and what does The Simpsons look like when modelled in the medium of Lego?
Yup, they’re all there in their yellowie goodness, complete with bulging eyes, shorts, skirt, tie, bouffont hair and dummy. Pretty hard to imagine they could be anyone else!
So, I see this as basically the difference between programming in assembly language and modern languages like .net or Java. I should, however, point out at this stage that I am not a programmer, and cannot program in .net or Java myself, although I do dabble a bit with the Arduino flavour of C++
The Z80 has very few instructions which can be summed up in couple of dozen 2 or 3 letter mnemonics, such as LD, RLR, JP or INC. My LED Matrix program only used 12 different mnemonics. So, consider this as your original Lego blocks. 2×4, 2×2, 6×1 or 4x8flat. With a very limited set of instructions or bricks, it was possible to make amazingly complex creations. However, if you used those brickstructions creatively, and used enough of them, it was possible to come up with amazing creations. Sure, the resolution was low, so you had to build your dragon really huge so you could see any detail, and maybe you had to rely a bit on the users imagination, but amazing things could be built. Such things as a single command to multiply by 5 wasn’t possible, and neither was curved bricks to build round structures.
During the 80ss and 90′s, computers got slicker and faster, and when I wrote my first program in 1982 I used BASIC, which compared to Assembly Language was pretty, well, basic! Likewise the Lego sets got better too, so my spaceships had radar dishes and control panels, and I wasn’t limited to just red, white, blue and yellow bricks (which, in hindsight, was awful spaceship colours!)
These days, if I want to build a Lego castle, I simply buy the Harry Potter set and build myself Hogwarts. If I want to get my Arduino to talk to a LED matrix, I call the LED matrix library and tell it want I want to say. I can build a spaceship that looks just like Millennium Falcon or I can call a Java script that fetches SQL data and draws it as a pretty pie chart in whatever colour theme I choose.
Now, I’m not saying that progress is a bad thing. I know that if I was still 12 years old and was offered an official Star Wars branded Lego X-Wing fighter to play with versus the Lego spaceships I built in 1983, I’m totally sure I would go with the one that actually included R2D2. Likewise, I am currently working on an Arduino and LCD project at work, so do you think I am crafting the code for this from one layer above 1′s and 0′s? Hell no, I’m calling a library, telling it the screen size and what text I want placed where. Job done.
80s command line display vs modern gui display
I do think it is important though to appreciate where things started though, and appreciate how far we have come. And, although the libraries are there for the complex and tedious jobs, and the kits are there to let you build the set from The Lego Movie, it is still possible to take things down to a much more fundamental level. With a bit of practice, hard work, some creativity and squinting a bit, you can still build whatever your imagination can dream up!
03 August 2014
In a lot of electronic audio circuits the response is controlled by a variable resistor rather than a control voltage (CV). If you want to adapt these circuits to use in a modular configuration then you often feel it would be nice to replace or augment the variable resistor with a control voltage input. In some cases this can be quite easy – the variable resistor might just be set up as a voltage divider between two DC levels and effectively the output of the wiper is a control voltage. However it is often the case that the variable resistor is actually manipulating a waveform inside the circuit. For example, in a lot of filter designs the resonance level works on a variable resistance controlling the amount of positive feedback from the output to the input and this isn’t easily replaced with a control voltage.
I recently got this question from the web:
I want to add external CV [control voltage] control to an existing circuit. It’s to control the resonance of a filter where there’s already a pot to do this manually. My first idea was to use a vactrol and run the resistance from that in sequence with the pot with the pot then acting as an offset whenever there’s CV applied. However there’s a few things I’m struggling with.
1) It’s always only going to be a positive offset, even if you feed a bipolar signal to the CV, being that the vactrol can’t output negative resistance
2) What’s the strategy for managing current limits going to the vactrol? I’m familiar with *reducing* current via resistance but what if you don’t actually know what the current is going to be? How do you bring it within a usable range?
3) The big question: is this the best way to achieve the original aim? Any other suggestions?
This question nicely captures the classic problems in this situation – there isn’t an easy general purpose way of changing a control voltage in to a variable resistance. The simplest approach, as suggested here, is to use a vactrol. For those not familiar with the term a vactrol is a light pointing at a light dependent resistor in a sealed unit. By connecting the control voltage to the light you generate a variable resistance that depends on the control voltage while keeping the control voltage electrically isolated from the resistance.
Vactrols are easy to use but have lots of limitations – they don’t have a well defined relationship between the CV and the resistance and the range of resistance values achieved may not match what you want in your application. Generally they also have quite slow response. There isn’t much you can do about these limitations. Some kind of preprocessing of the CV might help set the range of resistances achieved to better meet your needs. You will also want to introduce the light dependent resistor in to the circuit with some kind of additional adjustment (perhaps the existing control) to set the control-point it is working around. For example, to get a bipolar response (Q1 above) you can add a DC offset to the CV so that the bipolar signal becomes an alternating positive signal and then set the adjusting resistor to position the range of the output to be that you are interested in. You can try putting the vactrol in series with the adjusting resistor instead of in parallel.
As far as I know most vactrols will go down close to 0 Ohms resistance when the controlling light is fully-on. This gives you the lower bound for the resistance, and hence upper bound for the in-circuit current. As just about all variable resistors also go to 0 Ohms you can pretty much add a vactrol in series or parallel with an existing variable resistor from the point of view of the minimum resistance (Q2). If you don’t want the vactrol to drop to 0 Ohms put a resistor in series with it, or manipulate the CV to limit how large the signal feeding the vactrol’s lamp gets.
As for Q3 – no, sorry there isn’t a general way of replacing resistance-driven circuits with CVs. There are various circuits that are called voltage-to-resistance converters (eg see the LM13700 datasheet) but in reality these have complicated limitations on how they can be used and don’t fully isolate the CV from the rest of the circuit. Unless you know a lot about how the circuit you are modifying works and fully understand the limitations it is hard to retrospectively introduce these in to an existing design that uses a mechanical variable resistor. If you *really* want a solution you could have a servo-motor turning a mechanical variable resistor – I can remember a few hi-fi buff friendly amps that used this approach.
Normally though the best you can do is to experiment with different ways of using a vactrol and learn to love their limitations. Any technical defects are called “character” and in classic audio equipment people pay good money for them!
Testing the platform and new control box… in the dark… because it’s pretty.
02 August 2014
It's inevitable when you're working with wood that a few of the sheets are going to end up warped. I thought I would share a few of my tips for working with slightly warped wood while still getting good cuts from the laser. Magnets.
This is it really, magnets are the key to success, plonk them down all over the work piece and that will hold the wood flat while you cut. The magnets cling to the honeycomb underneath and a decent stack of neodymiums can pull 9mm sheets back onto the table.
When the wood is bowed, arrange it so that the centre of the wood is lifted off the table. Magnets placed right in the middle of the bow will pull it flat to the honeycomb. When placed the other way up you have to balance the magnets on either side of the work piece and you can get a 'see saw' effect if the bow is too severe.
The trick to placing magnets in the middle of the work is figuring out where to put them so that they aren't cut by the laser. My trick for this is to draw a few circles on the wood right at the very start of the process, pause the machine, then move the magnets onto the circles. This way you know that the magnets will not be under the laser beam at any point.
01 August 2014
31 July 2014
Here we see some photos of BarBot assembled with the various dispensers in place. The [mono]rail for the platform has been attached, and the platform [monorail car?] has been powered up to show the pretty lights.
There’s still a huge amount to do to get it working, but seeing everything in place really makes it feel real. This coming weekend the team plan to do some serious hacking to mount the dispensers, arrange wiring and such. With a bit of luck we’ll have a functional BarBot for the fundraiser party in the 16th of August (6-9pm at Nottinghack).
Wow! What an awesome month July has been. The whole Retro Challenge thing has been great, and despite moments of stress or despair, I have thoroughly enjoyed taking part and seeing what everyone else has been up to. Before I sum up my project, I should make a few honourable mentions.
Retro Challenge – A huge thanks to Mark and Wgoodf do a great job in hosting this twice a year. Keeping everyone updated via Twitter has worked really well. Cheers guys!
Grant Searle is responsible for the general Z80 design I used and also converted MS BASIC from the Nascom to run on this. Really, this project is a test of my understanding of Grants work and seeing how far I can take things.
Nottingham Hackspace has an amazing “parts bin” that included the LEDs, Veroboard, case, some of the logic chips and the RAM I used.
OSHPark did a great job (for a very good price!) on the PCBs – even if the postal system did keep me on the edge of my seat for a bit!
Chris Gammell introductions to KiCad PCB design videos were critical in guiding me through the various stages of board design.
Rodney Zaks book Programming the Z80 has been like a bible for me. Combined with a few dozen other resources of Z80 info on line I’ve been able to at least get the basics assembly language programming.
CLRHome is a great online Z80 IDE that can compile assembly language in a variety of output formats including for the ZX Spectrum. I doubt I could have managed this in notepad!
All of the other Retro Challenge entrants deserve a mention too, but there’s a few that really caught my eye and taught me stuff about their particular approach to RC2014, such as Wgoodf – Turtles all the way down, Ians restoration of Northstar Horizon, Tezzas restoration and programming of Challenger 4P, John finishing work on Fahrfall
I have shared the PCB design files on OSHPark, so if you want to build your own Z80 computer but don’t want to get involved in the PCB design side, you just need to click Add To Cart and the boards will pop through your letterbox soon. I think all the component info and other details you need are there, but if you do decide to build your own, please let me know. I’d love to see other people using the RC2014!
I cannot get my head around Github, so, for now, the design files and source code are not up there. If I can get Github to do what I expect it to do any time soon I’ll upload the files. In the mean time though, I am going to print the schematics, BOMs and PCB layouts as pdf files for those of you that want to take a look. Feel free to drop me a line if you want the actual KiCad files or if there’s anything I can help you with.
As for the Z80 assembler code, here’s an abridged version (The full ASCII stuff was posted here a couple of weeks ago, and makes for a very long tedious lising!). As I have said before, I am not a programmer, so I know that this is not pretty code. It is not efficient code. It is not easy to read code. It does, however, do what I needed it to do, so that’s fine by me :-)
#define DECODED $9000 #define DEC2 $9001 #define DEC3 $9002 #define DEC4 $9003 #define DEC5 $9004 #define WRKSPC $8045 .org $0000 NOP NOP di ;disable intrupts. NOP NOP NOP ld hl,WRKSPC ld sp,hl ;set stack pointer to 0x8045 ;clear led matrix ld a,255 out (0),a ld a,0 out (1),a out (2),a out (3),a out (4),a out (5),a ld a,49 out (129),a ;Fill display memory - 1st character ld b,0 ld c,8 ld ix,STRING ld a,(ix+0) sub 32 ld hl,0 ld l,a add hl,hl ;2 x string(b) add hl,hl ;4 x string(b) add hl,hl ;8 x string(b) ld de,ASCII add hl,de ; hl now points to ASCII +( 8 x (STRING+b)) ld de,DECODED Loops80: ld a,(hl) ;load A with line from ASCII ld (de),a ;DECODED now contains line of stuff inc de inc de inc de inc de inc de ;added 5 to DECODED address inc hl ;increment to next line of ASCII dec c jp nz,Loops80 ; repeat for next 7 lines ;This bit of code is copied & pasted 5 times for each character, but with an incrementing "ld a,(ix+0) and the loops80: For brevity I've omitted them here ;5th character ld c,8 ld ix,STRING ld a,(ix+4) sub 32 ld hl,0 ld l,a add hl,hl ;2 x string(b) add hl,hl ;4 x string(b) add hl,hl ;8 x string(b) ld de,ASCII add hl,de ; hl now points to ASCII + 8 x (STRING+b) ld de,DEC5 Loops84: ld a,(hl) ld (de),a ;decoded now contains line of stuff inc de inc de inc de inc de inc de ;added 5 to decode address inc hl dec c jp nz,Loops84 ;Main Loop START: ld hl,DECODED ld a,127 ;start x with $01111111 ld b,8 ROWLOOP: out (0),a ld c,5 COLLOOP: ld d,(hl) out (c),d inc hl dec c jp nz,COLLOOP ;repeat this loop 5 times call DELAY rrca ;move to next row <<10111111<<<11011111<<etc dec b jp nz,ROWLOOP ;repeat this loop 8 times jp START DELAY: push hl ;save hl and af registers push af ld hl,1000 DELLOOP: dec l jp nz,DELLOOP ;countdown l from 255 to 0 dec h jp nz,DELLOOP ;countdown h from 16 to 0 ;clear led matrix ld a,255 out (0),a ld a,0 out (1),a out (2),a out (3),a out (4),a out (5),a pop af ;restore hl and af registers pop hl ret STRING: .db "SOwen" ;this is the text to be displayed ASCII: ;these ascii characters were taken from ZX Spectrum ROM ; $20 - Character: ' ' CHR$(32) .defb %00000000 .defb %00000000 ;See previous post for full ascii listing
Thanks to everyone that has been keeping up with this project and encouraging me along the way. There’s still a lot that I want to do with the RC2014 computer, but I’m sure a lot of that can wait until the Winter Challenge!
30 July 2014
With over 24 hours to go before the end of July deadline the final piece of the puzzle fell in to place!
But, first, a quick catchup from the last blog post;
On Sunday I successfully burned BASIC to a couple of 8k slots on a 64k EEPROM, and that worked great. So, on Monday, I figured there was no more putting it off, I had to finish my Assembler Code program and give it a go. So, I removed the Spectrum specific bits that I’d used to debug it, added bits specific to my hardware and wrote the actual display code loop. Then burned it to the EEPROM, held my breath and plugged it in….
This left me with a dilemma. Apart from the LED matrix, how could I debug code on a Z80 that had no form of input or output? Then I realised the serial port must have an address. So I hunted through the source code and found stuff being sent to port 0×81 (129). So I added a few OUT (129),a commands and tried again. Nope. Still nothing. Ahhh… I hadn’t initialised the stack pointer. Ok, do that and try again… No. Still nothing. Check BASIC still works. Yup, that’s fine. My code? No, nothing.
Then I swapped between BASIC and my code with the jumpers without turning it off. After hitting reset the serial port spewed out a load of .Owen# all over the screen! So, my code was doing something.
Finally today I noticed a huge glaring mistake. I was JUMPing out of the main loop to a delay subroutine when I should have CALLed it. Doh! I made the change, burned the code to EPROM, fired it up and… BINGO! It worked!
Well, it was mirrored, but otherwise it worked! My name was written in LEDs being driven by a Z80 based computer I built myself from scratch running my own code written in Assembly Language. That, I believe, is challenge complete!
Well, almost complete. Tomorrow I will write a closing blog, as well as publish the code, schematics, PCB layouts on GitHub and share the PCB files on OSHPark so that everyone else can play along at home.
29 July 2014
I tried to make make some cube shaped pumpkins last year but I built the box too large and it never really worked out. I've recut the box again this year using last years box and I got to my pumpkin a lot sooner. It's already developed flat spots on all 6 sides and I'm hoping it will grow out into the corners of the box soon too.
It'll add to our now 'freakish' collection of garden plants such as our 9ft tall sunflower and it's (now) 14 headed, 8ft tall neighbour, and our marrow sized courgettes.
28 July 2014
I have a new and awesome supplier of poplar plywood. I'm so pleased with the quality and standard that I actually feel guilty that I didn't write the post 2 weeks ago when I first got the goods. My new preferred supplier for poplar plywood, mdf and birch plywood is Kitronik. For the longest time now I've been looking for a supplier who actually acknowledges that laser plywood comes in types and that the standard of the wood actually matters and Kitronik were actually listening.
As soon as I received my order I was pleasantly surprised. The wood came in a sturdy cardboard box sealed and taped neatly rather than the usual ensemble of salvaged cardboard wrapped loosely around sheets of wood. The sheets didn't quite fill the box so air bags were used to fill the voids and ensure no damage would occur during transit. Each sheet is clearly marked with a sticker to say exactly what material it is and what thickness. This is such a simple idea, I have a whole rack of wood sheets and I don't really know where is came from which makes it hard to reorder the nice things.
For quite some time I've been working toward installing my car pc setup with custom software, but it never seems like I have the time to finish actually getting it into the car.
Recently I realised that I could achieve a pretty good stop-gap setup by using a Chromecast paired with my Android phone. So I set about getting this in the car, with the aim of replacing it once I get time to install the PC.
The parts I've used for this install are as follows, with approximate prices:
- Double DIN touchscreen (£85)
- HDMI splitter (£5)
- Chromecast (£35)
- Fiesta MK6 Double DIN converter (£20)
The total installation cost was around £145, most of which was on the screen.
At first I made the assumption that the stereo in my MK6 fiesta was double-din. This turned out to be a faulty assumption and the screen was far too small.
So I had to find a kit online which would let me put the double-din sized screen into the dashboard.
When the kit arrived I gave the system a quick test in the house to make sure it was all working.
Since the Chromecast is HDMI and the screen I have has no audio-out, I got the HDMI splitter (white device in the image). It has a HDMI input, with seperate audio and DVI outputs. That let me use the screen but direct audio to the car speakers.
Fitting the screen into the dashboard was the part I had been dreading the most. Pulling the centre console forward is a bit of a hastle on this car and I've already had to do it a few times.
There are some screws under the glove box, so the glove box has to be removed to get at them.
The next set of screws are behind the steering column surround so that has to go as well.
And finally after taking out even more screws and disconnecting the air conditiong controls, the console pulls forward.
Fitting the screen was as simple as putting it into place and threading the cables through the left side near to the glove box. The outer frame just hides the nasty looking space where the din cage meets the dashboard.
The screen is currently wired directly to the cigarette lighter. Once the distribution block is in properly the screen will get power from there. Chromecast is getting power from the existing USB port, but again it will draw from the distro block in future.
I did obtain a TL-WR702N in order to have a wireless network in the car, however the Chromecast needs to have an internet connection during startup in order to function properly. That meant I had to use wifi tether to my Android phone instead. I don't have a decent solution to this yet, other than a 4G router.
With the parts installed and powered, there was nothing left to do but test it out.
This screen is a good sign because it means that the Chromecast has passed the point where it needs internet connection.
First test was to cast Momentum from a Chrome tab on my Macbook.
Next was getting media working. Plex was able to stream to the screen from a local source no problem.
So was casting the Spotify web player.
From the Android device, I gave screen casting a try. I only had one device with me, so sorry for the screen-ception.
Youtube also worked well.
And last but not least, web browsing.
All together this probably took me two hours to install. A nice quick weekend project which should tide me over for media in the car until the full PC installation is ready to go in.
27 July 2014
Despite a late start today, things have gone well so I actually feel like I’m ahead of the game right now. Certainly not finished, but with most of the major hurdles now behind me, the only thing left is writing a bit of Z80 assembler code. And even that is starting to look manageable.
I started off by throwing a load of capacitors at the matrix board. If it was a power issue, then this would likely help… and, would you believe it, it did! I redid the test that was giving me odd results yesterday with 3 matrices and got exactly what I expected to see! (Well, actually, I got what I should have seen. I actually expected it to still behave oddly).
So, I added the other 2 matrices and they worked too. Then they didn’t. Then they did. The ‘not working’ had all the hallmarks of a short circuit between one of the X axis and one of the Y axis. So, I pulled out all the displays and had a poke about…
Can you spot a short circuit in there?
I poked about and generally freed up all the wires, put the displays back testing them one by one, and it seems to work fine. So, as long as I don’t breath too hard, I think that gremlin will be kept at bay.
Using BASIC I ran a few more tests, and it would appear that I did get the X and Y axis wired up wrongly. Oh well, it just means I will have to write my name as
instead. Yeah, sure, I could go through and rotate all the ASCII character encodings by 90 degrees, but do you really think I’ll bother to do that? Well, we’ll see…
I also fired up my EPROM programmer and did a test on a 64k EEPROM that I designed one of the other boards for. [This needs a computer with a real parallel port, so my Toshiba Satellite Pro 4600 running Windows 2000 keeps me well within the Retro Challenge guidelines!]
The 64k is divided up in to 8 banks of 8k by 3 jumpers. These jumpers set the A13, A14 & A15 lines either high or low. I have tested this by burning a copy of MS BASIC to the EEPROM at an offset of 0×2000 and then again at 0×4000, and these work fine with the appropriate jumpers connected. And there’s still 6 more slots left on this chip before I need to erase it!
So, tomorrow, I’ve got no more excuses, it’s time to crack on with the Z80 assembler code. It should be reasonably straight forward… but I just know there’s going to be something to catch me out.
A leather working friend asked me if I would engrave some items for him. I merely added the lettering to these wonderful things the rest of the patterns were all added manually after they left me. I have some very talented friends and I'm pleased to help them where I can even if it means cutting stinky leather for them.
Designed originally as a kippah clip to hold your yarmulke in place, the Leatherdos (portmanteau of Leatherman and dos, meaning religious) was designed by Yaacov Goldberg as the natural progression of all the things men have done with their kippah clip over the years.
It’s now being sold as a hair clip as well as a kippah clip, and it has on it:
- Shopping trolley coin
- Screwdriver for Phillips heads
- Small screwdriver
- Large screwdriver
- Cutting edge
- 8mm wrench
It’s currently at Animi Causa for $9.99.
(Seen at Gizmodo.)
26 July 2014
So, exactly 3 weeks after they were ordered, the PCBs from OSHPark arrived today. It’s just as well, as I was running low on things to do without them, and with just 6 days left of the Retro Challenge I would have struggled to finish in time.
Well, that’s my weekend planned out for me now!
I think I’ve mentioned it already, but OSHPark manufacture boards in multiples of 3. Even though I only need one of each board, the price is better than anywhere else even for a single board. It also means if I have messed up and need to cut tracks or have variations to swap in then I’m covered.
Almost straight away I noticed my first mistake. When I created the ‘connector’ part, I didn’t change the default hole size. So although it’s fine for wire components or chip legs, the thicker pins on the 0.1″ headers were just too tight. Eventually, with some subtle persuading they went in. I’m sure I could have left them unsoldered without any effect!
So, bit by bit I assembled the boards for the CPU, the eprom (for BASIC), the eprom (for my machine code), RAM (incorrectly screen printed with ROM on), serial I/O and clock/reset.
I had a nerve-biting start when I plugged in just the clock and the Blinkenlights and found it wasn’t giving out a clock signal. Closer inspection showed that I’d plugged the board in 1 pin to the right of where it should be! After reseating it correctly the clock was there.
So, in with the other boards. Initially, I got nothing. One by one I started to take the boards out and test without them. As I pulled the eprom board out I almost burned my fingers on the little logic chip on there. It turns out they can give off a lot of heat when plugged in the wrong way around! Who knew! One of the other casualties of this was the CPU. After changing the fried chip and CPU for known good ones… it bloody well worked!
Using PUTTY through a FTDI cable I can connect to it and run BASIC. This way I can check all the hardware is doing what I expect it to do and that when I come to run my assembler code on it I can be sure it’s the code not working rather than the hardware.
I tried out the LED matrix board through the adapter I made on Tursday, and, although it sort of worked (some lights came on), it didn’t behave as I would expect. There’s still a little bit of doubt over the orientation of the displays, so top left might be bottom left, or one dot in top right might be 7 dots up the right side except for the top one. So I still have to ‘map’ the display yet.
However, it is not behaving rationally. I ran a BASIC program that I would expect to light each pixel sequentially on each of the 8×8 matrices simultaneously. This is what I got;
I am suspecting a power issue, but I’ve not yet ruled out a short or bad wiring, or even faulty chips. I guess this will keep me busy tomorrow
24 July 2014
Just a little update as I’ve only done a little bit of work on the Z80 this evening;
The LED matrix board now plugs in to my Z80 backplane!
Sadly, the rainbow coloured ribbon cable you saw in the photo a couple of days ago was 14 way. So although it looked much nicer, I would have had to drop one of the data lines and the IRQ line to use it. (It was tempting though!).
Still no delivery from OSHPark though. Now only got a week left to fill all those empty slots on the backplane!
Word of mouth filtered back some pretty exciting news for me this evening, my marble machine that was picked up by Solarbotics two months ago has now found it's way over to the Maker shed and I received a very complimentary write up in the weekly newsletter. It's a pretty big goal for me and I'm stoked, means the whole journey has been pretty worthwhile.
Makes me want to push on with my other projects now, these little victories are very encouraging. Hopefully see some of you at Manchester Maker Faire this weekend. I'll try to remember to bring my copy of this kit with solar engine.
23 July 2014
Sorry I’ve not made any updates for a couple of days, but there’s not been much of significance to report of late. Until today, that is. Although, as far as the PCBs I’m waiting for are concerned, the only news to report there is that there is no news to report. I will report tomorrow if there is news to report on this or not.
I have, however, been plodding away at teaching myself Z80 assembler language. And with some progress too! I’ve managed to pass the first major milestone with the code I’m writing to display text on the LED matrix displays! It basically, looks at some text stored in a memory location, then looks up each character in turn on the ASCII character map that I lifted from a ZX Spectrum ROM, and puts each line in every 5th byte in a different location. This new location is essentially a 40 byte screen map for the matrix
Now, I realise that this might not look like much to the untrained eye, but if you take the hex data from 0×7000 to 0×7028, convert it to 8 lines of binary, and squint at it, you will be able to read “SOwen”! Pretty cool, huh?
Now, I think I have mentioned before, but I am not a programmer. So, to me, this is pretty amazing. Although, I realise it’s trivial to a lot of people, and I know my code is not pretty, or efficient, or well written…. but it does what I want it to do, and that’s good enough for me :-)
This part of the code will run just once when the computer is first turned on. The next part will simply read each location in turn and write it out to the appropriate LED, and repeat continuously. Unless I decided to try something fancy like scroll it, or… nah, just display it will be fine!
22 July 2014
Vale LRP has rather nice phys reps for their resources. I got fed up of throwing these test tubes full of powder into my storage box, knocking the corks out and being left with piles of funny coloured sand staining everything else in the box so I made these racks to hold the tubes securely and vertically. While I was doing one for powders I also did one for the resins too. I quickly discovered that I end up with a lot more than 25 of each resources over the course of an event so I'll be remaking them larger soon.
21 July 2014
20 July 2014
The 5 matrix board has now been finished. And no one could be more relieved than me. There’s a LOT of soldering going on in there!
A brief overview of the circuit goes like this; There are 5 separate 8×8 LED matrix modules. All 8 lines on each of the Y axis are chained from one to another, and driven by a 74F374 latch (the chip in top right). Then every matrix has each of their X axis lines driven by their own 74F374 latch (the remaining chips in 1st and 2nd row). Every latch is connected to the 8 bit data bus that’s directly driven by the Z80. The 74LS138 (bottom right) does some address decoding and has a chip select line going to each of the latches. So, when the appropriate address is written to, the ’138 tells whichever one of the 6 ’374s to read the data bus and keep that data as its output. Next to the ’138 is a connector for the 8 data lines, as well as power, some address lines and !IRQ, !RW & M1
Bingo! It worked! And from BASIC I could select the individual rows and columns to light.
If you’ve been keeping up with the blog (then I’m highly flattered, but haven’t you got better stuff to do?), then you’ll remember I wanted to put this on to my own design of PCB but failed to fit it in to an acceptable size. To me, an acceptable size for 7 modules was 140mm x 40mm. The space used on this board, overall, is 125 x 125 for just 5 modules. I know the wires I used was a lot bigger than PCB traces, but the photo below shows just HALF of the wires that are running under the LEDs!
In other news, I’ve got a bit of Z80 assembly love going on with the ClrHome website and Fuse. I’ve got it (sort of) reading memory and writing it to other places, and I can verify that it’s writing stuff! It doesn’t crash the virtual Spectrum either! It’s getting close to the point where I will have to sit down and draw a flow chart or something though as my brain doesn’t yet work at assembler level.
And fingers crossed the PCBs will arrive in the next day or two so I can get the main Z80 machine built up and tested.
19 July 2014
18 July 2014
There has been a spate of pedal power projects in the re-innovation workshop recently.
This post shows one recently built for Nottinghamshire Healthcare. The pedal generator was designed as a challenge with a twenty second test to see the amount of energy the cyclist can generate. It also needed to be relatively potable (to fit within the boot of a car).
The systems consist of:
- a shunt regulator (rated at 400W) to dump any excess power
- a LED bar graph display as a visual read out of power generated
- an LED display which shows the actual power output in Watts
- a 20 second test display with an output in Watt-seconds
Its very difficult to explain the concepts of power and energy. People often ask me "Can I power my kettle with that?".
So to try and put the energy in a cup of tea into perspective I built the 'Cuppa-meter'.
The 'Cuppa-meter' shows a cup of tea which lights up as the energy required for a cup of tea is generated. This can be plugged into a pedal generator and people can 'feel' the energy required to make a cup of tea.
They can either pedal slowly (and hence low power) for a long time, or they can pedal hard (high power) for a shorter time. The end result (the energy) is the same - a nice hot cup of tea (or rather a lit up image of one).
This post gives a few images of the cup of tea and also the calculations used.
The mounting of the LED matrix has probably caused me the biggest turmoil so far on the Retro Challenge. First, I was going to design a custom PCB for them, but I missed the window of opportunity to get it manufactured at a reasonable price. So, for simplicity, I decided to use breadboard until I realised this wasn’t simple with that amount of wires. So, I went back to PCB design preparing to take the financial hit. However, it proved impossible to get the tracks to fit, so this idea went in the bin again. Back to breadboard, I bought a load of jumper cables, and started expanding on what I started earlier. For the driver chips it was ok. For the matrices themselves though, I came across a show stopper; The width of it is so wide that in the breadboard there are 2 free tie points on one side but just 1 on the other. Getting a data bus down all of them was not going to be possible :-(
So, I had a rummage through some vintage Veroboard and found a Euro-card sized board with chip layout tracks. It would only fit 5 modules side by side, but I was prepared to make that sacrifice. I also had some 40 pin female sockets, so that made life even easier!
All the Y axis data bus cables went in fine. I was running out of solder though, but had just enough left for the chip sockets
I didn’t have the appropriately sized 20 pin sockets, but I did have plenty of 14 pins ones… so I’ll just have to be careful in marking where one chip ends and the next one starts.
There’s still a lot more wires (25 actually) to connect under the LEDs, but the headers are quite tall so there should be enough room to hide them away.
Hopefully I’ll be able to complete this at the weekend, in time for the other PCBs to arrive.
17 July 2014
16 July 2014
just a quick update about my Z80 development environment.
If you look down a couple of blogs, you’ll see that I found an online Z80 emulator and I’d written a couple of bits that executed in it, so I was going to do my Z80 learning and development on that. However, there were two issues. The first being that it didn’t run on Chrome on my Linux PC at home (but did on Chrome on Windows at work). The second issue is that it isn’t a Z80 emulator, it’s a 8080 emulator. I didn’t think this would be a problem as they pretty much run the same instruction set, although the 8080 has a sub-set of the Z80 (well, technically, as the 8080 came first, the Z80 has an expanded instruction set), and I quite quickly came across an instruction that wasn’t supported. Bugger! That’s messed up that plan.
Then I remembered I have Fuse which is a ZX Spectrum emulator running on my Linux PC. There are oodles of menus and options which I’ve never looked at, but thought it worth a poke (no pun intended) about with.
Sure enough, there’s a debugger that shows all the registers and instructions being executed and stuff, and also a memory browser.
The native Spectrum file format is .tap, which is an output option for the online compiler at clrhome
So far I’ve not managed to successfully execute a program, but by changing my code I can get the virtual Spectrum to freeze up or reset itself, so I know it’s having an effect! Also, with the memory browser I can actually see where my code is being loaded in to; 0x5CD3 – which seems like an odd location to me
It still needs some playing around with before I know what I’m doing, but at least now I feel like I have got a plan!
We’re at the halfway mark of the Retro Challenge, and there’s a slight lull in activity, so this seems like a good chance to catch up on what’s been done so far, and what’s still to come.
Firstly, a quick review of the challenge I set myself; write my name in LED lights. These must, however, be controlled by a Z80 computer, which I’ve got to design and build myself, and written in assembly language which I need to learn.
Well, the start of the challenge saw me dive headlong in to KiCad, learning some of the intricacies of printed circuit board layout. I’d used KiCad for a couple of little projects before, but certainly wouldn’t have described myself as competent. I’m still not a master of it, but I’m a lot more familiar with it than I was.
I split my breadboard based Z80 down in to several modules, each of which will plug in to a Veroboard backplane. 6 of these have been designed and sent off for manufacture which will give me a basic Z80 computer that I can use via a terminal emulator. The boards are;
- Eprom (for BASIC eprom)
- Eprom (for my Z80 code)
- Serial I/O
I put a lot of energy in to getting these done early on as they take about 2-3 weeks to get manufactured. I did actually get notification today that they’ve been made, and are currently being shipped from the United States. Hopefully they’ll be here early next week.
I left the ‘LED’ part of my challenge fairly vague as I didn’t have any particular display in mind when I started this. Maybe 7-segment display? Maybe a bunch of individual lights? Maybe even LCD display with LED backlight? Well, I found a huge amount of mini 8×8 dot matrix LED displays at the local Hackspace. I tracked down the datasheets and got one tested out with the breadboard Z80 and BASIC.
This works fine, so I’ve now worked out a circuit to drive 7 of them. 7 is an ideal number, not just because there’s 7 letters in SPENCER but 7 * 8 X-axis plus 1 * 8 Y-axis maps really well on to the 8-bit Z80 data bus! I missed the window to get this manufactured as a PCB by OSHPark, so decided to build it up on breadboard. This proved too time consuming, so I decided to go for a more expensive UK based PCB company, but this turns out to be really hard to fit on to the size board I want to use, so have abandoned that idea too.
I’ve started teaching myself Z80 assembly language from introduction websites and also reading the book “Programming the Z80″. It turns out that assembly language is really hard! Who’d have thought! I’ve found an on-line compiler which works pretty good, and an online emulator. I can only use the emulator by manually entering the hex code though, as I can’t get it to load programs, so although it’s great for checking very low level stuff, it won’t scale up to larger stuff.
Talking of larger stuff, I’ve been through the Sinclair ZX Spectrum ROM and extracted out the character set from that. This will mean I don’t have to worry about plotting every single dot on the matrix displays myself, and will also mean I can easily write things other than my name!
Wow, that sounds like a lot so far! Well, there’s still plenty more to do.
Firstly, I’ve got to learn a LOT more assembly language. Then come up with a flow chart for a program, and actually write the program. I also have to wire up the LED displays (currently wondering about Veroboard) and their driver chips. Plus, the PCBs should be here soon, so I have a lot of soldering to do. Of course, all of these steps will need to be tested at each stage, which, inevitably will mean fixing stuff, redesigning bits or even having a total rethink.
Then, all I need to do is put everything together and write my name in LEDs. Simples!
15 July 2014
I knew there would be some stumbling blocks with this Retro Challenge, but, hey, it wouldn’t be a challenge if everything was just nice and simple. However, I seem to be beset by little stupid technical issues that aren’t necessarily retro in nature.
However, the fact that you’re reading this does at least mean that my blog is working again! I ran some updates last week, and it caused some issues with a plugin meaning I had no way of adding, editing or modifying any posts. I’ve now got that tracked down to the Poll plugin and disabled it. So, yay, I’m back!
So, part of this challenge is to use LEDs, and the little 8×8 matrix modules I found seem ideal. I had initially intended to design a PCB to mount a bunch of these on, but due to time constraints, it was looking very unlikely I’d get them designed, ordered, manufactured and delivered by the end of the month, let alone time for testing. So I decided to go Old Skool, and do this part on a breadboard. Well, 2 breadboards, as they each need a driver chip. Although, it’s actually 3 breadboards, as 2 aren’t quite big enough. Not to mention the other breadboard with the supporting circuitry on. I made a start on this last night;
After an hour or so, the enormity of this began to dawn on me. There’s 7 matrix modules. Each with 8 pins on X and 8 pins on Y axis. All the X pins need to connect between them, and then to a 20 pin latch chip. All the Y axis pins go to a latch chip themselves. All the latches have a 8 bit data bus that connected them all together. Plus the controller. And power rails. That’s over 450 wires I’ve got to trim and push in!
At which point I decided to abandon that idea, and go back to a PCB plan. It would mean using a UK company in order to get it manufactured in time, and that would cost a small fortune for a one-off. But I gave it a go. 4 hours later I realised that trying to minimise the amount of space the board took up by mounting the display and driver chips on opposite sides made the routing impossible. I tried a couple more ideas, and then gave up on the PCB plan. I have, however, ordered a load more jumper wires from eBay this morning!
When I first started to investigate Z80 CPUs a few months ago, this book was widely held as the difinitive guide. It is out of print, but there are scanned PDF versions out there if you know where to look. For better or worse, they are not OCRd PDFs, and despite nearly finishing reading this, I’ve never really got on so well with books on a tablet, so I managed to pick this up cheap from eBay. For a reference book to skip backwards and forwards, or flick through looking for something I think it’s better than the electronic equivalent.
How is the Z80 assembler side of the project going I hear you ask? Well, yeah, it’s coming along. Slowly. With such a limited amount of commands even the simplest of things really has to be broken down to a very basic level. What do you mean I can’t just multiply by 7? Well, I had some little test-lets that I was going to try out last night before I ended up breadboarding, however, due to some other glitch, the Z80 Emulator website does not run on my Linux machine at home. This could be quite inconvenient. But I’m sure I’ll find a way around it sooner or later. Isn’t that part of what a challenge is?
12 July 2014
10 July 2014