What’s this about?
This is the UK website for Peter and Maureen Scargill. We live in the Northeast of England and also Andalucia in Spain.

Read through the blog entries, menu-accessible pages and archives if you're interested! Welcome to Peter and Maureen's website.

Get in touch via Facebook My Facebook Page
You should follow me on Twitter Follow me on Twitter
Join my LinkedIn network Join my network

Pete's Online CV
Archives

To Ubuntu or not to Ubuntu

Why Ubuntu?
One of the less pleasant aspects of my "part time but in reality fully time career" in the not-for-profit sector is to make decisions about things like how long to keep computer equipment. Realistically in an organisation with many computers, you have to have a policy. There was a time when we kept our PCs forever or until they basically packed in – but that time is thankfully long gone. The potential downtime, in an age where people rely utterly on their laptops, makes it essential to have an end-of-life policy.

And so it was that some time ago my IT Committee and I decided that we did not want to be involved in repairs and being saddled with staff or volunteer downtime and set the life of a laptop at 3 years. All laptops were to be purchased with a 3-year on-site warranty and that would be the end of that.

Although in a recession we’re being a little more flexible right now, the fact still remains that we get a constant trickles of laptops coming back in past their end of life – and this is on-going of course.  Ideally they’d all be old and worn away and so no-one would feel guilty about having them smashed up…and data securely wiped in the way a fly’s memory is wiped by your car windscreen. but in practice, some laptops get more use than others… and it has plagued me for years that we simply have a blanket policy to send them all off to be broken up – something agreed upon years ago in a somewhat different financial climate of course. The problem, or one of them – is Windows itself, the other problem is data.

Licensing Models
To explain, our licencing model for the software does not allow giving the computers back to their previous "owners" or indeed anyone else and up to now, though the hobbyist might just put an OEM Windows disk onto machines to resurrect them (usually involving some setup time), that really doesn’t work in a larger organisation or with a large number of machines – there are licencing issues and the slight matter of TIME – and so we’ve been at a loss for a solution as to how to make some use of the better defunct machines, ANYTHING rather than the wasteful process of sending them off for destruction. As well as the operating system there is the issue of confidential information in user files.

If you’ve ever tried erasing this stuff you’ll find it’s often not as simple as it looks and it is time-consuming. What is needed is a complete wipe – which of course makes the computer pretty useless.

And so it was that after some discussion I managed to get other directors to agree that it was not ESSENTIAL to destroy them IF we could find a better solution – and that perhaps, in some cases, people could request to KEEP their old machines. This of course does not get around any business issues of using out of warranty laptops – but I simply felt that it was a crime to smash all of these up when at least some would provide pleasure for their previous owners or find some other non-critical use in the organisation itself… perhaps to drive DASHBOARDS or other scenarios where failure would not bring the house down.

That’s fine – but that didn’t get around the problem of protecting corporate information OR solving the licencing issue – not that is – until now.

Emerging Alternative?
Every now and then I take a look at Linux to see how it’s coming along and I usually end up giving up and promising myself I’ll have another look in a year. Either the installation is simply too time consuming (and that is incredibly important in this case because "someone" has to do the resurrecting and we’re not here for the fun of it) or the end product simply isn’t worth it in a "Windows" world.

Installing Ubuntu
With that background, I recently went off to the Ubuntu website to get their latest creation (Ubuntu 12 is an open source operating system along the lines of Windows but free and not entirely compatible – but in recent years a lot of the Apps available for that operating system have been improving to the point where they can co-exist in a primarily Windows world). I downloaded an ISO file and made myself a DVD.  This was weeks ago and as it happens we had a returned machine come in to play with. I put the laptop into setup and told it to boot from CD, inserted the disk and after maybe 15 minutes I found myself with a working Ubuntu setup complete with Open Office.

I have to say… it really did work well and I promised myself I’d spend some more time on this… and so it was one evening that I found myself in the office with a Dell Latitude XT machine ready to try another install… and that’s where it all went wrong…  the laptop didn’t have a CD/DVD.

At that time I was faced with an unusual situation of being in a 3-day meeting-fest yet being alone at the hotel for the night – I wasn’t particularly hungry and decided that rather than go out eating alone, I’d spend the entire evening getting to grips with this issue of updating old laptops. The session was a complete success and so I’m documenting what I did for anyone who cares to follow.

