Archive for June, 2006

LED Clock: Ordering Parts

Friday, June 9th, 2006

I’m starting to gather parts to prototype the blue LED clock.

LED Drivers

I ordered four samples of the Allegro Microdevices A6276 constant current 16-LED driver chip that I want to use to run the display. I didn’t care whether I got traditional or lead-free; but due to availability and the way their sample fulfillment process works, they’ve sent me four lead-free and will send me four traditional when they restock their samples. Cool.

LEDs

I’ve purchased 500 blue LEDs (10,000 mcd) on eBay from Best Hong Kong for $50.35 with free shipping and free resistors.

I haven’t figured out their pricing scheme, other than arbitrary. On their web site, these LEDs (AFAICT) are $.18 each, or $90 for 500; on eBay, they were $50, with a Best Offer option that suggests they’re willing to negotiate even further. That suggestion seems to be incorrect, though–they gave no response whatsoever to my two offers and my ask seller a question.

The LEDs have a 20° viewing angle, which is too narrow. Jeremy and I tested some of my Phillips LEDs, and they’re so directional we’re afraid we might not be able to see both ends of the clock from the same viewing position. However, I scuffed one up with 1500-grit sandpaper, and it looked fantastic–a very uniform brightness from a wide range of viewing angles. Yes, it’d be nice to just buy frosted ones, but I can’t find them in the quantity I need for anywhere near the price. I expect I’ll dedicate a buffing wheel to being a scuffing wheel when the LEDs arrive.

Timekeeping

I had several hours to myself in the car in the last couple of days, and did some thinking about timekeeping and battery backup. As much as I’d enjoy programming timekeeping functionality in the LogoChip, I shudder to think of dealing with backup during power loss.

I could take a reference timekeeping source from the 60Hz line supply like consumer alarm clocks, but then I’d have to switch to the internal oscillator for timekeeping when the clock was unplugged. To do that with any more accuracy than my alarm clock, I should compare the oscillator to the line frequency during normal operation and record the actual number of oscillator cycles per period. Add in dealing with battery changes–and do you have to recalibrate from scratch if you do lose all power? Or add a 1-bit NVRAM chip to the design? All of that’s doable, but ecchhh. I’ve started thinking about using an external real-time clock (RTC).

I have an old Dallas NVRAM/timekeeper DIP (probably lots of them, actually), which provided RTC functionality for 8088-vintage computers. Unfortunately, it’s made to work with a microprocessor and has 8-bit and wider address and data buses, registers, etc. Way too many pins to work with a small microcontroller, when I already have other pins to deal with to drive the LEDs.

Google on “real time clock” integrated circuit led me via Wikipedia to Maxim/Dallas. I feel like I’m starting to get a clue about browsing manufacturer’s offerings–after looking up their 1309, I visited related products and found the DS1340 I2C RTC with integral trickle controller to recharge the backup battery, and the DS1302 RTC with trickle-charge and a simple three-wire serial interface. I ordered samples of the DS1340C SOIC with internal 32KHz crystal, the DS1302 DIP, and (bless Maxim!) the external crystal for the 1302.

Replacing My PowerBook Screen

Sunday, June 4th, 2006

This weekend, I transplanted the screen from a nonfunctional 500MHz PowerBook G4 onto my 550MHz G4 to replace the one that broke off.

Writeup here.

Resocketing my LED Tester

Thursday, June 1st, 2006

I recently bought a $10 LED tester. It has a 9V battery, a dual-row header to put LEDs in, and resistors to provide different test currents to try different LED brightnesses. [Uh, is "brightnesses" a word??? Whatever . . .] You can use it to determine the polarity of an LED if you can’t tell by the case (I’m getting better at visual identification, though), and it’s really handy to figure out what current you want to use while the LED is still out of circuit.

LED Tester

Problem is, the manufacturer used a cheap dual-row connector intended for header pins (probably .037″) that’s way too loose on the smaller pins (probably .028″) on the LEDs, so I get bad connections that make it difficult to use–I pretty much have to hold the LED in place to keep it lit. Also, the socket elements were oriented with the metal on the sides rather than the top and bottom, so bending the LED pins further out didn’t help make any better contact.

LED Tester with Cheap Socket

Tuesday night I fixed that problem by replacing the original header with a better one from my parts bin.

Parts Bin of Headers

I started with a salvaged header that I desoldered from a printer control board a while back. The header was too long (too many pins), so I cut it to size with a razor saw. These headers are actually really nice to cut; because although they’re not snappable (I don’t see how that could work with a dual-row connector), they’re notched between every set of pins, so there’s a groove in which to start cutting.

Cutting DIP Header

I desoldered the original header from the board with solder wick and the temperature turned all the way up on my new Weller iron. It actually worked pretty well, partly because the board’s plated through-holes were way oversized, so the solder came right out. But I’ve had trouble desoldering things like this before, where the holes are the size they should be and the capillary action just doesn’t pull all the solder out into the wick. Partly spurred by my good luck on this project, I’m starting to do a little research on buying a decent vacuum-powered desoldering station (secondhand, of course).

LED Tester, Solder Side

I soldered the new header in place, tested operation, and reassembled the case. It works much better now–I have five LEDs inserted in a row for comparision, and they all consistently stay lit.

LED Tester with Blue LEDs