RGB LED Life Bar, 10 Sections, Individual LED Control, Arduino Answered
Okay, I want to make a "Life Bar" using an arduino controller, 10 RGB leds, and a clear plastic box with ten sections.
I'm going to mount this on a wall in my room.
Each section will be diffused or frosted and will be 4 x 4 x 4.
One RGB LED will in the "back" of the section, with the wiring, coming out of the back of each section.
The controller will be to the left side of the total ten sections, with the USB port having easy access.
I think I'm going to have one switch to control the modes of the LED and cycle through each mode, which would reset after the lowest
"health" of the bar is reached; RED BLINKING >> Press Switch >> FULL HEALTH.
I'd like to control each LED individually so I can create a diminishing "Life Bar."
(Colors of the LEDS)
OFF = No Color, LED not LIT
BLU = Blue
AQU = Aqua
GRN = Green
YEL = Yellow
RED = Red
REDB = RED Blinking
Phase One (Full Health. HAHAHAHA I'M INVINCIBLE.)
Phase Two (I tripped whilst fighting.)
Phase Three (I'm hurt a little, but I'll be okay.)
Phase Four (I should probably start looking to see if there are any potions around.)
Phase Five (Green? Green is good.. Right?)
Phase Six (It's okay I've fought this boss before at much less health.)
Phase Seven (This boss... This boss can breathe fire now..?)
Phase Eight ('Tis but a Scratch!)
Phase Nine (HEALS HEALS HEALS HEALS PLEASE PLEASE ANYONE.)
Phase Ten (Okay, I have almost no health, my party is dead, and my strongest attack: Let's do this.)
Basically, every press of the switch would idealy cause the lifebar to cycle through these phases, after the lowest health, it would cycle back to the beginning, full health status.
The actual box will be DC powered, because I want it to be as seamless as possible with no wires showing.
The answers that I am looking for :
What would be the best controller for this application?
Any helpful hints on where I could look for something relatively similar for programming this?
I know that I am asking a lot, I am pretty much new to arduino programming and every howto or tutorial I've found talks of controlling all the LEDS together, I'm not sure if that would apply here since I have so many "phases" if you can shed any light on how to approach this, I would be eternally grateful and would totally fight dragons with you any time.