Monday, 16 September 2013

How to get text from a screenshot using OCR

An interesting conundrum today - how to get a plain text copy of a long list of options in a bit of software that isn't copy/paste-able.
OCR This! :-)

I should point out before I start that I'm using Ubuntu 12.04

So, anyway, I screen-captured the areas of the screen that formed the list into a series of image files. At this point I tried OCRing one of them straight off the bat, using the tesseract OCR.

Friday, 12 July 2013

Samsung Galaxy S3 Sensor Data

Recently I was fiddling around with a program on my S3 called Sensor Dump which just dumps the raw data from the various sensors onto the screen, and/or saves them into a CSV file.

Looking at the mag-field data on a graph is pretty interesting. This is where I passed my phone over the top of a laptop power supply.

It occurs to me that you could overlay this data on a camera display and do some kind of really low-resolution magnetic field camera thingie.

Hmm.   I wonder how directional it is.

Further tests required.

Thursday, 14 February 2013

Ah, Android. Always looking out for me.

So my phone, currently being used to play MP3s while I type documentation, just informed me that I should "consider reducing the volume to prevent damage to your ears" - well, thanks Android Music Player, that's very kind of you to say so. You're right. You're just 30 years too late.. (Damn you Not-Sony Not-quite-Walkman!!)

And also hugely underestimating the crapness of these £1 headphones - they don't go loud enough to damage my ears.

Monday, 28 January 2013

Experiments with really cheap hardware

Recently a new "pound shop" opened near my place of work.  Everything costs £1.
You'd be surprised how many people at the till still say "how much is that then?" 

Anyway, they sell all the usual pound shop stuff; sweets, plastic flowers, unknown brand batteries, blue powerade that no doubt makes your brain itch.

They also have an aisle that has random bits of tech.  So I thought I'd try some out. 

The first I tried was a micro bluetooth USB dongle. I took the lid off it to make sure it wasn't just going to short out and burn my PC to the ground - it looked ok, so I tried it on an old sacrificial PC..  and it worked just fine.. Not the fastest in the world, but functional. 

The next thing I tried was the headphones.. Not quite so successful as the cable is only about 750cm long, and my tower PC is on the floor - so I end up stooped over to hear anything. Also the plug seems to be a little bit too short, and you have to really wiggle it around to get both speakers working correctly.  

Next - A "Blakberry USB charger cable" - yes, that's how it was spelt.  It's actually a standard micro USB cable, I checked the pins using a multimeter and they appeared to all be connected as they should be. Tried it on a sacrificial PC again, and an old phone (paranoid much?!)   and yep, worked first time - full data connection.  Not bad for £1.   

They also do car phone chargers, watches, HDMI cables, SCART cables, and all manner of things with LEDs in. All good stuff for future projects.

Concatenating CSVs the easy way

I was recently asked how to 'merge' a few CSV files into one, and if there was a script or tool that could do that. Lets say you h...