Nov. 27th, 2010

johnridley: (555)
This was goal #3 in getting this blinkie up and running. This was the last significant hurdle as far as the software is concerned. Now I just need to develop some nifty patterns. I may add one more thing, which is a simple pushbutton for on/off and modes, rather than just an on/off switch. Depends on how the patterns go.

I was kind of dreading this step because interrupts on this chip was one thing I knew nothing about, and I must admit I was dragging my feet on getting to it, but I finally decided I'd better get moving. I was tearing my hair out for about an hour because the compiler kept optimizing out all my pattern generation code. Finally I realized that I had to define the values as volatile, and it started right up.

Of course the board needs to be laid out but I have a friend who will help with that (I don't know the CAD software used and he's done a ton of this stuff). I also need to determine how long it will run off a CR2032 battery (I did test that it DOES run off one today) - and also I need to see if I can decrease the duty cycle of the LEDs without a lot of difference in brightness - that will increase battery life.

Depending on battery life, I may have multiple options. Two AAA cells on the back would run it for quite a long time but would be too heavy for earrings, OK for a necklace.

CR2032s in quantity are QUITE cheap, on the order of 12 cents, but I don't know what my runtime would be with them. A single CR2032 has very nearly the same energy as the four LR44s that the previous blinkies have been using (3v x 225mAH = .675 watt hours, vs 6v x 120mAH = .72 mAH) but it's a lot smaller and lighter and both the battery and the holder are cheaper.

October 2025

S M T W T F S
   12 34
567891011
12131415161718
19202122232425
262728293031 

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated Oct. 8th, 2025 09:10 pm
Powered by Dreamwidth Studios