Raspberry Pi Retro Gaming LED Display

20x10 WS2812 LEDs driven by Raspberry Pi/Arduino to play games like Tetris in the living room

Similar projects worth following
I am building a retro gaming display for my living room to play games like Tetris or Snake with a wireless controller while I am sitting on my sofa. 10 columns of WS2812 LED stripes are integrated in a lasercutted MDF frame, which is covered by a transparent wood veneer. The heart of the system is a Raspberry Pi A+ which is integrated in the MDF frame. This Pi is connected to an Arduino driving the LED stripes. Four 8x8 Matrix displays are combined to a highscore display which is also connected to the Pi via SPI.

The wireless controller is based on an ESP8266-IoT-board, which connects to the Pi over Wi-Fi. A Joystick and four Arcade buttons are used for game controlling. The controller is powered by a LiPo and could be charged by a microUSB connector.

Based on the python_games package coming with Raspbian, all games are written in Python.

This project was inspired by Türtris:

Check the videos on Youtube



Adobe Portable Document Format - 13.96 kB - 06/12/2016 at 14:51


CAD files for MDF matrix

Zip Archive - 306.31 kB - 05/04/2016 at 15:44


  • 1 × Raspberry Pi A+
  • 1 × Arduino Pro Mini
  • 200 × WS2812 LED (stripes 30 LED/m)
  • 34 × Lasercutted MDF
  • 1 × Joystick

View all 7 components

  • UART speed issues

    makeTVee01/26/2019 at 05:07 0 comments

    After discussing this issue with several people who want to build their own matrix, I decided to sum up the main points in a project log.

    In the newer versions of the Raspberry Pi with integrated Bluetooth like Pi3B/B+, ZeroW and the new 3A+, the hardware UART is used for the Bluetooth module. The second UART, which is connected to the extension header, is a software UART implementation. This second UART seems to be limited to 250kBaud. You can read more details on this website:

    This project uses 500kBaud for transferring the LED data between Pi and Arduino. I am using an old, non-Bluetooth Pi A+. The only thing, I have changed, was adding this line at the end of the /boot/config.txt :


    There is an option to change the UART configuration on newer Pis by connecting the hardware UART to the extension header and the software UART to Bluetooth:

    I didn't have time to test this, but it looks quite straight forward. Also if there are other solutions, I will update this post.

    Of course, it is also possible to reduce display update timings to reduce the UART speed to 250k. 

  • Data visualization (German parliament)

    makeTVee09/29/2018 at 15:25 0 comments

    I just started to play around with parsing data from internet sources to the matrix. 

    Starting with this page (German parliament seat distribution):

    and extracting data and colors from the SVG image using this code:

    doc = minidom.parse('diagramm.svg')  # parseString also exists
        style_string = [path.getAttribute('style') for path in doc.getElementsByTagName('path')]
        label_string = [path.getAttribute('aria-labelledby') for path in doc.getElementsByTagName('path')]
        text_string = [text.getAttribute('id') for text in doc.getElementsByTagName('text')]
        data_string = [text for text in doc.getElementsByTagName('text')]
        for i in range(0,7):
        for i in range(0,text_string.__len__()):
            if text_string[i]==label_string[index]:
                percentage.append(int(round(200*int(data_string[i]._get_childNodes()[0]._get_data().split(": ")[1])/709)))
                if index < label_string.__len__()-1:

    So after sending this data to the matrix, I got this:

     Nice starting point...

  • Matrix size

    makeTVee04/28/2018 at 13:19 0 comments

    After several questions regarding code adaption for different matrix sizes, python code now has global pixel settings called PIXEL_X and PIXEL_Y.

  • Controller details

    makeTVee03/04/2017 at 07:47 0 comments

    I have uploaded the Arduino sketch of the ESP8266 based controller to Github.

    Wiring is pretty simple, using a Sparkfun Thing and a single cell LiPo.

  • Schematic

    makeTVee06/12/2016 at 14:58 0 comments

      The schematic is now available. There are only three relevant connections:

      1. UART between Pi and Arduino (connected DTR-pin for programming the Arduino firmware from the Pi), with a simple voltage divider for 5V to 3.3V conversion
      2. SPI for the MAX7219 matrix display
      3. Serial connection from Arduino to the WS2812 stripes

  • Android app control

    makeTVee05/26/2016 at 20:40 1 comment

    Instead of the retro controller there is also a small Android app for game control. It provides the same functionality, so no additional controller hardware is needed if you already have an Android device.

    There is a video on Youtube showing the app in action:

  • Github

    makeTVee05/12/2016 at 19:33 0 comments

    Python code and Arduino sketch now on Github. I will add more documentation how to use the code within the next week.

  • Veneer application

    makeTVee05/11/2016 at 19:24 0 comments

    In reply to a comment, I will describe how to apply the veneer paper to the MDF matrix. The veneer I have used, is called Microwood, which is a 0.1 mm veneer with paper backing.

    Before the final full-surface bonding onto the MDF matrix, I did some pre-testing with the glue and the surface preparation of the MDF. To avoid paper curling after the adhesion, I used a solvent based all purpose adhesive (UHU black), which worked as expected. For testing purpose, the black laser cutting edge on the MDF surface was removed with sand paper:

    The following image shows the veneer glued on the MDF sanded off (right) in comparison to the veneer glued on the more or less black MDF. For me, this difference was not enough to polish all the MDF parts and the final result proved me right.

    Because of the paper backing, it is quite easy to apply the veneer and there is no problem with dissolving, although the veneer was rolled up when it arrived.

    If you have any questions, leave a comment.

  • CAD files

    makeTVee05/04/2016 at 15:49 0 comments

    I have now uploaded the DXF files of the MDF matrix. I have used 3mm MDF. The next version will be a combination of MDF and cardboard to save some cost.

  • Weather forecast

    makeTVee04/27/2016 at 19:42 1 comment

    Running Python code on the Pi makes it so easy to realize new features. This is a quick preview of getting a weather forecast on the LED matrix. Using PyOWM to talk to OpenWeaterMap and some 10x10 pixel weather icons, that's it.

    Planned features:

    • animated icons
    • 7 day forecast (slideshow)
    • Barbecue forecast

