This is an old revision of the document!


DARIUS LED Display

Introduction

This project displays the name “DARIUS” sequentially on an 8×8 LED matrix and on a 1602 LCD screen, using an ATmega328P microcontroller. Each button press reveals the next letter of the name on the LED matrix. Two additional buttons control the brightness of the LEDs (increase/decrease intensity).

The idea started from wanting to combine multiple lab concepts (GPIO, I2C, SPI, PWM/timers) into a single cohesive embedded project. The result is a simple but visually engaging embedded system that demonstrates sequential display control, communication protocols, and user input handling.

It is useful as a learning reference for anyone getting started with LED matrices, I2C displays, and button debouncing on AVR microcontrollers.

General Description

The system is built around the ATmega328P (XMini board). The user presses a button to advance through the letters D → A → R → I → U → S, each rendered as a bitmap pattern on the 8×8 LED matrix driven by a MAX7219. The LCD 1602 (I2C) shows the current letter being displayed. Two separate buttons increase or decrease LED brightness via the MAX7219 intensity register.

Block diagram: [insert block diagram image here]

Modules:

  • ATmega328P (XMini) – main microcontroller
  • MAX7219 + 8×8 LED Matrix – SPI-driven LED display
  • LCD 1602 (I2C) – displays current letter label
  • Push-buttons (3x) – next letter, brightness up, brightness down
  • Resistors / Breadboard / Jumper wires – wiring and current limiting

Hardware Design

Components list:

  • ATmega328P XMini (university board)
  • 8×8 LED Matrix with MAX7219 driver module
  • LCD 1602 with I2C interface (PCF8574 backpack)
  • 3x Push-button (momentary)
  • 10kΩ potentiometer (LCD contrast backup / optional use)
  • Breadboard
  • Jumper wires (M-F and M-M)
  • Set of resistors (10kΩ pull-downs for buttons)
  • Micro-USB cable (power + programming)

Connections:

MAX7219 ↔ ATmega328P via SPI:

  • DIN → MOSI (PB3)
  • CLK → SCK (PB5)
  • CS/LOAD → SS (PB2)

LCD 1602 I2C ↔ ATmega328P:

  • SDA → PC4
  • SCL → PC5

Buttons:

  • Next letter → PD2 (with 10kΩ pull-down)
  • Brightness up → PD3
  • Brightness down → PD4

Schematic: [insert schematic image here — drawn in Fritzing/Wokwi/KiCAD]

Software Design

Development environment: PlatformIO (VSCode), platform: atmelavr, board: ATmega328P

Libraries used:

  • LedControl (MAX7219 control via SPI)
  • LiquidCrystal_I2C (LCD over I2C)
  • Wire.h (I2C, built-in)

Algorithms and data structures:

  • Each letter (D, A, R, I, U, S) is stored as an array of 8 bytes representing the 8×8 bitmap pattern
  • A state variable tracks the current letter index (0–5)
  • Button press on “next” increments the state and renders the corresponding bitmap on the matrix
  • Brightness is stored as an integer (0–15), clamped to valid MAX7219 range; brightness up/down buttons increment/decrement it and call LedControl::setIntensity()
  • Software debounce via delay or state-change detection

Source files: [to be completed in stage 3]

Results

[to be completed after building the project]

The project successfully displays each letter of “DARIUS” on the LED matrix sequentially on button press, with real-time brightness control. The LCD correctly shows the current letter label.

Conclusions

[to be completed]

Source Code and Resources (GitHub)

GitHub repository: [link here]

Repository structure:

  • src/ – all source code (.cpp / .ino)
  • hardware/ – schematics and wiring diagrams
  • images/ – photos of the physical build

Journal

  • Week 1 – Project idea chosen, components ordered

Bibliography / Resources

pm/prj2026/tarik_ilhan.omer/darius.zaharescu.1778341902.txt.gz · Last modified: 2026/05/09 18:51 by darius.zaharescu
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0