Sunday, February 16, 2025

Ali Express "SDR TX/RX Switch" - A design not well thought out...

Figure 1: 
Front panel of the SDR switch showing the 3.5mm audio
connectors and the red/green RX/TX LED - which have
been swapped to be in their proper location.
Click on the image for a larger version.

IMPORTANT:

If you have one of these devices, DO NOT connect it to your transceiver and second (SDR) receiver UNTIL you have read and understood the issues described here. 

Failure to understand how this device works may result in your blowing up your SDR when you transmit! 

I've you've been following this blog, you'll note that I've used SDRs (Software Defined Radios) quite a bit - particularly for reception.  Transmitting in the vicinity of any receiver - or trying to use an outboard receiver in conjunction with a transmitter on the same antenna - is a bit problematic for several reasons:

  • If the transmitter and receiver are in close proximity and on very nearby frequencies (e.g. on the same band) then it is (nearly) inevitable that the receiver WILL be overloaded when the transmitter is active.
  • Unless the frequencies (transmit and receive) are very well separated AND both the receiver and transmitter have adequate filtering, the receiver will be overloaded by the transmitter.
  • It is possible that even if you have a separate receive antenna, it may intercept enough energy from the transmitter to damage/destroy the receiver.  If the two are on the same band, this is more likely - but even if the receiver is being operated on a very different frequency range than the nearby transmitter and there is unsufficient filtering at the receiver the receiver could sustain damage.
  • It is often the case that one might have a single antenna on which two receivers (e.g. the receiver built into the transceiver and an outboard SDR receiver).  In this case one clearly must protect (e.g. disconnect) the outboard receiver when transmitting.

It's worth noting that most SDR receivers do NOT have particularly strong filtering in them:  Unlike an amateur transceiver - which may have separate filtering for each amateur band - this is rarely the case for wide frequency-range software-defined radios:  RTL-SDRs, SDRPlay, Funcube and others have either limited or rather broad filtering in them.

What this unit does

Some modern radios actually have external receive ports on them to allow you to "share" the RF while protecting the external receiver.  If your radio doesn't have that, there are/were several devices to allow this that may be found on the market (e.g. the MFJ-1708)- but by attention was brought to an inexpensive unit (pictured above) that has appeared on the various seller web sites (Amazon, EvilBay, Ali Express, etc.) so I obtained one via a U.S. seller.

The description of this device is typical of those found on at the stores of Chinese sellers, curiously being both under and over-descriptive at the same time:  "160MHz 100W Portable SDR Transceivers Aluminum Alloy Box Device Radio Switch Antenna Sharer Practical Signal Equipment Accessory"

By the description, with this device it should be possible to connect your transceiver and SDR (receiver) to the same antenna, perhaps receiving using both (e.g. the addition of a waterfall to an older radio) without fear of damaging the SDR or the transceiver.

This device also has another feature:  To re-route audio when transmitting - which is probably the most usable feature of this device as it comes out of the box as we'll see.

As we'll see, this device doesn't quite work as you might think that it should.

"Documentation?  What documentation?!" 

This unit arrived in a package with (surprise!) no documentation at all - which was somewhat disappointing:  Sometimes one gets a (badly!) translated half-sheet of paper that hurts one's brain to parse - or even a URL to a page with... something... but not the case here.

From a practical standpoint, it's somewhat "self documenting" in the sense that if you ordered this device in the first place, you already had an idea as to what it was supposed to do, so it's possible to figure things out.  Referring to Figures 1 and 2 (the front and back panels) we have:

Front panel:

  • LED on the left-hand side.  This LED is illuminated when the unit is in "Receive" mode - that is, the "SDR" rear-panel RF connector is connected to the "ANT" rear-panel connector.  (The PC board shows this as a green LED, but on mine the red and green were interchanged during assembly:  I swapped them back.)
  • 3.5mm jack labeled "SDR".  This is a stereo (2-channel) audio jack and, during receive, both channels are connected to the "Audio Out" connector.  It is disconnected during transmit.
  • 3.5mm jack labeled "AUDIO OUT".  This is a stereo (2-channel) audio jack that is intended to be connected to speakers.
  • 3.5mm jack labeled "TRX".  This is a stereo (2-channel) audio jack that is intended to be connected to the transceiver during transmit.  Is is disconnected during receive.
  • LED on the right-hand side.  This LED is illuminated when the unit is in "Transmit" mode - that is, the "TRX" RF rear-panel connector is connected to the "ANT" rear-panel connector.  (As noted, this should have been a red LED according to the marking on the PC board but mine was populated with a green LED, which I swapped.)

Figure 2:
Back panel of the SDR antenna switch.  SO-239 connectors
are for the radio (transceiver) and antenna with the SMA for
the SDR.  The 3.5mm PTT and power connectors are visible.
Click on the image for a larger version.

Rear panel:

  • RADIO connector.  This is an SO-239 female connector to which the transmitter/transceiver is to be connected.
  • ANTENNA connector.  This is an SO-239 (female) connector to which the antenna is to be connected.
  •  PTT connector.  This is a 3.5mm connector in which the center pin, when grounded, will switch the unit from "Receive" to "Transmit" mode.
  • SDR connector.  This is an SMA connector to which the SDR (or other auxiliary receiver) is to be connected.
  • 13.8 VDC connector.  This is a 2.1x5.5mm coaxial power connector (center positive) though which DC power is supplied.  This voltage is not critical and could be anywhere from 11.5 through 15 volts.

Also in the box my unit came with an SMA-SMA jumper, SMA-BNC adapter, three 3.5mm "audio" cables, a 12 volt switching supply (with a European "pin" plug) and a universal plug adapter:  The 12 volt switching supply seems to be the cheapest, meanest possible unit with no brand name and should NOT be trusted or used - but at least its DC cord is useful!  (In other words, do not use this power supply - particularly as it is unfiltered from an RF standpoint and it would be a really bad idea to use it on an RF receive device of any type!) 

How it actually works

As you would expect, the antenna is to be connected to the "ANTENNA" port.  When in receive mode, the "SDR" connector is also connected to the "ANTENNA" port - but the "RADIO" port is not!

What this means is that as shipped from the factory, if you connect your transceiver, antenna and SDR to the unit, when it's in receive mode, you will get no receive signals on your transceiver.  This is by design, apparently.

It is expected that PTT connection on the back should be grounded when the transceiver is in transmit mode - and when this happens, the RADIO and ANTENNA ports will be connected to each other.  There is also an RF sensing circuit that is supposed to detect when the transmitter is producing RF, but this has its own issues as will be discussed later.

There is a jumper...

If you take the unit apart (via the four screws on the back panel) you'll see a jumper (J5 - see the schematic of Figure 3 and the photo of the board in Figure 4) and some awkwardly-worded text indicating that if you remove the jumper that you'll have "dual receive" - which means that the Radio's receiver and the SDR will be connected to the antenna at the same time.

This is technically true - but there are a number of "gotchas" here

 First, let's take a look at a reverse-engineered schematic of the unit, below:

Figure 3:
Reverse-engineered schematic diagram of the unit.
The parts designators are those shown on the silkscreen of the circuit board.
Click on the image for a larger version.

Circuit description:

DC power

The DC input power via J4 is protected with F1, a 500mA self-resetting fuse and D10, a diode for reverse polarity protection while L2, a 220uH inductor, isolates the connection at RF.  Capacitors C6 bypasses RF while C7, a 220uF electrolytic, provides smoothing/filtering - likely enough to even allow an AC power source (from a 12-ish volt transformer) to be used. 

It's worth noting that there are two "grounds" on this device:  The "antenna ground" of the rear panel and RF connectors and the "shack ground" of the DC power and audio which are isolated by L1, a 220uH inductor.  On paper, this isn't a bad idea - but on this unit there's a flaw:

