Javascript 7-segment RGB LED experiment

Before I get into what this entry is really about, I wanted to share a scary piece of JavaScript with you — here’s some code that checks what other websites you’ve visited (in all browsers that I tested). The idea and implementation isn’t mine, and it’s done quite simply — by examining the link color. If it’s visited, it’s got the “visited” color. If not, it’s got the “not visited” color. So it can’t actually read your browsing history, but it could certainly check if you’ve visited competitors and so on, and of course it can do it all in the background, for thousands of sites, without you even knowing it. Scary stuff… I’m sure that many advertising networks do it.


In the theme of funky Japanese watches (and continuing JavaScript experiments), I read somewhere about the idea of using RGB 7-segment LEDs to display the time by writing hours, minutes, and seconds to R, G, and B separately — overlaying them in different colors in the same space. On one hand I thought, that’s a neat idea that might work, but on the other hand, I thought, that’s going to be very hard to train your brain to see on something as low resolution as a 7-segment display. So I wrote a quick set of Javascript functions for controlling virtual 7-segment LEDs and tested the idea.

And yeah, very hard to read! That said, after having to look at it a bunch (tested it in Chrome, IE, and Firefox), maybe it would be a fun watch to build. Either way, maybe the Javascript is useful to someone.

Oh! And… check out the blurry version. In a lot of ways it’s much cooler. It’s exactly the same code, just using different images (well, actually, the same images, just blurred in a photo editor!).



  1. Elaine wrote:

    I can really only make sense of it if I cross my eyes a bit… like with those magic eye pictures.

    Monday, April 27, 2009 at 10:08 am | Permalink
  2. Celepr0n wrote:

    I just can’t figure out how the second clock works… maybe i’m too dumb :D

    And i like the blurry version – much easier to recognize

    Tuesday, April 28, 2009 at 4:31 am | Permalink
  3. Skoddie wrote:

    I’d be interested to see how readable it is without the seconds displaying. Perhaps without it changing too often it would be easier to perceive.

    Tuesday, April 28, 2009 at 12:42 pm | Permalink
  4. lucas wrote:

    The script didn’t work for me…

    Tuesday, April 28, 2009 at 2:58 pm | Permalink
  5. Shannon wrote:

    Huh! What browser are you using? I assume you have Javascript turned on?

    Tuesday, April 28, 2009 at 3:04 pm | Permalink
  6. ELY M. wrote:

    I love LEDs :D
    I have LED watch :)

    Tuesday, April 28, 2009 at 6:02 pm | Permalink
  7. Stuart wrote:

    RBG Clock, thats brilliant. Doubt I could train myself to use it though.

    About the Javascript history vulnerability. Your post was made over one year ago. And in Chrome.. it still works!

    Sunday, July 11, 2010 at 5:24 pm | Permalink
Wow Shannon, that's really annoying! What is it, 1997 on Geocities? Retroweb is NOT cool!

Post a Comment

Your email is never published nor shared. Required fields are marked *