Categories

Half-bridge

Here’s a simple half-bridge driver based on the LM5106 half-bridge driver with charge pump and programmable dead time coupled with a FDS6986AS dual N mosfet . It’s pretty much the sample circuit in the datasheet with an added jumper to select the charge pump source. The current setup allows for driving loads at 30V up to 6.5A continuously while switching at high frequencies (50khz and up). By replacing the chosen dual mosfet with two discrete high power fets up to 100V loads and very high currents can be controlled. The current minimum switching frequency is around 1-2Hz (charge pump self-discharge).

Eagle library, schematic and board available here. Use 25V X5R or X7R capacitors, do not use Y5V/Z5U capacitors.

The second image shows a use for the half-bridge driver; driving a synchronous three-phase hard-disk motor. Commutation is done “blindly” with an adjustable delay between each commutation step. The output to each phase is a trapezoidal waveform. Speeds of up to 20,000 RPM are easily achieved. This design can easily be scaled up for larger motors.

Simple audio amp

I’ve often found that I need a basic audio amplifier for smaller projects so I decided once and for all to make a basic low-cost audio amplifier that can be used in a whole range of applications. After some searching I managed to find a surprisingly good monolithic amplifier, the TDA7057AQ. It’s good features are that it drives the load differentially (up to 8W), so only a single supply is needed, controls both left and right volume logarithmically from a single-channel potentiometer and mutes at very low volumes, has a very small number of required additional components, has a reasonable voltage range and is surprisingly cheap. It is limited in that the output can’t swing very close to the rails, is limited to 8W per channel and can’t operate above 18V, however for most simple solutions these limitations aren’t really problematic.

I’ve made a relatively small board that mostly follows the recommended setup detailed in the datasheet, I’ve added some more decoupling, the 0603 SMD X5R capacitor is placed directly underneath the IC in an attempt to reduce the risk of oscillation or other strange behavior from PCB lead-inductance (probably not a problem as the IC has a GBW of only around 300kHz). There’s also a fuse and a reverse polarity protection diode, use a low forward voltage SMC-case Schottky diode (here’s one, though somewhat over dimensioned).

Eagle schematic, board and library for TDA7057AQ available here

2xAA to 5V/500mA Boost

One aspect common to most available consumer ‘MP3 Players’ is that they, while very thin and easy to fit in a pocket, use a non replacable Li-Ion battery. Additionally usually they’re only rechargable via USB! The previous music player I had used AA batteries and it was very nice to be able to swap them when they got discharged. One possible way of solving this problem is by externally delivering 5V (nominal voltage for the USB bus). However as a NiMh cell is only 1.25-1.2V when discharging that would lead to using a lot of batteries! A somewhat more complex solution is to construct a voltage raising DC-DC regulator (boost, flyback, sepic etc), which would allow the use of one or two cells.

I’ve seen one switching solution on the web, called MintyBoost!, but it was limited to around 100-200mA output current which I felt was a bit on the short side, considering USB devices can draw up to 500mA. I didn’t have any data on how much current my music player drew, but it would be safe to design a regulator that could output 500mA constantly.

I’ve opted to go for a boost-type circuit as they’re relatively simple and there are a bunch of monolithic solutions requiring only an external inductor, diode, and stabilizing capacitors. The LM2621 was one (of many) circuits that offered the specifications I needed; small, high output current, monolithic, low input voltage.  As it happens it uses a ‘gated oscillator’ control scheme which greatly simplifies the routing of the PCB, from an anal retentive level that typical controllers use to the easier level of super-pendant. (Using two layers would simplify routing a lot).

I pretty much followed the design shown in example 1 on page 9, with the exception of CF1 which I found tended to feed too much noise into the FB pin and caused erratic operation (most likely because of the limitations caused by a single-sided PCB). By removing it the circuit it very stable but has a larger output voltage ripple (about 100mV, an approximate value is V_OUT/1.2028*30*10^-3, this as the hysteresis on the FB pin is 30 mV and the voltage is divied from V_OUT to this pin).  I managed to squeeze the entire boost part of the circuit into a box about 30×25x5mm (plus PCB thickness), and with some safety components about 40×35mm. The sustained output current is tested to around 500mA. 600mA worked for about 10 minutes before the device overheats and enters thermal shutdown. When 500mA is drawn out it gets hotter than I would like to run it, for high current applications using a 2-sided PCB with lots of cooling area on the back side is probably a good idea. 400mA is not a problem at all, it gets warm but not uncomfortably so.