The back panel being used to mount the connectors and it - and the entire case - is at "RF" ground - which would be fine as that would be the same "ground" as your radio.  The problem is that the circuit board's ground planes are not set back from the edges of the board meaning that it's possible that the green insulating coating could scrape off the board and contact the case it the mounting slot, connecting the two "grounds" together - perhaps intermittently.  (Practically speaking, most people would not be likely to ever have a problem.)

Oops.

Keying

J6 is the PTT input, activated by grounding the tip of the 3.5mm connection with the outermost sleeve being the "shack" (not antenna) ground.  Diode D6 blocks positive voltage and when the PTT is keyed, the gate of Q3, an N-channel MOSFET, goes low, de-energizing all of the relays.  When the PTT line is "un-grounded" capacitor C3 and R9 charge, preventing Q3 from re-activating the relays instantly, providing about 100msec or so of delay through the charging by R3.

Comments about the keying via the PTT port:

This relay keying scheme assumes that there is either NO voltage or a POSITIVE voltage on the keying line from the radio.  There are several caveats to this:

  • When powered up, the relays are energized.  What this means is that if power is removed, it's as if it's in "transmit" mode.
    • This connects the ANT to the RADIO port and the SDR port is grounded.
    • Additionally, the front-panel AUDIO jack gets connected to the TRX jack.
  • The keying line from the radio must go to GROUND when keyed.
  • If the keying line is shared with an amplifier, that amplifier CANNOT put a negative voltage on the keying line as that will hold the SDR switch in "Transmit" mode at best, damage the SDR switch in worst case - and in either case it would hold the amplifier in a "keyed" state.
  • If there IS a positive voltage on the keying line when "unkeyed" it must be at least 5 volts just to assure that Q3 will turn on reliably when the radio is un-keyed.  If the voltage is less than 10 volts, the full delay caused by C3 and R3 will not occur.
  • The 100msec or so of "unkey"delay afforded by R3 and C3 is insufficient to prevent the relays from "chattering" during SSB and CW transmissions if RF sensing is used!
    • If you are a CW operator, the unit will not switch back to receive mode as quickly as your radio might.  If you are a CW operator that prefers QSK (full break-in) you probably don't want to have this unit inline.

There is also an RF keying circuit:  Transmit RF is tapped from the RADIO RF line (from the transmitter) by C1, a 47pF capacitor and rectified by D1 and D2 and used to turn on Q1 - grounding it in the same way that grounding the PTT line does - which in turn keys the transmitter.  There is a fatal flaw in the design of this device exacerbated by RF sensing which I will discuss shortly.

Audio switching

Figure 4:
The circuit board, showing J5 in the center.
The power supply filtering is in the upper-right with the audio
relay (K3) on the left.
Click on the image for a larger version.

Relay K3 may be used to switch audio based on keying.  Let's assume that you are using a separate SDR with a computer to receive audio:  By connecting the computer speakers to the "Audio Out" connector and the computer audio output to the front-panel 3.5mm "SDR" jack the SDR audio will be muted when transmitting at which any audio from the radio connected to the front-panel 3.5mm "TRX" jack will be passed through to the speakers.

Practically speaking, you would probably never use the "TRX" jack to mute your radio's audio, but a more likely scenario is that if you are using an online WebSDR (see the WebSDR.org web site for a list) to listen on the air, you could use this to mute your speakers when you transmit to prevent your own transmitted audio from coming back with a delay and causing an echo.

RF Switching

This is where it gets a bit scary.  First, consider the configuration - from the factory - with jumper "J5" in place.

Remembering that when powered up, the relays are energized, you can see that when in "Receive" mode, the ANT port is connected directly to the SDR port - but you'll also note that the RADIO port is not connected to anything (e.g. floating).  When you transmit, the relays de-energize, connecting the RADIO port to the antenna and grounding the SDR port.  This means two things:

  • There is no receive RF at the transceiver.  Most people that I know don't use their transceiver's receiver instead of the SDR, but use them at the same time - perhaps turning down the volume on the one not being used.  Not having antenna RF to be able to receive anything on the transceiver is likely not what you really want to do.
  • When using the RF sensing, the transmitter is connected to an open circuit before the relay switches.  This has several implications:
    • If you don't have the PTT line wired to your radio, there will be a split second when RF first appears that the radio will see an infinite VSWR.  This can progressively damage a transmitter's finals, despite the SWR protection circuitry within the radio.
    • When relay K1 does de-energize and connect to the antenna, it will be "hot switching" the relay contacts.  This tends to burn contacts and shorten the life of the relay.
    • The RF sensing circuit doesn't have adequate "hang time" to ride through word pauses and CW elements meaning that it will likely "chatter", repeatedly causing the hazards noted above.

 As can be seen from Figure 4, there's a jumper, J5 on the board with the somewhat confusing text:

J5 Usage
Open = Dual receive wheh [sic] RX
Short = Normal Operation

By removing J5, relay K1 is never energized meaning that it is always connected to the antenna:  This helps to mitigate the problem that - when RF sensing is used - that the transmitter is connected to "nothing" as it would be the case with J5 installed - but this also means that in receive mode, the transceiver and the SDR are connected in parallel

Simply paralleling two (nominally) 50 ohm devices (the transceiver operating in receive mode and the SDR) isn't a great idea - but it will generally work "OK", particularly if the SDR and the transceiver are tuned to the same frequency range.  When the transceiver is OFF or on a band  other than that to which the SDR is tuned may cause its filters to "suck out" RF and a loss of signal/sensitivity on the SDR.   

(Note:  A "properly-designed" device that shared the antenna for receive would likely include a built-in 2-way splitter which can reduce such problems.)

The bad part here is that if you transmit - and, for some reason relay K2 doesn't de-energize instantly, as would be the case with RF sensing only - you will transmit directly into your SDR, likely destroying its front end.

Oops, again.

What this means is:

  • If you remove J5, DO NOT operate the unit UNLESS you are using the PTT cable - which is to say DO NOT rely on RF sensing alone as transmit power will briefly enter the SDR's front end before the relay can switch.  The SDR is likely to be damaged due to the lack of RF power protection on that port.
  • If your PTT cable accidentally becomes disconnected - or external keying is turned off in your radio's menu - you will transmit into the SDR and destroy its front end due to the inability of the RF sensing to act instantly and due to the lack of protection to the SDR.

The reason for this as as mentioned above:  Not only are the transceiver and SDR connected together without any protection circuitry, but also the RF sense needs to detect transmit power before it will activate - and by the time that it does, a brief burst of full transmit power may have found its way into your SDR.

A hardware bug

There is also a more subtle bug that I uncovered.  While testing the unit on the bench, I disconnected J5 - but was confused when the ANT and RADIO ports were not connected.  What was happening was that when I removed J5 - while the unit was powered up and in receive mode - enough current was flowing through LED D8 and resistor R4 to hold relay K1 closed.

Simply removing the power temporarily caused K1 to release - and there wasn't enough current to close it again, but if you are messing with the configuration, this "bug" could bite you, too!  I suppose that it's also possible that jarring the unit could cause the armature of K1 to hold in place - but I didn't try this.

The "fix" for this - if you want to bother with it - is to change resistor R4 to a 10k resistor:  This also tones down the TX LED's brightness a bit, too.

Overall comments

I get the sense that whoever designed this thing may have been copying the general idea from other, similar devices - but not really understanding what was being done, and why.  For example, the separate "grounds" implies an understanding that having them separated would be a good idea - but whoever laid out the circuit board made the "rookie mistake" of making it possible for the two "grounds" to be connected, anyway.

The description of this unit implies that it's useful up to 160 MHz.  I suspect that this is probably true-sh, but that the VSWR starts to climb when one gets to and above 6 meters (50 MHz) meaning that it's likely most useful at low power at these higher frequencies.

The cardinal - and unforgivable - sin has to do with the fact that if you want to use both your transceiver's receiver and your SDR simultaneously, you WILL want to remove J5 - but if you do - and you don't absolutely have the PTT connection working properly, you WILL blow up your SDR!

Fixing this problem is possible with the addition of some simple protection circuitry to allow the SDR to survive brief bursts of transmit power - perhaps the topic of a later post. 

AS IT IS, I WOULD NOT USE IT FOR ITS INTENDED PURPOSE, AS AN SDR ANTENNA SWITCH - at least not without significant modification.

What it IS useful for, out of the box

What it IS useful for is an audio switch to mute your computer audio when you transmit - as you might do when using a WebSDR or other remote receiver.  For this, I would:

  • Connect the PTT to your radio's PTT
  • Connect your computer's speakers to the "AUDIO OUT" jack
  • Connect your computer audio output to the "SDR" jack

If you are hell-bent on not using the PTT cable, the RF sense may be useful, but you would also need to:

  • Remove internal jumper J5
  • Connect the transceiver to the "RADIO" port
  • Connect the antenna to the "ANTENNA" port 
  • DO NOT connect anything to the SDR port

As noted before, the time constant of C3 and R3 may not be enough and the relay may "chatter" - in which case R3 could be replaced with a higher-value resistor of, say, 330k - or with a 1 Meg potentiometer in series with a 47k resistor to allow "hang time" adjustment.  (Adjustment of R3 is preferable to increasing the value of C3 as the latter could also slow the activation time when RF is detected.)

Final comments

Other than to switch audio as described above, I wouldn't use this device as it is shipped for any other purpose without appropriate modification.  This makes this device a possible  "starting point" for another project (e.g. there are already some relays and a metal box!) - one to provide proper RF protection for the SDR and make the RF sensing more useful when using modes that have variable power levels (e.g. CW, SSB) which can cause the current design to "chatter".

* * * * * * *

This page stolen from ka7oei.blogspot.com

[END]

Sunday, January 26, 2025

A short-term "UPS" for mini (NUC-type) PCs

The problem

Figure 1:
A "Beelink" small form-factor PC.  This unit sports a Ryzen
processor and runs from an external 19 volt supply.
Click on the image for a larger version.
Very small computers (so-called "NUCs" - a term that we'll use generically throughout) of recent manufacture are energy efficient and are increasingly used in lieu of full-size desk top PCs.  Many of these use external power supplies - often referred to as "bricks" - of the sort also used to power and charge laptops.

Even if one has a UPS (Uninterruptable Power Supply) attached to their computer - or especially in the case of a "whole house UPS" (e.g. Tesla Power Wall or equivalent) there are instances during which the transition between power grid going down and the UPS picking up the load may not be fast enough to prevent the computer from rebooting or just crashing and hanging.

For this article, we are looking at the case when the power supply for a "NUC" (small form-factor power supply) is incapable of "riding" through the aforementioned UPS transition.  In this instance at least part of the problem has to do with that unlike the power supply in a desktop computer - which are physically bigger and have a comparatively large reservoir of energy storage in the form of big filter capacitors - the small power supplies used for these small computers have a comparatively small energy reserve - and unlike a laptop, there is no onboard battery to serve as a backup.

Returning to the "whole house UPS" and, to a lesser extent its much smaller counterpart used to back up only critical gear, it may take more than 100 milliseconds for the power to resume after the grid is lost - depending on the nature of the outage:  Owning a Tesla Powerwall - and talking to others with this and similar (non-Tesla) systems - they all seem to share a common trait:  Sometimes they switch quickly enough that nothing reboots, but other times they take much longer to switch (sometimes more than 500 milliseconds) and many computers - even desktop PCs with more capacitive energy storage - fail to carry through the transition.

For this reason it might be reasonable to have a smaller (and, presumably a "fast") UPS to carry the computer through this transition although it seems a bit silly to have a UPS when one already has one for the entire house - but all it needs to do is to run for a few seconds, so even UPS batteries in poor condition will likely suffice.

In the case of a very small form-factor computer such as a NUC, we could contrive a means of providing power for just long enough for the UPS - whether desk-top or whole-house - to do its job.  It, too, needs only last long enough - perhaps a second or so.  If it's powered via a "brick" power supply this task is a bit easier and it is those devices with external power supplies that this article addresses.

Carrying through the interruption

In the specific case of the "NUC", these are often (but not always) powered via an external DC power supply.  In my case, I have a Beelink NUC using a Ryzen 5700 that is powered from a 19 volt supply.  In communicating with others who own this same mini PC it's clear that it's shipped with a wide variety of different power supplies from different manufacturers - some of them with ratings that seem a bit low for the rated power consumption of the computer - so I replaced it with a good-quality MeanWell unit (see sidebar) which not only has more robust ratings, but its input is power factor corrected - a very important consideration when powering it from a UPS! See comment #1 at the end of this article

Details about the replacement power supply

The MeanWell power supply that works with this Beelink NUC  is P/N:  GST90A19-P1M  which may be found at Jameco Electronics and it is Jameco Part Number 2223486 (link) and from Digi-Key as Part Number 1866-2156-ND (link).  This unit is rated for 19 volts at 4.74 amps - much greater than the supply that is likely to have been supplied with the PC and it has the needed 5.5mm O.D./2.5mm I.D. coaxial power connector with center positive.  Other NUCs will have different power requirements and connector types and polarities so it is up to YOU to determine what might work for your computer.

As noted, it has good power factor correction (PF of 0.9 or better) and produces very little to no radio frequency interference - unlike some power supplies of "unknown" brands.  As a bonus, it so-happens that this supply works perfectly with my older Asus ROG laptop as well!

In testing, neither the original or MeanWell power supply had enough reserve capacity to consistently carry it through a UPS transition - particularly if the computer was "busy" and consuming maximum power

The major reason why there is this concern is that this Beelink computer is located at the remote site of the Northern Utah WebSDR where power bumps and outages causing the load to switch to the UPS are very frequent - and occasionally, this causes the computer to "hang" (and not reboot!) requiring that the power outlet be remotely switched off - and back on.  As this is not a "public-facing" computer (it does WSPR monitoring) its outage may not be immediately noticed.  It's worth noting that the desktop-type computers have no issues with these transitions.

What to do?

Figure 2:
The Tecate SCAP PBLS-3.5/21.6 capacitor module.
This unit contains the necessary voltage equalization circuitry.
Click on the image for a larger version.
I did not want to put a separate mains-powered UPS on this computer and while I could have figured out a battery-based solution, this seemed overkill as I literally needed it to power the computer for less than one second - plus I didn't want to have batteries that would eventually "age out" and need to be replaced.  The obvious solution seemed to be the "supercapacitor" - devices with Farads of capacitance, capable of storing enough energy to power the computer for a very short period of time.

In perusing the DigiKey catalog I found at least two useful candidates:  One capacitor of 1.25 Farads with 540mΩ of internal resistance (Tecate P/N: SCAP,PBLS-1.25/21.6) and another of 3.5 Farads with 260mΩ of internal resistance (Tecate P/N: SCAP,PBLS-3.5/21.6), each rated for 21.6 volts - both suitable for use with a 19 volt supply.  These are actually capacitor modules, consisting of eight 2.7 volt capacitors of 10 and 20 Farads each, respectively, and containing simple circuitry to assure that the voltage across each of the internal capacitors was balanced.  It's worth noting that the voltage equalization circuitry itself will consume a small amount of current (perhaps as high as a few 10s of milliamps) - particularly as one approaches the maximum voltage rating and this must be considered in the design of the support circuitry.

It's important to note that these won't actually function as a UPS in the traditional sense:  These capacitors can store enough energy to power the computer for a short time - only for a few seconds at most - but this is more than enough to carry it through for the few hundred milliseconds of drop-out that might occur during a UPS transition. 

Using the supercapacitors

The problem with using a supercapacitor is that when they are discharged, they look like a dead short, meaning that you probably cannot simply tack them in parallel with a power supply:  To do so would stress the power supply - putting it into current limiting at best, possibly causing it to "trip out" and go offline, or in the worst case, damaging it - so provisions must be made to regulate the charging of the capacitor.  The diagram in Figure 3 shows the circuit surrounding the capacitor.

Figure 3:
Schematic of the supercapacitor NUC UPS.
A standard outboard power supply is used - typically the one supplied with the computer, but it could
be another unit - probably of better quality - as noted in the article.
Click on the image for a larger version.

How it works

For charging, we are using old and "newer old" tech here - R1 is a simple series resistor of 100 ohms with a power rating of 5 watts which will limit the current to around 200mA, tapering off gradually as the capacitor charges up.

In parallel with R1 is F2, a 100 milliamp self-resetting thermal fuse (e.g. "Polyfuse").  This device is really a thermistor and when "excess" current flows through it, it heats up and the resistance skyrockets, greatly reducing the current flow.  The way that it is used here means that when the power supply is first connected (and the capacitor is fully-discharged) there's a brief inrush of current until F2 "blows" (gets hot) at which point it takes only 15-20 milliamps to keep it in this state at which point R1 is handling most of the current.  As the capacitor charges and the voltage differential across R1 decreases, the current through the 100 ohm resistor will also drop - but F2 will also gradually cool down as the voltage across it decreases - but the current will also increase - but never more than approximately the 100 mA rating.

Figure 4:
Internals of the UPS.  The support circuit was constructed
on a small piece of prototype board (left) while the LEDs to
indicate the status are on the right.  The rear panel (far left)
has the power cable and coaxial power connector.
Click on the image for a larger version.
asfasdf

The use of F2, the 100mA fuse results in much faster charging of the capacitor.  In testing with a 3.5 Farad capacitor, it took about an hour for the capacitor's terminal voltage to be within a hundred or so millivolts of the power supply voltage with just R1, the 100 ohm resistor - but it took about 9 minutes with the addition of F2.  As an added bonus, when the capacitor is nearly fully charged (within a volt) the current through the 100 ohm resistor would be only about 10mA or so and the charging rate would slow to a crawl - plus the equalizing circuit within the capacitor module draws a few milliamps meaning that it will never get closer than 200-500 millivolts of the power supply voltage.

With the addition of F2 - and the fact that at this low voltage drop it will have cooled off and have a resistance of between 3 and 10 ohms - the capacitor's resting voltage will be within a few 10s of millivolts of the power supply rather quickly.  This is important as even a few hundred millivolts of extra charge on the capacitor will measurably extend the "run" time.  Attaining this sort of "full charge" could be done with a solid state circuit using FETs and op amps,  but it would be fairly complex:  This approach - with a single, inexpensive component - is nice and simple.  The use of F2 also overcomes the small current consumption of the capacitor module's equalization circuitry:  A few milliamps of current from this circuitry would drop the full-charge voltage by as much as a few hundred millivolts without F2.

A maximum charge current of 200-300mA seems reasonable as that would not put a significant amount of burden on the power supply - which must be able to power the computer and charge the capacitor.  I also considered the use of a simple transistor-type current limiter which would maintain a constant current until the capacitor got to within a volt or so of the supply voltage, but decided that it probably wasn't worth the added complexity - and I would still have required something like F2 to bright the capacitor right up to the supply voltage.

The "Charge" LED works by detecting the voltage crop across R1:  If it exceeds approximately 0.6 volts, Q1, a PNP transistor, is turned on, pulling its collector high, turning on LED2.  When this LED goes out, the capacitor will be within 0.5-0.6 volts of full charge.  The "Ready" LED (LED2) is in series with D2, a 15 volt Zener diode and it will start illuminating when the voltage across the capacitor exceeds about 17 volts for an old-tech AlGaInP LED (with a 2.1 volt threshold) or about 18 volts for a more modern GaN LED.  In a "standby" state, the "Charge" LED will have extinguished and the "Ready" LED will be on indicating the unit's readiness.  Neither of these circuits are perfect, but they give a "good enough" indication of the state of the device and let the user know that things are working.

Figure 5:
The completed UPS with the two LED indicators on
on the front panel.
Click on the image for a larger version.

An "ideal" diode - in real life

Parallel with R1 is a diode (D1) that is reverse-biased when the capacitor's voltage is lower than the supply voltage, preventing current flow other than through the resistor.  While I originally considered using an "ordinary" diode - which would have a voltage drop of about 0.6 volts for a standard silicon or around 0.4 volts for a high-current Shottky type - I decided to do something different:  Use an "ideal diode".

A voltage drop of 0.3-0.6 volts from a typical diode would represent an immediate voltage drop from the capacitor - and since the voltage on the capacitor will drop as it's discharged, the "diode drop" would represent less time that the computer could be powered by it, alone.  A hypothetical "ideal" diode would have zero voltage drop in the forward direction and block current in the reverse - and fortunately, something pretty close to that actually exists these days!

As it turns out, such a thing actually exists - and it is pretty inexpensive.  This implementation of an "ideal" diode is really a module with several components:  The specific modules that I used (which I got from Amazon - five for US$10) use the Diodes Incorporated DZDH0401DW chip along with an AGM30P05A P-channel FET along with a 100k and 1 Megohm resistor.  These "diodes" are rated for a maximum stand-off voltage of 26 volts and a steady-state current of 10 amps, but could probably handle 15 or even 20 amps for brief periods.

The way that these work is that the DCDH0401DW has a comparator that is used to detect the minute voltage drop between the "input" of the diode (the "+" side) and the "output" (the "-" side):  If the voltage on the input is higher than the output, the P-channel FET is turned on, allowing it to conduct from the input to the output.  If the voltage on the input is NOT higher than the output, the FET is turned off, preventing current from flowing from the output to the input.  The use of a P-channel FET allows the switch to be placed in the positive lead which permits the negative side of the power sources - the power supply and the super capacitor - to be connected together.  Incidentally, the FET is wired such that even if it weren't "on" at the moment that it might need to conduct, it's intrinsic diode would conduct, anyway, albeit with a 0.6 volt drop, but since the DZDH0401DW chip responds within a few microseconds at most, the FET would be very quickly turned on.

Figure 6:
The back panel of the supercap UPS.
The original power supply plugs into the jack while the
short cable needs to be just long enough to get to the
back panel of the PC.
Click on the image for a larger version.

When the FET is on, it's resistance is on the order of 5.5 milliOhms which means that if there's three amps flowing through it, less than 20 millivolts will be lost - about 1/30th of that of a standard silicon diode - and since there is so little voltage lost, there will be a similar fraction of heat being produced as well.

As you may have noticed in the schematic diagram of Figure 3, there are actually three connections to this "diode":  The anode, the cathode and ground - the ground being required because not only does the comparator/control chip need power, but the gate of the P-channel FET needs to be pulled negative with respect to its source.  The "overhead" current of the FET and comparator/control chip is only on the order of 175 microamps according to the data sheets so it's power consumption is practically negligible in our application.

The other components in the circuit include D2 - a 15 volt Zener diode along with LED1 and R2 for current limiting:  This LED will illuminate if the applied voltage exceeds about 17 volts and functions as a "Power" indicator.  Transistor Q1, a PNP, is connected across R1 via current-limiting resistor R4 and when the voltage drop across R1 exceeds about 0.6 volts, its collector will be pulled toward V+, causing LED2 to illuminate, indicating that the capacitor is charging.  When this LED goes out, this indicates that the capacitor is - at the very least - "mostly" charged.

The final component is F1 - a self-resetting thermal fuse (e.g. "polyfuse") which could have a rating of anything between 5 and 9 amps.  As the capacitor can deliver a large amount of current when shorted, this is provided as protection.  A "normal" fuse of 6-10 amps would suffice here, but I happened to have the polyfuse on hand.

Variations on a theme:  Backing up a 12 volt PC.

As noted, this unit was built using the 3.5 Farad capacitor - but it should be capable of doing its job with the lower-cost (and physically smaller) 1.25 Farad unit.

The described unit is also designed to be used with a NUC/PC that operates at 19 volts - a common voltage used by laptop computers.  Many of these small computers use 12 volts - and while one could possibly tack a small battery across the power supply, the use of a capacitor-based backup would mean that there would be no battery that would have to be checked/replaced on a routine basis.

The circuit depicted in Figure 3 - designed for 19 volts - would have to be modified slightly, as follows:

  • D2, a 15 volt Zener, would be changed to a 9 volt device for a 12 volt bus.  This would better-represent the charge state of the capacitor for a 12 volt supply, causing it to illuminate once it had charged to better than about 11 volts.  The "Ready" LED would illuminate at voltages above that of the 9 volt Zener plus the LED's forward voltage.
  • R1, a 100 ohm resistor for the 19 volt device would be changed to somewhere between 47 and 62 ohms but still a 5 watt device.
  • The capacitor described is rated for 21.5 volts - which is probably overkill for a 12 volt power supply.  A 16 volt capacitor would be a better choice.  Additionally, a lower-voltage capacitor module will have commensurately lower internal resistance which improves efficiency - and for a 12 volt power supply where voltage droop due to Ohmic losses is arguably more important, it would be best to keep it below 400mΩ.   Possible capacitors for 12 volt use include:
  • It's worth mentioning that while a "12 volt" computer may operate from a supply voltage that is nominally 12 volts, it's worth checking to make sure that it's within the safe operating range of the capacitors that you choose.  For example, the Tecate capacitors listed above can operate safely only up to 13.5 volts, ruling out the use of a power supply that operates in that range - but the Cornell-Dublier capacitor with its 18 volt rating would work nicely over a slightly wider range.

Conclusion

Figure 7:
The supercap UPS, on the shelf next to the PC -
now in service at the Northern Utah WebSDR!
Click on the image for a larger version.

As can be seen from the photos, the capacitor and support circuitry was placed into a plastic enclosure:  The two LEDs were placed on the front panel and labeled while the back panel has a female coaxial power connector that matches that of the computer and power supply along with a short cord terminated with the same type of male power connector used by the PC - which happens to be the common "5.5mm x 2.5mm" type with the outside shell being negative.

To install the UPS, the PC was powered down and the device inserted into the power lead - the power supply plugging into the UPS and the short cable plugging into the PC.  After a bit less than 10 minutes, the "Ready" LED illuminated - followed soon after by the "Charge" light extinguishing - but since the charger is current-limited, the PC could be powered up immediately after installation - not needing to wait for it to fully charge.  Of course, any testing of the device to determine its ability to "ride through" an interruption should wait until the capacitor has fully-charged.

As can seen in Figure 7, the UPS was placed on the shelf next to the PC that it supports.  With the PC under a "moderate" load (about half of the maximum power consumption) the power supply was unplugged briefly to see if it would hold.  Interruptions of up to 1.5 seconds were tried with no disruptions of the PC with the capacitor being fully "recharged" to just a few 10's of millivolts of the maximum voltage in under two minutes due to the "shallow" discharge.  We chose not to try to see how long it really would hold the PC up, but with the UPS installed, we cycled the UPS several times and the PC happily rode through it - something that it would not do without.

In other words, success!

 * * * * * * *

Comment #1:

In this article, I mention that having a power factor corrected power supply is particularly important when running from a UPS.  If your UPS is running power supplies without power factor correction, it may well be that it will trip out due to overload at around half of its wattage rating:  The real clue is to closely look at your UPS's specifications and note that it has a "volt-amp" rating (which is more of a true indication of its capability) that is much lower than its wattage.

For more information about this, see the Wikipedia article about Power Factor (link) - and pay special attention to the section about "Non Linear Loads" which are what a typical, non power-factor corrected switching supply presents to the mains.  In these cases, the peak amperage can be several times higher than the average - and all power circuits must be able to supply these high peaks regardless of the average power, which is why a UPS, generator or even mains supply circuit must to be de-rated to accommodate devices with poor power factor.

In other words:  If you don't use power-factor corrected power supplies on your UPS or generator, you won't be able to safely and reliably supply anywhere near its "wattage" rating - but if you do use only devices with good power factor, you will be able get much closer to its ratings without overloading it.

* * * * * * *

This page stolen from ka7oei.blogspot.com

[END]

 


Saturday, December 28, 2024

Charging LiFePO4 batteries from a vehicular electrical system - the problems and a solution.

Figure 1:
The Renogy RNG-DCC1212-20 - an isolated
and current-limited battery charger, intended
for use with vehicle electrical systems.
Click on the image for a larger version.

There are times - usually on a camping or road trip - where I would like to charge my LiFePO4 batteries en-route, from the vehicle.  The "need" is largely the result of having one of those coolers with a built in compressor:  It runs about 10-30% of the time at normal room temperature and pulls about 3.5 amps when doing so - but it's also advantageous to be able to keep a battery topped off in the event that you didn't start the trip with a fully-charged battery in the first place.

To do this, one may be tempted to connect the battery directly to the vehicle's electrical system, as might have done in days past with a lead-acid battery.

DO NOT do this with any lithium battery - at least not directly.

In short, you cannot and should not parallel a LiFePO4 battery with an existing charging system intended for lead-acid batteries.  The biggest issue with doing so is that unlike a lead-acid battery, a LiFePO4 battery will attempt to charge with all available current, likely resulting in blown fuses, heated wires and burnt-out alternators. A secondary issue has to do with the BMS (Battery Management System) of the LiFePO4 simply disconnecting abruptly when the battery is fully-charge, potentially causing voltage spikes capable of damaging vehicle electronics and possibly, the BMS itself.

See the section "Why you need to treat LiFePO4 batteries differently" in the "tl;dr" section near the end of this article (link) for more details as to the problems that can occur.

A solution

The solution to the issues noted above lie largely in limiting the charging current.  One way to do this would be resistively - perhaps with the use of intentionally small-gauge wire and/or resistor or incandescent automobile headlamp in series.  This will, by its nature, generate heat as it's inefficient - and it can generate quite a bit of heat (potential fire risk here!) - but this is the way one might have accomplished this in years past.

This sort of limiting may occur unintentionally if one charges via, say, a cigarette lighter/accessory plug connected with light-gauge wire, but this is sort of a "kludge".  One issue with this is that it can cause frequent blown fuses as the current isn't regulated and if the user attempts to circumvent this by using a higher-current fuse, damage to the electrical system (or even fire) can result.  If the connection is made to a power source that is switched on/off with the ignition, a connected battery can "back feed" the electrical system which can result in the battery being discharged when the vehicle is off or, worst case, damage to both the vehicle and battery.

These days one would use a current-limited and regulated voltage DC-to-DC converter with its power source connected as close to the vehicle battery as possible.

One of the many devices out there that will fit the bill is the Renogy RNG-DCC1212-20 (pictured above), available at the time of the original posting of this article for around US$100:  Using DIP switches, the type of battery (lead-acid, Lithium-Ion or LiFePO4 - I configured for the latter) may be selected along with the charging profile/voltage - and the device will limit the maximum charge current to just 20 amps, selectable to 10 amps with the addition of a jumper wire to the "LC" terminal.  What this means is that no matter the charge state of the LiFePO4 battery, the current being pulled from the vehicle's electrical system will be limited - very useful if one expects to avoid blowing fuses, destroying alternators, or burning up wiring.  (Note:  I have no vested interest in Renogy, they just happen to make one of the readily-available devices that is appropriate for this task.)

Additionally, it's rated to operate from between 8 and 16 volts while maintaining a constant output voltage (once the output current has dropped below limiting) that is independent of the voltage from the vehicle's electrical system. The Renogy is also an isolated DC-DC converter in that there is no electrical connection between the input and output terminals:  By being isolated, circulating currents (through the chassis or other "sneak paths") can be completely avoided which may be helpful for some sensitive equipment and/or to minimize/eliminate alternator "whine".

This particular unit is rated for up to 20 amps output current.  Rated at about 90% efficiency, it will take more power on its input connections than it will output, producing a bit of heat (which is why it has internal fans).  Also note that the current pulled by the unit will vary depending on the voltage input despite the fact that the output voltage and current may remain constant.

For example, let's say that the unit is outputting 20 amps at 14.5 volts, representing a LiFePO4 battery that is nearly fully-charged representing an output power of 290 watts:  Assuming 90% efficiency, the unit will actually consume 322 watts with the difference (32 watts) as heat.   At an input voltage of 12.0 volts,  322 watts is 26.8 amps, but at 14.0 volts, 322 watts is just 23.0 amps.  The fact that it can pull more current from the source supply than it is outputting - particularly when the input voltage goes down - must be taken into account when sizing the wire and selecting the fuse rating.

You can't just connect it and walk away!

The Renogy has a "D+" terminal that, when connected to a voltage source, will activate it.  The intent is that this wire is connected to some part of the vehicle's electrical system that is likely to be on when the engine is running to charge the battery - such as the "accessory" circuit.  The reason for this is that the Renogy itself has no useful low-voltage disconnect:  If you connected it to the vehicle's electrical system with the engine off, it will happily attempt to charge the battery to which it's connected - and if the battery being charged is a large, discharged LiFePO4 battery, it will likely run the vehicle's battery down completely in doing so.

For a permanent installation in a truck, van or RV, finding a wire that is only active when the engine is running (or, perhaps, the ignition is just "on") makes sense - but in my case I have no need for a permanent installation of the unit - plus, I don't have room to mount the unit and am unwilling to connect/disconnect an "ignition on" wire from the electrical system every time I install/remove it.

One way around this would be to monitor the battery voltage:  If it's above about 13.5 volts, one can be assured that the engine is running, but it will drop fairly quickly when the engine is off as the lead-acid starting battery's voltage drops.  Unfortunately, the Renogy's only means of low-voltage cut-off is set to 8 volts (a very "dead" 12 volt battery!) which requires that I come up with another way of enabling/disabling the device. 

Another issue is that whenever  the unit is on (the D+ line is active) but unloaded (e.g. no battery connected to the output) it consumes about 250 mA at 14 volts - increasing to over 500mA at 10 volts - and more than this if its cooling fans are running:  This sort of load will run a battery dead in a few days at best, so there had to be a way of completely disabling it and eliminating current draw.

A voltage-controlled switch

In poking around, I noted that without the "D+" line connected to a voltage source, the Renogy drew no detectable current meaning that I could leave the high-current input leads connected full-time:  By switching just the D+ lead I could enable/disable the device as needed without the need of a heavy-duty relay.  (Judging by the "clunk" that one hears when applying power to the D+ line, the Renogy probably has such a relay built into it.)

As the D+ line itself drew very little current (only about 3 milliamps) and anything above about 4 volts seemed to reliably trigger it, it would take almost nothing to drive it so the circuit could be very simple as the diagram below shows:

Figure 2:
Schematic diagram of the low-voltage cut-off circuit with hysteresis.
This circuit provides an "on/off" control of the converter to the "D+" line based on the
voltage at the "V+" and "V-" connections.
Click on the image for a slightly larger version.

How it works:

The "V+" and "V-" lines are connected across the unit's input terminals to monitor the voltage applied to it.  Resistor R1 scales the input voltage to a lower value to apply to the top of R2, a 10-turn trimmer potentiometer, that is used to divide the voltage down to the 2.5 volt threshold of U1, a TL431 "programmable Zener" via its "reference" terminal.  Capacitor C1 connected across the top of R2 provides a degree of filtering to reduce the probability of the circuit from responding to noise on the electrical system.

Figure 3:
The prototype, built on a scrap of proto board.  This uses
uses through-hole components, but could have been built to be
much smaller using surface-mount devices.  The capacitor has
been lifted up to allow a better view of the components.
Click on the image for a larger version.

Resistor R3 limits the current into U1 and R4 limits the current into Q1 while R5 keeps the emitter-base voltage of Q1 high when U1 isn't conducting, turning it off, resulting in no voltage on the "Out" lead and in this state, with the Out lead connected to the Renogy's "D+" connection, the unit would be powered down and draw no current.  Resistor R6 offers protection to the circuit in case the "Out" terminal is momentarily shorted to ground.

If the voltage on the reference terminal on U1 exceeds 2.5 volts, it turns on, pulling the bottom of resistor R3 toward ground, turning on Q1 and causing the "Out" lead to go high, enabling the Renogy via the "D+" line. When this voltage goes high, resistor R7 feeds back a slight amount of current into the junction of R1/R2, very slightly increasing its voltage, lowering the circuit's turn-off voltage slightly but leaving the turn-on voltage unchanged:  The value of 270k shown causes this voltage difference between "on" and "off"  to be about 0.9 volts while a value of 680k results in a threshold difference of about 0.3 volts.

This threshold difference between turn-off and turn-on (a.k.a. hysteresis) is very important to the stable operation of this circuit.  If the voltage applied to the circuit were just above the threshold (by a fraction of a volt) the "Out" lead would turn on and activate the Renogy.  When this happened, the Renogy would start drawing current, causing the voltage to drop slightly through wire losses and load on the electrical system - but if this voltage dropped below the threshold, the "Out" lead would turn off again and the current consumption would stop, causing the voltage to rise again and turn it back on, causing an endless "on-off" cycle.  

By adding such hysteresis - and making sure that the voltage drop under load was comfortably less than the hysteresis amount - the unit will reliably turn on at the high voltage threshold and will not turn off until/unless the voltage drops below the low voltage threshold.  It is also imperative that this unit be connected as close to the battery (with appropriate fusing!) with as short and heavy leads as practical:  Too-light wiring will cause the voltage to drop under load, possibly causing it to trip out due to low voltage - only to be re-enabled immediately (e.g. the "on/off" cycling mentioned above.)  The need to minimize voltage drop is one reason why the power source should be connected as near the battery/alternator as practical.

Figure 4:
The completed unit in heat-shrink tube.  There are no
exposed electrical connections - just the adjustment at the end.
Click on the image for a larger version.
Enabling the Renogy by voltage detection alone isn't quite as reliable as having a connection to the ignition circuit of the vehicle, but it will work "well enough" and prevent the vehicle's battery from being flattened by the unit staying on all of the time, when the engine is off.

Figure 3, above shows the prototype unit, built on a small piece of prototype board.  R2, the 10 turn potentiometer is the blue device on the far right with U1 being the black object to the left of it with Q1 being on the far left.  In this photo, capacitor C1 is bent up, out of the way to allow a view of the components underneath where it will be laid over.

Figure 4 shows the same circuit covered with some yellow heat-shrink tubing to hold the components together and to protect it from external short circuits.  The end of the adjustment resistor, R2, protrudes from the end of the tubing so that it is accessible.

Installing within the unit

Figure 5:
The circuit within the converter.  The DC output
terminals (to the battery being charged) are in
the lower part of the image.
Click on the image for a larger version.
Not wanting to have a maze of wires outside the device, I installed the circuit inside the Renogy unit itself as seen in Figure 5.  Using some "Shoe Goo", a strong rubber adhesive (do not use "hot melt" glue!) the encapsulated board of Figure 4 was mounted in the upper-right corner of the "output" side of the unit, set back by about 3/8" of an inch (10mm).  The location is such that the voltage threshold adjustment is accessible via one of the ventilation holes:  Setting it back prevents it from obstructing air flow and makes the precise alignment between the screw of the potentiometer and the hole less critical.

The "V+" and "V-" wires from the circuit are soldered directly to the bottom of the board on the DC input terminals and the "out" terminal of the circuit (the blue wire in Figure 5) is routed through another hole near the green "D+" and "LC" terminals.

Figure 6 shows how these wires are routed.  In addition to the connection to the "D+" terminal from the circuit, another wire and a switch was added that optionally connects the "LC" terminal to the "D+" to set the Renogy to the "Low Current" mode by pulling it high when the switch is closed - in this case, limiting the maximum charge current to 10 amps, which may be useful if you are connecting the unit to a current-limited power source (e.g. "cigarette lighter" plug) that cannot supply the 25-ish amps current input that the unit may draw when charging at 20 amps output.

Figure 6:
Looking on the "output" side of the Renogy, this shows how
the "out" wire from the circuit routes out of one of the air
to the "D+" terminal.  Also shown is a switch that optionally
connects the "D+" to "LC" terminal for just 10 amp max.
Click on the image for a larger version.

This "modification" - since it does not involve drilling any holes - is "reversible" if desired as the circuit and wiring could be easily removed.

In-vehicle testing and use

High/low voltage turn-on/turn-off

Prior to testing the modified unit in my vehicle I set the "cut-in" voltage to about 13.65 volts which resulted in a disconnect voltage of around 12.7 volts - a voltage below which a 12 volt lead-acid battery will quickly drop when charging is stopped.  As expected, the unit did not get turned on until a few seconds after the engine was started, the voltage rising due to charging by the alternator:  If the battery had been heavily discharged and a lot of accessories were running (headlights, blower, wipers) it may take longer than this for the voltage to rise above the threshold.

The voltage dropped below the 12.7 volt shut-off threshold within a few 10s of seconds of turning off the engine with the entire unit drawing only about 0.5mA (all of that being from the added circuit) in that state - far lower than the vehicle's own quiescent current, and probably lower than the vehicle battery's self-discharge rate.  So far, I have found no tendency for the unit to cycle on and off while the engine is running - even if the headlights, heater blower and windshield wipers are on.

Of course, the voltage thresholds mentioned above are only valid for a healthy (and properly functioning) conventional charging with lead-acid batteries as part of the chassis electrical system:  If your vehicle somehow has a different type of electrical system than the conventional "alternator + lead acid" configuration it'll be up to you to determine how and even if a solely voltage-referenced on/off system like this can be done.

RF Noise generation

Being an amateur radio operator, I was concerned that this unit might produce an excess of radio frequency interference as it contains a high-power oscillator in its power converter.  While visual inspection of the Renogy (with its end covers removed) showed that it does have some filtering of its own in the form of series inductors and capacitors across the input/out leads and to the metal case (to suppress common-mode and differential RF energy) it would be unusual for even a well-designed commercial device to go to extremes in reducing radio frequency energy to the point of extinction. 

Using a "Tiny SA" Spectrum analyzer I connected directly to the input and output leads - using a 0.002uF capacitor to block DC and protect the analyzer - I measured the amount of RF energy being differentially emitted from the unit.  This measurement is important in that if the instantaneous RF voltage on the output leads is different than on the input leads, the in/out cables will necessarily conduct RF energy to the outside world, into whatever is connected at both ends, including the wiring itself, which may radiate like a dipole antenna and/or conduct radio-frequency current through the unit and into other wiring and/or equipment.  A plot from the spectrum analyzer showing the produced RF energy up to 10 MHz is shown below:

Figure 7:
The spectrum of RF energy as measured directly between the voltage in and out terminals across the range of 0-10 MHz with no filtering.  If a receiver's input terminals were connected directly to the DC terminals, the signal level at 40 meters (7 MHz) would be bit more than "10 over S-9.

Without any added filtering, I tested it in my vehicle - powering the 100 watt HF transceiver directly from the Renogy (with no battery) - something that I probably would not ever do in normal use:  If the converter does have the tendency to produce RF interference, connecting the radio directly to it and putting conducted RF energy on its power leads - and its chassis - would represent a "worst-case" scenario.  On 40 meters (7 MHz) and 12 meters (24 MHz) I could just hear the switching frequency's harmonics near the noise floor which indicated that it was pretty quiet - but not completely so.

Since the spectral switching components were just audible I decided to add a modicum of filtering on both the DC input and output leads - four bifilar turns of #12 AWG (e.g. the input/output power cables) each on their respective T140-43 ferrite cores as seen in Figure 9.  In most situations I would prefer to include bypass capacitors in the mix (see figure 4 in the article "Reducing QRM (interference) from a Renogy 200 watt (or any other!) portable solar panel system" - link) to (significantly!) improve performance, but I decided that even a modest reduction in conducted emissions would likely reduce them to the point of inaudibility.

A spectrum analyzer plot of the noise generated by the unit with the added filtering using just the bifilar-wound T140-43 cores is below:

Figure 8:
The spectrum of RF energy as measured between the in/out terminals with the bifilar inductors between the measurement point and the converter - also over the range of 0-10 MHz.  If a receiver's input terminals were connected directly to the DC terminals the signal level at 40 meters (7 MHz) would be a bit less than "S-9" - for a reduction of about 15dB, or nearly  3 "S" units.

As can be seen Figure 8, the bifilar chokes alone reduced conducted RF by a significant amount above a few MHz, but from as noted in the linked article mentioned above, the addition of the capacitors would have improved the attenuation of the conducted RF energy by another 20 dB or so, but including capacitors is a bit awkward as it involves baring wires and adding additional jumpers.  One issue related to lacking capacitors is the response peak around 2 MHz - likely due to a broad resonance of the bifilar inductors themselves - but this effect diminishes quickly as frequency increases on amateur bands likely to be used in a vehicle.  While not shown in any of the included plots, between 10 and 30 MHz the attenuation afforded by the bifilar chokes, alone, remains at 20dB or better for much of that range.

Note:  At HF, a simple "snap on" choke with a single wire running through its center will not offer enough impedance to provide good attenuation - particularly below 20 MHz.  As the choking inductance is proportional to the square of the number of turns through the ferrite device (e.g. 16-fold with four turns) it is only by being able to put multiple turns through it that we can effectively attenuate frequencies in the HF spectrum.

Figure 9:
The Renogy charger with 5-turn bifilar-wound 12 AWG
chokes wound on the DC input and output leads.  For best
results, always place the inductors as close to the noise-
generating device as practical.  Not visible is a fuse on the
input lead to provide protection to the device and wiring.
Click on the image for a larger version.

If interference from this device were to persist after adding the bifilar inductors, I will go through the trouble of adding the aforementioned capacitors.

Can it be scaled up?

The Renogy RNG-DCC1212-20 is "only" a 20 amp converter/charger, but higher current devices are made by Renogy and others.  While I don't own a higher-current Renogy device, those units seem to operate in exactly the same way:  The "D+" terminal may be used to power it on/off and the "LC" terminal, when pulled high, sets the output current to half of the unit's rating.

If RF interference is considered to be an issue, the higher-current units would require proportionally larger wires and likely larger ferrite cores (say, FT240-43) to accommodate a reasonable number of turns of that larger wire.

I cannot speak to how other brands or dissimilar models from Renogy might be powered down via their equivalent of the "D+" terminal to minimize quiescent current consumption:  That must be left as an exercise by the reader.

Conclusion

This unit - and the modification - have worked as expected:  The unit gets turned on and off with the running of the engine automatically with no connection required other than that of power.  When traveling, 20 amps is enough to provide a reasonably fast charging rate to a modest bank (say, 200aH) of LiFePO4 batteries while even the "Low Current" 10 amp limit is more than enough to keep the batteries topped off with a moderate load such as a refrigerator-type cooler or a 100 watt HF amateur transceiver occasionally used for transmitting.

With the added filtering using the ferrite cores on which multiple turns are wound, no interference from the Renogy is audible on the HF transceiver in the vehicle.

 * * * * *

The TL;DR part

Why you need to treat LiFePO4 batteries differently

In the "old days" of lead-acid batteries, you could probably get away with putting it in parallel with the vehicle's electrical system - possibly with the use of an "isolator" (e.g. diode, FET pack, a relay or contactor that connected it in parallel with the starting battery when the engine is running) to prevent the drain on the auxiliary battery from depleting the vehicle's starting battery when the engine was off - but this CANNOT and SHOULD NOT be done with LiFePO4 batteries.

A LiFePO4 battery will attempt to pull "infinity" current when charging

The reason for this has to do with a fundamental difference between the two chemistries.  A healthy lead-acid battery is somewhat self-limiting in the amount of charging current it will take - at least when it's nearly fully-charged:  The charge current will gradually taper off as it asymptotically approaches full-charge.  Additionally, on a typical lead-acid battery the internal resistance of the battery and evolution of gasses at the plates often leads to intrinsic current limiting.

A healthy LiFePO4 battery is closer to that of an "ideal" battery in that unlike a lead-acid battery, where the current will gradually taper off as it approaches "full-charge" voltage (which isn't well defined in that chemistry), a LiFePO4 battery will attempt to consume as much current as it can until it is fully charged.  Practically-speaking, the current is actually limited by internal resistance of the battery - which can be in the milli-Ohm range - and the resistance of the wiring between the voltage source (the alternator) and the battery - and since heavy-gauge wire is typically used, this current can be very high.

In the case of a large (100aH or bigger) LiFePO4 battery, it's likely capable of consuming as much current as the alternator will put out - and this could easily exceed its actual ratings.  Short-term overcurrent conditions on an alternator - such as those that might occur immediately after starting the engine, particularly if accessories (lights, wipers, heater) is on - are tolerated, but they cannot withstand a continuous overload - such as that which might occur with a discharged LiFePO4 battery - without overheating - particularly in hot weather and/or if the vehicle is moving down the road quickly and providing air movement.

Another potential issue with a LiFePO4 battery has to do with its BMS (Battery Management System).  If the charge current exceeds the rating of the BMS, it will disconnect to prevent overcurrent that could damage the cells by charging them too vigorously.  At best, this would cause the BMS to disconnect/reconnect the battery (called "load dump", which is a problem as noted below) and at worst it could cause overheating and damage to the BMS.

The dangers of alternator "load dump"

Another issue with LiFePO4 batteries that does not exist with Lead Acid is that they can abruptly "dump" their load.  While a lead-acid battery's charge current will gradually taper off, if a LiFePO4 battery attains full charge, its BMS (Battery Management System) will abruptly disconnect the battery once any of its individual cells get to full voltage - something that can happen if the cells are all fully-charged and the current is minimal (the preferred situation) or if high current is still flowing, perhaps due to too-high charging voltage - a much worse case.  The result of an abrupt drop of a large current flow is that the voltage from the alternator will briefly skyrocket, its voltage regulator unable to compensate quickly enough.

While this can happen in a vehicle using a lead-acid battery when a load is suddenly removed (e.g. fan cycling, headlights being turned off) a healthy lead-acid battery is quite good at suppressing such voltage spikes and protecting the attached electronics - but voltage transients high enough in voltage to cause damage can still occur, perhaps cumulatively, particularly if the lead acid battery's condition is poor:  If there is no lead acid battery at all to buffer such transients (e.g. only a LiFePO4 battery) such a voltage spike can damage other devices connected to that power source as described in the example below.

Lead Acid and LiFePO4 batteries don't use the same voltages

A third issue is that the full-charge voltage of a typical "12 volt" LiFePO4 battery is 14.6 volts, precisely, whereas a lead-acid battery is quite forgiving, allowing anything between 13.5 and "14.something" volts as a full charge.  The implication of this is that a vehicle's electrical system is not precise enough to either avoid under-charging (e.g. too low voltage, preventing full charge) or over-charging (e.g. causing the BMS to connect/disconnect/reconnect).

Maintaining a precise voltage near the maximum voltage of a "12 volt" LiFePO4 battery (14.4-14.6 volts) for extended periods (a few hours) - at least occasionally - is also necessary for the BMS (Battery Management System) equalize the individual cells within the battery.  Failure to do this every so often will allow individual cells to drift apart in their charge states as inevitably, one or more cells will discharge more quickly - and if never fully recharged, those cells will seem "weaker" and the battery will appear to lose capacity.

"Equalization" as done by the BMS of a LiFePO4 battery is typically done by "leaking" current across fully-charged cells to top off those that are not - but this will only happen effectively at/near the battery's maximum voltage.  Depending on the degree of this "inequality", it may take hours of holding the battery at this high voltage to fully equalize the battery's cells.

Note that the equalization mechanism for LiFePO4 cells is NOT compatible with that which might be done for Lead-Acid - see the battery's manual or other references for the technical details.

Real-world case

I've seen the above issues play out on a friend's RV:  The original "chassis" battery to run the engine and charge the engine starting battery was augmented by a second and completely separate "coach" alternator which was dedicated to charging the LiFePO4 battery bank and running the devices in the living quarters (lights, TV, pumps, microwave oven, inverter, etc.)

Built by Thor onto a Mercedes chassis,  several alternators were destroyed (one of them lasting only minutes!) by overheating due to the the lack of current-limiting in the battery-charging regimen:  One of them lasted longer than the rest only due to several of the rectifier diodes going open-circuit almost immediately, crippling the ability of the alternator to produce output, limiting current - but putting very high ripple voltage/current onto the coach battery's electrical system.  Additionally, equipment connected to that circuit (a $1200 amateur radio transceiver) was destroyed by the high-voltage spike when a "load dump" occurred at the instant that the LiFePO4 battery disconnected  upon full charge do to the intrinsic inability of the alternator's voltage regulator to act quickly enough.  

It is fortunate that this vehicle had two separate alternators, so the integrity of the "chassis" electrical system responsible for powering the vehicle itself was spared any problems - and no damage to its components (engine and transmission computers, etc.) was possible.  Without a functioning "coach" alternator to recharge the LiFePO4 battery he was still able to make his trip, but had to stop every couple of days and camp somewhere where he could plug into a mains outlet and use the onboard charger to top it off.

Ultimately this friend ended up taking his rig to a company that specialized in RV power systems and the system was upgraded and reconfigured - at significant expense - to avoid the issues noted above.  A quick perusal of online RV forums will reveal many similar stories - some a result of the manufacturers apparently being unfamiliar with the requirements of LiFePO4 batteries and others from individual owners' botched retrofits.

* * * * *

This page stolen from ka7oei.blogspot.com

[END]