8 x 8 pixel red display

The 8 x 8 pixel red display is one of the first projects I did after a long hiatus. I wanted to build something useless and work on my C programming skills.

The schema was made in CadSoft Eagle, the layout was laser-printed overhead sheet and the board was etched on the kitchen. Nowadays I use MakePCB or Sparkfun‘s BatchPCB.

The schematic is really simple : a 74HCT595 as high side driver, and a 74HCT595 driving a ULN2803 as low side driver.

I kept the board simple as well so I could etch it myself.

The built up board :

The software bitbangs a couple of IO ports to control the two shift registers, intensity variation is done by changing the duty cycle of the leds. This example has 3 bits intensity (8 different intensities).  We can use these “8 pixels x 8 pixels x 3 bit” intensity as 3 bitmaps with 8 pixels x 8 pixels. The highest valued bitmap (the MSB of the intenisty) is shown 2 x als long as the second highest. The second highest value is shown 2 x as long as the LSB.

Example 2 :

Making character bitmaps is a lot of work. If you have access to a unix box of sorts you can use figlet and the 5×7 font to generate these for you.

This will result in a monospaced font which are not as pretty as the hand made fonts.

For instance, you can generate the character “0” with :

figlet -f 5x7 0 | tr ' #' '01' | sed "s/\([01]\{6\}\)/B8(\100),/"

And this will output :
B8(01000000),
B8(10100000),
B8(10100000),
B8(10100000),
B8(10100000),
B8(01000000),
B8(00000000),

I used Tom Torfs binconst macro to make the bitmaps usable.

Example 3 :

LivingColors 1st generation

(This is a cut & paste from my old site)

The Philips Living Colors is a remote controlled 15 W. RGB led lamp.

It is available (April 2008) in the UK, The Netherlands, Belgium, France and Luxemburg for about 110 to 150 euro.

The build and design are high quality. This is not a re-labelled generic chinese designed product.

The remote uses a radio frequency transmitter and reciever om the 2.4 GHz ISM band from Chipcon (now Texas Instruments). It does not need line of sight and can control up to 6 lamps independently or as a group.
The microcontroller in the remote and lamp is a low power microcontroller from Texas Instruments. The comminication is bi-directional which suggests Philips has more products planned, say an AmbiLight – LivingColors bridge.

Philips owns Lumileds ( http://www.philipslumileds.com/ ), the manufacturer of the high power LEDs used in the lamp.

Remote

Lamp

  • MSP430 from TI
  • CC2500 : Chipcon / Texas Instruments : “Low Cost, Low-Power 2.4 GHz RF Transceiver Designed for Low-Power Wireless Apps in 2.4 GHz ISM Band” (see : http://focus.ti.com/docs/prod/folders/print/cc2500.html )
  • Luxeon K2 : Lumileds ( http://www.lumileds.com/products/line.cfm?lineId=18 )

I didn’t have the nerve to crack open the lamp itself.  Someone else did.

Patents

  • EP 05110865.2
  • EP 05111947.7
  • EP 06111044.1
  • EP 06111041.7
  • EP 06114311.1
  • JB8978

Publications

Elektor article about hacking the protocol (in dutch).

Jeroen Domburg expains how he reverse engineered the Living Colors protocol and show how to build a USB remote controller for the LivingColors lamp.

See : http://www.elektor.nl/artikelen-als-pdf/2008/mei/kleurig-computerlicht.429788.lynkx
And : http://meuk.spritesserver.nl/projects/livcol

Elektor article about disassembling the lamp (in dutch).

The editors from Elektor disassemble a LivingColors lamp and remote and comment on what is inside.
See : http://www.elektor.nl/artikelen-als-pdf/2008/februari/philips-livingcolors.350438.lynkx

YouTube

http://www.youtube.com/watch?v=pxv-kFQdD3w

Official Site

http://www.lighting.philips.com/microsite/living_colors/ (link broken)

Testing plugins in WordPress

WP-Syntax is a syntax highlighter for WordPress. Not sure if i like it..

Code Colorer is a different syntax coloror

WP-Syntax and are both based on Code Colorer GeSHi

SyntaxHighlighter Evolved is does the Syntax Highlighting in Javascript and is based on SyntaxHighlighter from Alex Gorbatchev

Let’s compare the options:

XML / GML

WP-Syntax

      
          
              
                  
                      
 222589.799 433765.081 222567.148 433755.043 222555.526 433748.222 
 222553.978 433747.425 222540.611 433739.534 222539.611 433722.180 
 222566.459 433681.207 222575.316 433666.027 222584.647 433670.364 
 222586.846 433671.386 222595.805 433676.184 222605.758 433681.096 
 222630.792 433693.222 222634.298 433694.711 222644.841 433699.628
 222663.798 433708.937 222589.799 433765.081
                    
                  
              
          
      

Code Colorer
[cc lang=”xml” line=”1″]

222589.799 433765.081 222567.148 433755.043 222555.526 433748.222
222553.978 433747.425 222540.611 433739.534 222539.611 433722.180
222566.459 433681.207 222575.316 433666.027 222584.647 433670.364
222586.846 433671.386 222595.805 433676.184 222605.758 433681.096
222630.792 433693.222 222634.298 433694.711 222644.841 433699.628
222663.798 433708.937 222589.799 433765.081

[/cc]

SyntaxHighlighter Evolved

[xml escaped=”false” line=”1″]

222589.799 433765.081 222567.148 433755.043 222555.526 433748.222
222553.978 433747.425 222540.611 433739.534 222539.611 433722.180
222566.459 433681.207 222575.316 433666.027 222584.647 433670.364
222586.846 433671.386 222595.805 433676.184 222605.758 433681.096
222630.792 433693.222 222634.298 433694.711 222644.841 433699.628
222663.798 433708.937 222589.799 433765.081

[/xml]

File inliner + Code colorer
[file lang=”xml” start=”1″ end=”18″ link=”on” preserveformat=”on”]http://www.knutsel.org/wp-content/uploads/2011/08/gml_example.xml_.txt[/file]

WP-Syntax

void PrintAdress()
{
  for (int l=0; l<livcol.getNumLamps(); l++)
  {
    if (livcol.getLamp(l,adress))
    {
      Serial.print("[");
      Serial.print(l);
      Serial.print("] ");
      for (int x=0; x<9; x++)
      {
        Serial.print(adress[x], HEX);
        Serial.print(", ");
      }
      Serial.println("");
    }
  }
} 

Code Colorer
void PrintAdress() { for (int l=0; l <livcol.getNumLamps(); l++) { if (livcol.getLamp(l,adress)) { Serial.print("["); Serial.print(l); Serial.print("] "); for (int x=0; x<9; x++) { Serial.print(adress[x], HEX); Serial.print(", "); } Serial.println(""); } } }

SyntaxHighlighter Evolved

[sourcecode language=”c”]
void PrintAdress()
{
for (int l=0; l
<livcol.getNumLamps(); l++)
{
if (livcol.getLamp(l,adress))
{
Serial.print("[");
Serial.print(l);
Serial.print("] ");
for (int x=0; x<9; x++)
{
Serial.print(adress[x], HEX);
Serial.print(", ");
}
Serial.println("");
}
}
}
[/sourcecode]

File inliner + Code colorer
[file lang=”c” start=”1″ end=”10″ link=”on” preserveformat=”on”]http://www.knutsel.org/wp-content/uploads/2011/08/c-example.c[/file]

Knspr-ImgNote lets you put notes on images.