CN115343529B - Electric quantity detection circuit and method and electronic equipment - Google Patents

Electric quantity detection circuit and method and electronic equipment Download PDF

Info

Publication number
CN115343529B
CN115343529B CN202211246459.0A CN202211246459A CN115343529B CN 115343529 B CN115343529 B CN 115343529B CN 202211246459 A CN202211246459 A CN 202211246459A CN 115343529 B CN115343529 B CN 115343529B
Authority
CN
China
Prior art keywords
current
resistance
pcb
resistor
voltage
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202211246459.0A
Other languages
Chinese (zh)
Other versions
CN115343529A (en
Inventor
温玉磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202211246459.0A priority Critical patent/CN115343529B/en
Publication of CN115343529A publication Critical patent/CN115343529A/en
Application granted granted Critical
Publication of CN115343529B publication Critical patent/CN115343529B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01RMEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
    • G01R22/00Arrangements for measuring time integral of electric power or current, e.g. electricity meters
    • G01R22/06Arrangements for measuring time integral of electric power or current, e.g. electricity meters by electronic methods

Abstract

The application discloses electric quantity detection circuit, method and electronic equipment, the circuit includes power, PCB and walks line resistance, consumer circuit and coulomb meter, PCB walks line resistance for at least one section wire in the PCB board, wherein: the power supply, the PCB wiring resistor and the consumption circuit are connected in series, and the electricity meter is connected with two ends of the PCB wiring resistor; the electricity meter is used for measuring a first voltage V1 and a second voltage V2 at two ends of the PCB wiring resistor, determining a first current I1 flowing through the PCB wiring resistor based on the first voltage V1, the second voltage V2 and a first resistor R1 of the PCB wiring resistor, and determining the electric quantity flowing through the PCB wiring resistor based on the first current I1. In the embodiment of the application, the electric quantity detection cost can be reduced, and the flexibility of the circuit is improved.

Description

Electric quantity detection circuit and method and electronic equipment
Technical Field
The present disclosure relates to the field of electronic circuits, and in particular, to a circuit and a method for detecting electric quantity and an electronic device.
Background
When measuring the electric quantity, a special device for measuring the electric quantity is generally needed to be purchased, and the special device is connected in the circuit to be able to measure the electric quantity condition in the circuit. However, the dedicated device is costly for product implementation and has poor circuit flexibility.
Disclosure of Invention
The embodiment of the application discloses an electric quantity detection circuit, an electric quantity detection method and electronic equipment, which can reduce electric quantity detection cost and improve circuit flexibility.
In a first aspect, the present application provides an electric quantity detection circuit, the circuit includes power, PCB routing resistance, consumption circuit and coulomb meter, PCB routing resistance is at least one section wire in the PCB board, wherein:
the power supply, the PCB wiring resistor and the consumption circuit are connected in series, and the electricity meter is connected with two ends of the PCB wiring resistor; the electricity meter is used for measuring a first voltage V1 and a second voltage V2 at two ends of the PCB wiring resistor, determining a first current I1 flowing through the PCB wiring resistor based on the first voltage V1, the second voltage V2 and a first resistor R1 of the PCB wiring resistor, and determining the electric quantity flowing through the PCB wiring resistor based on the first current I1.
In the embodiment of the application, a current detection resistor does not need to be connected in series in the circuit, but the electric quantity meter can detect the electric quantity flowing through two ends of the PCB wiring resistor by utilizing the resistance value of the PCB wire in the path. Therefore, the cost of the current detecting resistor and the layout area on the PCB can be saved, the impedance of a charging path is reduced, and the charging efficiency is improved.
In a possible implementation manner, before the electricity meter determines the first current I1 flowing through the PCB trace resistance based on the first voltage V1, the second voltage V2 and the first resistance R1 of the PCB trace resistance, the electricity meter is further configured to determine the first resistance R1. Therefore, the resistance value of the PCB routing resistor, which is accurate, of R1 can be ensured, and the accuracy of the electric quantity detection result can be ensured.
In a possible implementation, the fuel gauge determines the first resistance R1, in particular for: and determining a resistance correction coefficient R based on the current temperature t, and determining that the first resistor R1 is the product of a second resistor R2 and the resistance correction coefficient R, wherein the second resistor R2 is a theoretical resistance value prestored by the fuel gauge. Therefore, R2R can correct the error of the resistance calculation result, so that the resistance is close to the actual resistance value as much as possible, and the accuracy of the electric quantity detection result is ensured.
In one possible implementation, the fuel gauge determines a resistance correction factor r based on the current temperature t, in particular for: the fuel gauge determines a resistance correction factor r based on the current temperature t, specifically for: determining a resistance correction coefficient r under the current temperature t condition based on a first mapping relation, wherein the first mapping relation is a mapping relation between different temperatures and resistance correction coefficients, the electricity meter stores the first mapping relation, and the resistance correction coefficient r is a ratio of actual resistivity to theoretical resistivity under the different temperature conditions; or, determining a second resistivity rho of the PCB routing resistance based on the current temperature t, and determining the resistance correction coefficient r as the first resistivity rho 0 And the second resistivity p is the theoretical resistivity. Therefore, before the electric quantity detection circuit leaves a factory, the measured resistance correction coefficient r can be in one-to-one correspondence, so that even if the PCB routing resistor has resistance errors caused by temperature variation, the errors can be calibrated, and the accuracy of an electric quantity result is improved.
Wherein ρ = ρ' [1+ (t-t) 0 )d],ρ 0 May be a theoretical value determined in advance.
In a possible implementation manner, the fuel gauge determines, based on the first voltage V1, the second voltage V2, and the first resistance R1 of the PCB trace resistance, a first current I1 flowing through the PCB trace resistance, and is specifically configured to: determining a second current I2 of the PCB routing resistor as a ratio of a difference value between the first voltage V1 and the second voltage V2 to the first resistor R1; determining the first current I1 as the product of the second current I2 and a current correction coefficient k based on the current correction coefficient k, wherein the fuel gauge stores the current correction coefficient k. Therefore, the I2 xk can correct the error of the current measurement result, so that the current is as close to the actual value as possible, and the accuracy of the electric quantity detection result is ensured.
In a possible implementation manner, the current correction coefficient k is a ratio of an actual current flowing through the PCB trace resistor to a measured current of the electricity meter. Therefore, before the electric quantity detection circuit leaves the factory, the measured current correction coefficient k can be in one-to-one correspondence, so that even if errors exist in the manufacturing precision of the PCB routing resistor, the errors can be calibrated, and the accuracy of the electric quantity result is improved.
In a possible implementation, the fuel gauge determines the first resistance R1, specifically to: the method comprises the steps of obtaining a current temperature t, and determining a first resistor R1 corresponding to the current temperature t based on a second mapping relation, wherein the second mapping relation is a mapping relation between the temperature and an actual resistor. Therefore, the actual resistance can be directly determined without correcting the coefficient, the S, the L and the rho are corrected, the accuracy of the electric quantity detection result is improved, the detection method is simplified, and the execution efficiency is improved.
In one possible implementation, the PCB trace resistance material is copper metal. Therefore, the PCB wiring is generally made of metal copper, so that the material of the PCB wiring resistor is also made of metal copper, and the applicability of the PCB wiring material can be ensured.
In a second aspect, the present application provides an electric quantity detection method, which is applied to an electric quantity detection circuit, where the electric quantity detection circuit includes a power supply, a PCB trace resistor, a consumption circuit, and an electricity meter, the PCB trace resistor is at least one section of conducting wire in a PCB board, where the power supply, the PCB trace resistor, and the consumption circuit are connected in series, and the electricity meter is connected to two ends of the PCB trace resistor; the method comprises the following steps:
measuring a first voltage V1 and a second voltage V2 at two ends of the PCB wiring resistor through the electricity meter, determining a first current I1 flowing through the PCB wiring resistor based on the first voltage V1, the second voltage V2 and a first resistor R1 of the PCB wiring resistor, and determining the electric quantity flowing through the PCB wiring resistor based on the first current I1.
In the embodiment of the application, a current detection resistor does not need to be connected in series in the circuit, but the electric quantity meter can detect the electric quantity flowing through two ends of the PCB wiring resistor by utilizing the resistance value of the PCB wire in the path. Therefore, the cost of the current detecting resistor and the layout area on the PCB can be saved, the impedance of a charging path is reduced, and the charging efficiency is improved.
In one possible implementation, before the electricity meter determines the first current I1 flowing through the PCB trace resistance based on the first voltage V1, the second voltage V2, and the first resistance R1 of the PCB trace resistance, the method further includes: the first resistance R1 is determined by the fuel gauge. Therefore, the resistance value of the PCB routing resistor, which is accurate, of R1 can be ensured, and the accuracy of the electric quantity detection result can be ensured.
In a possible implementation manner, the determining, by the fuel gauge, the first resistance R1 specifically includes: determining a resistance correction coefficient R by the fuel gauge based on the current temperature t, and determining that the first resistor R1 is a product of a second resistor R2 and the resistance correction coefficient R, wherein the second resistor R2 is a theoretical resistance value prestored by the fuel gauge. Therefore, R2R can correct the error of the resistance calculation result, so that the resistance is close to the actual resistance value as much as possible, and the accuracy of the electric quantity detection result is ensured.
In a possible implementation manner, the electricity meter determines the resistance correction coefficient r based on the current temperature t, and specifically includes: determining, by the fuel gauge, a resistance correction coefficient under the current temperature t condition based on a first mapping relationr, the first mapping relation is a mapping relation between different temperatures and resistance correction coefficients, the electricity meter stores the first mapping relation, and the resistance correction coefficient r is a ratio of actual resistivity to theoretical resistivity under the different temperature conditions; or, determining a second resistivity rho of the PCB routing resistance based on the current temperature t through the electricity meter, and determining the resistance correction coefficient r as the first resistivity rho 0 And the second resistivity p is the theoretical resistivity. Therefore, before the electric quantity detection circuit leaves a factory, the measured resistance correction coefficient r can be in one-to-one correspondence, so that even if the PCB routing resistor has resistance errors caused by temperature variation, the errors can be calibrated, and the accuracy of an electric quantity result is improved.
Wherein ρ = ρ' [1+ (t-t) 0 )d],ρ 0 May be a theoretical value determined in advance.
In a possible implementation manner, the determining, by the fuel gauge, the first current I1 flowing through the PCB trace resistor based on the first voltage V1, the second voltage V2, and the first resistance R1 of the PCB trace resistor specifically includes: determining, by the ammeter, a second current I2 of the PCB trace resistance as a ratio of a difference between the first voltage V1 and the second voltage V2 to the first resistance R1; determining, by the fuel gauge, that the first current I1 is a product of the second current I2 and a current correction coefficient k based on the current correction coefficient k, the fuel gauge storing the current correction coefficient k. Therefore, the I2 xk can correct the error of the current measurement result, so that the current is as close to the actual value as possible, and the accuracy of the electric quantity detection result is ensured.
In a possible implementation manner, the current correction coefficient k is a ratio of an actual current flowing through the PCB trace resistor to a current measured by the electricity meter. Therefore, before the electric quantity detection circuit leaves the factory, the measured current correction coefficient k can be in one-to-one correspondence, so that even if errors exist in the manufacturing precision of the PCB routing resistor, the errors can be calibrated, and the accuracy of the electric quantity result is improved.
In a possible implementation manner, the determining, by the fuel gauge, the first resistance R1 specifically includes: the method comprises the steps of obtaining a current temperature t through the fuel gauge, and determining a first resistor R1 corresponding to the current temperature t based on a second mapping relation, wherein the second mapping relation is a mapping relation between the temperature and an actual resistor. Therefore, the actual resistance can be directly determined without correcting the coefficient, the S, the L and the rho are corrected, the accuracy of the electric quantity detection result is improved, the detection method is simplified, and the execution efficiency is improved.
In a possible implementation manner, after the electricity meter determines the amount of electricity flowing through the PCB trace resistance based on the first current I1, the method further includes: and displaying the electric quantity value of the power supply through a display based on the electric quantity flowing through the PCB wiring resistor. In this way, the display can display the power of the power supply in the power detection.
In one possible implementation, the PCB trace resistance material is copper metal. Therefore, the PCB wiring is generally made of metal copper, so that the material of the PCB wiring resistor is also made of metal copper, and the applicability of the PCB wiring material can be ensured.
In a third aspect, the present application provides an electronic device, where the electronic device includes the power detection circuit described in any one of the possible implementation manners of the first aspect, and a discrete device connected to the power detection circuit.
In a fourth aspect, an embodiment of the present application provides a computer storage medium, which includes computer instructions, and when the computer instructions are executed on an electronic device, the electronic device is caused to execute the power detection method in any possible implementation manner of the second aspect.
In a fifth aspect, the present application provides a computer program product, which when run on a computer, causes the computer to execute the power detection method in any possible implementation manner of the second aspect.
Drawings
Fig. 1 is a schematic circuit diagram of an electrical quantity detection circuit according to an embodiment of the present disclosure;
fig. 2 is a schematic circuit diagram of another electrical quantity detection circuit according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a section of PCB trace according to an embodiment of the present application;
FIG. 4 is a schematic diagram of a circuit structure for calibration compensation according to an embodiment of the present disclosure;
fig. 5 is a schematic flow chart of a power detection method according to an embodiment of the present disclosure;
fig. 6 is a schematic flow chart of another method for detecting electric quantity according to an embodiment of the present application;
fig. 7 is a schematic flow chart of another method for detecting electric quantity according to the embodiment of the present application.
Detailed Description
In the embodiments of the present application, the words "first", "second", and the like are used to distinguish the same items or similar items having substantially the same functions and actions. For example, the first chip and the second chip are only used for distinguishing different chips, and the sequence order thereof is not limited. Those skilled in the art will appreciate that the terms "first," "second," and the like do not denote any order or importance, but rather the terms "first," "second," and the like do not denote any order or importance.
It should be noted that in the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described herein as "exemplary" or "such as" is not necessarily to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the word "exemplary" or "such as" is intended to present concepts related in a concrete fashion.
In the embodiments of the present application, "at least one" means one or more, and "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a alone, A and B together, and B alone, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of the singular or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, a-b, a-c, b-c, or a-b-c, wherein a, b, c can be single or multiple.
Printed Circuit Boards (PCBs), also called printed circuit boards, are important electronic components, support bodies for electronic components, and carriers for electrical interconnection of electronic components. PCB boards are one of the important components of the electronics industry. Almost every electronic device, as small as electronic watches, calculators, as large as computers, communication electronic systems, etc., has electronic components such as integrated circuits, and PCB boards are used to electrically interconnect the various components. The printed circuit board consists of an insulating bottom plate, a connecting lead and a welding disc for assembling and welding electronic elements, and has double functions of a conductive circuit and the insulating bottom plate. The PCB board can replace complex wiring, and the electrical connection among all elements in the circuit is realized.
The PCB multi-layer board refers to a multi-layer circuit board used in electric products, and the multi-layer board is a wiring board on which more single-sided or double-sided boards are mounted. A printed circuit board with two surfaces as an inner layer and two single surfaces as an outer layer or two printed circuit boards with two surfaces as an inner layer and two single surfaces as an outer layer are alternately arranged together through a positioning system and an insulating binding material, and the printed circuit boards with conductive patterns interconnected according to the design requirement form a four-layer, six-layer and eight-layer printed circuit board, which is also called a multilayer printed circuit board.
In the process of charging and discharging a battery of the current electronic device, the electric quantity of the battery needs to be measured. The current can be determined by the voltage difference between two ends of the current detection resistor, so that the discharged electric quantity of the battery can be determined.
Fig. 1 is a schematic circuit structure diagram of an electric quantity detection circuit disclosed in an embodiment of the present application. As shown in FIG. 1, the circuit includes a power supply, a current sensing resistor and a board level circuit. The battery is used for providing power for the circuit, the board-level circuit is a consumption circuit, and the board-level circuit is used for consuming energy consumption provided by the power supply. The current detection resistor is a resistor specially used for measuring electric quantity, and is connected in series with a path where the battery is located. Two ends of the current detecting resistor are connected with the ammeter in parallel. A coulomb counter (coulomb counter) is a device for measuring the amount of electricity passing through a circuit and may be referred to as a coulomb counter or a fuel gauge. The electricity meter can accurately calculate the amount of electricity passing through the circuit using the amount of substance reacted on the electrodes based on faraday's law.
The fuel gauge may measure the voltage across the current sensing resistor. Therefore, the voltage difference of the two ends of the current detection resistor can be calculated, the current passing through the current detection resistor is determined based on the voltage difference and the resistance value of the current detection resistor, and the charging and discharging electric quantity is determined based on the current accumulation in a period of time.
Exemplarily, assuming that the electric meter knows that the resistance value of the current detection resistor is M Ω, the voltage of the first end of the current detection resistor is X1, and the voltage of the second end is X2, the corresponding current I = (X2-X1)/M can be determined. After determining the current, the fuel gauge may integrate or add up the current over a period of time, thereby enabling determination of the amount of charge charged and discharged by the resistor over the period of time.
In the above embodiment, the current detecting resistor in the circuit is expensive, and occupies a certain area on the PCB. In addition, the current detection resistor is arranged on the PCB, so that the impedance is large, the charging efficiency is low, and unnecessary power consumption is also caused.
The embodiment of the application provides an electric quantity detection mode, a current detection resistor is not required to be connected in series in a circuit, the resistance value of a PCB wire in a channel is utilized, and an electric quantity meter can detect the electric quantity flowing through two ends of a PCB wiring resistor. Therefore, the cost of the current detecting resistor and the layout area on the PCB can be saved, the impedance of a charging path is reduced, and the charging efficiency is improved.
Since the target electronic products are generally realized by printed circuit boards, PCBs, may include wires and components thereon. The lead of the PCB is a lead with a resistor, and the lead can be used as a current detection resistor to measure the charge and discharge electricity quantity under the condition of determining a section of the resistance of the PCB.
Fig. 2 is a schematic circuit diagram of another electric quantity detection circuit disclosed in the embodiment of the present application. As shown in fig. 2, the power detection circuit may include a power supply, a PCB trace resistor, a consumption circuit, and a fuel gauge. Wherein, the power supply, the PCB routing resistor and the consumption circuit are connected in series. The electricity meter can be parallelly connected with PCB and walk the line resistance (promptly the electricity meter is connected the both ends that PCB walked the line resistance), and the electricity meter can detect the electric quantity that PCB walked the line resistance and flowed.
The consumer circuit is a circuit that consumes power of a power source, such as a board-level circuit, an external device, and the like, and the present application is not limited thereto. The PCB trace resistor is at least one section of wire in the PCB, that is, one or two sections of PCB trace, and is not limited. The PCB trace resistance acts as a shunt resistance in fig. 1.
The electricity meter can measure the voltage values at two ends of the PCB wiring resistor as a first voltage V1 and a second voltage V2 respectively. Thereafter, the fuel gauge may determine a first current I1 flowing through the PCB trace resistance based on the first voltage V1, the second voltage V2, and the first resistance R1 of the PCB trace resistance. The electricity meter may then determine the amount of electricity flowing through the PCB trace resistance based on the first current I1.
Before determining the first current I1, the electricity meter may need to determine a resistance value R1 of the PCB trace resistor, which is described in detail below:
in one possible implementation, in the case of an electricity meter having a cross-sectional area S of the PCB trace resistance, a trace length L, and a resistivity ρ of the PCB trace resistance material. The first resistance R1 of the PCB trace resistance can be determined to be rho L/S.
On the one hand, the fuel gauge needs to determine the resistivity based on the current temperature. The fuel gauge may first determine that the current temperature t is obtained by a thermometer (e.g., a temperature sensor) and calculate the resistivity of the material of the PCB trace resistance as ρ = ρ' [1+ (t-t) 0 )d]. Where ρ' is a specific temperature t 0 The resistivity of the PCB trace resistance material under the condition, d is the coefficient of the specific PCB trace resistance material.
Illustratively, the material of the PCB trace resistor is special, and a commonly used wire medium is metallic copper. For example, in the case of 20 ℃, the resistivity ρ' of metallic copper is 0.0178 Ω m, which indicates that the magnitude of the resistance of metallic copper per meter is 0.0178 Ω, and the d of copper is 0.0039. The electricity meter may calculate an electric resistivity of 0.0178[1+ (t-20) ] 0.0039 based on the present temperature t.
On the other hand, the electricity meter needs to determine the cross-sectional area S and the trace length L of the PCB trace resistor.
Optionally, when the PCB trace resistor is a rectangular parallelepiped, the trace length L of the PCB trace resistor is the length L of the rectangular parallelepiped, and the cross-sectional area S of the PCB trace resistor is a product of the width w of the rectangular parallelepiped and the thickness h (S = w × h). At this time, S and L are both values measured in advance and stored in the fuel gauge.
Optionally, in a case that the PCB trace resistor is a cylinder, the trace length L of the PCB trace resistor is the height of the cylinder, and the cross-sectional area S of the PCB trace resistor is the cross-sectional area pi n of the cylinder 2 . Wherein n is the cylinder radius.
The specific shape of the PCB trace resistor is not limited in this embodiment.
In another possible embodiment, the electricity meter may store the first resistor R1 in advance, and directly determine the first current I1= (V2-V1)/R1.
In yet another possible implementation, the fuel gauge may store a mapping relationship between temperature and resistance value, and after the current temperature is measured, the fuel gauge may determine the resistance value corresponding to the current temperature t as the first resistance R1 based on the mapping relationship between temperature and resistance value.
In the embodiment of the present application, the conducting wire medium may be copper, may also be other metal materials, such as silver, and may also be other conductive materials, which is not limited in the present application.
It should be noted that the power detection circuit may be a circuit in an electronic product, the consumption circuit may include a display screen, and the electronic device may display the power of the current power source through the display screen when the electric meter detects the power flowing through the PCB trace resistor. In addition, the electronic device is not limited to a specific one, for example, a mobile phone, a computer, a smart watch, a smart wearable device, and the like.
It should be further noted that, the current flowing through the PCB trace resistor may have positive and negative states, which indicates that the flowing direction of the current may be from left to right (left higher voltage, right lower voltage) or from right to left (left lower voltage, right higher voltage). The direction of the current corresponds to the power supply, and there are charging and discharging processes, so that it is known that the current power supply capacity can be obtained by adding/subtracting the power supply capacity at a certain moment and the power supply capacity flowing through the PCB wiring resistor within a period of time after the moment. Wherein the power source may be a battery.
In the actual electricity measurement process, there are many factors that influence the resistance determination process of the PCB conductor, which are described in detail below:
1. temperature changes affect resistivity, and resistivity changes affect resistance.
The resistivity of the PCB trace resistance is related to the temperature at which the PCB trace resistance is located, and the resistivity is rho = rho '[1+ (t-20) × 0.0039], wherein t is the current temperature, and rho' is the known resistivity under the condition of 20 ℃. For example, copper has a ρ' of 0.0178 at 20 ℃. When the current temperature is obtained, the current resistivity can be calculated.
There may be a deviation of the accuracy of the temperature values due to the temperature measurement, e.g. in the range of 3 ℃. This causes a deviation in the calculated resistivity, so that the determined first resistance R1 also deviates.
TABLE 1
Figure 740013DEST_PATH_IMAGE001
Table 1 is a table of the effect of resistance under different temperature conditions disclosed in the examples of the present application. As shown in table 1, the resistivity of the same section of copper trace (PCB trace resistance) of PCB is 0.0178 Ω m at 20 ℃, and the resistance thereof is 5m Ω; at 17 ℃, the resistivity is 0.017592 Ω m; the resistivity was 0.018008 Ω m at 23 ℃; at 80 ℃, the resistivity was 0.021965 Ω m, and the resistance was 6.17m Ω. Therefore, under the condition of higher temperature, the higher the resistivity is, the larger the resistance value of the copper trace (PCB trace resistor) corresponding to the same PCB is.
2. Precision deviation of PCB wire length and cross-sectional area control.
The thickness of the PCB conductors is typically in the micrometer order. There may be some tolerance in the control of the length and cross-sectional area of the micron-scale PCB conductors during the manufacturing process.
Fig. 3 is a schematic structural diagram of a section of PCB trace disclosed in the embodiment of the present application. As shown in fig. 3, the shape of the PCB conductor may be approximately a rectangular parallelepiped. The cross-sectional area S of the wire is the width w x the thickness h, and the length of the wire is L (where the current flow direction is perpendicular to the plane of the width w x the thickness h).
Illustratively, in the actual production of printed circuit boards, manufacturers can only control the minimum thickness to be 11um and the precision range of the width and length to be 10%. Under the condition that the width w, the thickness h and the length L of a PCB wire controlled by a manufacturer have deviation, the determined resistance value of the resistor also has certain precision deviation.
Illustratively, the wire length is 6.18 x 10 at 20 ℃ in a wire material of copper and a temperature condition of 20 ℃ -3 m, width 2 x 10 -3 m, thickness of 0.011 x 10 -3 m, the resistance at this time R =0.0178 × 6.18 × 10 can be determined -3 /(2*10 -3 *0.011*10 -3 ) Approximately 5m omega. If the manufacturer can only control the minimum value of the thickness to be 11um and the precision range of the width and the length to be 10 percent, the range of the length L is 5.561798mm to 6.797753mm; the width w ranges from 1.8mm to 2.2mm; the thickness h is a minimum of 11um and a maximum of 15um. Through measurement, the obtained minimum resistance value is 3m omega, the maximum resistance value is 6.11111m omega, and the error rate of the obtained resistor is-40% -22.2222%. If the temperature is further measured (the accuracy range of the ADC for detecting the temperature is 3 ℃), the minimum resistance value is 2.9649m Ω, and the maximum resistance value is 6.182611m Ω. The error rate of the obtained resistance is-40.702% -23.6522%.
Based on the above-described procedure, the procedure of measuring the electric quantity in fig. 2 is explained. The PCB trace resistance is determined as a cuboid (as shown in fig. 3), and the electricity meter may be pre-stored with a length L, a width w, and a thickness h. In addition, the electricity meter also stores the resistivity ρ 'of the PCB wire material, after which the current temperature can be measured and the resistivity ρ = ρ' [1+ (t-20) × 0.0039] calculated. The resistance value of the PCB track resistance can then be calculated based on R1= ρ L/S. Wherein S = w h. The electricity meter can measure voltages V1 and V2 across the PCB trace resistance and determine the current I1= (V2-V1)/R1 flowing through the PCB trace resistance. The current in between the segments may then be integrated or summed to determine the amount of power flowing in between the segments. As described above, the manufacturing process may result in current point differences and temperature measurement variations or in resistance variations, both of which may exacerbate variations in the power measurement results.
The temperature error and the error of the PCB wiring resistor manufacturing process can cause poor electric quantity detection results of the PCB wiring resistor. In order to solve the above problems, the present application provides two calibration compensation methods to improve the accuracy of measuring the electric quantity.
In the process of mass production, the electricity meter can preset a theoretical resistance value R 0 This preset resistance R 0 And (4) calculating. For example, the resistivity of a copper PCB trace resistance at 20 degrees Celsius is ρ 0 =ρ'[1+(t-20)*0.0039]And calculating to obtain R 00 L/S. However, in the actual electric quantity detection circuit, on the one hand, L and S have errors. On the other hand, the temperature changes and the resistivity also changes.
1. A current correction method is provided for errors of a manufacturing process. (correction of L and S)
Before the electronic equipment leaves the factory, namely in the production line manufacturing process, the battery power supply can be disconnected, and power supplies are separately provided for the PCB wiring resistor and the consumption circuit to be detected. In the case of providing an external power supply, the electricity meter can read the voltage difference between two ends of the PCB wiring resistor, and further can calculate the current I2', the external power supply knows the power supply current I1' of the external power supply, so that the correction coefficient k = I1'/I2' can be determined, and in the case of determining the resistance correction coefficient k, the electricity meter can store k. In the process of detecting the electric quantity (as shown in fig. 2), the electricity meter may measure a voltage difference between two ends of the PCB trace resistor, and further may calculate that the second current I2 is (V2-V1)/R1 (a ratio of a difference between the first voltage V1 and the second voltage V2 to the first resistor R1), and the actual first current I1= I2 × k (the first current I1 is a product of the second current I2 and a current correction coefficient k), so that the electric quantity flowing through the PCB trace resistor may be determined based on the first current I1.
With respect to the above process, the following two stages are described in sequence:
stage one: the current correction coefficient k is determined in advance.
Fig. 4 is a schematic circuit diagram of calibration compensation according to an embodiment of the present application. As shown in fig. 4, in the circuit structure, the power supply can disconnect the circuit connected in series with the PCB track resistor and the consumer circuit, and supply power to the consumer circuit through the external power supply 1, and supply power to the PCB track resistor through the external power supply 2. The external power supply 2 may be connected in series with a current limiting resistor in the circuit to ensure that the current is within the working range. External power source 2 can directly determine that its supply current is I1' (I1 ' is actual current, accurate value promptly), and the ammeter can calculate PCB and walk the resistance of resistance to can measure the voltage at PCB and walk the resistance both ends, thereby can calculate measuring current I2'. The current correction factor k = I1'/I2' (i.e., k is the ratio of the actual current flowing through the PCB trace resistor to the current measured by the fuel gauge) can be determined. After that, the electricity meter stores the current correction coefficient k.
The circuit in fig. 4 is not limited to be opened, and for example, the battery is removed, or a switch in the circuit is opened. The external power supply 1 and the external power supply 2 may be different power supplies or the same power supply, and the present application is not limited thereto. The external power supply 1 and the external power supply 2 can be connected or disconnected by an electronic probe, and the original circuit can be prevented from being affected.
And a second stage: the measured current is corrected based on the measured current and a current correction coefficient k.
After the first stage, the electricity meter stores the current correction coefficient k. As shown in fig. 2, in the power detection circuit, the fuel gauge calculates a first resistance R1 of the PCB trace resistance. The electricity meter may measure a voltage across the PCB trace resistance and determine a measured current as I2= (V2-V1)/R1 (second current) based on the voltage difference. The electronic device may correct the measured current I2 based on k, resulting in a first current of I1= I2 × k.
In the above embodiment, since the manufacturing process level of the PCB does not meet the precision requirement, there is always a certain difference between the actual resistance of the PCB trace resistor and the calculated resistance of the PCB resistor. Under the same temperature condition, the difference between the actual resistance and the calculated resistance is the same, and since the voltage across the resistance is equal to the product of the resistance and the current, the measurement result of the voltage difference is accurate under the condition that the resistance changes to Δ R, and the current changes along with the resistance, and the ratio of the current change is proportional to Δ R. Therefore, the current after correction by the correction factor is closer to the actual current. Therefore, even if the PCB manufacturing process is limited, the PCB wiring resistor can be ensured to replace a current detection resistor, and the charging electric quantity can be accurately determined.
It should be noted that, because different PCB trace resistances have different variations in parameters such as length, width, and thickness in manufacturing, the correction coefficient k of the resistance needs to be determined separately for each PCB trace resistance in each circuit before the electronic device is shipped from the factory.
2. A resistance correction method is proposed for errors in temperature measurement. (correction of ρ)
The resistivity of the wire material changes due to different environmental temperatures, so that the resistivity of the PCB wiring resistor also deviates, and the calculated resistance value of the resistor also deviates. For the above case, the corresponding resistance correction coefficient R may be determined based on the current temperature t condition, and the first resistance R1 or the first current I1 may be corrected based on the resistance correction coefficient R.
Stage one: the resistance correction coefficient r with respect to temperature is determined in advance.
In one possible embodiment, the resistance correction factor r is determined based on the theoretical resistivity (specific temperature) and the resistivity at the actual temperature.
Optionally, as shown in fig. 2, the power detection circuit may further includeAnd a temperature-sensitive resistor (not shown) is included, and the current actual temperature can be determined to be t based on the resistance value of the temperature-sensitive resistor. The first resistivity (actual resistivity) under the condition of t can be calculated as rho 0 =ρ'[1+(t-t 0 )d]And the second resistivity (theoretical resistivity) is ρ. Thereafter, the resistance correction coefficient r = ρ may be calculated 0 And rho, and the resistance correction coefficient r is the ratio between the first resistivity and the second resistivity. Wherein the theoretical resistivity in each PCB board should be the same.
Under different temperature conditions (at the moment, t changes), the resistance values of the temperature-sensitive resistors are respectively determined to determine the current actual temperature t, and then the corresponding first resistivity and the second resistivity under different current temperature t conditions are calculated. The correction coefficient of resistance r = ρ/ρ at different current temperatures t can then be determined 0 I.e. the ratio of the actual resistivity to the theoretical resistivity. The electronic device may store r at different temperature conditions. Where the calculated resistivity is a theoretical calculated resistivity, the corresponding temperature may be the same temperature, for example 20 ℃.
Illustratively, the current temperature t is 23 ℃ and the theoretical temperature is 20 ℃, the first resistivity and the second resistivity may be calculated, and the resistance correction coefficient r under the condition that the current temperature t is 23 ℃ is determined. Similarly, the resistance correction factor r under other current temperature conditions may also be determined. The different temperatures t form a mapping with their resistance correction factors r, which the fuel gauge can store.
It is possible for the fuel gauge to store a mapping of the current temperature t to the resistance correction factor r.
TABLE 2
Figure 988591DEST_PATH_IMAGE002
Table 2 is a mapping table of temperature t and resistance correction coefficient r exemplarily shown in the embodiment of the present application. As shown in table 2, there are specific resistance correction factors for different temperature conditions. If the current temperature is 0 ℃, determining the resistance correction coefficient to be r0; 823060, 8230; if the current temperature is 20 ℃, determining the resistance correction coefficient to be r20; 823060, 8230; if the current temperature is 100 ℃, determining the resistance correction coefficient as r100, and the like. It should be noted that the resistance correction coefficients in table 2 are only exemplary, and the range of the current temperature t and the specific resistance correction coefficient size are not limited in this application.
And a second stage: correction is performed based on the calculated resistance value of the resistor and the resistance correction coefficient r with respect to temperature.
Preferably, the resistance correction factor r is determined based on the current temperature t.
Optionally, r is determined based on the stored history. After the first stage, the fuel gauge stores the mapping relationship between the temperature and the resistance correction coefficient r (for example, table 2). As shown in fig. 2, in the electricity amount detection circuit, the electricity amount meter stores a threshold resistance second resistance R2, and corrects R2. The fuel gauge may acquire the current temperature t and determine the corresponding correction coefficient r based on the above-described mapping relationship.
Optionally, r is calculated in real time based on temperature. The electricity meter can acquire the current temperature t in real time and calculate the first resistivity (actual resistivity) under the condition of t as rho 0 =ρ'[1+(t-t 0 )d]. The second resistivity (theoretical resistivity) ρ may be calculated in advance. Thereafter, a resistance correction coefficient r = ρ/ρ may be calculated 0 The resistance correction coefficient r is a ratio between the first resistivity and the second resistivity.
Secondly, the resistance correction coefficient r under the condition of obtaining the current temperature t can be corrected based on the resistance correction coefficient r.
Optionally, the fuel gauge determines that the first resistance R1 is a product of the second resistance R2 and the resistance correction coefficient R. The second resistance R2 is corrected to obtain the first resistance R1= R2 × R. That is, during the power detection, the fuel gauge may determine the corresponding resistance correction coefficient R under the current temperature t condition, and correct the second resistance R2 to the first resistance R1= R2R (second resistance) based on the pair of calculated resistances R2= ρ L/S (second resistance), that is, the first resistance is the second resistance and the resistance correction coefficient R. Wherein, the second resistor R2 is a theoretical resistance R 0 I.e. a preset resistance value.
Optionally, in the power detection circuit, the fuel gauge calculates a second resistance R2 (uncorrected resistance) of the PCB trace resistance. The electricity meter may measure a voltage across the PCB trace resistance and determine the measured current as I2= (V2-V1)/R2 (second current) based on the voltage difference. The electronic device may correct the measured current I2 based on r, resulting in a first current of I1= I2/r (the first current being the ratio of the second current to the resistance correction factor r).
In the above embodiment, the resistance correction coefficient r under different temperature conditions can be determined due to the calculated resistance error caused by the temperature difference, and then in the process of measuring the electric quantity, the electronic device needs to correct the calculated resistance value based on the correction coefficient r, so that the error of the resistance value can be ensured to be smaller, and the accuracy of measuring the electric quantity can be improved.
Since the temperature deviation is different, the correction coefficient r of the resistance needs to be determined for each PCB circuit before the electronic device is shipped.
In the two calibration methods, the first stage may be preprocessing (corresponding to fig. 4) to obtain the corresponding resistance calibration coefficient r, and the second stage is to determine the battery capacity during the capacity measurement process (corresponding to fig. 2).
In the process of detecting the specific charging and discharging electric quantity, a first correction mode can be used, namely, the current is corrected, a second correction mode can be used, namely, the resistance is corrected, and the two correction modes can be used, namely, the current and the resistance are corrected.
Before the product leaves a factory, all the PCB boards need to calculate k and r respectively and store the k and r, namely, the k and r in each electric quantity detection circuit are generally different. Optionally, r may also be calculated in real time during the power detection process.
In the case where both the resistance correction and the current correction are used, a specific implementation is exemplified below. Fig. 5 is a schematic flow chart of an electric quantity detection method disclosed in the embodiment of the present application. As shown in fig. 5, the power detection method may include, but is not limited to, the following steps:
wherein, the electricity meter is preset with a theoretical resistance R2.
S501: the electricity meter measures a first voltage V1 and a second voltage V2.
As shown in fig. 2, the electricity meter is connected to two ends of the PCB trace resistor, and can measure the voltage at the two ends, as well as the first voltage V1 and the second voltage V2.
S502: the fuel gauge acquires a current temperature t and determines a resistance correction coefficient r based on the current temperature t.
Alternatively, the electricity meter may acquire the current temperature t and calculate the first resistivity and the second resistivity, and then may determine the resistance correction coefficient r under the current temperature t condition. For details, reference may be made to the description related to the first stage in the resistance correction method proposed for the temperature measurement error, which is not repeated.
Alternatively, the electricity meter determines the resistance correction coefficient r under the current temperature t condition based on the first mapping relation.
The first mapping is a mapping between different temperatures and resistance correction coefficients, for example, as shown in table 2. For example, the related description in the second stage in the resistance correction method provided for the temperature measurement error may be referred to, and details are not repeated.
S502 may refer to stage two above: the description about determining the resistance correction coefficient r based on the current temperature t in correcting based on calculating the resistance value of the resistor and the resistance correction coefficient r with respect to the temperature will not be repeated.
S503: the fuel gauge determines a second current I2 based on the first voltage V1, the second voltage V2, and the second resistance R2.
The fuel gauge may determine the second current I2= (V2-V1)/R1 based on the first voltage V1, the second voltage V2, and the first resistance R1.
S504: the fuel gauge corrects the second current I2 based on the current correction coefficient k and the resistance correction coefficient r to obtain a first current I1.
The electricity meter may determine, for the second current I2, a first current of the PCB trace resistance as I1= I2 × k/r based on the current correction coefficient k and the resistance correction coefficient r. The correction sequence of k and r is not limited, and k correction can be performed firstly and then r correction can be performed; the correction can be performed by r first and k later.
Wherein S502 is performed before S504.
For the detailed description of the step in fig. 5, reference may be made to the description of the relevant stages in fig. 2 and fig. 4, which is not repeated herein.
The execution main body may be an electricity meter or other processors, the electricity meter uploads measured data to the processor, and the data is processed by other modules.
In the case where both the resistance correction and the current correction are used, a specific implementation is exemplified below. Fig. 6 is a schematic flow chart of another electric quantity detection method disclosed in the embodiment of the present application. As shown in fig. 6, the power detection method may include, but is not limited to, the following steps:
s601: the electricity meter measures a first voltage V1 and a second voltage V2.
As shown in fig. 2, the electricity meter is connected to two ends of the PCB trace resistor, and can measure the voltage at the two ends, as well as the first voltage V1 and the second voltage V2.
S602: the fuel gauge acquires a current temperature t and determines a resistance correction coefficient r based on the current temperature t.
Alternatively, the electricity meter may acquire the current temperature t and calculate the first resistivity and the second resistivity, and then may determine the resistance correction coefficient r under the current temperature t condition. For details, reference may be made to the description related to the first stage in the resistance correction method proposed for the temperature measurement error, which is not repeated.
Alternatively, the electricity meter determines the resistance correction coefficient r under the current temperature t condition based on the first mapping relation.
The first mapping is a mapping between different temperatures and resistance correction coefficients, for example, as shown in table 2. For details, reference may be made to the description related to the second stage in the resistance correction method proposed for the temperature measurement error, which is not repeated.
S602 may refer to stage two above: the description about determining the resistance correction coefficient r based on the current temperature t in performing correction based on the calculated resistance value of the resistor and the resistance correction coefficient r based on the temperature is omitted for brevity.
S603: the fuel gauge corrects the second resistor R2 based on the resistance correction coefficient R to obtain the first resistor R1.
The fuel gauge may determine a first resistance R1= R2R of the PCB trace resistance to the second resistance R2 based on the resistance correction factor R.
S604: the fuel gauge determines a second current I2 based on the first voltage V1, the second voltage V2, and the first resistance R1.
The fuel gauge may determine the second current I2= (V2-V1)/R1 based on the first voltage V1, the second voltage V2, and the first resistance R1.
S605: the fuel gauge corrects the second current I2 based on the current correction coefficient k to obtain the first current I1.
The electricity meter may determine the first current of the PCB trace resistance as I1= I2 × k for the second current I2 based on the current correction factor r.
For the detailed description of the step in fig. 6, reference may be made to the description of the relevant stages in fig. 2 and fig. 4, which is not repeated herein.
The execution main body may be an electricity meter or other processors, the electricity meter uploads measured data to the processor, and the data is processed by other modules.
The temperature error and the error of the PCB wiring resistor manufacturing process can cause poor electric quantity detection results of the PCB wiring resistor. In order to solve the problems, the direct ground resistance correction scheme is provided.
In the process of mass production, the electricity meter can be used without presetting a theoretical resistance value R 0 . But a map (second map) between the temperature and the actual resistance value is stored in advance. In the electric quantity detection process, the actual resistance value R1 corresponding to the current temperature t may be obtained based on the current temperature t, and the current may be calculated and the electric quantity may be determined based on R1.
First, the second mapping relationship may be determined in advance.
According to the method in fig. 4, the resistance correction coefficient r at different temperatures can be determined by separately connecting the PCB trace resistor to the external power supply 2. As shown in fig. 4, the external power source 2 may provide power to the PCB trace resistor, and a user may read a current I3 of the external power source 2. The electricity meter can read the voltage at two ends of the PCB wiring resistor and determine the voltage difference V4-V3, so that the actual resistance value of the PCB wiring resistor can be calculated to be R1= (V4-V3)/I3. The currently measured temperature value is t. Thus R1 corresponding to t.
Illustratively, as shown in fig. 4, assuming a currently measured temperature of 20 ℃, the external power supply 2 may provide a specific current I3 for the PCB track resistance. The fuel gauge can measure the voltage values V2 and V1 across the PCB trace resistance. The actual resistance value R1 of the PCB routing resistor can be determined based on the (V4-V3)/I3, and the actual resistance value at 20 ℃ can be determined to be R1.
It is possible for the fuel gauge to store a second mapping of the current temperature t to the actual resistance R1.
TABLE 3
Figure 852642DEST_PATH_IMAGE003
Table 3 is a mapping table of temperature t and actual resistance R1 exemplarily shown in the embodiment of the present application. As shown in table 3, there are specific actual resistances for different temperature conditions. If the current temperature is 0 ℃, determining the resistance correction coefficient to be R1_0; \8230; if the current temperature is 20 ℃, determining the resistance correction coefficient to be R1-20; 823060, 8230; if the current temperature is 100 ℃, determining the resistance correction coefficient to be R1-100, and the like. It should be noted that the actual resistance in table 3 is only an exemplary illustration, and the range of the current temperature t and the actual resistance are not limited in this application.
In the case where both the resistance correction and the current correction are used, a specific implementation is exemplified below. Fig. 7 is a schematic flow chart of another method for detecting electric quantity disclosed in the embodiment of the present application. As shown in fig. 7, the power detection method may include, but is not limited to, the following steps:
s701: the electricity meter measures a first voltage V1 and a second voltage V2.
As shown in fig. 2, the electricity meter is connected to two ends of the PCB trace resistor, and can measure the voltage at the two ends, as well as the first voltage V1 and the second voltage V2.
S702: the fuel gauge obtains the current temperature t, and determines a first resistor R1 corresponding to the current temperature t based on the second mapping relation.
The fuel gauge determines the actual resistance R1 at the current temperature t condition based on the second mapping relationship.
The second mapping is a mapping between different temperatures and actual resistances, for example, as shown in table 3. For details, reference may be made to the above description, which is not repeated herein.
S703: the fuel gauge determines a first current I1 based on the first voltage V1, the second voltage V2, and the first resistance R1.
The fuel gauge may determine the first current I1= (V2-V1)/R1 based on the first voltage V1, the second voltage V2, and the first resistance R1. The electric quantity may be determined based on the first current, and specific reference is made to the related description in fig. 1 and fig. 2, which is not repeated herein.
For the detailed description of the step in fig. 7, reference may be made to the description of the relevant stages in fig. 2 and fig. 4, which is not repeated herein.
The execution main body may be an electricity meter or other processors, the electricity meter uploads measured data to the processor, and the data is processed by other modules, and the application does not limit the execution main body of the method.
In the process, the actual resistance can be directly determined without correcting the coefficient, the S, the L and the rho are corrected, the accuracy of the electric quantity detection result is improved, the detection method is simplified, and the execution efficiency is improved.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program is loaded and executed on a computer, the procedures or functions according to the embodiments of the present application are wholly or partially generated. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, the computer instructions may be transmitted from one website site, computer, server, or data center to another website site, computer, server, or data center by wire (e.g., coaxial cable, fiber optic, digital subscriber line) or wirelessly (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that includes one or more available media. The usable medium may be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid state disk), among others.
Those skilled in the art can understand that all or part of the processes in the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer readable storage medium and can include the processes of the method embodiments described above when executed. And the aforementioned storage medium includes: various media capable of storing program codes, such as ROM or RAM, magnetic or optical disks, etc.

