C:UsersSara>adb devices
* daemon not running; starting now at tcp:5037
could not read ok from ADB Server
* failed to start daemon
adb.exe: failed to check server version: cannot connect to daemon
用adb命令查看连接设备时,出现上面的报错,是由于5037端口被占用,所以查看一下占用该端口的进程,然后杀掉进程,重启adb服务
查看端口被什么应用占用的命令:netstat -ano | findstr "5037"
1528就是占用5037端口号的进程,所以需要杀死这个进程
杀掉进程的命令:taskkill -f -pid 1528
重现查看设备连接情况:adb devices