some tools for testing charger
recording the process when charging.
adb push chargingTest.sh /data
adb shell
cd /data
su
chmod a+x chargingTest.sh
./chargingTest.sh > chargingProcess.txt &
visualize the file generated by chargingTest.sh
python chargingShow.py
useful tools for analyzing the mbattery log
- python version
python 3.4
- dependency
matplotlib
re
copy
xlsxwriter
argparse
usage: mpower_tools.py [-h] [-o OUTPUT]
[-p {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}]
[-P {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}]
[-v]
logpath
positional arguments:
logpath
optional arguments:
-h, --help show this help message and exit
-o OUTPUT, --output OUTPUT
save as excel file
-p {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}, --plot {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}
plot the given argument sequentially
-P {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}, --PLOT {cc,icl,vbus,ulmt,scrn,fstchg,usoc,tsoc,vbat,ibat,usbvltg,dischg,brdtmp,battmp,usbtmp}
plot the given argument by time
-v, --version print version
python mpower_tools.py ./log -o output.xlsx
python mpower_tools.py ./log -p vbat
python mpower_tools.py ./log -P vbat