First test

Enough theory, on to the hardware!

I decided to build an one-board test at first to see if the uC I chose actually was quick enough to sustain the grayscale-procedure while sending out enought frames a second for a stable image. I built just a simple thingy that could display an image plus a little something to actually generate that image. I decided on using the ATMega88 as a processor: If I wanted to use grayscale, it would be easiest to implement graphic memory as one byte per pixel. That meant I had to have at least 16*32=512 bytes of RAM. The ATMega88 was about the cheapest processor I could find that was both quick enough to churn out pixel data at acceptable rates and had >512 bytes of RAM.

As you can see, the schematic is almost trivial: the uC is directly wired to the LED-display and is clocked by a 20MHz crystal, 20MHz being the maximum the ATMega88 is able to run on. There's a serial port which initially was only used for debugging purposed.

Hardware-wise, it's implemented as a piece of prototyping board directly connected to the header and power-connection of the LED-board. It ended up being a lovely small doughterboard in the corner of the led-PCB.

With the hardware in place, I started with creating the grayscale routines. I ripped a plasma routine from another project I had done, and after some programming and debugging, I ended up with this:

Seeing how this gave a lovely effect, I decided to give real video a try. I hacked mplayer so it would spit out grayscale values to a serial port. I also implemented a lookup-table to convert grayscales to PWM-values. This was necessary because the human eye doesn't interpret PWM-values as linearily as they are. For example, changing the PWM value of a LED from 0 to 10% looks as a huge change, while changing the PWM-value from 90 to 100% is almost invisible. The implemented lookup-table compensated for that.

The result was a nice monochrome lo-res display. (If you can't recognize the video image, try sitting further from your monitor. The clip playing is this one.)

« Prev 5 Next »

© 2006-2022 Sprite_tm - Contact