1 Star 0 Fork 5.3K

乱雪丶 / docs

forked from OpenHarmony / docs 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
writeproc.md 3.61 KB
一键复制 编辑 原始数据 按行查看 历史
wenjun 提交于 2020-09-08 10:08 . add OpenHarmony 1.0 baseline

writeproc

Command Function

This command is used to write data to a specified proc file system. The proc file system supports the input of string parameters. Each file needs to implement its own method.

Syntax

writeproc <data> >> /proc/<filename>

Parameter Description

Table 1 Parameters

Parameter

Description

Value Range

data

Indicates the string to be entered, which ends with a space. If you need to enter a space, use "" to enclose the space.

N/A

filename

Indicates the proc file to which data is to be passed.

N/A

Usage

The proc file implements its own write command. After the writeproc command is called, the input parameter will be passed to the write command.

NOTE: The proc file system does not support multi-thread access.

Example

Enter writeproc test >> /proc/uptime.

Output

OHOS # writeproc test >> /proc/uptime

[INFO]write buf is: test

test >> /proc/uptime

NOTE: The uptime proc file temporarily implements the write command. The INFO log is generated by the implemented test command.

马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/Luanxue1999/docs.git
git@gitee.com:Luanxue1999/docs.git
Luanxue1999
docs
docs
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891