Saturday, November 30, 2013

YALEDD! 16x16 LED Display

I would like to present to you "Yet Another LED Display" (YALEDD!): a 16 by 16 LED Display. I am currently taking an engineering project management course and one of the objectives is to take a circuit from design to implementation while sticking to a schedule that we define.

The class was instructed to choose a simple circuit such as an LED flasher or a simple sequential state machine composed of discrete logic, capture the schematic, layout the PCB and have it made by the end of the term.

I decided that it would be boring to design a simple state machine. I also thought it might be pretty cool to have an electronic gizmo of my own design to show off on my desk at work.

Something Special :]
This display utilizes constant current LED drivers to regulate 10mA through each of the LEDs. I have not used multiplexing to drive this display. I've done multiplexing in the past, and the STP16CPC26 drivers looked like they would be fun to experiment with. The entire design uses surface mount technology (aside from a couple of connectors) and was hand assembled by yours truly.

PCB Back
A Sea of LEDs


YALEDD! includes numerous features:

  • FTDI UART to USB Interface
    • UART Activity LEDs
  • ATMEGA1284P Microcontroller
  • STP16CPC26 16 Channel LED Drivers
  • JTAG Debugging Interface
  • Separate LED Power Connector

The microcontroller that I have chosen is largely overkill for a project of this complexity. I chose it because I did not want to limit myself to what I could do in software. The display currently acts as a UART slave device using a simple protocol to set/clear pixels, write the internal buffer to the LEDs and clear the display. In the future, it would be nice to have provisions for stored animations or user defined characters to make it easy to create a clock (digital or analog with this resolution) or a simple "Deli Counter".

Implementation Details

The entire design is fit to a 2-layer PCB and uses SMT components. I have some concerns about the thermal performance of this device. When all of the LEDs on the panel are lit, the display generates a large amount of heat. This is due to the linear current regulators for the LEDs dropping nearly 1.5V at 10mA each.

I chose the large USB-B connector to reduce the soldering effort. My original design included an SMT Micro-USB connector, but I decided that it would be too difficult to solder.

Software Details

Communications with the display are very simple. The protocol is handshake driven. You send it a command and it responds with a 0x65 ('A') to indicate that it was successful in whatever you asked it to do. If you send it an invalid command, it simply ignores it.

I have written a simple driver in LabVIEW in order to drive the display. I would normally do something like this in C#, but I wanted access to their easy to use FFT library. I plan to implement a driver in C# soon and run it in Mono on a RaspberryPi.

The following simple test application simply writes 33 bytes to the display. The first byte instructs the display that the following 32 bytes contain pixel data. The remaining 32 bytes indicate the state of each of the 256 LEDs.

Simple Test
I then wrote a more complex example that uses FFT to generate a nice audio visualization.

FFT Audio Visualization
I am using event driven programming techniques in LabVIEW using a queue to synchronize the threads. The code is a bit messy. I could spend some time breaking it down into SubVIs to make it easier to debug, but it works. This has become a sort of scratch pad for me to experiment with the display.

FFT Audio Visualization Source


It is a bit late, but I am eager to get this blog post out. I will post a video of the audio visualization soon, but for now I have some pictures of the build to share.

Microcontroller and FTDI

LED Current Regulators
Audio Visualizer
I had the board made by the guys over at Pentalogix. They did a great job of getting the board turned around quickly (despite a minor error in the process).

Stay tuned for a video demonstration. Thanks for reading!

No comments :

Post a Comment

Note: Only a member of this blog may post a comment.