The Solution
Clearly then a good solution would be to have everything one needs on a USB memory stick to simply plug into an old laptop, press a couple of buttons and hey presto – a sparkly "new" machine free of the original software and so after some research I came up with a solution.

Why a memory stick? Well, they are robust and fast and cheap. a 2Gbyte bottom end stick is fine. I ended up at this site and downloaded the Universal USB Installer. After hunting around for a couple of 2GB USB Memory sticks, I ran the above software on my laptop and I was asked which version of Linux I wanted to install. The first option was a desktop version of Ubuntu I was not even aware was out – version 12.04 – turns out this is new and VERY much improved (though not perfect but read on). A tick-box offered to download the ISO image for me and so I accepted that. A mater of minutes later I was asked which drive my USB memory stick was attached to – and that was it – within a minute I had a working USB Ubuntu installer stick.  I made a few copies.

Speedy Installation
The Dell Inspiron XT in it’s time was quite a machine – with swivel touch-screen – a precursor to the tablets of today this machine was not to be sneezed at – but how would it fare with Ubuntu – I didn’t for a moment imagine the touch-screen would still work – not to mention Bluetooth, WIFI and all the other features the machine provides. Surely this would at the very least take some manual intervention and a time-consuming search for drivers  – which would knock this project on the hear immediately because the whole thing has to be done by predominantly non-technical staff in no time at all, for cost reasons.

The reality was very different to what I was expecting… here, step by step is what happened…

  • Time 00:00 – Rebooted the laptop, pressed F" for setup and selected BOOT FROM USB.
  • Time 00:01 – Plugged in the USB stick, rebooted.
  • Time 00:02 – I was asked (in a graphical interface) if I was in the UK and would I like to download FLASH – I said yes.
  • Time 00:03 – the laptop amazingly knew all about the WIFI and asked me for the password for our network.
  • Time 00:05 – Did I want to install Ubuntu alongside Windows or overwrite – I chose the latter and the software indicated it would wipe the existing partitions,start from scratch, format the disk and install Ubuntu – I would lose all data… I said yes.
  • Time 00:07 – I was shown a map with London preselected – I confirmed UK keyboard
  • Time 00:08 – Would I supply a user name, PC name and password and did I want to auto boot. I supplied the details and confirmed.

Office Software
At that point the laptop amazingly went off and got all the software it needed from the web. I went off to answer some emails and by the time I’d done that, I had a complete, working laptop – including the touch-screen, WIFI, Bluetooth – in face everything just WORKED. The installation included replacements for Microsoft WORK and POWERPOINT and more called Libre Office.  But what about media?

I plugged in one of my USB PC pocket drive containing my movies, music and pictures – Ubuntu read this no problem but when I tried to run a movie I was warned about missing codecs… was this going to be the first problem?

Multimedia
At home, rather than Microsoft Media Centre, I use a popular and free media centre called XBMC – a really powerful spin-off from what was originally "X-BOX Media Centre" available for Windows, Apple TV and… as it turns out, Linux.  The software installation pack on Ubuntu is REALLY easy to use so off I went to install (from a menu) XBMS and VLC (another favourite media player which I recommend to everyone to use).

5 minutes later I had a complete working XBMC that ran all of my media flawlessly. The new ribbon interface on Ubuntu 12.04 works a treat and after a little exploration I realised I had a complete working computer even including an Internet Radio program (RythmBox Music Player) capable of satisfying the need for a basic work machine AND home media system.

Fluke Installation?
Wary that this might have been just a fluke I then took an even older Dell computer, a really clapped-out old rattler and repeated the same procedure. Although this took longer, the installation went just as well and again, everything just “worked” – this was a completely different model and by this time I’d gotten it down to just a couple of minutes of my actual time involved. This really does look like a nice solution for re-use of old machines without breaching copyright or letting confidential materials loose. Of course one could argue that a good engineer might resurrect the original information, just as they do on CSI – the reality – highly unlikely as much of it as much of it will have been over-written by the new software and the operating systems are just not compatible at that level. Unless the information is of such a nature as to be highly sensitive, worth investigating a lot of time and effort to recover, I don’t believe this method of re-using old kit represents a corporate threat.

