每个ocd数据对应一个索引值。 您可以使用index获取ocd数据。 OCD指标值
枚举如下所示。

enum ocd_lockable_table
{magic_number = 0, //ocd.index.0
magic_number_factory = 1, //ocd.index.1
revision = 2, //ocd.index.2 and so on...
system_ocd = 3,
modem = 4,
gps = 5,
module_sn = 6,
board_sn = 8,
product_sn = 10,
wifi_mac_ap = 12,
wifi_mac_sta = 13,
wifi_mac_p2p = 14,
wifi_cy_code = 15,
bt_mac = 16,
barcode = 17,
wifi_mac_go = 18,
ocd_last_stc, //Hold this in the last item
};

读取与设置ocd值

Get OCD in adb console terminal
getprop ro.ocd.index.5
Set OCD in adb console terminal (no need prefix ro.)
setprop ocd.index.5 123
Get OCD in framework layer
SystemProperties.get(“ro.ocd.index.5”, “0”)

ocd值含义

Member name Significance
magic_number This magic number represents the existence of a successfully programmed OEM configuration data
magic_number_factory This magic number indicate factory mode flag present or not. If this item equal 0x 5A12E7A5 then go to normal mode, otherwise go to factory mode
revision OEM configuration data version If the table format changes or if add more member into structure, this version number can be incremented to keeptrack of the changes.
system Reserved.
modem Indicate which types of modem to be used. Zero means that ignore this item.
gps Indicate which types of GPS to be used. Zero means that ignore this item.
module_sn Module serial number. It is a one-dimensional array of characters which is terminated by a null character ‘\0’. Zero means that ignore this item.
board_sn Board/PCB serial number. It is a one-dimensional array of characters which is terminated by a null character ‘\0’. Zero means that ignore this item.
product_sn Product serial number. It is a one-dimensional array of characters which is terminated by a null character ‘\0’. Zero means that ignore this item.
wifi_mac_ap Wi-Fi MAC address for AP/STATION/P2P mode. It is a one-dimensional array of characters which is terminated by a null character ‘\0’. Zero means that ignore this item. Example: 001345B9860D
wifi_mac_sta 同上
wifi_mac_p2p 同上
wifi_cy_code Wi-Fi Country Code. Example: TW , US , BE …
bt_mac Bluetooth MAC address. Example: 003A856D7F90
barcode Indicate which types of barcode to be used. Zero means that ignore this item.
wifi_mac_go P2P group mac.

adb shell读取设置手机ocd值以及ocd介绍相关推荐

  1. adb shell读取返回值_如何在ADB shell中读取耳机状态和读取ACCDET寄存器

    如何在ADB shell中读取耳机状态和读取ACCDET寄存器 录入:edatop.com    点击: [Description] 如何在ADB shell中读取耳机状态和读取ACCDET寄存器 [ ...

  2. adb shell读取返回值_android代码执行adb shell终端命令(linux命令)并返回执行结果...

    在做Android开发板相关的开发需求的时候,我们有的时候需要去到Android系统的一个linux终端(adbshell)里面来执行一些命令,以便于查看部分文件内容或者修改部分文件权限等需求,通常我 ...

  3. linux获取android界面,Android中 adb shell ps 查看手机中进程信息

    adb shell 进入手机后,执行ps就能显示手机里所有正在运行的进程. 一.ps命令详细说明 1,ps的命令参数:-t -x,-P,-p,-c [pid|name] -t显示进程下的线程列表 -x ...

  4. Android中 adb shell ps 查看手机中进程信息

    adb shell 进入手机后,执行ps就能显示手机里所有正在运行的进程. 一.ps命令详细说明 1,ps的命令参数:-t -x,-P,-p,-c [pid|name]  -t显示进程下的线程列表   ...

  5. 【Shell】设置变量默认值,参数默认值, 自动赋值

    设置变量默认值,参数默认值, 自动赋值 转自:https://zhuanlan.zhihu.com/p/98636736 默认参数(变量默认值) if 繁琐方式 if [ ! $1 ]; then$1 ...

  6. adb shell读取返回值_shell学习笔记03(函数amp;shell工具amp;面试题)

    自定义函数 1.基本语法 [ function ] funname[()] {Action;[return int;] } funname 2.经验技巧 (1)必须在调用函数地方之前,先声明函数,sh ...

  7. mark:adb命令读取安卓手机文件安装apk获取运行日志

    一.预置条件 二.adb命令行查询文件夹 1.adb devices查询链接设备列表 2.adb -s RFCNC0V712R shell 打开shell 找到文件路径后记录下来,使用pull命名获取 ...

  8. 通过adb shell命令切换手机的输入法

    ime   enable:使输入法可用 ime  set :设置输入法 一.命令:切换到自定义的输入法, shell@android:/ $ ime enable mycom.speaking.app ...

  9. adb shell常用命令收录

    一.文件操作相关命令 1.文件操作命令 子命令 参数 说明 cd 无 进入目录 cat [-beflnstuv] [-B bsize] [file...] 查看文件内容 -n:显示行号 -b:显示行号 ...

  10. 详解adb shell 常用命令

    一.文件操作相关命令 1.文件操作命令 子命令 参数 说明 cd 无 进入目录 cat [-beflnstuv] [-B bsize] [file...] 查看文件内容 -n:显示行号 -b:显示行号 ...

最新文章

  1. [算法] 2-4 组合游戏
  2. 如何保存一个函数_如何表达一个“分段函数”之学习Matlab Function模块
  3. delphi 常用属性/方法《转》
  4. 键盘enter按钮出发登陆事件
  5. java 使按钮被选中_java – 让我的单选按钮在Android中被选中
  6. Apache 虚拟主机
  7. [论文阅读] Cross-layer feature pyramid network for salient object detection
  8. 纯新手DSP编程--5.21--DSP/BIOS使用
  9. arduino 中断 串口_【Arduino教程】第一讲:Arduino是什么?
  10. java axis_Java 使用Axis实现WebService实例
  11. java/php/net/python大学生就业管理系统设计
  12. C#编程总结(四)多线程应用(进度条的编程问题)——转自http://www.cnblogs.com/yank/p/3232955.html...
  13. e470c拆机图解全拆 thinkpad_e470c拆机图解全拆 thinkpad_THINKPAD e470硬盘拆解教程是?...
  14. 混淆矩阵 confusion matrices
  15. 普通人在家做什么兼职工作(推荐5个可以在家做的副业)
  16. 程序员数学(18)–平行四边形
  17. 计算机营销专业,计算机营销专业自我评价
  18. 逻辑回归分类器(linear_model.LogisticRegression)
  19. C1认证学习笔记(第四章)
  20. Flutter 生成 Icon 提示徽标 Widget

热门文章

  1. XML基础知识及四种解析方法
  2. 如何用matlab对两个行向量作图_matlab 绘图与图形处理(二)
  3. Android 圆形头像控件CircleImageView
  4. JS将unicode码转中文方法
  5. dwg怎么转换成html,web html页面显示autocad等dwg格式图形文件方法
  6. 盘是什么意思计算机网络,hdd网络上什么意思
  7. 微信企业转账到银行卡
  8. Short Pairing-based Non-interactive Zero-Knowledge Arguments
  9. 《Beyond Part Models: Person Retrieval with Refined Part Pooling 》PCB论文解读
  10. linux Ubuntu 安装的搜狗双拼输入法只有五笔解决办法附安装教程