Skip navigation

Category Archives: Computers

Well, looks like my sonar sensor (SRF-05) is a just a tad inaccurate for precise measurement as I found from my radar screen I made (here).

So I’ve got hold of a Sharp GP2Y0A02 series infrared distance sensor. It’ll detect and measure anything within a 20-150cm range and it does this by triangulation from where it emits a beam of IR and from when it receives it – this isn’t too important to understand.

http://luckylarry.co.uk/2009/11/arduino-using-a-sharp-ir-sensor-for-distance-calculation/

A collection of useful links/ index for primarily Arduino projects both my own and of other peoples.

http://luckylarry.co.uk/2010/06/arduino-weblinks-projects/

We use them every day, but has no one got bored of pressing buttons on a stick, it’s far too much effort pressing buttons! Surely there are better ways to control a device? After doing some work with my Nikon camera using IR to control it, I wanted to do the same with other devices. Check out the video…

http://luckylarry.co.uk/2010/06/arduino-redefining-the-tv-remote/

Ok so you want to upload a file to your webspace. Easy enough you just need some sort of server-side language. In this case it’s PHP, this tutorial should work with versions 4 upwards.

So we’ll build just 1 file to handle the upload, display status and the form.

Im going to call this upload0r.php (you can call it whatever you want)

First of all make a folder in your webspace/server called uploads, by default it should have read, write and execute permissions (chmod 777) if it doesn’t you can use something like Filezilla FTP client to alter this.

More here: Upload a File Using PHP

Why would you need to do this? Well for instance if you were using 3rd party AJAX APIs and you wanted to capture the data from them perhaps, or maybe you just have a complex form.

Or you could use this for form validation to return errors from the server without refreshing the browser, for example, if the data already exists in a database you could let the user know.

Either way its pretty simple. Basically we just use javascript to post the form object over http to a serverside page – e.g. PHP, JSP, ASP etc…

More here: Using Javascript/ AJAX to post HTML form data

Recently I had to build a system that would take an address, pass it to google and return latitude and longitude values. The result is then stored for later use and display on Google maps.

However, firstly I found that the default XML geocoding service provided by Google that allows you to do bulk geocoding on a data source and the geocoding provided by their maps API/ AJAX library (GClientGeocoder) had huge differences in results. Most postal codes passed to googles XML geocoding service were miles out or just not recognised. Yet when using the same postcode in the maps API when calculated on the fly the results were more or less spot on.

More here:Google Maps API part 1: Accurate Geocoding for UK Postcodes

A snappy title for this tutorial! This is a quick guide with a bit of extra info that I’ve learnt along the way to getting this working, showing that we can:

A) Use a supplemental power source to power the motor
B) Use the L293D chip to drive the motor
C) Use a switch to change the direction of the motor

More here: Control a DC motor with Arduino and L293D chip

A quick circuit showing how to control the speed of a DC motor with a potentiometer with your Arduino board. Also shows how to use a TIP120 transistor to allow the Arduino control a larger power supply.

More here: Arduino: Control a DC motor with potentiometer and multiple power supplies

A guide to using the SRF05 with Arduino in order to calculate distances from objects. In this case I’m also altering the output of an LED with PWM according to how close an object is to the sensor. So the nearer you are the brighter the LED.


More here: Arduino: Sonic range finder with SRF05

Quite useful, I had the case where I needed to provide a CSV file to an external party from our Oracle 10g database. No problem, there are loads of CSV export tools out there. But it then transpired that the CSV’s that I was generating were using quote (”) marks to identify fields e.g. “field1″,”field2″ and so on…
More below at my main blog site:
Spool a CSV file from Oracle/ SQL*Plus without quotes