A very small microcontrolled RGB led circuit.
My Specifications are:
* Very small PCB, preferably 1.5cm x 1.5cm or smaller, I chose this size as if I panalize them, I can get 9 out of a 5cm x 5cm pcb, so from somewhere like Seeedstudio, I could get 90 for $17 including shipping! Which is rediculous.
* Single RGB led.
* Small and cheap PIC processor, I like PICs...
* Cheap boost convertor, so it can be run from a single alkaline cell.
* Pushbutton power switch, I've a nice little circuit for this that I developed a few years ago, allowing power on/off and a general user switch from a single input pin and a tiny SMD pushbutton.
* I2C interface to allow the circuit to be used for other stuff, essentially giving me a serial RGB led. I know Neopixels are out there and are rather nice, but this will have the advantage of having the controller onboard.
* For the LED, I'm going to go with this, Its nice and bright and cheap enough.
* For the processor, I'm going with the PIC12LF1552, this is a nice little 8pin beasty, only 42p in 25 qtys, has an 16MHz internal oscillator, a mighty 2k of program FLASH ( should be enough for a flashy light) and a I2C Master port.
* The boost convertor is the Microchip MCP1640. This is a nice little(6 Pin SOT23) package, is cheap, 32p in 10 qtys, can start from 0.65V and can work down to 0.35V, admittedly at low current. It can also deliver more than enough current to drive a LED.
My first draft of the circuit, shown in the gallery, had the TAG programming connector and also a 4pin 2.54mm pitch header connector, which supplies power and also the I2C connection. I realised that I was using 2 out of the 3 programming pins for the I2C link, so have decided to redo the PCB, getting rid of the TAG connector and using a 5 pin header, this will have GND, VCC and the 3 programming pins, after which it can be used for I2C if needed. This frees up quite a bit of board space and simplifies the routing.
As the programming pins don't like other components connected when programming is underway, I will have to add a couple of parts afterwards, this is a little awkward, but as its not a complex project, will be managable.