static public List <Device> GetDevices() { List <Device> devices = new List <Device>(); string cmd = String.Format("{0} -l", dicADBDebuggingCommands["devices"]); string r = CmdHelper.ExecCmd(cmd); string result = CmdHelper.GetCMDResult(r); string devicesStr = result.SubStringAfter("List of devices attached"); //c66e333b device product:dipper model:MI_8 device:dipper transport_id:51 string[] devicesStrs = devicesStr.Split(new String[] { "\r\n" }, StringSplitOptions.RemoveEmptyEntries); foreach (var deviceStr in devicesStrs) { devices.Add(new Device(deviceStr)); } return(devices); }