Z80 Breadboard Computer
Lepai Class-T Amplifier Mods
Soft Touch Power Control
AM Radio In a Playing Cards Box
This project has moved to:
Added January 29, 2010
Updated June 11, 2013
From about 2007 to 2009, I went through a period of renewed interest in collecting vintage audiophile equipment - this was sparked primarily by discovering a near limitless supply of dirt-cheap CD players, tuners and receivers at a local thrift store. This led to online searches and further acquisitions of piecemeal components known to be of good quality. Well, this all came to a screeching halt as 2010 rolled around, after discovering the little $20 Class-T amplifier mentioned here. If you haven't heard about the Lepai Tripath series of amplifiers, you seriously don't know what you've been missing!
Theory of operation: Traditional, Class-A amplifiers work by amplifying both phases of an audio signal. As such, they sound great but are typically only about 25% efficient. This means they waste a lot of power and generate a lot of heat - regardless of the volume level. Class-B amplifiers are theoretically two or three times more efficient, but generate too much distortion for practical use in audiophile applications. The Class-A/B design is a trade-off between the two, and is slightly less efficient than Class B. There is also a small amount of switching distortion due to the push-pull configuration of the output transistors, which some audiophiles claim to be able to hear. The Lepai LP-2020 amplifier is designed around the Tripath TA2020 IC. Although Tripath calls this a "Class-T" amplifier, this seems to be more of a marketing ploy to help differentiate themselves from manufacturers of other Class-D amplifiers, since they're both basically the same. It works by converting the input audio signal from analog to digital, with inductors on the output side to form a low-pass filter, thereby converting the amplified digital signal back into analog. Voltage is rapidly switched on or off across the inductors, exploiting the collapse of magnetic flux to smooth-out the realized waveform that is presented to the speakers. This is the basic idea behind Pulse-Width-Modulation (PWM). Transistors are traditionally used as signal amplifiers or as switches, but are most efficient when used as switches. By exploiting the advantages of transistors in switched mode, together with passive components such as inductors and capacitors, this design can reach up to 90% efficiency! This is also why a device as small as this can provide 20 Watts per channel @ 4 Ohms, continuously, while still remaining cool to the touch or only slightly warm.
I soon discovered a related forum discussing various modifications (mods) to this device to improve the sound further. Here is a listing of mods I've made to mine so far:
Replaced the original soldered-in JRC4558 op amp with a pin-compatible OPA2134PA equivalent. In this configuration, the op amp serves as a bridge between the input audio signal and the Tripath amplifier IC, and also helps to mitigate voltage drop-off from the bass and treble controls, which work by attenuating the signal. A DIP socket allowed me to sample several different offerings before settling on this particular part, which seemed to sound best among those I tested - to my ears, at least.
Replaced several carbon resistors with metal film types in the pre-amp stage. This was done to improve the signal-to-noise ratio.
Replaced a couple electrolytic capacitors with higher-capacitance mylar types. This was also done to improve the signal-to-noise ratio, as well as improving low-end frequency response.
Replaced the 2200 µF power supply capacitor with one of a higher capacitance value of 4700 µF. This was to increase available power for high-volume signal transients (think bass thumps.
).Replaced the stock inductors with toroidal types. This was done to improve current-handling on the output side of the amplifier and maximize available power to the speakers. As you can probably tell by the photos, quarters were a little too cramped for them to sit side-by-side, so the middle two sit above the heat sink with wires serving as "mini extension cords" to the board.
Swapped the left and right input channels, since they were erroneously reversed in this production run.
Glued a small piece of aluminum foil between the front of the blue LED and its plastic housing, to act as a light-diffuser. Like too many products these days, this device incorporates an LED designed for illumination, but is being used as an indicator.
Added rubber feet to the bottom of the case. Granted, they cost a bit more than foam pads, but are not as prone to sliding around a table or desktop surface when a cable is tugged.
I can honestly say there was a marked improvement in the quality of the sound by replacing the cheap (as in quality as well as price) op amp chip, with the other mods providing more subtle improvement - but nonetheless still worth the effort. The model I own is the 2010 design, which is not the first revision, nor the last. More recent revisions of the board contain a tone-defeat switch and a speaker-protection relay on the outputs... but they also use surface-mounted components, which can make it more challenging to modify.
I like the tone controls on these Lepai amps, which is also a rarity among popular Class-T designs in this price range, so the absence of a tone-defeat switch is of no consequence to me. There is a subtle "click" when powering the unit on or off, but it's barely audible - so while a speaker relay would probably be a nice addition, I can live without it. The simple solution is to leave the unit on longer and enjoy more music.
About four years ago, I posted a page describing how I had modified a laptop monitor stand to allow easy control of A/C power to other devices. Being a long-time Commodore computer enthusiast, this had appeal since many of their vintage computers used heavy "brick" power supplies, and often with the power switch on the adaptor itself. This meant either crawling to the floor to turn it on or off, moving it to an already crowded desktop or using a clunky rocker-type power switch on a power strip or 1990's-era monitor stand with neon-backlit rocker switches. It seemed such a luxury to have a laptop and docking station at work with soft-touch power buttons within arms reach at my desk. Since the laptop was getting a bit shall we say, "long in the tooth", I thought about picking up one for myself as prices were coming down. While looking for accessories, I noticed prices for matching monitor stands were dropping like a rock! Then it occurred to me that for just $6, it might be worth buying one just to bastardize it and see if the switches could be exploited for my own uses.
As described on the other page, I was able to isolate the wires leading to the two front-facing switches with built-in bidirectional LEDs. I created a switching circuit from a schematic I found on the web, and embellished upon it to also support the LEDs by lighting them green for "On" and amber for "Off" (I know, it should really indicate "Standby"... so we'll bend the rules a bit, okay?
After the circuit was working, I moved the protoboard into a project box big enough to contain it along with a power outlet. It worked as a prototype, but I didn't feel comfortable enough to use it long term due to the close proximity of the high and low voltages... it probably wouldn't have received the UL logo anyway, if they even go through that anymore.
Then I recently stumbled upon a web page describing how someone is using a modified power strip to allow his switched amplifier to control power to more devices than it was originally designed for. He did this by installing a relay in the unused space within the power strip, then added a jack to feed it power. Then it occurred to me that I could probably update my switching circuit to similarly control such a relay-readied power strip. This would have the benefit of isolating the low-power circuit from the high-power one. Once the power strip was ready for prime time, updates could later be made to the control circuit without impacting wiring for the devices running from A/C. It would be a win-win!
I found the exact power strip described above at Fry's for just over $3, so I picked up a couple. The operation went without a hitch, although I cheated a bit - instead of soldering wires between the input jacks and relays, I fed the reverse-biased diodes through the soldering holes on the RCA jacks and extended the leads all the way to the solenoid input pins, making them serve as wires. It saved a bit of time, and between the thick leads on the 400x-variety diodes and A/C wires soldered to opposing sides of the relays, along with cramped quarters within the housing of the power strip, there's little room for jostling and possible arcing.
Besides relocating the relay to the power strip, I wanted to update the control circuit as well, since the original implementation suffered badly from switch bounce. I tried several other designs based mostly on the 555 Timer IC, but each came with a caveat that I wasn't willing to settle for. Instead of the transformer-based power supply in the previous version, I wanted to go with a switched-mode power supply. For a circuit using less than 70 mA total, including relay, it seemed unnecessarily wasteful to use a power supply sucking 300 mA regardless of load. The switched-mode supply I intended to use had a no-load maximum draw of just half a Watt, so I could cut the energy expenditure by 77% by using it instead. I know we're not talking about the power involved in lighting a stadium or anything, but every little bit helps, right?
Well, it just so happened that the 555-based circuits would occassionally toggle state when there was noise on the lines - usually when turning the fluorescent kitchen lights on or off. No amount of smoothing electrolytic capacitors on the rails or filtering ceramic discs next to the ICs themselves seemed to help (yes, I even added one to Control Pin #5 on the 555). Another circuit would toggle twice if the switch was held down too long.
I finally found the perfect circuit for the task, based on the 4013 Dual D-Type Flip-Flop IC. It's perfect not only because it works flawlessly with the switched mode power supply, and not only because it stays in the selected state no matter how long the switch is held down, and not only because it doesn't suffer from switch bounce, but it also has provisions for controlling TWO inputs (devices). Since the monitor stand has two sets of switches and bidirectional LEDs, all the stars aligned on this one because it cut the number of required components to an absolute minimum. The previous implementation used discrete components and had double everything, so you can probably imagine my excitement to get started wiring-up the circuit once the benefits and simplicity of this design were realized!
The astute reader will notice that on the schematic, current is "trickling" through the relay in the off condition. This is by design so as to supply the amber LED with 5 milliamps, whereas the relay needs approximately 25 milliamps to activate. I've been using the circuit for a couple weeks now (as of 25-Jun-2012), and so far there hasn't been a single hiccup or anomaly to mention.
Any A/C devices can of course be used with the modified power strips, but they're currently set up so the left switch controls power to the computer and related peripherals, while the right switch allows effortless access to a reading light. I used a higher value resistor for the amber LEDs as compared to the green ones - the reason being that devices powered by the strips are usually off at night, so I wanted the LEDs to be bright enough to be visible, without being so strong that they would become a source of irritation. Yeah, I'm probably being overly-picky... but I guess if I'm picky enough to want a better power switch, it's probably just par for the course, right?
At some point I'll probably look into adding a photoresistor to vary the intensity of all LEDs depending on ambient light, but that's not on the radar (for now).
Added February 2, 2009
Probably every electronics hobbyist has built a crystal set or small transistor radio at one time or another, and this was my attempt. It's based on the MK484 "radio-in-a-chip" IC, which doesn't really look like an IC since it uses a TO-92 case; usually seen only with transistors. The idea of running a radio from a single, 1.2-Volt AAA rechargeable battery seemed like such an amazing feat I just had to check it out. It drives a set of 32-Ohm earbuds or Walkman-style headphones at a respectable volume, and while it's not a superheterodyne, sensitivity and selectivity are still pretty decent.
After finalizing the board layout, I needed to find a permanent home for it. While meandering at a local thrift store one day, I found an old playing cards storage box with a casino's logo imprinted on it. I thought it would give the project a good "retro" look, so I snatched it up and... well, here it is.
The volume control includes a power switch, which is exploited in this circuit. I would have preferred to use matching knobs for tuning and volume, but the tuning capacitor has more range of motion and because of that, the detent on the knob comes in contact with the flange running along the bottom edge of the box. I probably could have filed it down, but to save time just swapped it with a spare I had laying around. While mentioning caveats, it also would have been nice to mount the audio jack through a hole on the side of the box, but alas I couldn't find one with the depth necessary to position it there - so the box needs to be open when listening to a station. Not the biggest deal in the world, right? Besides, it lets one admire the superior craftsmanship of this winning hand (very big chuckle).