Hold-Up Capacitance Health Measurement With Current Leakage Detection
20220122631 · 2022-04-21
Inventors
- Richard S. Lucky (Louisville, CO, US)
- Brian Hadley Robinson (San Pedro, CA, US)
- Andrew David Prosory (Queen Creek, AZ, US)
Cpc classification
G06F11/073
PHYSICS
G01R31/52
PHYSICS
International classification
Abstract
Circuits for measuring a leakage current of one or more capacitors coupled to a power supply line that powers an apparatus, such as a storage device, are disclosed. In one embodiment, the circuit includes first and second resistors between the power supply line, and first and second respective switches to ground. A controller may charge the voltage line to a first voltage. Thereafter, the controller discharges the first voltage to a second voltage via the first resistor during a first identified time. After recharging the voltage line, the controller then discharge the first voltage to the second voltage via at least the second resistor during a second identified time. The controller determines the parasitic resistance using the first and second identified times, and then the leakage current from the parasitic resistance. Removing the leakage current factor from subsequent measurements can greatly improve testing accuracy and can avoid false positives in the testing process that would otherwise require removal of drives or other systems that are working properly.
Claims
1. A circuit, comprising: a capacitor between a voltage line and ground and having a parasitic resistance; first and second resistors between the voltage line and first and second respective switches to the ground; and a controller configured to charge the voltage line to a first voltage, to discharge the first voltage to a second voltage via the first resistor during a first identified time, to discharge the first voltage to the second voltage via at least the second resistor during a second identified time, and to determine the parasitic resistance using the first and second identified times.
2. The circuit of claim 1, wherein the controller is further configured to determine a leakage current through the capacitor based on the parasitic resistance.
3. The circuit of claim 2, wherein the controller is further configured to determine whether the capacitor maintains a specified energy for at least a power-off discharge time determined based on the leakage current.
4. The circuit of claim 3, wherein the controller is further configured to provide a pass indication when the capacitor maintains the specified energy for at least the power-off discharge time, and a fail indication otherwise.
5. The circuit of claim 1, wherein the controller is further configured to: perform the discharge via the first resistor when the first switch is closed and the second switch is open; and perform the discharge via the second resistor when the first switch is open the second switch is closed.
6. The circuit of claim 1, wherein the controller comprises a voltage source configured to charge the voltage line to the first voltage to enable the discharge via the first resistor and to recharge the voltage line to the first voltage to enable the discharge via the second resistor.
7. The circuit of claim 6, wherein the voltage source is coupled to the voltage line via a third switch; and the controller is configured to charge the voltage line to the first voltage when the third switch is closed and the first and second switches are open.
8. The circuit of claim 1, wherein the at least the second resistor comprises a parallel combination of the first and second resistors.
9. A circuit, comprising: a capacitor between a voltage line and ground and having a parasitic resistance; a first resistor between the voltage line and a first switch to the ground; a second resistor between the first switch and a second switch to the ground; and a controller coupled to the voltage line and configured to charge the voltage line to a first voltage, discharge the first voltage to a second voltage via the first resistor during a first identified time, discharge the first voltage to the second voltage via the first and second resistors during a second identified time, and determine the parasitic resistance using the first and second identified times.
10. The circuit of claim 9, wherein the controller is further configured to determine a leakage current through the capacitor based on the parasitic resistance.
11. The circuit of claim 9, wherein the controller is further configured to: perform the discharge via the first resistor when the first switch is closed and the second switch is open; and perform the discharge via the first and second resistors when the first switch is open the second switch is closed.
12. The circuit of claim 9, wherein the controller comprises a voltage source configured to (1) charge the voltage line to the first voltage to enable the discharge via the first resistor and to (2) recharge the voltage line to the first voltage to enable the discharge via the first and second resistors.
13. The circuit of claim 12, wherein the voltage source is coupled to the voltage line via a third switch; and the controller is configured to charge the voltage line to the first voltage when the third switch is closed and the first and second switches are open.
14. The circuit of claim 9, wherein the capacitor comprises a bank of two or more capacitors organized between the voltage line and ground in one or both of in series and in parallel, a net parasitic resistance of the bank comprising the parasitic resistance.
15. The circuit of claim 9, wherein the resistors comprises one or more transistors in silicon or as discrete elements.
16. A circuit, comprising: a capacitor between a voltage line and ground and having a parasitic current sink (pi.sub.s); first and second current sinks (i.sub.s) between the voltage line and first and second respective switches to the ground; and a controller configured to charge the voltage line to a first voltage, to discharge the first voltage to a second voltage via the first is during a first identified time, to discharge the first voltage to the second voltage via at least the second i.sub.s during a second identified time, and to determine a current through pi.sub.s the using the first and second identified times.
17. The circuit of claim 16, wherein the controller is coupled to the voltage line via a third switch.
18. The circuit of claim 17, wherein the controller is further configured to: charge and recharge the voltage line to the first voltage when the third switch is closed and the first and second switches are open; discharge the voltage line via the first i.sub.s when the second and third switches are open and the first switch is closed; and discharge the voltage line via at least the second i.sub.s when at least the third switch is open and one or both of the second switch, or the first and second switches, are closed.
19. The circuit of claim 16, wherein the switches comprise field effect transistors (FETs).
20. The circuit of claim 16, wherein the controller is further configured to determine whether a specified amount of energy is retained on the voltage line for at least a discharge time determined using the determined current through pi.sub.s.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
[0010] Various aspects of the present invention will now be presented in the detailed description by way of example, and not by way of limitation, with reference to the accompanying drawings, wherein:
[0011]
[0012]
[0013]
[0014]
[0015]
[0016]
[0017]
[0018]
[0019]
[0020]
[0021]
[0022]
[0023]
DETAILED DESCRIPTION
[0024] The detailed description set forth below in connection with the appended drawings is intended as a description of various exemplary embodiments of the present invention and is not intended to represent the only embodiments in which the present invention may be practiced. The detailed description includes specific details for the purpose of providing a thorough understanding of the present invention. However, it will be apparent to those skilled in the art that the present invention may be practiced without these specific details. In some instances, well-known structures and components are shown in block diagram form in order to avoid obscuring the concepts of the present invention. Acronyms and other descriptive terminology may be used merely for convenience and clarity and are not intended to limit the scope of the invention.
[0025] The words “exemplary” and “example” are used herein to mean serving as an example, instance, or illustration. Any exemplary embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other exemplary embodiments. Likewise, the term “exemplary embodiment” of an apparatus, method or article of manufacture does not require that all exemplary embodiments of the invention include the described components, structure, features, functionality, processes, advantages, benefits, or modes of operation.
[0026] The principles of this disclosure may be implemented by different types of controllers that may be coupled to the test circuits described herein. These controllers and their components may be implemented using electronic hardware, computer software, or any combination thereof.
[0027] By way of example, an element, component, or any combination thereof of a controller may be implemented using one or more processors. Examples of processors include microprocessors, microcontrollers, graphics processing units (GPUs), central processing units (CPUs), application processors, digital signal processors (DSPs), reduced instruction set computing (RISC) processors, systems on a chip (SoC), baseband processors, field programmable gate arrays (FPGAs), programmable logic devices (PLDs), state machines, gated logic, discrete hardware circuits, and other suitable hardware configured to perform the various functionality described throughout this disclosure. The one or more processors may be part of a workstation or a server computer configured to perform the routines described herein. The one or more processors may execute software and firmware. Software and firmware shall be construed broadly to mean instructions, instruction sets, code, code segments, program code, programs, subprograms, software components, applications, software applications, software packages, routines, subroutines, objects, executables, threads of execution, procedures, functions, etc., whether referred to as software, firmware, middleware, object code source code, or otherwise.
[0028] Accordingly, in one or more example embodiments, the functions described may be implemented in hardware, software, or any combination thereof. If implemented in software, the functions may be stored on or encoded as one or more instructions or code on a computer-readable medium.
[0029] The present disclosure is directed to capacitor-based circuits that are used to protect data in devices when power fails. For the purpose of this disclosure, the term capacitor shall include within its scope one or more capacitors unless otherwise stated. Thus, for example, a capacitor as referred to herein, and often (but not necessarily) denoted as “C” may describe any number including a single capacitor, a few capacitors, a capacitor bank, etc. Where a capacitor is positioned between two nodes under this definition, the net capacitance is understood as routinely used and known by practitioners in the art, e.g. as it may be computed in parallel or series by those skilled in the art without the need herein for a further configuration information of the capacitor that may include plural elements between two nodes. In one set of embodiments, the capacitor may be positioned between a power supply node (e.g., 5 volts, 28 volts, etc., depending on the nature of the circuit and power needs) and a ground. In other embodiments, however, the power supply may be connected to a voltage node other than a supply or ground node. For the purpose of this disclosure, a circuit or plurality thereof is also coupled to the power supply (directly or indirectly), e.g., for performing data transactions. While the circuit at issue need not be a particular type of circuit, in one embodiment an enterprise solid state power supply is used. The capacitance value of the capacitor (or bank thereof) is selected based on the needs of the circuits that are attached as well as the value of the supply voltage.
[0030] The circuit may be in the process of exchanging data, for example. After the time the circuit has begun the data exchange but prior to completion of the change, the supply node may experience a sudden power glitch or an outright power failure. In these circumstances, it is desirable to complete each of the data transactions that were initiated prior to loss of power at the circuit. For example, in one embodiment, the circuit may be one or more enterprise-class solid-state storage drives for backing up data. During the course of normal operation, one of the drives may receive write requests from a host device. After acknowledging the requests, but prior to completing the actual data writes, it is assumed that a sudden power loss is experienced such that the supply node is no longer provided power. It is for this reason that the capacitor is coupled between supply and ground. The capacitor is configured to slow down the discharge of energy at the supply node so that, prior to the time the node loses a threshold power amount that would render the drive inoperable, the drive has enough time to complete the outstanding writes. After that time, when the writes are complete and the integrity of the data is preserved, the device may power down until power is once again restored.
[0031] In this example, if the capacitor were not present or the value of its capacitance (or net capacitance for more than one capacitor) was insufficient, the data would be lost. Thus if the capacitor's performance degraded over time, eventually it would no longer be effective at maintaining the energy of the supply node at a sufficient magnitude to enable the writes to complete.
[0032] For this reason, a periodic “health” test of the capacitor may be performed over time to ensure that the capacitor is functioning properly. In the example of the storage drive, provided the capacitor passes the periodic heath tests, the drive will continue to be able to ensure proper writes even in the event of a power outage. By contrast, a failed test would likely mean that the drive can no longer guarantee completion of writes in the event of power failure. At best, the data on the drive could be “read only”.
[0033] The premise of this type of health test is that, by partially discharging the capacitor (bank) through a known resistance, the time can be measured to reach a set voltage. Thereupon, the supply node can be recharged and the capacitor can be partially charged again, but this time under a different load for reasons that will become apparent below. Accordingly, in one embodiment a firmware routine can start a health test by initiating the discharge and monitoring the time taken by the capacitor to decay to a specified voltage. This time can generally be set to be greater than some specified threshold. Otherwise, in the case of the storage devices, host writes are terminated and an error is reported. Generally, this discharge technique should ensure through relevant calculations the capacitor is capable of maintaining some necessary energy threshold for a specified time to ensure data integrity in an energy outage event.
[0034] One potential problem with this technique is that capacitor leakage current varies with temperature, component age, population of components, and capacitor type. Particularly at the wrong edges of the process corners, the parasitic resistance of each capacitor can draw enough current to alter the discharge test results by significantly increasing the discharge rate. The time to discharge is thereby reduced, and the hold-up energy available in this event can be substantially underestimated. This underestimation can result in erroneous test failures, or false positives, meaning in some cases that the drive is deemed outright inoperable or defective, and potentially removed from service. Each of these outcomes are, to say the least, suboptimal.
[0035] The leakage current discussed above is ordinarily not a problem during a discharge test because, more often than not, its magnitude is similar to that of the current draining through the set load resistance of the circuit in normal operation. That is to say, leakage current is often not a problem during an input power failure because the magnitude of the leakage current is proportionately very small in comparison to the large drive energy needed to hold-up the node properly, and hence the large magnitude of the current that would be needed to prematurely discharge the node. However, the nature of the discharge test in many circumstances is that it uses a minimum energy draw. This is because using a minimum energy draw means that the circuit (e.g., the drive) served by the capacitor bank can continue to be available and operating even during health-testing. However, because the inventors have determined that the capacitor leakage current can be a large percentage compared to the measured drain through the set load resistors during normal operation, but only a small percentage of the total current drawn at the onset of an actual power outage, the test as currently configured by many manufacturers may not produce an accurate result.
[0036] Accordingly, in one aspect of the disclosure, techniques are disclosed to increase the accuracy of the hold-up measurements by detecting and accounting for the leakage resistance of the capacitor. Instead of performing a single discharge and taking measurements, for example, the technique described herein combines results from multiple capacitor discharge tests to remove the common leakage current component through the net parasitic resistance of the capacitor bank. In various embodiments, each discharge test is run with different drain resistors. These multiple measurements can be combined mathematically as shown herein to nullify the effect of the capacitor leakage otherwise present in each individual test.
[0037]
[0038]
[0039] Controller 114 and/or module 112 may be an external controller that can be used on the fly, in which case it may be removable (e.g., a “hotswap” controller or the like). In other embodiments controller 114 and/or module 112 may be an integrated part of the circuit structure. In addition, controller 114 may be part of the flash controller. In other embodiments, portions of the functionality of the controller 114 may be incorporated into the device (e.g., as part of one of the circuit boards) and other portions may be attachable and/or removable. In still other embodiments, controller 114 may be an external controller coupled to some external device that is connected to the FETs. Controller 114 may also include one or more processors and memory for performing calculations and making time and other measurements relevant to the hold-up tests. Module 112 and/or controller 114 may also have networking capabilities and may be controllable from another location. Controller 114 may also be able to make pass and fail determinations as necessary.
[0040] Controller 114 may also be configured to charge and discharge the capacitor C.sub.holdup. Thus, by way of example, when FET.sub.1 and FET.sub.2 are turned off and on, respectively, to discharge the capacitive load through R1, the total load resistance of the circuit is Ra=R1∥RL (where the “a” signifies test run a). Similarly, after the capacitor is re-charged, and when FET.sub.1 and FET.sub.2 are turned on and off, respectively, to discharge the capacitive load through R.sub.2, the total load resistance of the circuit is Rb=R.sub.2∥R.sub.L.
[0041] Generally for a capacitor discharge from voltages V1 to V2, the discharge time can be calculated for both cases with the well-known formula:
T1=(Ra)(C)ln(V1/V2) and
T2=(Rb)(C)ln(V1/V2).
[0042] Solving for (C)ln(V1/V2)=T1/Ra=T2/Rb since the quantity (C)ln(V2/V2) can be maintained constant.
[0043] Solving for the leakage resistance yields:
R.sub.L=(T1−T2)/((T2/R2)−((R1−R2)/R1))
[0044] Thus, in one embodiment, the calculated leakage resistance (R.sub.L) may then be used to alter the discharge time threshold that corresponds to a capacitance range. It is also noted that the leakage current calculation is straightforward once R.sub.L is known.
[0045] The general description above can be extended to a variety of ways to use the identified formula to compute the parasitic resistance of the capacitor bank, as well as the leakage current, after which the discharge time threshold for a given capacitance range can be set in a manner such that capacitor banks that can maintain the desired energy at the supply node for the necessary time no longer are determined to result in ‘false positives’.
[0046]
[0047] The resistors throughout this disclosure are generally referenced using their symbolic values. One general desire for the resistors is that they match fairly well. Resistors for the purpose of this disclosure can otherwise be discrete components, resistances implemented (e.g., using metals or transistors) in silicon, and virtually any type of device that can function as a resistors that have sufficiently matching properties may be used in connection with this disclosure. In addition, the capacitors used for holdup may be discrete devices. If implemented in a smaller scale in silicon, the capacitors may be appropriately configured transistors, for example.
[0048] Referring now to
[0049]
[0050] As discussed below, S1 also remains open during discharging periods. Referring back to
[0051]
[0052]
[0053] The next desired operation of the circuit 500 is to recharge V_Node to the value V1 (i.e., the same value used in the previous steps), and then discharge V1 through another resistive path to determine a second discharge time, T2. To accomplish this, reference is made once again to
[0054]
[0055] At this point, the controller has the discharge times, T1 and T2, the resistance values corresponding to the discharges R1 and R2, and the voltage values V1 and V2 which it determined at the beginning. The controller can now perform the necessary calculations to identify the parasitic resistance RL and the leakage current. In addition, the controller can independently validate the discharge times to ensure that the calculation match with the measured values.
[0056] The controller first can now verify its measurement of the discharge time by calculating the discharge time (T.sub.1) of a capacitor (C) into a load (R.sub.1), from voltage V.sub.1 to V.sub.2 with the following equation (i):
[0057] The controller can thereafter make the same calculation using the other resistor R2 and identical voltage range and capacitance to confirm the second discharge time T2, using the following equation (ii):
[0058] Since the product of the capacitance and the natural log of the voltage ration are identical in both equations, the first equation can be divided by the second equation to arrive the ratio of the discharge times and load resistances, or at equation (iii):
[0059] Because the capacitors have leakage, the loads have an equivalent resistor (R.sub.L) in parallel with them. R.sub.1 is actually
And R.sub.2 is actually
Thus we get
[0060]
[0061] With some arithmetic manipulation we end up with—eqn (iv):
RL=(R2*((T1/T2)−1))/(1−((T1*R2)/(T2*R1))) (iv)
[0062] The discharge times T1 and T2 from the simulation can be applied to equation (iv) to arrive at the parasitic or leakage resistance due to capacitors C. Accordingly, with test times of two known resistive loads the parasitic resistance of the capacitors C can be determined. It is a straightforward manner to use ohm's law to determine the leakage current i.sub.L through the parasitic resistance. Once the leakage current is known, it can be taken into account to determine whether the energy threshold at V_Node is sufficient to preserve the integrity of the data in a power outage event.
[0063] As an example, the following values are possible.
[0064] C=500 uF
[0065] R.sub.1=8.869K (9.1K (2 each 18.2KΩ in parallel) in parallel with 350KΩ in the feedback network)
[0066] R.sub.2=4.435K (4.55K (4 each 18.2KΩ in parallel) in parallel with 350K)
[0067] R.sub.L=27.3K (gives an average of 1 mA over the 95% discharge range of 28V to 26.6V)
[0068] Based on the above values, a simulation can then be run as described in this disclosure to identify T1 and T1. Having obtained T1 and T2, we can use equation (iv) to compute the leakage resistance. As such, with test times of two known resistive loads determined based on simulation, the leakage resistance can be determined. The ohm's law can provide the leakage current i.sub.L.
[0069]
[0070] Following the discharge time measurements T1 and T2 taken by the controller with reference to the embodiment of
as the second resistance value.
[0071]
[0072]
[0073] The controller, as before, can also calculate the discharge time (T.sub.1) of capacitor (C) into a load (R.sub.a), from voltage V.sub.1 to V.sub.2 with the following equation:
[0074] Next, the controller can make the same calculation using a different load (R.sub.b) over the same range to obtain:
[0075] The controller can take the ratio to arrive at:
[0076] As in the previous embodiment, The capacitors have leakage, and consequently the loads have an equivalent resistor (R.sub.L) in parallel with them.
[0077] R.sub.a is actually
[0078] R.sub.b is actually
[0079] In this case Ra is R.sub.1+R.sub.2 and Rb is R.sub.1. Thus the ratio of discharge times is:
[0080] Again, with arithmetic manipulation, the following expression can be obtained:
RL=ΔT*(R.sub.1.sup.2*R.sub.2+R.sub.1*R.sub.2.sup.2)/(T.sub.2*R.sub.2.sup.2−ΔT*R.sub.1*R.sub.2), [0081] where ΔT=T.sub.1−T.sub.2
[0082] If R.sub.1=R.sub.2=R then this equation simplifies to
RL=(ΔT*2*R)/(T.sub.2−ΔT)
[0083] In summary, with test times of two known resistive loads identified through simulation, the leakage resistance can be determined, and a straightforward application of ohm's law allows the controller to obtain the leakage current.
[0084] In another embodiment, it is possible to perform the hold-up test using only one external load. For example, the leakage of the capacitor can be isolated as the first load and the external load can be used as the second load. The mathematics become simpler, but, since the natural leakage of the capacitor is low, or stated differently, the equivalent resistance is very high, test duration will be comparatively long. Since the increased test time with the natural leakage raises a greater likelihood of a power failure occurring during that time (and the capacitor having less than full charge), this configuration is best used for systems that have a limited number of tests or for circuit configurations with potentially less urgent consequences.
[0085] An example of this embodiment is shown in
[0086]
[0087] The controller 112 can calculate the discharge time (T1) of a capacitor (C) into a load (R.sub.a), from voltage V.sub.1 to V.sub.2 with the following equation:
[0088] If the controller 112 makes the same measurement using a different load (R.sub.b) over the same range, the result is
[0089] If the controller takes the ratio, then the result is
[0090] Because the capacitors have leakage, the load has an equivalent resistor (R.sub.L) in parallel with it. If we let the leakage be the first load then Ra is only RL as illustrated in
[0091] In this case Ra is R.sub.L and Rb is just R. Thus the equation reduces to the following:
[0092] The controller can thereupon use the measured values to determine the leakage or parasitic resistance.
[0093] In another aspect of the disclosure, in lieu of resistors as loads, the test can implement current loads or sinks. An example of this configuration is shown in
[0094] Referring now to
[0095] In summary for the constant current loads, Voltage source Vin charges capacitor C to voltage V.sub.1 when switch S1 is closed and switches S2 and S3 are open. The normal capacitor leakage is represented by current sink I.sub.L. The capacitor C is discharged to V.sub.2 with I.sub.1 by opening S1 and closing S2. The discharge time from V.sub.1 to V.sub.2 (ΔV) is saved as T.sub.1 (ΔT.sub.1). The capacitor is recharged to V.sub.1 by opening S2 and closing S1. The capacitor is discharged to V.sub.2 with I.sub.2 by opening S1 and closing S3. The discharge time from V.sub.1 to V.sub.2 (ΔV) is saved as T.sub.2 (ΔT.sub.2). It should also be noted that. as before, a second load may be to configure both switches (S1 and S2) to close simultaneously.
[0096] The current (I) through a capacitor (C) with a voltage changing at a rate of ΔV/ΔT is given below.
I.sub.1=C*(ΔV/ΔT.sub.1)
[0097] If the measurement is made with a second load over the same voltage range, the result is:
I.sub.2=C*(ΔV/ΔT.sub.2)
[0098] If the ratio of the measurements are taken, the deltas can be eliminated as follows:
[0099] Because the capacitor has leakage, the loads have an equivalent load (IL) in parallel with them. For example, I.sub.1 is actually
I1+IL [0100] and I.sub.2 is actually
I2+IL
[0101] Thus with this change: (I.sub.1+I.sub.L)/(I.sub.2+I.sub.L)=T.sub.2/T.sub.1
[0102] As usual, with some arithmetic manipulation, the result becomes
(I2*T2−I1*T1)/(T1−T2)
[0103] As an example, using the following numerical values the controller can make the following calculations and then use the obtained test times to calculate the unknown leakage current.
[0104] For C=1000 uF [0105] I.sub.1=50 mA [0106] I.sub.2=100 mA [0107] I.sub.L=5 mA
[0108] In short, with test times from two known constant current loads we can determine the unknown leakage current. Discharging from 28V to 26.6V: [0109] The simulation shows: [0110] T.sub.1=25.45 mS [0111] T.sub.2=13.33 mS [0112] If we plug those results into our equation we get [0113] I.sub.L=4.9917 mA
[0114] Since the currents are strictly additive, another combination of loads, I.sub.1+I.sub.2 for example, could be used and its value just substituted for the value for I.sub.2 above.
[0115] The various aspects of this disclosure are provided to enable one of ordinary skill in the art to practice the present invention. Various modifications to exemplary embodiments presented throughout this disclosure will be readily apparent to those skilled in the art, and the concepts disclosed herein may be extended to other magnetic storage devices. Thus, the claims are not intended to be limited to the various aspects of this disclosure, but are to be accorded the full scope consistent with the language of the claims. All structural and functional equivalents to the various components of the exemplary embodiments described throughout this disclosure that are known or later come to be known to those of ordinary skill in the art are expressly incorporated herein by reference and are intended to be encompassed by the claims. Moreover, nothing disclosed herein is intended to be dedicated to the public regardless of whether such disclosure is explicitly recited in the claims. No claim element is to be construed under the provisions of 35 U.S.C. § 112(f) in the United States, or an analogous statute or rule of law in another jurisdiction, unless the element is expressly recited using the phrase “means for” or, in the case of a method claim, the element is recited using the phrase “step for.”