Random Flashing Christmas Lights with Geiger Counter Effect Output

Advertisement:  If you're enjoying these pages and you have an interest in hobby type electronics or repair jobs, you might like to visit my UsefulComponents Etsy Shop where there are many difficult to find items, and my other website www.usefulcomponents.com, where there are details of some good radio and other kits.

65535 bit LFSR
          XOR and D-Type Board Whole

About ten years ago, [Edit: written some time ago!] things were a bit slow at work and the joyous season of goodwill was almost upon us.  How might it be possible to relieve the tedium and simultaneously look a bit like you're doing some work?  Ah Hah!  You can make some annoying flashing Christmas lights, but not any old annoying flashing Christmas lights, no.  These use a linear feedback shift register to generate a pseudo-random flashing sequence and make a pretty LED display.  You can also connect up a loudspeaker to one of the outputs to make a pseudo-random clicking effect like a Geiger counter, white noise or the interesting grinding noise of the sequence repeating if you turn up the clock rate.

The Linear Feedback Shift Register Pseudo-Random Sequence Generator

I'll not go into the full details of the theory here and I'd recommend looking up Linear Feedback Shift Register on Wikipedia.  Suffice to say that they are very useful and easy to make, either using old logic chips like I've done or a spot of VHDL or programming.  I've made a maximal length sequence for a 16-bit shift register using taps 4,13,15,16 (the numbers are one step out in the schematic) which creates a sequence 65535 bits long.  If you clock this at 10Hz, it will be almost two hours before the sequence repeats.

XMAS_LFSR Schematic Description

Here's the schematic.  You can click on the image for a bigger view or download a pdf here:  Linear Feedback Shift Register Using XOR Gates 65535 Bit Length.

Linear Feedback Shift Register 65535 Bits Using XOR

Schematic Walkthrough of Irritating Christmas Lights Linear Feedback Shift Register

The intention is to run from 12V d.c. overall and a standard 5V linear regulator provides 5V for the HC logic devices.  The main shift register is comprised of U1 and U2 74HC273 D latch devices and this allows access to all possible tapping points, unlike some other dedicated shift register chips.  They are cleared at start-up by an RC clear generator with a relatively short period.  A similar circuit with a longer period injects an essential '1' into the system.  U3 74HC86 provides the XOR gates.  The state of the shift register is shown on the LEDs which need to be 2mA low current types.  Four logic level gate threshold N channel MOSFETs provide pull-down output drive for external LEDs supplied from the 12V rail. 
Depending on what external devices you intend to drive with the output transistors, they are not particularly critical.  My prototype used IRF611 because they happened to be available.  You need to have suitable current limiting resistors appropriate for 12V on the external LED circuits.  The NDD02N40 shown on the schematic is a good, small, 2V gate drive voltage FET which has very good parameters at 5V gate drive.  The choice of taps to drive the output transistors is not important, or is an artistic decision.  A simple Schmitt inverter clock generator provides a variable rate clock signal and this can be adjusted for maximum irritation effect.  The clock signal to the shift register has to be good and sharp to avoid the sequence generator jamming, so a second Schmitt gate is used after the actual clock generator inverter.  The final gate on U4 74HC14 can be used to drive a small loudspeaker or amplifier via a d.c. blocking capacitor C6.  At low clock rates this sounds rather like a Geiger counter audio output.

Creating Interesting Noises With an LFSR

You can create interesting noises using LFSRs.  I've already suggested the Geiger counter effect, and you can hear that by connecting a small loudspeaker to output J3.  If you reduce the value of C3 to about 1nF, you can create pseudo-random white noise.  If you turn the clock up fast enough you can hear the lower frequency content of the sequence repeat.  I claim that low-pass filtered versions of these sequences, running fast enough to hear the repetition, sometimes appear in sci-fi film soundtracks and other places.  An example would be the noise underlying the DVD top menu on my box set of "The Prisoner" from 1967.  Of course, there are many different sequences that you can create using this technique by using different taps and shift-register lengths.  They will all sound different from each other but when low-pass filtered, each one will have a unique and reproducible grinding noise.  It might be interesting to try two identical sequence generators running at slightly different clock speeds driving the left and right channels of stereo headphones or speakers.

My Particular Implementation

Here are pictures of my particular prototype and links to some YouTube videos of it running.  I used some high brightness white LEDs and various other bits scavenged from mobile phones at the time to decorate a plastic Christmas tree.  Can you spot the type numbers of the mobile phones used?  The old Radio Shack solder breadboards in the shape of the plug-in breadboards were a fantastic gimmick at the time which I thought that I would try using because I happened to have some, and for a bit of fun.  Ordinary stripboard is better in practice.

Board Left Of LFSR Flashing Light Generator

I found some tiny orange LEDs from somewhere to indicate each stage of the shift register.

Pseudo-Random Light Flashing
          Unit XOR Gates and LEDs

5V Regulator and LED Driving MOSFETs

Right view of Irritating Christmas Lights Electronic

The rear side of the Archer "plug-in breadboard" style solderable breadboards Cat No. 276-170.  Cool!  Not immensely practical, but having stumbled across them, these definitely had to be used for something.

Rear View of Archer / Tandy /
          Radio Shack Breadboard Type PCBs Cat No. 276-170

Can you spot which Nokia mobile telephones the scrap keyboard PCBs are from?  No prizes.  Nokia N80 in blue on the right I think, and let's just say that we had quite a lot of the other horseshoe shaped ones left over.  And let that project never be mentioned again.  In *anyones'* C.V. :)

Keyboard PCBs from A Certain Ill-Fated and Badly
          Conceived Nokia Mobile Phone

YouTube Video of The Linear Feedback Shift Register Based Annoying Pseudo-Random Flashing Christmas Lights Project.

Edit History:

0.0 01-MAR-2022:  Initial page.
0.1 02-MAY-2022:  Edit to include some pictures which never seem to have appeared, or got lost in a bad update. 

general email

Navigate Up