Category Archives: Computers

Model Railway Arduino Point Control – Design

As stated elsewhere, I’ve mothballed the Arduino Dalek Project, and started to cannibalize bits for a new project: Arduino control of the turnout points on an N Gauge model railway layout.

For a start, heres some information about the point motors I’m using: The PECO PL-11 side mounted motors, which attach to the side of the points, like this:

PECO PL-11 (© PECO Publications)
PECO PL-11 (© PECO Publications)

These motors operate on 16v AC and require only (and indeed cannot tolerate more than) momentary current, and are currently controlled from “passing contact switches” drawing power from a Capacitor Discharge Unit.

There are currently 6 turnouts/points, arranged in pairs as below. As it would be reckless (and in real life impossible, due to interlocking) to operate either of the pair independently, I’ve decided to activate them together.

points1Thus, at all times both A and B will either both lead straight ahead, of both lead off to the left (for sets C&D and E&F it will be right not left).

As the Arduino can only throw out 5v DC, each pair of motors will need to be driven via a 5v DPDT replay. But, as we can’t leave the current on without melting the motors, each pair will actually need two relays (one for each direction of change), driven independently from different output pins. Another complication is that the relays will have to energised and then de-energised within a specific time-frame to avoid motor damage, but this is a programming issue to be dealt with later.

PL-11-CDU-Relay WiringThe above diagram shows only the 16vAC side of the wiring. The Arduino 5vDC is shown below.

Arduino-Relay Wiring

Obviously I could have chosen to just use SPDT relays, and connect the outputs together, but due to the vagaries of how the motors work and the orientation and placement of them on the layout, I thought it was safer to design and wire it this way at the outset, rather than back-fix it later when it went wrong. Plus, I had all the wiring in place, so thought I might as well use it.

Note the lack of common Ground between the two halves of the circuit. Grounding AC and DC together isn’t a good idea. Just say no.

Anyway, here is all is again on one convenient image.

Arduino-Relay-PL-11 Wiring
Click to embiggen

So now the next stage to to take that abstract squiggle and build it as a circuit.