Claims (9)

1. The utility model provides an electric quantity detection circuit, its characterized in that, the circuit includes power, PCB and walks line resistance, consumer circuit and coulomb meter, PCB walks line resistance and is at least one section wire in the PCB board, wherein:
the power supply, the PCB wiring resistor and the consumption circuit are connected in series, and the electricity meter is connected with two ends of the PCB wiring resistor;
the fuel gauge is used for determining a resistance correction coefficient r under the condition of the current temperature t based on a first mapping relation, the first mapping relation is a mapping relation between different temperatures and the resistance correction coefficient, the fuel gauge stores the first mapping relation, and the resistance correction coefficient r is an actual electricity under the different temperature conditionsThe ratio between resistivity and theoretical resistivity; or, the electricity meter is used for determining the second resistivity rho of the PCB routing resistance based on the current temperature t and determining the resistance correction coefficient r as the first resistivity rho 0 A ratio to the second resistivity ρ, the second resistivity ρ being a theoretical resistivity;
the fuel gauge is further configured to determine that a first resistor R1 of the PCB trace resistor is a product of a second resistor R2 and the resistance correction coefficient R, and the second resistor R2 is a theoretical resistance value pre-stored in the fuel gauge;
the electricity meter is further configured to measure a first voltage V1 and a second voltage V2 at two ends of the PCB trace resistor, determine a first current I1 flowing through the PCB trace resistor based on the first voltage V1, the second voltage V2, and the first resistor R1, and determine an electric quantity flowing through the PCB trace resistor based on the first current I1.
2. The circuit according to claim 1, wherein the electricity meter determines a first current I1 flowing through the PCB trace resistance based on the first voltage V1, the second voltage V2 and the first resistance R1, in particular for:
determining a second current I2 of the PCB routing resistor as a ratio of a difference value between the first voltage V1 and the second voltage V2 to the first resistor R1;
determining the first current I1 as the product of the second current I2 and a current correction coefficient k based on the current correction coefficient k, wherein the electricity meter stores the current correction coefficient k.
3. The circuit of claim 2, wherein the current correction factor k is a ratio of an actual current flowing through the PCB trace resistor to a current measured by the fuel gauge.
4. The method is characterized by being applied to an electric quantity detection circuit, wherein the electric quantity detection circuit comprises a power supply, a PCB (printed circuit board) wiring resistor, a consumption circuit and an electric quantity meter, the PCB wiring resistor is at least one section of conducting wire in a PCB, the power supply, the PCB wiring resistor and the consumption circuit are connected in series, and the electric quantity meter is connected with two ends of the PCB wiring resistor; the method comprises the following steps:
determining a resistance correction coefficient r under the current temperature t condition based on a first mapping relation through the fuel gauge, wherein the first mapping relation is a mapping relation between different temperatures and the resistance correction coefficient, the fuel gauge stores the first mapping relation, and the resistance correction coefficient r is a ratio of actual resistivity to theoretical resistivity under the different temperatures; or determining a second resistivity rho of the PCB wiring resistance based on the current temperature t through the electricity meter, and determining the resistance correction coefficient r as a first resistivity rho 0 A ratio to the second resistivity ρ, the second resistivity ρ being a theoretical resistivity;
determining, by the ammeter, that a first resistance R1 of the PCB trace resistance is a product of a second resistance R2 and the resistance correction coefficient R, where the second resistance R2 is a theoretical resistance value pre-stored by the ammeter;
measuring a first voltage V1 and a second voltage V2 at two ends of the PCB wiring resistor through the electricity meter, determining a first current I1 flowing through the PCB wiring resistor based on the first voltage V1, the second voltage V2 and the first resistor R1, and determining the electric quantity flowing through the PCB wiring resistor based on the first current I1.
5. The method for detecting electric quantity according to claim 4, wherein the electricity meter determines a first current I1 flowing through the PCB trace resistor based on the first voltage V1, the second voltage V2 and the first resistor R1, and specifically includes:
determining, by the ammeter, a second current I2 of the PCB trace resistance as a ratio of a difference between the first voltage V1 and the second voltage V2 to the first resistance R1;
determining, by the electricity meter, the first current I1 as a product of the second current I2 and a current correction coefficient k based on the current correction coefficient k, the electricity meter storing the current correction coefficient k.
6. The method for detecting electric quantity according to claim 5, wherein the current correction coefficient k is a ratio of an actual current flowing through the PCB trace resistor to a current measured by the electricity meter.
7. The power detection method according to any one of claims 4-6, wherein after the power meter determines the power flowing through the PCB trace resistance based on the first current I1, the method further comprises:
and displaying the electric quantity value of the power supply through a display based on the electric quantity flowing through the PCB wiring resistor.
8. An electronic device characterized in that it comprises a power detection circuit according to any one of claims 1 to 3 and a discrete device connected to said power detection circuit.
9. A computer-readable storage medium comprising instructions that, when executed on an electronic device, cause the electronic device to perform the method of any of claims 4-7.
CN202211246459.0A 2022-10-12 2022-10-12 Electric quantity detection circuit and method and electronic equipment Active CN115343529B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211246459.0A CN115343529B (en) 2022-10-12 2022-10-12 Electric quantity detection circuit and method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211246459.0A CN115343529B (en) 2022-10-12 2022-10-12 Electric quantity detection circuit and method and electronic equipment

