蓝猫淘气

Simple battery internal resistance tester

 
Overview

Project Description
Design a low-cost and simple battery internal resistance tester, with open source software and hardware.
 
Open source agreement
GPL 3.0
 
Project related functions
Measure the internal resistance of the battery, with a range of 1 milliohm to 100 ohms, divided into 5 gears, 0-10 milliohms, 10-100 milliohms, 100-1000 milliohms, 1-10 ohms, 10-100 ohms, and button 2 to switch gears.
 
Project attributes
This project is the first public and is my original project. The project has not won any awards in other competitions.
 
Project progressThe
project has been completedDesign
 
principleThe
single-chip SPWM generates a 1KHZ sine wave through RC filtering
 
 
and then enters the constant current circuit, which is divided into two gears of 100 mA and 10 mA. The 100 mA sampling resistor is 10 ohms, and the 10 mA sampling resistor is 100 ohms. It is switched through MOS tubes and 4053 analog switches.
 
 
The DC voltage of the battery is isolated by capacitors and connected through Kelvin clips. Note that the HC and LC lines should be wound together, and the HP and LP lines should be wound together, otherwise the magnetic field generated by the HC and LC lines will couple to HP and LP. . One clip for HC and HP, one clip for LP and LC, don't connect them wrong!
 
 
 
It enters the differential amplifier circuit through the 104 safety DC blocking capacitor. The differential amplifier circuit is followed by a 1, 10, 100, 1000 times adjustable amplifier. It is first attenuated and then amplified. The last stage raises the sine wave to 1.65V and enters the ADC port of the microcontroller.
 
 
 
The power supply part samples the 9-12V input, 7805 generates +5V, LM2596 generates -5V, and the 10 ohm and 470UF capacitors RC filter to power the amplifier circuit.
 
 
The microcontroller uses the cheap STM32F030F4P6
 
display sampling, which is easier to buy 1602.
 
 
 
Software description
The software is relatively simple, with an ADC sampling rate of 1MHZ to collect 1KHZ sine waves, collect 1000 points, and then DFT calculates the real and imaginary parts, and then enters the 200-point filter. After filtering, the square root of the amplitude is calculated, and the amplitude obtained is multiplied by a value to obtain the resistance value of the measured resistor
 
. The open source address of the software
is https://github.com/yjmwxwx/stm32asm/tree/master/gcm0/nei_zu_yi.
 
All software is open source, and we look forward to improvements by netizens. The program is written in pure assembly, and the compiler ARM-NONE-EABI can
 
be compiled by typing make.
 
 
 
Physical display of the front and back clips
 
of the small lithium battery. Design precautions: It consumes more power and is not suitable for battery power supply. Of course, you can change it to battery power supply if you don’t care. Other physical demonstrations: the front and back of the video circuit board. Video calibration method. The video clip is short-circuited, press button 1 to enter the short-circuit clearing mode, and make the reading 0 by adjusting button 1 and button 2. Then press button 1 and button 2 at the same time to enter the next gear. All clearing is completed and the display is automatically saved to FLASH after completion. Press button 2 and do not release it, then press button 1 to enter the calibration mode. For example, to calibrate the 0-10 milliohm range, clamp a 10 milliohm resistor. Use buttons 1 and 2 to add or subtract to adjust to 10 milliohms, then hold down button 1 and press button 2 to enter the next range. When all calibrations are completed, the display will show completion and the data will be saved to FLASH. The data refresh rate is reduced to 4 times per second, and the readings still jump violently. The data refresh is reduced to 4 times per second. The picture below the video shows that the 10 milliohm range is calibrated with a 0.5 milliohm resistor. You can see that values ​​greater than 0.5 milliohms are too large, values ​​less than 0.5 milliohms are too small, and both linearity and accuracy are not good. The picture shows the actual measurement from 0.1 milliohm to 10 milliohm. The ADC sampling rate is changed to 100KHZ, the reading is more stable, and the linearity is better. The video sampling rate is 100KHZ, the reading is stable and the linearity is better. Below is the result of the sampling rate 100KHZ. 20230404 updated the battery-powered version video and drew a battery-powered version PCB. 2023-04-11 updated the reduced power version program and circuit. The reduced power version test video circuit only needs to replace the 10 ohm sampling resistor with three 100 ohm resistors in parallel, and the 100 ohm sampling resistor with three 1K ohm resistors in parallel. The power amplifier part can use only two transistors and the other two in parallel can be removed. The program is changed to 33333 characters, and the gears are 0-33 milliohms (33.3 mA), 33 milliohms-333 milliohms (33.3 mA), 333 milliohms-3.33 ohms (3.33 mA), 3.33 ohms-33.3 ohms (3.33 mA), 33.3 ohms-333 ohms (3.33 mA). The stability is poor and the reading jumps greatly. The current calibration method is relatively simple, and the calibration is troublesome and too slow to press one by one. Only when someone is willing to copy it will they write a linearity calibration program. The current calibration method wants the lowest gear micro-ohm level to be calibrated first, for example, 10 milliohms should be adjusted, and then the first zeroing mode should be cleared before calibration, and then clamped, for example, 200 micro-ohms. This time, the calibration mode cannot be adjusted, and the short-circuit zeroing mode should be adjusted to the same size as 200 micro-ohms. The calibration mode is relatively slow to adjust and you need to be patient. Measure 100 microohm resistance Measure 200 microohm resistance Measure 300 microohm resistance Measure 500 microohm resistance
 

 

 
 
 

 
 


 

 


 

 

 

 

 

 
 

 
 
 
 
 
 
 
 
 
 
 
 
 
 

 


 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 



 
 
 
 
 
 
 





 
 
 

 
 

 
 

 
 

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
参考设计图片
×
 
 
Search Datasheet?

Supported by EEWorld Datasheet

Forum More
Update:2025-05-08 21:02:26

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
community

Robot
development
community

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号