View all 12 project logs

Enjoy this project?



ourharlequin wrote 01/05/2019 at 09:18 point

Thank You. I will try this! Really want to test yours project on my matrix;)

  Are you sure? yes | no

ourharlequin wrote 01/03/2019 at 21:06 point

Hi. I have a question how to set uart between rpi 3b+ and arduino nano. I already use logic level converter. Maybe I need an extra sketch for arduino or special soft, python module? 

  Are you sure? yes | no

makeTVee wrote 01/05/2019 at 07:07 point

As far as I know, Raspberry Pi 3 (and Zero W) are different from the UART compared to all other (non Bluetooth) Pis. Please check this link for more information 

You also need pythons-serial lib. 

Hope that helps.

  Are you sure? yes | no

ourharlequin wrote 01/16/2019 at 15:18 point

Still try to connect pi and arduino by uart:( Maybe You have variant of py file without arduino and uart?

  Are you sure? yes | no

makeTVee wrote 01/26/2019 at 05:08 point

please check my new project log

  Are you sure? yes | no

renatoberrezueta23 wrote 12/03/2018 at 16:25 point

Hello, maybe you have the connection schema of the matrix, i'll be thankful if you can help me with that.

  Are you sure? yes | no

makeTVee wrote 12/04/2018 at 20:56 point

Hello, there is no document right now, but I have started in the lower left corner and then zig-zag connected the stripes ending in lower right corner with the last pixel. Power is distributed to all the stripes from the lower side (you can see it on one of my first project logs). 

  Are you sure? yes | no

Patrick wrote 07/10/2018 at 20:13 point


is there any preferred supplier for laser cutting of the MDF material? is one option, cost approx. 200 euro for one complete set. any suggestion for other suppliers / less costs?

  Are you sure? yes | no

makeTVee wrote 07/22/2018 at 06:27 point

For lower costs, maybe use "Finnpappe" instead of MDF, but it has a different thickness, so you have to change the design. Today I would go to the next fablab to do the laser job.

  Are you sure? yes | no

paulakoden wrote 07/04/2018 at 04:32 point


Really like your project currently making one of my own any chance you could send me apk for the controller

  Are you sure? yes | no

makeTVee wrote 07/22/2018 at 06:30 point

The app currently only works for Android version lower than 7.0. Please send me a PM.

  Are you sure? yes | no

Patrick wrote 06/16/2018 at 07:41 point

Hello all,

very cool project and I just had a look to the software packages required. Obviously the MAX7219 library of the referenced source has changed a lot as it has been developed further on with new features.

Is there a quick fix to use the new library or is everybody using the previous version?

I assume it is all under python3, correct?




  Are you sure? yes | no

makeTVee wrote 06/28/2018 at 04:42 point

Thanks! I didn't look at the new lib yet, I will try soon. 

Yes, it is all python3

  Are you sure? yes | no

gamer1966 wrote 09/10/2018 at 19:55 point

Without many knowledge in Pythgon, i've changed the code to work with the new libraries. Thanks to Google. You can find my code at:

  Are you sure? yes | no

leelossy wrote 05/10/2018 at 17:11 point


Very cool project, we are building the same just with pi zero. Can you please send me the android app?  We will be using this for childrens to try the old games at big display :)