Publications (2)

Publication Number Publication Date
CN115343529A CN115343529A (en) 2022-11-15
CN115343529B true CN115343529B (en) 2023-03-10

Family

ID=83957514

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211246459.0A Active CN115343529B (en) 2022-10-12 2022-10-12 Electric quantity detection circuit and method and electronic equipment

Country Status (1)

Country Link
CN (1) CN115343529B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104502670A (en) * 2014-12-25 2015-04-08 小米科技有限责任公司 Voltage detecting device, battery and voltage detecting method
CN205067584U (en) * 2015-09-07 2016-03-02 中兴通讯股份有限公司 Current detection circuit
CN106489223A (en) * 2016-05-27 2017-03-08 广东欧珀移动通信有限公司 Battery protecting plate, battery and mobile terminal
CN108627701A (en) * 2017-03-15 2018-10-09 上海骐宏电驱动科技有限公司 Resistance measurement system and resistance measuring equipment
WO2020259322A1 (en) * 2019-06-26 2020-12-30 Oppo广东移动通信有限公司 Electronic device
CN112986879A (en) * 2019-12-16 2021-06-18 北京小米移动软件有限公司 Electricity meter correcting method and device, electronic apparatus, storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104502670A (en) * 2014-12-25 2015-04-08 小米科技有限责任公司 Voltage detecting device, battery and voltage detecting method
CN205067584U (en) * 2015-09-07 2016-03-02 中兴通讯股份有限公司 Current detection circuit
CN106489223A (en) * 2016-05-27 2017-03-08 广东欧珀移动通信有限公司 Battery protecting plate, battery and mobile terminal
CN108627701A (en) * 2017-03-15 2018-10-09 上海骐宏电驱动科技有限公司 Resistance measurement system and resistance measuring equipment
WO2020259322A1 (en) * 2019-06-26 2020-12-30 Oppo广东移动通信有限公司 Electronic device
CN112986879A (en) * 2019-12-16 2021-06-18 北京小米移动软件有限公司 Electricity meter correcting method and device, electronic apparatus, storage medium

