32×24 LED matrix

Introduction

This project was part of a course I attended in back in 2008, during my studies. We were supposed to do something with a Renesas-based microcontroller board that we had built earlier in the course. I think we built the microcontroller board in November 2007. After spending some time figuring out what I wanted to do with the microcontroller, I decided to build a small LED screen and interface that with microcontroller board. As the project moved forward, I added a gamepad and wrote three games to the microcontroller, which users were able to play on the LED screen. Because of a harddrive crash 2 years ago I’ve lost a lot of schematics and documentation on this project, so therefore I can’t go into too much detail on this project at the moment.

Microcontroller board

The core of microcontroller board is a Renesas H8S/2357 microcontroller. Other components on the board are an external 128kb SRAM, a USB to RS232 converter, rotary switch, buttons, LCD and a connectors for the microcontrollers IO-ports. Programs for the microcontroller were written using KPIT GNU Tools, a free C-compiler for Renesas microcontrollers. I highly recommend using it, good support from the community and it worked like a charm. Here are some pictures of what the microcontroller board looks like:

LED matrix board

The LED matrix board is based around the Max6960 chip from Maxim. This chip can drive one bicolor 8×8 LED matrix or two monocolor 8×8 LED matrices. Each LED can have 4 different levels of intensity, so this gives 4 intensity levels of red and 4 intensity levels of green. This gives a total of 16 different color combinations for each led on the 8×8 matrix. Inside the chip there are also two memory planes, one visible and one invisible. These can be toggled so that the invisible plane becomes visible and the visible one becomes invisible, I guess you can call it dubbel buffering. This eases animations a lot and helps to remove flickering during display updates.

The Max6960 chips are controlled by the microcontroller board using a common 4-wire SPI interface. But that is not all, the Max6960 chips on the board are interconnected with each other using a local 3-wire interface. One of the purposes of the local 3-wire interface is to enable automatic addressing of the each device, depending on how they are connected to each other. This is actually a really neat feature. Once the devices have been powered up and configured, you can start sending data to them. The two memory planes I mentioned earlier are seen as a one continous memory on the microcontroller. This makes it a lot easier to send new data to the matrix board. I must admit, I did read through the datasheet quite a few times before I understood how everything worked, but it is quite simple once you get the hang of it. The board is a single-sided board, so I had to use a few jumper wires here and there. It really should have been made as a dubble sided board, but anyway, this is what the board looks like:

Power supply and level converter

The LED matrix board runs on 3.3 volts and the microcontroller board runs on 5 volts. Because of this I had to make a 3.3 volt power supply and a level converter board for the digital signals. The power supply had to be capable of delivering enough current to drive all leds, peak current for the board can be almost 4 amperes. It is a linear power supply, so it generates quite a lot of heat if it is powered with voltages above 7 volts. It is based on two LM317-regulators and they have a voltage drop of about 3 volts, so the power supply should be driven at around 7 volts to function properly and to avoid excessive heating. The level converter board consists of two buffer chips, one chip converts 5 volt signals to 3.3 volt signals and the other one converts 3.3 volt signals to 5 volt signals. This is what the power supply and level converter board looks like:

Gamepad

The last part of this project is the gamepad. The gamepad was built around a Max7300 port expander chip. I²C is used for communication between the gamepad and the microcontroller board. There are 10 buttons on the gamepad and 9 LEDs. Each led can be turned on or off from the microcontroller board. It kinda looks like a crude version of a NES controller.

The final setup

Once all circuit boards were built it was time to connect everything together. So, this is what it looks like when everything is hooked up:

Some pictures from the first tests.

Pictures of the three built-in games, Snake, Pong, and Tetris.

And two videos of it in action.

 

4 Comments


  1. please can you share shematics and programme for this project??

    Reply

  2. Sorry, I’ve lost them after a hardrive crash.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *