Archive

Archive for February, 2009

Hacking a digital alarm clock

February 22nd, 2009

 

Philips AJ3540

Philips AJ3540

About 6 months ago, I purchased an digital alarm clock/radio from Walmart. The model i purchased was the Philips AJ3540 for about $40. I purchased it for the large display, which I did not see available for other clocks in the same price range.

The clock is not without its flaws, however. The sound of the alarm buzzer is deafening and the backlight on the display is just too bright, even on the lowest settings for both on their respective control knobs. 

This week I finally had enough and decided something needed to be done.

On opening up the alarm clock I saw that the clock was divided into 3 segments – the display, the controls and the “brains”. The brains section had some interesting components. The buzzer was actually a high wattage piezo buzzer, I haven’t ever seen a piezo buzzer that was this loud. Also the circuit used to convert the incoming ac to dc was interesting.

Anyway, down to business.

How do I reduce the sound of a piezo buzzer?

This was suprisingly easy. The incoming AC power is converted to 5v DC, so all I had to do was find the power rails and hook up a potentiometer to it. I then hooked up the wiper on the potentiometer to the buzzer, where it was previously connected straight to 5v. After setting the alarm to go off, I moved the wiper around till I found a volume I found suitable. 

Basicly that is really all you need to do. However I didn’t want to just leave the potentiometer there inside the alarm clock. The first idea I had was to cut a hole into the casing of the alarm clock and use the pot as my new volume control knob. However, I do not have a dremel handy for cutting a clean hole, so this would not do. Also I only have 1 potentiometer currently in my possession (I need to put an order in for parts!), so I didn’t want to give it up, especially since I use them quite regularry for testing.

After some thinking I suddenly remembered that the way I was using the pot was similar to a voltage divider. Which brings us to step 2 of our procedure.

What is the voltage I want to step down to?

This wasn’t as easy as I thought it would be. 

At first I hooked up my Arduino to the clock – share the ground and hook the wiper up to an Analog Pin through a 10K resistor. I then intended on displaying the data on my computer monitor serially. However, this wasn’t simple, as the circuit on the alarm clock was pulsing the buzzer faster (PWM) than the arduino could print values to the screen. At times like these, I wish I had an oscilloscope…

Anyway, there is always a way around difficulties! I calibrated the pot to the volume I wanted it and then removed it from the alarm clock. I then hooked it up to the arduino through the 5V power out. The reading I got out was 4.8V. This part still doesn’t make sense to me, as for a drop of .2V the volume decreased by quite a bit! Guess the buzzer doesn’t follow a linear curve (which would make sense as its based on frequency).

A little voltage divider math showed that my R2 should be equal to around 24 times my R1. Looking through my available resistors I used a 300 ohm resistor for R1 and a 5.1K and a 2K resistor in series for my R2. 

Soldered the resistors on and voila!! Your sound is now exactly how you want it!

I went on and did the same thing for my display backlight.

Hope this helps someone out! I planned on adding pictures but I my SD card on my laptop reader isn’t working :(

Darius Gai Arduino, Projects, personal

Learning Eagle

February 11th, 2009

I have been dabbling a lot with Eagle as of late. And today I started to make some inroads. I created my first part in Eagle and have started a library. The part I created was the AS1106 LED Driver from Austria Microsystems: http://www.austriamicrosystems.com/eng/Products/Lighting-Management/LED-Drivers/AS1106

It is a cheaper alternative of the MAX2219 LED driver from Maxim-IC. I recently embarked on created a game using the Arduino that incorporates tons of LEDs and depending on my final configuration (haven’t decided on this yet), it would require 2-3 of these LED Drivers.

I also plan on using this project to Learn Eagle and since my AS1106 chips came in yesterday I thought I’d start by creating a part for them. It wasn’t as bad as I thought it would be and the Sparkfun tutorials on Eagle are a good starting point.

 Next I want to create a small protoboard with a single piece of each component type. Once I make sure that the footprint of each one is right, I’ll finish up the board and then I am set to go!

Darius Gai Arduino, Projects