ADB常用命令

/*/
/通用/
/
/
//打开权限
adb root
adb remount

//查看设备
adb devices

//抓取当前cpu信息
adb shell cat proc/cpuinfo

//重启
adb reboot

//抓取 log
adb logcat

//暂停抓取log
鼠标左键

//停止抓取log
Ctrl+c

//log筛选 (abcdef为需要筛选的字符串)
adb logcat | findstr adbcef
adb shell cat /proc/kmsg | grep “string”

//清空并重定向到a.log
adb shell cat /proc/kmsg | grep “string” > a.log
adb logcat > a.log

//拍照
adb shell input keyevent 27

//
/Qualcomm
/
/
*/
//8909/8916 开3Alog信息
adb shell setprop persist.camera.mobicat 2
adb shell setprop persist.camera.stats.debug.mask 3080207
adb shell setprop persist.camera.stats.tintness enable

//tintness
adb shell setprop persist.camera.stats.tintness enable //使能tintness
adb shell getprop persist.camera.tintless enable //获取是否打开

//adb 抓log命令 gain color_temp 关键字
logcat | grep final //awb 最终
logcat | grep simple //标点
logcat | grep color_temp //AWB 色温
logcat | grep final-awb-decision //光源
logcat | grep real_gain //查看当前的gain值
logcat | grep linecnt //查看曝光行
logcat | grep exp_index
logcat | grep green-percent //green zone

// so路径
8x12/8x10/8x26/8916/8909 push /system/vendor/lib
8x25 push system/lib/

内核:adb shell cat /proc/kmsg > path/xxx.txt
用户层:adb logcat -v time > path/xxx.txt

adb shell setprop persist.camera.stats.debug.mask 7 //开log
adb shell setprop persist.camera.stats.debug.mask 1 //aec
adb shell setprop persist.camera.stats.debug.mask 2 //awb
adb shell setprop persist.camera.stats.debug.mask 4 //af
adb shell setprop persist.camera.stats.debug.mask 8 //asd
adb shell setprop persist.camera.stats.debug.mask 16 //afd

8909/8916 enable exif 3a information
adb root
adb remount
adb shell chmod 777/data
adb shell setprop persist.camera.mobicat 2
adb shell setprop persist.camera.stats.debug.mask 3080192
adb shell sync

//fastboot
使用adb shell
reboot bootloader

fastboot flash boot boot.img
fastboot flash system system.img
fastboot reboot

删除文件:

adb shell rm <文件名>
adb shell rm -rf <路径文件>

文件传输:
adb push <电脑路径> <设备路径>
adb pull <设备路径> <电脑路径>
./:当前路径
… :上级路径

抓通道:
adb logcat | find “FillTuningModeData”

Camx日志由属性控制,具体也是一套规则,首先获取权限:
adb root
adb remount
如果remount报错:failed: Read-only file system,
则执行:
adb disable-verity
adb reboot 解决,然后重新
adb root
adb remount

开dump:
adb root
adb remount
adb shell mkdir /sdcard/Android/data/com.oplus.camera/files
adb shell mkdir /sdcard/Android/data/com.oplus.camera/files/spdebug
adb shell setprop persist.sys.assert.panic true
adb shell setprop persist.sys.dump.aps 3
adb shell setprop persist.camera.llhdr.iso 0
adb shell setprop persist.camera.llhdr.ev0 1000
adb shell setprop persist.camera.llhdr.ev1 1000
adb shell setprop persist.camera.llhdr.ev2 1000
adb shell setprop persist.camera.llhdr.drc 0
adb shell setprop persist.camera.llhdr.ispgain 0
adb shell setprop persist.camera.hdr.iso 0
adb shell setprop persist.camera.hdr.ev0 1000
adb shell setprop persist.camera.hdr.ev1 1000
adb shell setprop persist.camera.hdr.ev2 1000
adb shell setprop persist.camera.hdr.drc 0
adb shell setprop persist.camera.hdr.ispgain 0
pause

拉dump:

adb root
adb remount
adb pull sdcard/Android/data/com.oplus.camera/files/spdebug ./

push参数:

adb root

adb remount

echo --------------push so--------------
set dir=%~dp0
for /r %dir% %%s in (*.bin) do (
echo %%s
adb push %%s /odm/lib64/camera
rem save %%s
)
echo ---------restarting cameraserver-------------
adb shell input keyevent 3
rem for /f “tokens=2” %%a in (‘“adb shell ps -A| findstr mediaserver”’) do adb shell kill %%a
rem for /f “tokens=2” %%a in (‘“adb shell ps -A| findstr mm-qcamera-daemon”’) do adb shell kill %%a
for /f “tokens=2” %%a in (‘“adb shell ps -A| findstr android.hardware.camera.provider@2.4-service_64”’) do adb shell kill %%a
rem for /f “tokens=2” %%a in (‘“adb shell ps -A| findstr camera”’) do adb shell kill %%a
timeout /t 5 /nobreak>nul
pause

给手机开启对应开关:
1.创建 camxoverridesettings.txt文件
2.将对应的开关写入该文件:
enableTuningMetadata=TRUE //开启3Alog信息
enable3AdebugData=TRUE //开启3Alog信息
dumpsensorEEPROMData=TURE//dump OTP。
Reprocessdump=TRUE//dump raw。
debugDataSizeAEC=6000//开启AEC信息

3.将camxoverridesettings.txt文件 push到手机以下路径:vendor/etc/camera:
adb push camxoverridesettings.txt’spath vendor/etc/camera
查看camxoverridesettings.txt内容:
adb shell cat vendor/etc/camera/camxoverridesettings.txt

adb push bin 文件进入手机:

adb push bin文件 vendor/lib64/camera

检查是否push成功:
adb shell
Cd vendor/lib64/camera
Ls -l | grep abra (筛选adra的文件 即bin文件)
修改时间为最新时间 push成功

Dump OTP:
adb pull data/vendor/camera <电脑路径>
杀死相机进程:
adb shell ps -A | findstr camera//查看相机相关进程

Adb shell kill [pid]//将第一个pid杀死

减少系统功耗

adb root
adb shell “echo 40000 >> /sys/class/thermal/thermal_zone26/trip_point_0_temp”

ADB获取高通usecase:

1.将以下三条指令写进camxoverridesettings.txt
logInfoMask=0xff
logVerboseMask=0xff
systemLogEnable=TRUE

2.将camxoverridesettings.txt文件 push到手机以下路径:vendor/etc/camera
adb push camxoverridesettings.txt’spath vendor/etc/camera

adb root
adb remount
adb shell " logcat | grep ‘PopulateGeneralTuningMetadata’ "
(或者:adb logcat | find “PopulateGeneralTuningMetadata”)
//抓取PopulateGeneralTuningMetadata关键字

photo预览: sensor 0 usecase 0
photo:sensor 0 usecase 1
video预览:sensor 0 usecase 2
Video:sensor 0 usecase 2

  • 0
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值