示例#1
0
        public static string SendTextCommand(this XDevkit.IXboxConsole xbc, string Command)
        {
            uint   connection = xbc.OpenConnection(null);
            string response   = "";

            xbc.SendTextCommand(connection, Command, out response);
            if (!(response.Contains("202") | response.Contains("203")))
            {
                return(response);
            }
            try
            {
                string line = "";
                xbc.ReceiveSocketLine(connection, out line);
                if (line.Length > 0)
                {
                    if (line[0] == '.')
                    {
                        return(response);
                    }
                    response = response + Environment.NewLine + line;
                }
            }
            catch
            {
            }
            return("FAIL");
        }
示例#2
0
 public static void Unfreeze(this XDevkit.IXboxConsole xbc)
 {
     xbc.SendTextCommand("go");
 }
示例#3
0
 public static void Reboot(this XDevkit.IXboxConsole xbc)
 {
     xbc.SendTextCommand("reboot");
 }