Also Published As

Publication number Publication date
CN115343529A (en) 2022-11-15

Similar Documents

Publication Publication Date Title
EP1247304B1 (en) Shunt resistance device for monitoring battery state of charge
CN102346242B (en) The calibration of conductivity measurement system
CN101185005B (en) Method and apparatus of detecting voltage for battery pack
CN111542760B (en) System and method for correcting current value of shunt resistor
US11164687B2 (en) Shunt resistor mount structure
CN105021941A (en) Test jig substrate test apparatus and substrate test method
CN108107369B (en) Battery monitoring circuit
CN115343529B (en) Electric quantity detection circuit and method and electronic equipment
KR20100035138A (en) Temperature measuring circuit in a flowmeter
CN107132417A (en) A kind of precision resister measuring method of reactive circuit parameter drift
US20220057438A1 (en) Current Sensor Element, Current Sensor Unit, and Method of Measuring a Current
CN111352036B (en) Battery sensor and method for operating a battery sensor
US6861834B2 (en) System and method for measuring the power consumed by a circuit on a printed circuit board
CN111337726A (en) Circuit structure based on patch shunt and current detection method
CN101788610B (en) Calibration method of coaxial impedance calibrator
KR102416052B1 (en) Resistance measuring devices and methods of measuring resistance
CN112714873A (en) Battery sensor for measuring current independently of temperature using a shunt
CN103487674B (en) Electrical characteristics detection method and detection means
CN113029377A (en) Measuring module, measuring method, measuring device and printed circuit board
EP3527995B1 (en) Shunt resistor and measurement system
KR101897522B1 (en) Internal Resistance Measuring Device
JP2013234949A (en) Weighing device
WO2023189742A1 (en) Shunt resistor and current detection device
CN218767949U (en) Voltage output circuit and voltage output device
CN215493857U (en) Origin positioning compensation device in electrical property automatic measurement system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant