Android系统SVC命令教程

svc命令,位置在/system/bin目录下,用来管理电源控制,无线数据,WIFI

?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# svc
svc
Available commands:
help     Show information about the subcommands
power    Control the power manager
data     Control mobile data connectivity
wifi     Control the Wi-Fi manager
 
# svc power
svc power
Control the power manager
usage: svc power stayon [ true | false |usb|ac]
Set the 'keep awake while plugged in' setting.
// 设置屏幕的常亮, true 保持常亮, false 不保持,usb当插入usb时常亮,ac当插入电源时常亮
 
# svc data
svc data
Control mobile data connectivity
usage: svc data [ enable |disable]
Turn mobile data on or off.
// 设置移动网络的数据是否启用
svc data prefer
Set mobile as the preferred data network
// 设置移动网络的数据优先于WIFI
 
# svc wifi
svc wifi
Control the Wi-Fi manager
usage: svc wifi [ enable |disable]
Turn Wi-Fi on or off. // 设置WIFI是否启用
svc wifi prefer
Set Wi-Fi as the preferred data network // 设置WIFI优先于移动网络的数据,一般应设置成这样,除非你刻意使用移动网络数据传输

上面的命令都要在shell中执行,需要root。

大家可以用gscript  ,然后输入这些命令做成在快捷方式放在桌面,跟那些开关软件一样方便使用。


原文:http://madgoat.cn/android_svc/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值