Exemplo n.º 1
0
        /// <summary>
        /// This function, when called upon, will reboot the Xbox Development Console.
        /// </summary>
        public void Reboot(RebootFlags reboottype)
        {
            //Determine our reboot type.
            switch (reboottype)
            {
            case RebootFlags.Warm:
            {
                SendTextCommand("reboot");
                break;
            }

            case RebootFlags.Cold:
            {
                SendTextCommand("reboot");
                break;
            }
            }
            //If we're cold booting.
            if (reboottype == RebootFlags.Cold)
            {
                //And try to disconnect.
                try { Disconnect(); }
                catch
                {
                    Console.WriteLine("Error Disconnecting");
                }
            }
        }
        public void Reboot(RebootFlags reboottype)
        {
            switch (reboottype)
            {
            case RebootFlags.Warm:
                this.SendTextCommand("reboot");
                break;

            case RebootFlags.Cold:
                this.SendTextCommand("reboot");
                break;
            }
            if (reboottype == RebootFlags.Cold)
            {
                try
                {
                    this.Disconnect();
                }
                catch
                {
                    Console.WriteLine("Error Disconnecting");
                }
            }
        }
Exemplo n.º 3
0
 /// <summary>You can shutdown the console or just reboot her according the flag selected.</summary>
 public int ShutDown(RebootFlags flag)
 {
     return(shutdown((int)flag));
 }