Corporate Email
One of my big gripes about Linux has always been it’s main email reader, Thunderbird. It’s inability to handle email systems such as Microsoft Exchange has always been a deal-breaker for me. All change… a little background program (free) called DAVMAIL allows Thunderbird to handle corporate email, calendars and contacts. I’m not yet convinced it works as well as Outlook – but like Firefox there are many plug-ins and I’m just waiting for a weekend to try out things like scheduled email and even mail-merge email.

Other Goodies
Up to now, most of the utilities I’ve installed via the “Apple App Store” type installation have been winners, there’s a simple video editor (sadly with no sound editing), Gimp (superb image editor), Blogilo (blog writer) and of course VLC, DropBox and other essentials I use every day in Windows – all of these are available in Ubuntu.

Overall impression
I’m impressed. Make no mistake this is NOT Windows 7 with Microsoft Office-  but as an alternative to binning half-decent laptops because they are out of date this seems to me to be a wonderful solution requiring (once you have the USB sticks) no technical expertise and very little time – just WIFI and a bench to leave the laptop to update itself. I could see a line of these quietly sitting being resurrected – at virtually no cost.

Next stop
A tin of compressed air to blow out the fan (old laptops tend to get clogged with dust helping them heat up and lowering reliability) and to clean up the keyboard. One laptop better off… for now. If someone gets a year or two good use out of this I’ll be more than happy.

Caveats
I tested several machines and in no case would external monitors work properly – either the resolution was wrong or some issue – so some work is needed there but by now someone will be onto this.

Summary
This blog provides the link to get the free software to resurrect old computers. There’s no guarantee that any of this works (and I’m not an advice service). Armed with nothing more than a USB memory stick, old laptop and Internet connection, if you’re lucky within half an hour you could have a sparkly new installation of Ubuntu on what might otherwise have been a fairly useless old machine. No guarantees – from here you’re on your own. I certainly intend to develop this further to make best use of older tech rather than simply consign it all to the bin. Though some old laptops are simply not worth it and will rightly be scrapped, every now and then someone’s machine that has been looked after is worthy and by the look of it capable of giving the world another few years of service thanks to open-source (and generally but not always free) software.

DIY Arduino–the “UberBareBoard”

Ok, so I’ve rekindled my interest in electronics with a vengeance. I’ve a load of gadgets I’ve been wanting and not finding anything reasonably priced out there I decided to get the soldering iron out and make them myself.

And so it was that I started looking at processor boards out there to make use of the popular Arduino design. I say design, the basic Arduino is really very little more than a manufacturer’s minimum setup – but the important thing is the volume of support software out there – in particular Ethernet software making it possible to create Internet-enabled devices such as my “EtherStat” Ethernet-and-infra-red-controlled unit which has now been on test for the past couple of weeks without a hitch and which will soon end up running Hollyberry Cottage.

UberBareBoard by ScargillNone of the boards out there are without issue and so three of us collectively decided we’d have our own board and I took on the design job.

Armed with Eagle PCB package with which I’m well familiar (though I had some catching up to do) and a little imagination I set off putting this together from scratch -  I should at this time thank friends Jonathan and Aidan for the encouragement and also the latter for checking my work and generating the “Gerber” files etc.

The result – here it is..I nicknamed it ”UberBareBoard” as it has everything except the kitchen sink in it (feel  free to zoom in on any of these images which should expand or “lightbox” if you click on them).

The board follows the same form factor as the original Arduino though that was only by chance as I spotted an open-source version of the board outline and connectors. Having put several commercial boards together into various test projects, I came across the same problems every time – not enough power connectors, regulator getting hot, parts too close together, same pins used multiple times- and so what you see here is fairly simple but with sufficient extra pins to make life easy for lash-ups.

In the bare-board image above you’ll see on the front-left a 10-way connector – that’s for the cheap Chinese radio boards. Lower left there’s a 6-way connection – that’s pretty standard as are the outer connectors giving access to the 19 I/O pins and power and ground. Note top left the regulator is mounted flat on plenty of copper board (both sides) to dissipate heat and there’s room for a standard power connector (standard that is unless you’re Maplins who have a HOPELESS and hopelessly over-priced selection of connectors).

Populated UberBareBoard by ScargillAt this point it’s probably better to look at the populated board. Front right you’ll see a LED which is attached to D13, a far better place than making a power led as you can see the board working on power up (it flickers). Over on the right I’ve left room for a 3-pin infra-red receiver and a LED to go with that. Top right is the reset button, left from there the standard programming connector and left again (ie upper middle) you’ll see a power (+5 and GND) connector and a 2-pin battery connector. Relevant diode and charge resistor are fitted. The empty socket is for a 24c256 chip (64K EEPROM) and centre front you’ll see 2 diodes, they’re to drop the 5v supply sufficiently to use with the radio or Ethernet modules.

Mass production? No, we scoured the web for cheap UK prototype suppliers and ended up sending off to China for a set of 10 prototypes at a reasonable price – somewhat over a fiver each – and this for fully tinned, masked, cut to size prototypes of production quality. I’ll be using these guys again – turnover was little over a week.

I’m happy to say that apart from not having sufficiently small 1k resistors to mount them horizontally (that’s what I get for using standard library parts and not checking) and getting the mounting hole layers wrong (hence no mounting holes, quickly corrected with a drill) the boards work perfectly – and I have lots of plans for them.

This article was written as a follow-up to the original cottage thermostat article – and the first follow-up to this is here – NRF24L01 transceiver and Arduino.

Project Production Line

It’s been a quiet weekend up to now, got my grandson over, last night we had WAY too much to drink with friends so I’ve been hiding away in my office with the soldering iron to recover. The Internet Thermostat is sitting testing 24/7 – I’m determined to leave it for a couple of weeks to make sure it is reliable before actually using it to control heating!