The device is stable with input voltages between 2.3 and 3.5V at loaded at <=500mA. The output voltage is kept within 5.05 – 4.95V from 1mA-500mA load (there’s a power OK led that draws 1mA). When drawing small currents (approx <50mA) then it can start from only one cell (1.2-1.4V), but it never enters it’s gated control scheme, so efficiency is probably a bit lowered, though the output voltage is still kept stable.

When I tested this with my music player, to my surprise, it drew very little current, only 300-600mA on the low side (so around 100-200mA on the 5V side, with a fudged efficiency of 70%). This varied primarily on whether the backlight was on or not. This means that the 2.1Ah low self-discharge NiMh batteries I use will last long enough for it to charge completely about twice (a full charge takes about 3 hours, assuming 300mA charge current), or about 20-30 hours of playing time!

It may well be that the mintyboost is powerful enough for most players, nevertheless it feels good to know that this circuit can handle up to the maximum possible current USB is rated for.

The parts I’ve used are primarily;

Diode – http://se.farnell.com/jsp/search/productdetail.jsp?sku=8647887

Inductor – http://se.farnell.com/jsp/search/productdetail.jsp?sku=1669991

Buffering capacitor – http://se.farnell.com/jsp/search/productdetail.jsp?sku=1650938

Update: It has come to my attention that Y5v and Z5U ceramic dielectrics are really, hideously awful. Check out this PDF (look at the capacitance vs. DC bias and temperature plots), you only effectively get 5% of the rated capacitance at 65°C and >50% rated voltage! So the capacitors I thought were 22µF are only effectively 3.3µF each. In my application the output is stable, though a far better capacitor choice would be to use X5R or X7R dielectrics, which are available in nearly the same range and have far better characteristics! (see http://se.farnell.com/jsp/search/productdetail.jsp?sku=1650891 for example).

Regulator – http://se.farnell.com/jsp/search/productdetail.jsp?sku=9779248

Along with some other common odds and ends laying around (fuses, cabling, electrolytic capacitor and so on)

Eagle board and schematic can be found here, there are some deviations from the schematic on the final board. I’ve used a couple more 22µF capacitors on the output, there are 3 1W 6V2 diodes that should clamp spurious voltage spikes, and a 0.33 ohm output resistor, followed by a 220 µF electrolyte in parallel with a 22µF ceramic capacitor to filter out the worst high frequency noise.

Boombox

I’ve recently got a boombox in exchange for development of a Li-Ion charger (the same charger is inside the boombox).

The charger is a very simple one based on the L200 linear regulator and an Atmel Mega168 microcontroller. The L200 is configured to charge with a constant current/constant voltage scheme limited to 2A and 16.75V, the microcontroller measures the current going into the battery with an INA139 and cuts of the power to the regulator with a P-type mosfet when the current is below 200mA. A charge is initiated only when the battery voltage is below 16V. This is done to ensure that there’s no risk of continuously topping up the battery. When the unit is powered by an external laptop-style power supply (19V) the audio  amplifier is switched by a relay to be driven by the external power, so there’s no power draw on the battery when powered from an external source. The microcontroller also displays the current battery level and charge status on some LEDs.

The audio amplifier is a AMP-9 Basic amplifier from http://www.41hz.com which is based on a Tripath TAA4100A monolithic switching amplifier, which has a very high efficiency. There’s also a minimal amount of electronics before the amplifier (basic ESD protection with diodes, mono mixing, volume adjustment). With the batteries placed inside the boombox currently (14V nominal, 4AH Li-Ion) I get around 15 hours of low volume play time (limited mostly by the quiescent current of the amplifier) and about 6-7 hours of painful-at-less-than-3-meters volume, which is very acceptable for me.

The enclosure is designed as a base reflex enclosure (not made by myself) and considering that it’s made from 2mm aluminum it works very well. There’s certainly a noticeable tonal difference compared to heavy MDF/fiberglass damped speakers, but considering the total weight of 5kg for the entire system (speakers, amplifier, enclosure, battery, power supply) it is very acceptable and certainly better than other “boomboxes” I’ve seen.
This is essentially everything you need when going to the park, beach, or anything else!

Hello world!

So, I’ve transferred the website to wordpress and to a new host (ie. no longer from the basement). Let’s see how things turn out. All data will be transferred to this new site relatively soon.

Update: All data worth transferring should now be transferred. W00t!