This is an all-in-one six digit 7-segment led display unit with an ATmega328 programmed with the Arduino bootloader. The displays can be used to count, time things or display numbers. The display is bright enough to use inside or out. The display is controlled using an SPI, which uses four digital pins from the microcontroller, leaving all the others free. Multiple displays can be connected together using the SPI bus.
Here at Renewable Energy Innovation, we have been asked to provide visible numeric displays, mainly to show power and energy. This kit came from one of those projects and we decided to create a PCB and put the parts together as a kit which might be useful to other folk.
The unit itself is based up the AS1107 8 digit 7-segment LED driver (which is a replacement part for the (more popular) MAX7219 IC). This does most of the hard work on the board, as it maintains the LED display with the data sent to it. It also controls the intensity of the display.
The AS1107 is interfaced via SPI (Serial Peripheral Interface) bus. This is connected to an ATMega328 with an Arduino Uno bootloader. This means we can communicate to it using programs written with the Arduino IDE. It is connected with the standard SPI connections of:
The various standard Arduino Input/Output pins are all available as connector pads (D0-13 and A0-5). These can be used as inputs for counters and timers.
Note: To program the Arduino, a standard FTDI USB-Serial lead is required. Update 25/3/14: We now also sell a re-programming lead which works with this kit, here.
Also a number of these units can be interfaced to one Arduino (each with a different Chip Select) and hence lots of information can be displayed.
Here is the example code (available below) in action:
This kit is available here, with payment via paypal. The cost is £25 (including p&p within the UK). This includes a programmed ATmega328 and 6 x 7segment LED units.
This is a relatively simple to put together kit, although it does have one surface mount IC to solder. The kit includes the following parts:
Note: You will need: soldering iron, solder, wire cutters.
The construction instructions are available here:
Here is the circuit schematic:
|AFF1-6||Battery holder||P4||Mounting hole|
|C1||100uf electrolytic capacitor||P5||Mounting hole|
|C2||100uf electrolytic capacitor||P6||Mounting hole|
|C3||100nf||P8||FTDI header (6-pin)|
|C4||100nf||P9||Analog 0-5 pads|
|C5||22pF||P10||Digital 8-13 pads|
|C6||22pF||P11||Digital 0-7 pads|
|IC1||AS1107 SPI LED Driver||R1||10k resistor|
|IC2||ATMEGA328P-P – UNO boot-loader||R2||10k resistor|
|28 pin DIL socket||SW1||Reset switch|
|P1||SPI Input connector (not supplied)||X1||16MHz Crystal|
|P3||SPI Output connector (not supplied)|
The code for this project was written using the Arduino bootloader and IDE. (Note: It was written on version 1.05 of the IDE and is untested on other versions).
This project assumes some knowledge of the Arduino platform. If you do not have this then please start with the numerous examples available within the Arduino community.
Here are the examples, which you will need to download and add to your Arduino sketchbook:
The code has numerous comments and is based upon ShiftOut code from the Arduino reference website.
This is a fully open-source project. The PCB and schematic for this project were drawn using the open-source KiCAD electronics design package.
The full KiCAD PCB files (schematic and board) are available within this GITHUB repository. The direct Gerber files are also included.
Here is the PCB and layout design: