Forums

Re: Battery charging circuit

Started by Uncle Steve May 6, 2013
On Mon, May 06, 2013 at 02:35:52PM -0500, Tim Wescott wrote:
> On Mon, 06 May 2013 12:01:44 -0400, Uncle Steve wrote: > > > Back again for some more abuse. > > > > I'm building a 12V battery charger that will be controlled by a small > > low-power microcontroller. I've not yet hooked up the microcontroller, > > but most of the code is written and I'm trying to finalize the charger > > electronics before I hook it up. > > > > The circuit is very simple. An 18V 2A transformer, a bridge rectifier, > > and filter capacitor feeds a main power rail. A 5V regulator produces a > > few mA for the microcontroller, which I won't show here. The charger is > > more or less as follows, though I will leave out the resistor/divider > > taps which hook up to the ADC channels on the micro. > > > > > > +18VDC ---------------------------+ > > Q1 c e | D1 R1 > > -----\_/--------->|----\/\/\--------+12(batt) > > b| | > > +------+ | > > | | +--+----------+ > > / Q2 e\_/c | > > R1 \ |b | > > / | e |c Q3 > > \ +--\/\/\------\_/ > > | R2 |b > > | | R3 SW1 > > LED1 \_/ +--\/\/\-- \-- +5V > > --- > > | > > | > > GND --------------+------------------------------------ GND(batt) > > > > > > Q1 - MJE3055 > > D1 - 1N4004 > > R1 - .5 5W > > > > Q2 - BC557 > > R2 - 200K > > > > Q3 - 2N2222 > > R3 - 1K > > > > > > The microcontroller will strobe R3 with PCM at about 488HZ with a duty > > cycle dependant on the charge profile. R1 is the sense resistor and > > permits measuring instantaneous charge current. I've got the battery > > attached and can watch the voltage rise (and settle) as I manually > > engage a switch attached as shown. The battery voltage as it came from > > Wallmart was about 12.7V. Charge current with this circuit is 1.4A at > > this point in its charge cycle. The heat-sink gets rather warm, but it > > isn't all that big and I'm going to target 3 or 4A as the peak charge > > current so I'll probably substitute a TO-3 package with a much beefier > > heat-sink when I put the project in an enclosure. > > > > So far, so good. The output of Q1 shows .6V ripple. Attaching my scope > > to the base of Q1 shows an idle (SW off) voltage of 16mV and a 120Hz > > signal with a 70mVpp with a duty cycle of 17%. I'm not exactly sure > > where this signal is coming from, although its frequency suggests a > > causal relationship with the AC mains. There does not appear to be any > > ripple on the 5V rail, but my scope isn't good enough to really zoom in > > on it. > > > > The other side of the coin is that the Q2/Q3 network seems to be rather > > sensitive. When I pass my hand over the breadboard the distortion > > described above doubles and I can get an amplitude of 1V on that > > distortion by standing up suddenly while sitting in front of the idle > > circuit. It is difficult to say what is happening because I can double > > the distortion by attaching the scope to a wall-wart USB charger, and I > > know I haven't yet calibrated the scope all that well either. (Scope > > shows 4.5V from the 5V regulator.) But the fact that I can affect the > > circuit just by moving things in the general vicinity is, um, rather > > shocking. > > > > Besides installing the circuit in a metal case, are there any easy > > solutions to fix that 16mV idle voltage? Should I just change the BC557 > > to a 2n2222 and work out how many of what kind of resistors I need to > > supply the 3055 with the mA it needs to dump several amps into the > > battery? I like this version because it is easy to set up and has a low > > part count, but I'd really like to get rid of the noise and the > > sensitivity to movement. > > Start a new thread! This isn't even remotely related to fan motors!
Sorry. My newsreader crashes when I 'post' so I have to reply to something and then delete the references header, which I forgot to do in this case. What happens next is dependant on the newsreader you use. Regards, Uncle Steve -- There should be a special word in the English language to identify people who create problems and then turn around and offer up their own tailor-made bogus non-solutions designed to completely avoid the root causes of the situation under consideration. 'Traitor' might be a good choice, but lacks the requisite specificity. One of the problems with contemporary English is it lacks many such words that would otherwise categorically identify certain kinds of person, place, or thing -- making it difficult or impossible to think analytically about such objects. These shortcomings of the English lexicon are representative of Orwellian linguistics at work in the real world.
On 5/6/2013 3:01 PM, Uncle Steve wrote:
> On Mon, May 06, 2013 at 02:35:52PM -0500, Tim Wescott wrote: >> On Mon, 06 May 2013 12:01:44 -0400, Uncle Steve wrote: >> >>> Back again for some more abuse. >>> >>> I'm building a 12V battery charger that will be controlled by a small >>> low-power microcontroller. I've not yet hooked up the microcontroller, >>> but most of the code is written and I'm trying to finalize the charger >>> electronics before I hook it up. >>> >>> The circuit is very simple. An 18V 2A transformer, a bridge rectifier, >>> and filter capacitor feeds a main power rail. A 5V regulator produces a >>> few mA for the microcontroller, which I won't show here. The charger is >>> more or less as follows, though I will leave out the resistor/divider >>> taps which hook up to the ADC channels on the micro. >>> >>> >>> +18VDC ---------------------------+ >>> Q1 c e | D1 R1 >>> -----\_/--------->|----\/\/\--------+12(batt) >>> b| | >>> +------+ | >>> | | +--+----------+ >>> / Q2 e\_/c | >>> R1 \ |b | >>> / | e |c Q3 >>> \ +--\/\/\------\_/ >>> | R2 |b >>> | | R3 SW1 >>> LED1 \_/ +--\/\/\-- \-- +5V >>> --- >>> | >>> | >>> GND --------------+------------------------------------ GND(batt) >>> >>> >>> Q1 - MJE3055 >>> D1 - 1N4004 >>> R1 - .5 5W >>> >>> Q2 - BC557 >>> R2 - 200K >>> >>> Q3 - 2N2222 >>> R3 - 1K >>> >>> >>> The microcontroller will strobe R3 with PCM at about 488HZ with a duty >>> cycle dependant on the charge profile. R1 is the sense resistor and >>> permits measuring instantaneous charge current. I've got the battery >>> attached and can watch the voltage rise (and settle) as I manually >>> engage a switch attached as shown. The battery voltage as it came from >>> Wallmart was about 12.7V. Charge current with this circuit is 1.4A at >>> this point in its charge cycle. The heat-sink gets rather warm, but it >>> isn't all that big and I'm going to target 3 or 4A as the peak charge >>> current so I'll probably substitute a TO-3 package with a much beefier >>> heat-sink when I put the project in an enclosure. >>> >>> So far, so good. The output of Q1 shows .6V ripple. Attaching my scope >>> to the base of Q1 shows an idle (SW off) voltage of 16mV and a 120Hz >>> signal with a 70mVpp with a duty cycle of 17%. I'm not exactly sure >>> where this signal is coming from, although its frequency suggests a >>> causal relationship with the AC mains. There does not appear to be any >>> ripple on the 5V rail, but my scope isn't good enough to really zoom in >>> on it. >>> >>> The other side of the coin is that the Q2/Q3 network seems to be rather >>> sensitive. When I pass my hand over the breadboard the distortion >>> described above doubles and I can get an amplitude of 1V on that >>> distortion by standing up suddenly while sitting in front of the idle >>> circuit. It is difficult to say what is happening because I can double >>> the distortion by attaching the scope to a wall-wart USB charger, and I >>> know I haven't yet calibrated the scope all that well either. (Scope >>> shows 4.5V from the 5V regulator.) But the fact that I can affect the >>> circuit just by moving things in the general vicinity is, um, rather >>> shocking. >>> >>> Besides installing the circuit in a metal case, are there any easy >>> solutions to fix that 16mV idle voltage? Should I just change the BC557 >>> to a 2n2222 and work out how many of what kind of resistors I need to >>> supply the 3055 with the mA it needs to dump several amps into the >>> battery? I like this version because it is easy to set up and has a low >>> part count, but I'd really like to get rid of the noise and the >>> sensitivity to movement. >> >> Start a new thread! This isn't even remotely related to fan motors! > > Sorry. My newsreader crashes when I 'post' so I have to
Fix your newsreader!
On Mon, May 06, 2013 at 03:38:19PM -0500, amdx wrote:
> On 5/6/2013 3:01 PM, Uncle Steve wrote: > >Sorry. My newsreader crashes when I 'post' so I have to > > Fix your newsreader!
I started doing that, but the path I went down is superficially similar to Larry Wall's story and I fear it will be a while yet before I have running code. Regards, Uncle Steve -- There should be a special word in the English language to identify people who create problems and then turn around and offer up their own tailor-made bogus non-solutions designed to completely avoid the root causes of the situation under consideration. 'Traitor' might be a good choice, but lacks the requisite specificity. One of the problems with contemporary English is it lacks many such words that would otherwise categorically identify certain kinds of person, place, or thing -- making it difficult or impossible to think analytically about such objects. These shortcomings of the English lexicon are representative of Orwellian linguistics at work in the real world.