Close
0%
0%

Lit Christmas Ornament/Badge

It is a PCB ornament which is designed to look like a house in the winter with Christmas lights.

Similar projects worth following
It is a PCB ornament which is designed to look like a house in the winter with Christmas lights. It is an Attiny85, controlling over i2c an MCP23017 which then drives the leds, it is all powered off of one cr2032 battery (NOT included).

I figured out that i could set a mode by having 2 run modes for the ATtiny85

mode 1: set mode - plays each type of LED blinking patterns, if you want that to be the only one displayed, turn it off when you see it displaying. 

Mode 2: display mode - will display the last one which was demoed in a loop, only displaying that one until shutdown again, where it goes into the set mode.

for mode 1 LED 7 will blink before anything else, letting you know it is in set mode.

for mode 2 LED 8 will blink before anything else, letting you know it is in display mode

ON the House those LEDs are the 2 that are over the garage, LED 8 is the left LED and LED 7 is the right LED.

  • 1 × attiny85-su
  • 1 × mcp23017 Microprocessors, Microcontrollers, DSPs / IO Controllers
  • 2 × 10k Resistor (i2c pullups)
  • 16 × 0805 LEDs (various colors)
  • 16 × SMD 0805 led current limiting resistor

View all 7 components

  • Project Overview

    thelogicofpi12/01/2018 at 19:57 0 comments

    It is a PCB ornament which is designed to look like a house in the winter with Christmas lights. It is an Attiny85, controlling over i2c an MCP23017 which then drives the leds, it is all powered off of one cr2032 battery (NOT included). The code is using the watchdog timer with different periods to setup different blink mode timing. In the code linked via GitHub, there are the examples with how it is done as well as how long each period is (if you are going to reprogram yourself this will be useful) keep in mind the longer the lights are on for each mode the shorter the batteries will last. so blinking is the longest lasting as well as only having a couple on at a time.

    There are a few modes, the default option (ALL OF THEM) is to have all the modes play after each-other. But if you would like to select just one that you like, there is a dropdown where you can select just one. Since these are controlled by a mcp23017, there are essentially 16 LED outputs, in the form of 2 bytes (8 bits), there are many ways to set a pattern.

    • ALL THE MODES (looping)
    • ALL - ON
    • ALL - Flashing
    • Alternating even/odd - (flashing)
    • Alternating even/odd - (on-off)
    • Binary Counter
    • Grey Code Counter
    • Knight Rider Scanner (only middle row)
    • Looping Around Roof
    • Random Flashing
    • right shift in 1 until all on, then left shift in 0 until all off

    Components

    • 1 House PCB
    • 1 ATtiny85
    • 1 MCP23017
    • 16 LEDs (red, orange, yellow, green, blue)
    • 16 0805 SMD Resistors (10k ohm pullups for i2c and 137 ohm LED current limiting)
    • 1 Power Switch
    • 1 2032 Battery Holder (battery NOT included)

  • YouTube Video of Modes

    thelogicofpi12/01/2018 at 19:56 0 comments

View all 2 project logs

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

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