tmpB2BCSo, having grasped the basics I’m now 90% through my next project. The board you see to your right is an 8-relay controller, capable of switching 8 devices (lights, heaters etc etc) at up to 2Kw each. You see the relay panel at the bottom, microprocessor on the left and Ethernet controller on the right. The primary control is via the Internet, from, say, my iPhone but I’ve added infra-red remote control (the little green thing top left) and tomorrow depending on the weather I plan to add short range radio control also. The idea being that this would be controllable by short range radio but also that the power of the board could be extended to a further up to 8 relays (or more) for those hard to wire places… depending on the reliability of the radio (I know it works as I had a test rig up with two of them chatting to each other – but I don’t yet know how reliable the radio is.

That’s my next job…

Kittens

We’ve had kittens! Not much more to say at this point… 3 kittens, can only have appeared between me going to sleep at 3.30am this morning and getting up now at 10am..

tmp28DC

tmpCCE9

The Forthcoming Postal Increases

The more I think about this, the more I think we should be banging on post office doors with banners and slogans and…

Sounds simple enough, doesn’t it –post office want to put up the price of stamps by a whopping 30%.   Who cares, we all use email, right?

Wrong.. think about all the cheap little goods that people buy, say on EBay every day. Small businesses working at home making jewellery perhaps might be constantly buying small quantities – I could probably sit down and come up with a list of 1000 different reasons which SMES or individuals would be sending off for stuff costing a couple of quid… I just bought a package of 20 small nuts and bolts for £1.50 for example…

EVERY one of these purchases is now going to cost more. If the seller is offering free postage they’ll have to put the price up – if they’re charging for postage, they’ll have to charge more. Not only that but if they had to buy they stuff in, in the first place, they’ll have to charge EVEN more to cover that.

The entire chain – that’s right from manufacture down to you and I the individuals, will be getting added costs – and quite often you’ll just think everyone is getting greedy whereas in fact it’ll be due to the post office.

Small companies and individuals all over the UK are smarting with this recession, our standard of living is effectively dropping by the day and the post office gets away with WELL past inflationary price increases as do other large organisations such as power companies….  WHY? Well because we’re Brits and we sit there and put up with it…  and this will continue until we finally get off our BACKSIDES and start complaining NOISILY.

But of course that won’t happen. Fuel is at a record high – last time it went this high we did… erm, nothing – this time we’re doing – erm, nothing.  What we should be doing it getting our act together, getting people to go to the cheapest suppliers and boycott the more expensive ones – but we won’t. Of course you can’t do THAT with the post office because for smaller stuff they are a monopoly just as BT are effectively a monopoly in many rural areas – and monopolies are BAD, BAD, BAD  – they just don’t work for anyone except shareholders.

Rant over, I don’t feel much better..

Cottage Thermostat

If you’ve been keeping up I’ve spent all my spare time recently getting to grips with the Arduino – which is in essence nothing more than a single-chip Micro with bootloader and a decent library of routines.

We needed a better thermostat for Hollyberry Cottage and decided to “give it a go” – here’s the results so far after MANY blind alleys and the smell of fried plastic on more than one occasion…

Arduino-based thermostat

So essentially what you’re looking at on the right is a prototyping board with a microprocessor on the right and associated parts (the little long grey chip on the right), at the top of the board – the blue sub-board is an Ethernet (internet) interface, at the bottom a mains relay. Off the board to the left is a control pot (user heating control, to the top are some LEDs  and on the right is the cable I use to program the lot – that’s not part of the project.

So the idea is simple enough – the unit via a remote head controls the temperature in the place with two options – normal and standby… in standby the temperatures drop, in normal they are suitable for having people there.. in each case there are 4 timezones and the level of control the pot has is controllable… so we might let people vary the temperature by +-4 degrees from the setpoint for example….

tmp6261So why the Ethernet interface – well, Maureen and I are out and about, perhaps even in Spain and we need to be able to handle last minute cancellations or indeed last minute bookings.  Instead of driving over to the cottage to change the heating, we want to be able to do this from anywhere… and that means on a mobile phone. There are TWO different and incompatible Ethernet Interfaces for the Arduino board and I made the mistake of spending a lot of time working with the cheap one using the ENC28J60 chip – it’s cheap – but it simply does not work reliably. I then moved onto the standard board which uses a Wiz5100 chip – and that worked perfectly except for inexplicable hang-ups which were pretty predictable – turns out the standard library that everyone uses has a bug – that sorted the board is now working utterly reliably (up to now, longest test 24 hours – I plan to give it a couple weeks next).

tmpBBE7The interface has to be simple.. As you can see on the left I’ve stuck with large buttons. Typically you would log into the site and press NORMAL or FALLBACK to control the heating – but you can also set up the time, set the temperature zones and even view a graph of historical temperature (stored locally in EEPROM). The graph will get more sophisticated in time but for now it merely shows historical data. The chip has enough spare EEPROM for around 900 points (to the nearest degree, much smaller if you want fractions – though thinking about it I could store to the nearest 0.5degrees just by doubling the figure and getting the 8-bit equivalent – if the temperature hits 128c we’re in BIG trouble – or minus for that matter internally).

Instead of an expensive LCD display at the user end I’ve gone for 3 simple LEDS – red, green and blue. The GREEN light simply flashes to let you know the unit is thinking – when the heating is ON it flashes far more obviously…. the red and blue are optional and give a varying indication of HEATING (red) or COOLING (blue) depending on the setting of the pot.. they may or may not make it into the final unit.

I’ve incorporated delays to stop someone madly fiddling with the controls and setting the relay on and off rapidly….. and the settings will survive a power loss – though right now the time won’t… my next job is to get the board to send me an email if the power dies so I can reset the time – cheaper than using a battery and more useful as I need to know if power cuts occur! Maybe I’ll get it to send a TWEET…. more as things progress.

Update 29/3/2012

The email was not that easy – turns out it’s quite hard to have the board do a server/client on it’s own web pages AND handle something else – so email, even twitter is out (I did get the code running to send TWEETS!) until I can find out how to do 2 things at once. On the upside I’ve now added a real time clock board so it knows the time and can keep it if the power goes off. The board is essentially done, it now needs to sit on test to make sure it’s reliable. NOW I can get back onto working on Maureen’s SAD light… which will also get the real time clock treatment!  I’ve ordered more of the Ethernet boards – I can see lots of applications for this stuff.

Update 24/9/2014

See other posts on the subject of home control – amazing how far this project has come on in 2 years! The first follow up to this original article occurs here – my UberBareBoard project.

Sunny Scarborough

This week I’m in Scarborough for the week – the FSB’s annual conference – it’s my job as IT Chairman to ensure we report everything that is going on – and I have a team of staff to do that but the really techy stuff – video on demand, imagery etc. is run by a small group of us (I’m the first here) and involves high speed broadband, gigabytes of video and a lot of hard work – and fun.

But that’s for another set of blogs – I got up this morning and started snapping photos to give delegates a feel-good factor – the weather here is great (as someone who’s now done about 11 of these Conferences I can tell you that’s not always the case in March – indeed usually the opposite).

So here they are, some of my late evening and early morning photos of Scarborough! By all means click on the images for larger versions…

6am Scarborough sunrise

View from the Crown Spa Hotel

Parking's an issue already

The beach

Copper the Catalyst and Nail Varnish Remover

This may well not be new to you – or you might not be the experimenting type – in which case look no further.

Copper is a catalyst, that is something that speeds up a reaction but does not suffer in the process… so examples like platinum catalysts in cars come to mind.

This one is new to me – and is a great, fun and relatively safe way to demonstrate the use of a catalyst.

IF YOU BLOW YOURSELF UP OR GAS YOURS IT’S NOT MY FAULT. Acetone (Nail Varnish Remover) is flammable and the fumes set fire relatively easily (hence the requirement to use a tiny amount)).

Copper glowing hot above AcetoneGet a piece of copper wire, let’s say earth wire out of one of those 2-core+earth mains cables… and wrap one end around a nail so as to make a coil, maybe half an inch (12mm) long… with slight air gap between the turns..

Get a short glass – like a half-pint glass or less and arrange something non-flammable (like the rest of the wire – or a drill, or fork so that you can put the item across the top of the glass and use it to suspend your coil just off the bottom of the inside of the glass.. maybe 1/2 inch or less.

Put the tiniest amount of nail varnish remover (has to be the type that uses acetone as that’s the bit we’re interested in.

So, you have your coil on the end of your wire, dangling…… just above the acetone…  take the arrangement away from the glass and with a cigarette lighter, heat it until red hot… replace the arrangement in the glass…. and watch.

Without flame, the copper will continue to glow red hot… experiment with layout, size of coil etc. but always near but not touching the surface, the idea being to get air and acetone fumes on the copper.

There are plenty of places on the web to explain this – I can’t help thinking there has to be a way (while venting waste fumes) of making a neat heater with this. With thicker cable I managed to keep the thing hot at just below red glow level… The example you see here was thick earth wire, one coil within another – to keep the surface area up… but a MUCH simpler arrangement works just fine , even a thin copper WIRE with no coil works fine but tends to turn off quite easily.

Life as Normal

Petes relay control panelI’m looking out of the window and wishing I was in the sun… though to be fair, it’s not that cold today, yet.  In-between bouts of database work for the Fed, I had a trip to the docs as my foot keeps giving me trouble, so now I’ve a load of exercises to do, reckons I’ve damaged something.

I’ve been working on my relay board… this is a board that talks to the Internet and serves up a web page by which I can turn up to 8 mains relays on and off at a distance – like – any distance.  I need these to control stuff in Spain when I’m here and so it has to be very reliable.

As you can see on the right, the interface (web page) is pretty basic but I wanted it that way as I have to control this from the iPhone.

Microprocessor-Controlled Relay BoardProgress so far is good… I built a pre-prototype using an Arduino board and this model here is done using a little Arduino Nano. Most of my time was taken up figuring out why one of the pins didn’t respond as normal – I figured it out – CHINA! And so now, all’s well and it’s one test where it’ll stay for a couple of weeks to make sure it’s crash-proof.

Next stop is to add a couple of temperature sensors (inside/outside).

A break from Winter

Just taking a short break from the cold misery of old Blighty (though to be fair it’s not been THAT bad a winter). Here’s a few shots of Embalse Del Negratin just outside of BAZA in Andalucía that I took this morning – and remember – this is FEBRUARY! The water’s probably a little cold to go swimming but it’s a nice thought.

Embalse Del Negratin - Photo Peter Scargill