您的位置:首页 > 其它

通过ADB口,实现设置和读取MAC地址

2015-06-04 14:09 351 查看
read and write MAC through ADB

Android APP of setting the MAC

@echo designed by Herman.Xu

color 0A

echo===========Start to modify MAC address===========

echo.设置MAC地址输入w,读取MAC地址输入r

set /p choice=输入开启的版本(w r):

if "%choice%"=="w" goto writeMac

if "%choice%"=="r" goto readMac

:writeMac

cls

echo.请输入你要设置的MAC地址,注意格式不要空格,比如:00:01:02:03:04:05

set /p macaddress=

adb shell "echo MAC=%macaddress% > /data/system/eth0-macaddress.conf"

#adb shell "echo MAC=%macaddress% > /data/system/.svn/text-base/eth0-macaddress.conf.svn-base"

echo.回车重启,设置的MAC地址生效

pause

adb reboot

:readMac

adb pull /data/system/eth0-macaddress.conf C:\

set /p a=<C:\eth0-macaddress.conf

echo.%a%

pause
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: