New House family visit photos
by Pave Graphics on Apr.02, 2012, under Family, Photography












New House family visit
by Pave Graphics on Apr.02, 2012, under Family, Photography































New Vista Shots
by Pave Graphics on Feb.08, 2012, under Uncategorized
Arduino Project: Disco Lights with Relays
by Pave Graphics on Jul.18, 2011, under Art, Electronics, Music, Special Needs
Describing some of the electronic-based challenges faced while making some disco lights…
Background
I am a care worker working with people with special needs in Aberdeen. One of my clients was gifted an old pair of disco light screens (the kind used by mobile DJs at weddings etc) – some of the wires were broken, the boxes were worn and the Perspex was dirty and cracked in parts. We decided to restore them for use at the Special Needs Disco.
Research
I already knew some electronics basics such as Ohm’s Law, everything needs to be in a loop, and ‘don’t touch that if it’s plugged in’, but not much about controlling light circuits beyond the utilisation of an external disco light ‘chaser’. I looked up ‘controlling light sequences’, ‘disco light projects’ and ‘programmable microcontrollers’, because the design we had in mind would require a unique sequence. I eventually came across Arduino, an open source project comprising a versatile electronic controller board, its programming language and associated community projects. It interested me because I’d like to do more ambitious projects in the future and figured I might as well start learning Arduino.
I also had to learn that in order to switch a high-voltage circuit like disco lights on and off, you need a relay (for our design, at least six).
Shopping List
- Seeeduino v2.2 (328) Arduino-based programmable board (will refer to as Arduino) £16
- 8 Relay Board from eBay: £17
- Pack 10 m-f Jumper cables– £3
- ‘JST’ cable 2 pin female: £1
- Loads of .8 wire from Maplin – c. £10
- An old 12V adaptor/transformer from an unused cordless telephone
- An openable 1-socket extension lead: £6
- Junction box
- Joinery / Cosmetic costs e.g. Perspex, paint, plastic protective corners, handles etc.

Tools
Soldering kit, wire strippers, screwdrivers etc and a bit of ingenuity / innovation!
Procedure
First up I identified that there would be a few different circuits in play here:
- The 12V supply to both boards
- The jumper cables from Arduino to Relay board and back (5V)
- The 6 disco light circuits going from mains to lights and back via the relay board.
I was eager to get the Arduino speaking to the relay board next to make sure I had the correct compatible parts:
- Someone had already done the legwork to identify which of the two snipped cables coming out of the 12V AC/DC transformer was live, I presume you can do this with a multimeter or by examining the wiring at the plug end and the -/+ inside/outside configuration of the transformer.
- Before purchasing the relay board I made sure it was going to be compatible with the Arduino: run on the same 12V supply and respond to the same 5V signal which the Arduino would be sending to tell it which state to set the relays.
- I wired this to the relay board and wired the ‘JST’ plug in parallel to the Arduino and plugged it into the mains – success! Both were showing an initialising light.
- I then sought to hook up the Arduino to the computer via the built-in USB interface and an existing compatible USB cable from a Fuji digital camera. I downloaded the Arduino language software and had a wee bit of trouble configuring the driver due to it being a Seeeduino (Arduino compatible). Eventually I discovered I had to set up the driver as a ‘Arduino Duemilanove< or Nano w/ ATmega328'
- I looked up some code snippets – The following code initiates the Arduino and tells it which inputs/outputs it’s going to be using.
void setup(){
pinMode(1, OUTPUT);
pinMode(2, OUTPUT);
pinMode(3, OUTPUT);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
pinMode(6, OUTPUT);
}
I thought about our sequence – we wanted the lights to ‘move’ following an arrow graphic that was going to be on the Perspex, a bit like a slot machine chasing the lights around. Here’s a short snippet showing which circuits to switch on and off, using delay (in mS). The loop command tells it to repeat the sequence:
void loop(){
digitalWrite(1, HIGH);
digitalWrite(2, HIGH);
digitalWrite(3, HIGH);
digitalWrite(4, HIGH);
digitalWrite(5, HIGH);
digitalWrite(6, HIGH);
delay(500);
digitalWrite(1, LOW);
delay(250);
digitalWrite(2, LOW);
delay(250);
digitalWrite(3, LOW);
delay(250);
digitalWrite(4, LOW);
delay(250);
digitalWrite(5, LOW);
delay(250);
digitalWrite(6, LOW);
}
Success! The relay LEDs were blinking away in sequence indicating how they’d be switching once the lights were wired into them. I was so excited I took some video footage (see below).
Next up it was time to wire the light circuits. The old lights we received had existing light-blocking plates and lamp holders in place but we stripped it all out and changed the layout to suit our needs.
I ascertained from the Relay Board schematics that the mains live should go to the lights first and then through the relay, which then makes or breaks the circuit.
After deciding where the mains would be coming into the box, where the lights would be situated and where the relay board would be, all the wires were cut to length and connected to the lamp holders first.
Most of the light circuits had two lights in series; see the diagram below for the circuit.
- Another thing to point out is that each relay on the board I bought had 3 terminals: C, NO and NC. The first is the common connection to the mains neutral. The other two are for either a ‘Normally Open’ (NO) connection or ‘Normally Closed’ (NC) – ie you can have the 5V supply switch off a connection which is usually on or switch on a supply which is usually off (we went for the 2nd option).
Next up we snipped the extension lead near the socket end and attached a junction box. The live wires for the lights and neutral wires from the relay board went in here along with the socket we’d just snipped off to plug the 12V transformer into. Now everything was hooked up into the same handy plug coming out the back.
All the wiring got tidied up and all the parts properly mounted to the box.
A wee lick of paint, protective corners, a handle and a new Perspex sheet (c.£40) with custom vinyl graphics from Pave Graphics later and our freshly restored custom sequenced lights were ready!
Austin’s Disco
by Pave Graphics on Jun.29, 2011, under Art, Family, Film, Special Needs
An inspiring story about a man with Cerebral Palsy who runs his own special needs disco in Aberdeen.
Mini-documentary filmed, written, narrated & edited by John Phethean.
Click the YouTube link to comment, rate and subscribe!
Thanks for watching.
www.austin-disco.co.uk for more info on the disco.
Google Streetview
by Pave Graphics on May.13, 2011, under Business, Funny Stuff, Graphic Design, Internet
They got my van twice on Google Streetview
Although taken a matter of 50 yards apart, the Google car must have taken a while to get from one street to the next as I’ve added graphics to the vehicle by the time it comes around again…
Shuggie Otis – Inspiration Information
by Pave Graphics on May.04, 2011, under Music
I just made a YouTube playlist of this brilliant brilliant funk/soul album from a highly underrated artist…
Fingerstyle Guitar Videos
by Pave Graphics on Apr.11, 2011, under Art, Family, Music
I’ve recently posted some of my fingerstyle acoustic guitar playing on YouTube for the masses, check out my channel (and subscribe!!) at http://www.youtube.com/user/johnpheth
Haudagain Roundabout
by Pave Graphics on Jan.12, 2011, under Art, Graphic Design, Photography
I’ve been busy making a little ‘Plaything’, a vista shot of the Haudagain Roundabout at rush hour. Check it out here
Mark McGhee
by Pave Graphics on Dec.07, 2010, under Sport
A video I made of ex-Aberdeen FC Manager Mark McGhee in a press conference