Thanks for the help!


  Are you sure? yes | no

Ray Sotkiewicz wrote 03/08/2018 at 23:40 point

Just joined this project. I'm involved in a hack-a-thon event at work and this project is what we're going to use to get familiar with Python.
My problem is that I can't find any of the supporting files to load into the Pi and the Arduino.

Can you point me in the right direction?


  Are you sure? yes | no

makeTVee wrote 03/09/2018 at 04:41 point

Sounds great! For source code check out my Github page

  Are you sure? yes | no

Ray Sotkiewicz wrote 03/14/2018 at 22:28 point

Thanks! It's looking good so far. My LED matrix is 10 columns x 30 rows. (An impressive sight) Just need to figure out how to load the MAX7219  library and I should be off and running. 

  Are you sure? yes | no

diego gonzalez wrote 01/25/2018 at 08:57 point

Hello. I have a problem with your project. 

Im working on this now, but I cant connect with led matrix. 

When I execute and controller sim, I can see tetris on my monitor, but I cant see nothing on my led matrix. 

I execute the samples of the library (luma led matrix) and works fine on led matrix, but when I open the with python, the matrix dont work

Can you help me please?

Pd: Can you send me the android app? Thanks for all

my mail :

  Are you sure? yes | no

ymmas wrote 10/02/2017 at 12:42 point


I found your project by reading much about led coffee tables. And now i am building my own table and i would like to use your code. Later i hope i can integrate the table to fhem.

My matrix is  24 X 14 and i use ws2812B, a raspberry3 and an arduino nano. I set the baudrate up to 1.000.000.

My problem seems like the same from grim, posted  03.07.17 in his gallery.
You were ready to betray, how do you make the android app?

Sorry for my bad english :)

  Are you sure? yes | no

makeTVee wrote 10/17/2017 at 18:39 point

please send me a pm and I will send you the android app.

  Are you sure? yes | no

zombinary wrote 09/29/2017 at 20:50 point

Very nice Porject, but i have many problems to run the phyton scripts on my rpi zero.
This is my first contact with python an the '' returns an 'segment fault'. Also it is not possible to run the '' script. The library 'socketserver' isn't found and i could not install the module PIL.

I using an pi zero W with '2017-09-07-raspbian-stretch-lite.img'

Has somebody run this script on pi zero?

  Are you sure? yes | no

makeTVee wrote 09/30/2017 at 16:24 point

controller_sim is a simulator to test the code on a PC, so not needed for running the code on a Pi. 

Please use python3 for socketserver. 

  Are you sure? yes | no

Grim wrote 07/15/2017 at 02:44 point

Hello, it's me again. Good news is that I finished the project in time. Here is a picture if you're interested with how it turned out:

For some reason I cannot reply to the other comments. However I had a question about the "boot logo" that the teensy displays during the Pi's boot. How did you create that? I am looking to change it however I'm not sure why but when I change the code, I get a crash. Thanks.

  Are you sure? yes | no

makeTVee wrote 07/15/2017 at 06:16 point

That's awesome! Thanks for sharing the image!

For the boot logo i have used GIMP, because it has an option to export c files (.c or .h). Afterwards you can edit the image in a text editor.

  Are you sure? yes | no

Grim wrote 07/15/2017 at 19:25 point

Thanks, eventually I want to have more games and whatnot added. I've been thinking about pacman but haven't figured out how I'd do it. I downloaded gimp and I've exported a picture both to .c and .h however I am not getting the hex values as you did. This is what I get: 

Again thanks for the help.

  Are you sure? yes | no

makeTVee wrote 08/07/2017 at 18:13 point

I am back from summer vacation, sorry for the delay. It's been a long time ago, maybe I'm wrong. I tried gimp for sure, but maybe later I used a different tool to convert RGB bin data to Hex string, ending up with tools like Matlab/Octave or something else. If I find the tool again, I'll let you know. 

  Are you sure? yes | no

Grim wrote 03/09/2017 at 14:39 point

hey man, really liking your project! I'm currently building a 32x32 Matrix very similar to yours and came across your project after I've already started. I've decided to use your program to run the matrix as a main goal of this was able to play pong, Tetris, and snake. Which yours does! However I'm having some issue with the code. When I play Tetris, the shape will show the entire time going down the board but after it lands, the shape disappears. It only does this for the first 12 or so led rows. Also the clock does not show properly. I've added links to 2 gifs that show the issues I'm having. If you'd be willing to help that'd be great. I'm only using a 16x32 panel right now as I'm working on the build part of the matrix. Your help is greatly appreciated

  Are you sure? yes | no

makeTVee wrote 03/10/2017 at 15:35 point

Did you changed in simulation mode first? I will test it over the weekend and come back to you soon.

Could be a timing issue, because you have 2.5x more LEDs. Are you using the same PI/Arduino setup at 500kbaud?

  Are you sure? yes | no

Grim wrote 03/11/2017 at 00:23 point

What do you mean changed in simulation mode first? If you mean tested, I changed the values however they did not reflect in the simulator. Snake works properly and uses the entire board. It is just the other ones that I am having issues with. I have yet to add the 4 8x8 LED's. Here is a screenshot of my options:

Also, I am currently using an Arduino Mega and RPi3. I was originally intending to use the teensy 3.6 however your provided sketch is not compatible with the teensy 3.6.

  Are you sure? yes | no

makeTVee wrote 03/11/2017 at 15:46 point

Did you changed the pixel values in the drawBoard function (line 1042)? 

  Are you sure? yes | no

Grim wrote 03/13/2017 at 18:28 point

good news: somehow got the teensy to work so switched to that and it fixed most my problems. Now I just have to resize the various components. Pong doesn't use the proper borders and I can't find in the code where it specifies the borders. Also I can't change the clock size, I get a crash every time. Not sure if I'm changing them right

  Are you sure? yes | no

makeTVee wrote 03/21/2017 at 19:09 point

Pong does not scale yet, sorry for the code, it was really quick and dirty. For changing the clock size, you have to change the font via the clock_font array. How is your progress? 

  Are you sure? yes | no

JM wrote 02/27/2017 at 11:51 point

Hi makeTVee,

this is really great stuff!!!

I´m very interested in your controller. 

Can you give me some details on wiring and code?


  Are you sure? yes | no

makeTVee wrote 02/28/2017 at 19:56 point


thanks and good point, I will add this information shortly to the log/github

  Are you sure? yes | no

bvanasselt wrote 11/16/2016 at 20:34 point

Hi - Thanks for sharing!  Working on something very similar with my son for a Christmas project.  Any chance of posting any of your code?  Would give us a great starting point for our own project - this is, by a mile, the most ambitious project we've undertaken and we're a bit in over our heads. 