Note – for myself, mainly: Each “pair” takes up 2 outputs, so for the three pairs of points we need 6 lines from the Arduino, out of a total of 12 (not 14, as I’d rather not use the 0 and 1 lines (RX & TX) as this could cause issues with data transfers activating the relays – something that the Dalek had problems with at first.

To be continued… with a start on Signalling!

Death to the Arduino Dalek

Here I go again, repurposing shit. In this case it is both a Doctor Who episode title and some  electronic bits.

The Arduino Dalek/Raspberry Dalek project has been on hold for some time (obviously), due to me not being arsed to sort out a niggling wiring problem that only allowed one of the motors to run in one direction.  That and the camera melting itself into slag. That didn’t help.

Anyway, today it suffered a major setback when the Arduino and relays got removed for use in another project.

But Daleks never say die, so it might come back later.

The gubbins are being reassigned to Project Railway, and will act as the point motor control system, once I’ve worked the circuit design out.

To Every Electronics Company In China

Dear Every Electronics Company In China,

I understand that you have trouble finding people to translate instruction manuals for your products into readable English.

I am willing to undertake this task. Whilst I do not speak nor read Chinese, I am willing to lake your partially translated manuals, which make little sense, and translate them in to correct English.

I work very cheaply, requiring only £12 per hour for my work. I realise that this is about 24 times what you normally pay, but if you want your manuals to be readable, it is a small price to pay.

Also, I will require one example of every product for which you require a manual.

Hope to hear from you soon,


Tony Blews



Facebook App Privacy Concerns Are Bullshit

There seems to be a lot of kerfuffle and whatnot about the privacy concerns of the Facebook Messenger App on Android phones going on at the moment. Mainly it seems to be fuelled by this piece of shitehawk “journalism” by the Huffington Post:

Please bear in mind that The Huffington Post is owned by AOL, who have a long-standing mardy about Facebook.

So, what are the concerns? Well allegedly Facebook can spy on you constantly, use your phone to send text messages and make calls, yada yada yada be evil. Here is a screencap of the entire list (from that site – taken 13/01/2015)


Notice how it is in text format, and not a screencap. Now, there is a screencap of the current permissions (actually its two screencaps stitched together…

full perm list

Should you be scared that it can access your microphone and camera?

Firstly, due to the way Android handles permissions, you have to allow access to things all the time for an App to work. iOS does it differently, only requesting access as and when it is needed.  So on an Android device you have to agree in advance to let it use your camera, but on an iPhone you can opt to use the App but not let it access the camera. I know which model is better, but I am never, ever, EVER going to make any public statement that I agree with anything that Apple have done. Blame Bono for that.

Secondly, do you really know what all those permissions mean? No? Well I’m going to tell you. With pictures. Try not to fall asleep at the back!

Starting at the top…


  • “directly call phone numbers” – well you know that bit in the App where you can telephone people? Have a guess why it needs to do this.
  • “read phone status and identity” – well the two come bundled together. It has to know about your phone and whether ot not you are on a call or not just so that it doesn’t fire up and bombard you with voice calls from Dickhead Dave while you are trying to order a pizza.


I’ll lump all the above into one. The app (yeah bollocks to capitalisation now) allows you to send and revieve SMS/MMS messages. So it needs to be allowed to do just that.


You know how you want to do that chatty with live video and sound? Just try to work out why the app needs to use your camera and microphone.


Just like Facebook posts, messages say where you are. If you don’t like it, turn Locations off in your device settings.


You want to contact people don’t you? No? Oh just delete the app, get rid of Facebook entirely, and go and live in a cave. You could always use Google+.

Hang on, why does it read the call log? Maybe, just maybe, its so that when you start a new conversation it will prioritise those contact’s names in the list as you ham-fistly bash at the screen with your knuckle trying to spell N I C K.

huff6Really, have a guess on this one. Did you go with “so it knows who I am”? Yes? Well you’re not having a prize.


Want to save that pic of a dog in Darth Vader costume that Alan The Muppet just sent you? Well you’ll need this.

The same goes for if you want to send your home-made pornographic version of “The Wrong Trousers” to someone.


Do you want to connect Facebook to your Twitter, Instagram, Swarm, etc accounts?

huff9Right… so here we go…

  • “change network connectivity” – this basically allows the app to determine if you actually have a valid connection or not. Its a badly worded phrase in the Android permissions list really. Panic Not.
  • “download files without notifications” – Do you really want to have to agree to see every picture that you are sent?
  • “full network access” – It is a communications app. It will need it.
  • “receive data from internet” – How do you think message are received.
  • “view network connections/ view Wi-Fi connections” – bundled in with the above “change network connectivity”


Can we guess this one?


This is just so that Chatheads can piss you off by floating on your screen in the most inconvenient place possible.


  • “control vibration” – buzz your phone if it is on silent
  • “prevent tablet from sleeping” – keep the screen turned on if the app is active
  • “change your audio settings” – actually is should be called “check your audio settings”. It is used to determine whether your device buzzes or bings.


Well it does need to know if the contacts list is synced and up to date or not.


“install shortcuts” allows the app to put those really annoying “Chatheads” on your home screen,

and finally…

“send sticky broadcast” – this is where it all gets a bit complicated.

A “sticky broadcast” is a parcel of information concerning your identity, location. recent activity, blood pressure, IQ, heart rate, and whether or not you smell of almonds. It is broadcast to the CIA, MI5, Mossad, WASP, Interpol and the ISPF.

Or, it could just be a method of inter-process communtication.

So thats that. Nothing sinster going on at all. Whats more sinister is that Google track your every move and action, that you’ve agreed to this, and furthermore seem quite happy about it.


A Few Days With a HUDL 2

Yeah yeah I know I’ve said many times that I’m not a big fan of tablets, seeing them as big phones that you can’t make calls from, dismissing them as useless for not having keyboards, and calling them nothing more than toys.

Fair enough, I can be wrong. It does happen.

So the missus bought me a HUDL 2 for Christmas. Ok, it isn’t the ex-MOD Defender 110  I wanted, but that would have been too much to expect. Important note: In 2016 she bought me a Freelander instead!

Here is a screen-grab of the home screen:

2014-12-26 13.58.30Well I’ve never seen a bunch of VW owners looking so happy. Surely they should all be frantically trying to find where the smoke is coming from, and looking worriedly at the huge puddle of oil forming? And there seems to be an AA low-loader missing from the photo.

Oh, and surfing in a meadow really isn’t going to work (unless it is on the tide of oil leaking out of the knackered van).


So what is a HUDL 2 then?

Well, it is a £129.99 tablet sold exclusively by Tesco. From the info on the box, the important bits are:

  • 8.3″ FHD 1920×1200 IPS LCD anti-smudge screen
  • Intel Atom quad-core processor up to 1.83 GHz
  • Android 4.4.2 Kitkat
  • 16 GB Storage (expandable  by another 32GB)
  • Dual Band Wifi
  • 2GB RAM
  • 1.2MP Front Camera
  • 5MP Rear Camera
  • Bluetooth 4.0
  • Micro-HDMI and Micro-USB ports
  • Weighs 410g

410g might seem a lot, but it is probably how much sugar I consume in a day.

And what is it good for?

Well, I still think it is a bit of a toy, but as Jack Nicholson said, some toys can be “wonderful”. The HUDL is better for watching iPlayer on that an iPhone4 for a start. I can load it up with stuff to watch at work and not have to squint at a tiny screen.

The battery life is fantastic. I got five hours watching stored iPlayer content no problem.

The cameras are ok, but I prefer the ones on the iPhone4, mainly for the ease of physical handling, but also because the HUDL lacks a flash (aha, he saved everyone of us). The automatic Panorama and PhotoSphere functions are cool though.

Bob a Telnet and VNC client on it, fettle your router right and cross your fingers and your can play about on your home machines when you’re on the bus (how come Arriva can provide free WiFi for a ten minute trip into town, yet Virgin can’t for a two hour trip to Preston?).

Blinkbox Books will give you a tenner free credit, which is enough to buy those two Pratchet books that you missed (Unseen Academicals and Making Money in my case).

And what is it bad for?

Well the wifi on it won’t connect to the access point I having running on my Raspberry Pi. Not surprising really, as Android devices in general don’t work with it (and I have no idea why).

It is a little bit big. Far too big to fit in a pocket. Coat makers need to address this. Bring back “poacher’s pockets”!

I find the form factor of the device a little odd. It seems good when used in landscape mode, but it seems a bit too tall when used portrait mode, and a little top heavy too. Maybe it it was about half an inch shorter it would feel better. And its not often that you hear that.

And I still hate touch-screen keyboards.

Would I have bought one myself?

Eventually, yes. It would be as inevitable as death and taxis not turning up on time.

In general I get hold of tech devices for a reason, but in this case I received one before I knew I needed it. So it has caused me to re-start my learning of app writing for Android devices. This may be considered a good or bad thing. Only time will tell.

Fake News on Facebook

There seems to be a spate of fake news sites going around Facebook at the moment. By that I don’t mean sites that are posting fake news, such as Toytown News, but posts that seem to link to legit news articles but then throw you off to something else.

I’m not going to give any direct links, but Bellingham tributes linking to UKIP hates sites is a particularly vile example.

So, how does this happen? Well to put it simply, when you post a link on Facebook, the site trawls the link to grab a picture and some text details. For example:

fakenews-eg1Note the “WWW.SYFY.CO.UK” text in the bottom left corner of the image. Most people wouldn’t pay attention to it, but that shows what website the post will actually link to.

The good news is that you can’t hide the destination site, but the bad news is that you can confuse people about it.

People don’t pay attention, and generally only scan “unimportant” information, so if the text at the bottom left says something like “news” or “feed” they are inclined to trust it.

So I registered a domain name to test this out.  I figured that it would have to include the word “news”. So, being a bit of a sick puppy (and a Chris Morris fan) I tried to get Sadly, it was taken, so I got (As an aside, I will probably use this to post news articles about a fake village somewhere in the the Staffordshire Moorlands. If I can be arsed.)

Anyway, back to the fake news thing. Nothing makes a fake story looks real like the logo of a reputable news organisation. so I used this:

bbc-newsNext, you need a title. I went with my long held belief that you can use modern cleaning fluids to get rid of a body. Hence: “Cillit Bang Used to Disolve Corpses”, including a deliberate spelling mistake.

Next, some flavour text that will show up under the link. I decided to make it contradictory and nonesensical yet still grammatically valid, so:

According to South Lancashire Police, several corpses have been found completely disolved in Cillit Bang, leaving no traces whatsoever.

Ignoring the fact that there is so such organisation as “South Lancashire Police”, if no traces have been left, then nothing can have been dicovered? Obvious, right? Erm, no. But I’ll get back to that.

So, how does our fake news link look now?

fakenews-eg2It all looks legit doesn’t it, well apart from the “felchnews” bit that nobody pays attention to?

And here is the HTML to do it:

<title>Cillit Bang Used to Disolve Corpses</title>
<meta name=”description” content=”According to South Lancashire Police, several corpses have been found completely disolved in Cillit Bang, leaving no traces whatsoever.”>
<meta name=”keywords” content=”According to South Lancashire Police, several corpses have been found completely disolved in Cillit Bang, leaving no traces whatsoever,humor, prank”>
<meta name=”author” content=”News Editor”>
<body bgcolor=ffffff>
<img src=”/assets/bbc-news.png” width=1 height=1>
<font size=+10>Don’t be so fucking stupid! </font>


Clearly this just links to a site that says “Don’t be so fucking stupid!”, but with a little bit of javascript or the right HTML you can immediately bounce the browser the somewhere else.

I suppose, really, that this post could be condensed down to “be careful what links you click on”, but really, if you haven’t worked that out by now then you have no fucking business owning a PC/tablet/smartphone.




iPhone4 Guitar interface

Apps such as Garageband on the iPhone allow you to record your guitar noodling and play about with various effects. But first you need to get the guitar connected to the ‘phone.

Looking about on t’internet, there are loads of instructions on how to build a guitar interface for the iPhone, but most involve butchering existing cables.

As the cost of the required AV cables is stupidly high, I decided to just buy the bits and have a go at making one from scratch.

So, lets have a look at what we need:

A 3.5mm 4-pole jack – plugs in to the iPhone


A 3.5mm stereo socket (case mountable) – for headphones


A 1/4″ mono socket (case mountable) – for the guitar input


Some 3 core shielded audio cable. Sadly, Maplin fucked up and sent me 2 metres of the wrong cable, despite them looking totally dissimilar and having completely different catalogue numbers.

Anyway, sod Maplin, I’m prototyping here. I’ll make do with bits from my wires box.

The first thing to do is solder the cable on to the horrendously fiddly 4-pole plug.  Get the most difficult thing done first, that’s my philosophy.


The pin out for the plug now looks like this:


  1. Green – (Input)
  2. Yellow – (Ground)
  3. Orange – (Output Right)
  4. Red – (Output Left)


Wrap it all up in the casing that came with the plug, and get a “pigtail” lead:


Originally I wanted this lead to be about four inches longer, but this will have to do for the moment. (You can insert a joke here if you really want).

Next, solder up the stereo socket. I went for the same colour code for Ground/Outputs.


Finally, solder-wise, its time to connect up the socket for the guitar input.

Following the same colours from above:


And here it all, all breadboarded up for testing:


After buying a small case, I discovered it was too small to mount the 1/4″ mono socket in, so I had to look about for an alternative.

I haven’t found anything handy yet, but you get the gist.


An old 35mm film container prooved to be the best case I could find. So, now it looks like this:

2014-09-03 22.00.44 2014-09-03 22.00.49


A Minor Gripe With World of Warcraft

While Blizzard’s World of Warcraft is for the most part a well thought out and utterly brilliant game, I have two minor gripes with it. Neither are really concerned with the gameplay, and neither really affect the world. They just annoy me.

So, I’ll start with the first one, as is traditional in this sort of thing…

Technology is not consistant within the world. You can handwave all you like about Gnomes and Goblins being insane and providing lasers, bombs and all that kind of stuff, but as far as I’m concern it doesn’t matter.

Let us look at what the World has to offer:

We have motorcycles:



planeAn underground mass-transit system:


rocketWe also have Airships, Submarines, Airbourne aircraft carriers, Speedboats, Tunnelling machines, Tanks, Exo-skeletons, and semi-sentient Robots.

What we dont have is trains. Yes, trains. Good, old-fashioned, steam trains.

But, you might be thinking, why should there be steam trains on Azeroth? Well, because there is a toy one you can buy in Dalaran:

toytrainAnd if there is a toy one to annoy other people with, why shouldn’t there be a real usable one? Maybe from Stormwind to Redridge?

And as for annoying people with a toy… well, this really used to upset people:

But now they just seem to join in and play:

I said two irritations didn’t I? Well the other one is this. There is an item called the Cooking School Bell, which summons your student (Nomi – no relation to the goth comic character Nemi):

cookingbellAs you will see in the following video, it isn’t a fucking bell!

Ranting over. For now

Daleks Never Retreat

I’ve thought again about the problem of not being able to do bi-directional motors on the Dalek Project when using just one Piface Digital.

Why should the motors need to run backwards? Daleks never retreat! The only controls I’m going to need are Forward! Advance Left! and Advance Right! (and Exterminate!)

Looking back (which is something that Daleks can’t do anyway), the whole full movement thing came from my idea to build an Arduino Turtle (which was based on an idea developed from a Spectrum project from about 1985). But a Turtle is not a Dalek. Sure, they both have a hard shell and two driving wheels, but that is where the similarity ends.

So now we just need a web interface to control the Dalek’s movements forward, and to the sides a bit. All the while we need to be able to see what the Dalek sees from the on-board camera


The Death of Windows XP


Microsoft is set to discontinue their support of the Windows XP operating system on April 9, 2014. Finally after nearly 13 years, they’re going to give up on their most stable product to date.

But what does it really mean for those of us who actually have to run software that won’t run on newer versions,  can’t afford to upgrade to a never version, can’t afford the hardware to run a newer version, or just plain prefer the XP UI to later versions?

It won’t stop working

Well, XP is not going to stop working. Microsoft are stopping support for it. That means that it will continue to work (unless they suddenly turn into total Shitehawks and remotely disable every XP system in the world – not impossible, but totally improbable).

There will be no new updates

Remember that annoying shield icon that you’ve been ignoring for months, as running updates slows down your game of Solitaire? Well pretty soon it is going to be time to pay attention and run every outstanding update.

Really, if you have the time and resources, I recommend doing a complete XP install on a new drive, updating to SP3 and then applying all subsequent updates. Then taking a bit-for-bit copy of that and storing it somewhere safe for if you ever want to install XP on a new machine. Extreme, I know, but you may thank me later. Maybe you’ll be able to sell it on eBay one day.

Of course, if Microsoft issues a “Service Pack 4 – The Goodbye Edition”, you wouldn’t have to do that.

Your system security is going to suffer

Of course it is. Microsoft are going to concentrate on all the security holes in their newer operating systems, rather than fix problems in something that they haven’t get any revenue from for six years. Microsoft are in this for the money, not the love of what they are doing  (unlike most of the people involved with Linux).

Sadly, another bunch of people who are in for it for the love of what they are doing (and maybe some money), are the ratbastards that create all those viruses, trojans, and bits of malware that will seriously feck up your computer if you come into contact with them.

With Microsoft stepping out of the picture, these pissweasels are going to see a whole bunch of easy, unprotected, targets. And like a bunch of hillbillies seeing fish in a barrel, the shotguns are going to get fired.

But still, it really isn’t as bad as it seems. If your router if configured correctly, you really shouldn’t be liable to random attacks on your IP address. Most routers by default “lose” any incoming connections that aren’t connected to outgoing requests, but if you’ve set up port forwarding then you may expose yourself to a problem.

Personally, my router forwards all unknown ports to a VAX/VMS system that records every attack attempted, and then gives me a list of IP addresses to block.

Then you’ve got the multitude of third-party virus protection options, none of which I will name, as I have an equally low opinion of all of them.

I’m going to swear shortly. I’m warning you now, as it will be in bold and in a bright colour. The message is important and needs to burn itself into your conciousness, so I think I’m allowed in this case.

After faffing about fixing machines for people for bloody ages, most of the time taking trojans and viruses off machines that allegedly had good virus protection (see my distain above),  here is my shortlist of things not to look at:

  • Porn sites. Really, didn’t you realise that an advert you click on could install a virus on your machine?
  • Gambling sites that you haven’t seen on TV.
  • Any advert that says “You have a new message”/”You have just won an iPhone” etc. Don’t fall for that.
  • File sharing sites such as Frostwire, Limewire etc. Just because it looks like an mp3 music file doesn’t mean that it isn’t really hiding a virus. Really, if you must download stuff illegally, do it on a Linux system.

If you continue doing any of the above, you are a FUCKING IDIOT and shouldn’t be allowed a computer in the first place.

Your games may stop working

Well, it all depends. I play World of Warcraft a bit, and my graphics card has just been taken off the Supported List. It is also off the Vista supported list. As of the next update, I’ll have to buy a new machine to play. That is a worst case example. It probably counts for Diablo too.

If the company does downloadable content, check with them.

Office won’t work

If you’re still using Microsoft Office, get OpenOffice. Free, and it is as good as the Microsoft product.

So what are my options if I want to stick with XP?

Well, it depends. If your machine never sees the Internet, like my emulation games machine, just carry on as before.

Otherwise, sort the router out, stay off the dodgy sites, and just “be careful out there”.

And if I want a new OS?

Well, obviously the only alternative is going to be some breed of Linux. For a beginner, I’d have to recommend Ubuntu.

I really hope this is helpful to some people. I’ve tried to dial down my normal level of sarcasm to zero for this.