Table of contents

Abstract
A fun little Christmas display project with full build instruction. If you can’t wait for Santa to visit this display will automatically count down to his arrival. Suitable for "kids" of "all" ages.
Project
Requirements
The hardware is designed to be as simple as can be using low cost modules. All the electronics cost me less than £7.
You will need the following...
- ESP D1 Mini or equivalent ESP8266 module
- MAX7219 quad dot matrix module
- 5 jumper wires
- A USB cable
- 3D printed case (optional)
- Laser cut 3mm acrylic display window (optional)
- Rubber feet (optional)
You will also need a computer with the Arduino IDE (or equivalent) set up for programming the ESP module. A soldering iron is also required for some basic soldering.
The Electronics
At the heart of the system is a low cost ESP8266. This will connect to the Internet to get the correct date and time so there is no need to set the time or have a clock battery. It also renders the text to display and talks to the MAX7219 matrix drivers to control the display. I have used a D1 Mini module as this is low cost ESP8266 module that includes power regulation to 3.3v, but the code is platform agnostic and other microcontroller modules can be used if you have one in a drawer. The only changes you will need to make is to the pin assignment, and to use the wifi library appropriate for you board.
As we are using the ESP8266 SPI hardware to communicate with the display drivers we need to use D7 and D5 for the data and clock. We can use almost any pin for the chip select so I have used D8 for no other reason than to make the soldering slightly easier. Be warned that other projects use different pins so don't try and assemble this from memory. Ask me how I know ;-) .
To connect the microcontroller to the display module connect D7 to DIN (data in), D5 to CLK (clock), D8 to CS (chip select), G to GND and 5V to VCC. If in doubt copy these photographs.
Software
The software is a simple Arduino application (santacountdown_firmware.ino) with a separate library (font6x8.h) containing the font. These can be downloaded from my GitHub page . The code is intended to be accessible and easy to understand by anyone. It is commented throughout if you want to dig in to it and learn more.
The easiest way to upload the code is to use the Arduino IDE. You will also need to install the LEDMatrixDriver library from Bartosz Bielawski to communicate with the MAX7219 display drivers. You can simply search for this in the Arduino library manager, or download it directly from https://github.com/bartoszbielawski/LEDMatrixDriver of you are using a different IDE.
Before uploading the code you will need to make a couple of configuration changes for your location and your wifi. The wifi details are on lines 23 and 24 (MY_WIFISSID and MY_WIFIPSK) and are hopefully self-evident.
The default time zone is configured on line 27 (MY_TZ) and defaults to GMT/BST. For anywhere else in the word simply look up the POSIX timezone string for your location (there is a good list at https://github.com/nayarsystems/posix_tz_db/blob/master/zones.csv ) and enter it in to this line.
All the other configuration settings should be fine as they are unless you want to improving the design or personalise things. The display brightness is set on line 92 but a value of 0 is normally bright enough. If you want to change the wording of the text then edit line 125, and the text on line 121 will be displayed from Christmas day to the new year. There is nothing stopping you from adding more features yourself, and if you do please consider sharing that with others.
After configuration click the upload button in the IDE and the hardware should connect to the wifi, get the current date, and start scrolling the message.
Please note that I may have gone a little overboard on making the code will deal with leap years for thousands of years into the future, especially as the Arduino time library may require updating before 2036. It may be a silly little project, but I want it to be at the top level of quality and excellence in execution of a silly little project. That and someone may use the code in a different project that is more important.
The Enclosure
The case I have designed does require a 3D printer for the main body, and a laser cutter for the face plate. Not everyone has access to these, but it is now affordable to order online. Alternatively make your own design out of cardboard, Lego, or anything else you have available.
The 3D printed part comes in two halves that can be downloaded from my GitHub page. I printed mine in galaxy black PLA so it sparkles. The face palate is cut from 3mm acrylic and can also be downloaded from the GitHub page as well. Clear acrylic will work fine, but I have found using a colour that matches the colour of the matrix display improves the look and feel.
Once printed the cable can be pushed into its slot. The slot was measured for a thin budget cable, but thicker cables can still be eased into place. Once in place the microcontroller module can be plugged in. I prefer to secure the module with a double sided sticky pad, but this is optional.
The display can then be pushed into place. With the UAB cable slot facing towards you make certain to have the display's wires to your right (as photographed). If you put it in the other way the display will be upside down. The display should slide in without any significant force. If you need to take it out again gently slide a screwdriver in to the cable slot and ease it up.
Next remove the protective film from the laser cut face place, place the plate on the front, and softly ease the final 3D printed part over the top. Friction will hold the display together, but it can be separated with a little force by pressing on the face plate if needed.
To finish off this enclosure add some feet to prevent the display from sliding all over the place. Optionally add some tinsel, a bow, or any other decorations that you like.
Demonstration
Now everything is assembled, simply plug the display into a phone charger and it will start scrolling the text after a few seconds.
Just so you know, the duck in the video is called Chris and he really really likes Christmas. Bonus marks is you spot the typo in the video that has since been corrected in the firmware.
Hopefully you found this project fun and inspiring. I will be monitoring the comments here of you have any questions. Do comment if you have a go at building one or made any improvements yourself.
References
Thanks to Stephen Denne for making the font (based on work by Neven Boyanov) available under the MIT open source licence. Credits and links to the original work are in the source code.