1# syspara系统属性组件<a name="ZH-CN_TOPIC_0000001081867232"></a> 2 3- [简介](#section469617221261) 4- [目录](#section692981610397) 5- [约束](#section741841418125) 6- [使用说明](#section1464106163817) 7- [相关仓](#section641143415335) 8 9## 简介<a name="section469617221261"></a> 10 11系统属性组件,根据OpenHarmony产品兼容性规范提供获取设备信息的接口,如:产品名、品牌名、厂家名等,同时提供设置/读取系统属性的接口。 12 13## 目录<a name="section692981610397"></a> 14 15``` 16base/startup/syspara_lite/ # 系统属性组件 17├── frameworks # 系统属性组件源文件目录 18├── hals # 系统属性组件硬件抽象层头文件目录 19└── interfaces # 系统属性组件对外接口目录 20``` 21 22## 约束<a name="section741841418125"></a> 23 24- 使用C语言开发。 25- 同时支持轻量系统设备(参考内存≥128KB),如Hi3861V100以及小型系统设备(参考内存≥1MB),如Hi3516DV300、Hi3518EV300。 26- 系统属性各字段由OEM厂商负责定义,当前方案仅提供框架及默认值。具体值需产品方按需进行调整。 27 28## 使用说明<a name="section1464106163817"></a> 29 30获取系统属性 31 32``` 33char* value1 = GetDeviceType(); 34printf("Device type =%s\n", value1); 35free(value1); 36char* value2 = GetManufacture(); 37printf("Manufacture =%s\n", value2); 38free(value2); 39char* value3 = GetBrand(); 40printf("GetBrand =%s\n", value3); 41free(value3); 42``` 43 44修改系统版本号 45 46``` 47系统版本号参数定义在startup_init_lite仓库的/services/etc/param/ohos.para文件 48const.product.software.version参数的值即为展示的系统版本号 49等同于之前修改宏OHOS_DISPLAY_VERSION[]的值 50``` 51 52## 相关仓<a name="section641143415335"></a> 53 54[启动恢复子系统](https://gitee.com/openharmony/docs/blob/master/zh-cn/readme/%E5%90%AF%E5%8A%A8%E6%81%A2%E5%A4%8D%E5%AD%90%E7%B3%BB%E7%BB%9F.md) 55 56**[startup\_syspara\_lite](https://gitee.com/openharmony/startup_syspara_lite/blob/master/README_zh.md)** 57 58[startup\_appspawn\_lite](https://gitee.com/openharmony/startup_appspawn_lite/blob/master/README_zh.md) 59 60[startup\_bootstrap\_lite](https://gitee.com/openharmony/startup_bootstrap_lite/blob/master/README_zh.md) 61 62[startup\_init\_lite](https://gitee.com/openharmony/startup_init_lite/blob/master/README_zh.md) 63 64