Either way, thanks again for sharing!

  Are you sure? yes | no

makeTVee wrote 11/16/2016 at 22:36 point

Sounds great, you will find all the code on Github:

  Are you sure? yes | no

bvanasselt wrote 11/17/2016 at 22:20 point

Thanks!  I see now that you had already posted that link.  I don't know how I missed it.  Sorry about that.  Thanks anyway for the fast reply!

  Are you sure? yes | no

anders wrote 07/11/2016 at 21:07 point

I have been looking for a project like yours for long time!
I'm pretty new to Raspberry Pi. Is there an easy way to connect controller directly without having to change too much code? Instead of wifi.

  Are you sure? yes | no

makeTVee wrote 07/12/2016 at 18:21 point

Sure, you can connect a keyboard or gamepad to the Pi via USB. Then use the event system from the pygame lib which I have used in the 

Only small changes in the code are necessary, if you tell me your controller type, I will provide you some example code.

  Are you sure? yes | no

Wayne Verish wrote 06/03/2016 at 14:34 point

All these projects are very interesting. So much talent, so many great ideas.

  Are you sure? yes | no

stevemoseley wrote 06/03/2016 at 13:23 point

Any updates coming soon?  Would love to get more detail on this.

  Are you sure? yes | no

makeTVee wrote 06/05/2016 at 10:25 point

Quite busy these days, next updates will be a schematic and some details regarding the MDF frame and a more detailed part list.

  Are you sure? yes | no

stevemoseley wrote 06/06/2016 at 00:04 point

Fantastic.  Looking forward to it.

  Are you sure? yes | no

stevemoseley wrote 05/13/2016 at 15:41 point

I've been looking for details for building something like this.  Looking forward to seeing more about it and diving into the details.

  Are you sure? yes | no

makeTVee wrote 05/18/2016 at 14:53 point

Sounds great, do you have an idea regarding the overall size and the number of leds for your project?

  Are you sure? yes | no

stevemoseley wrote 05/18/2016 at 16:43 point

Similar size to your project.  Just wanting something large that can be on the wall.  I was thinking a 5 to 6' tall field.  I was considering trying to program something that was only on an Arduino, but that might be a bit of a challenge for me.

I love the added score and next piece at the bottom.

I would like to have it switch between an LED clock mode and Tetris mode when not being played.  You could have the time rotated 90 degrees or have the hours stacked on top of the minutes.

Will you be adding more detail to the build?  I was hoping you would get it to the point that others would be able to use the information to build their own.


  Are you sure? yes | no

makeTVee wrote 05/19/2016 at 07:05 point

Sure, I will add more details for rebuilding. But during this process, I will also fix some issues from the first version, so it will take some time. 

And there are also some new features in the pipeline ;-)

From the programming side, it would be the easiest way to combine the Raspberry Pi with one of the availiable Arduino addon boards for the Pi and slightly adapt my software.

  Are you sure? yes | no

stevemoseley wrote 05/19/2016 at 18:38 point

MakeTVee - That would be great.  I look forward to the next improved version.

Thanks for your input.

Another thought I had was mounting the LED board on a swivel in the center so it can be rotated 90 degrees.  Might make using it as a digital clock a little more appropriate in landscape mode.

  Are you sure? yes | no

mclien wrote 04/25/2016 at 20:44 point

I would like to see a log with abit more detail about the veneer apply method, any fotos/ docu about that?

And a question (for the next Türtris Version) :  How  good is the length tolerance of the LED strips (how much difference after 1m/ 5m)?

  Are you sure? yes | no

makeTVee wrote 04/27/2016 at 16:24 point

I will address this veneer topic in one of my next logs. 

The length tolerance is an issue, there is an offset of minus 2-3 mm/m, but this offset is quite constant. 
For these longer strips, 50cm-strips are soldered together and there is some overlapping at the connection point. Might be avoided by re-soldering these points.

  Are you sure? yes | no

makeTVee wrote 05/11/2016 at 19:28 point

Now there is a log focused on the veneer topic. Hope that helps.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates