Ejemplo n.º 1
0
        public static void itmdTest()
        {
            Console.WriteLine("Starting ITMD Test...");
            //Console.ReadKey();
            iph = new iTMDiPhone();
            lliph = new iTMDiPhoneLL();
            try
            {
                mdv = new iPhone();
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }
            tai = new TAIiPhone();

            mdv.Connect += Mdv_Connect;
            mdv.HostAttached += Mdv_HostAttached;
            iph.Connect += Iph_Connect;
            tai.Connect += Tai_Connect;

            lliph.HostAttached += Lliph_HostAttached;

            iph.DfuConnect += Iph_DfuConnect;
            while (true)
            {
                if (mdv.attachedToHost ^ mdv.IsConnected)
                {
                    //Console.Clear();
                    //Console.WriteLine("Device attached but not paired. Enter passcode on device to pair.");
                }
            }
        }
Ejemplo n.º 2
0
 static void PowerMode()
 {
     iPhone iph = new iPhone();
     while (true)
     {
         Console.WriteLine("Power Mode:");
         Console.WriteLine("1. Enter Recovery");
         Console.WriteLine("2. Exit Recovery");
         Console.WriteLine("3. Recovery Cycle [Refresh Firmware]");
         Console.WriteLine("X. Exit");
         string c = Console.ReadLine();
         if (c == "1")
         {
             //iph.EnterRecovery();
         }
         else if (c == "2")
         {
             //iph.ExitRecovery();
         }
         else if (c == "3")
         {
             //iph.EnterRecovery();
             //iph.ExitRecovery();
         }
         else
         {
             Console.WriteLine("Exiting Advanced Mode.");
             break;
         }
     }
 }
Ejemplo n.º 3
0
 private void initPhone()
 {
     t.Stop();
     try
     {
         iph = new iPhone();
         iph.Connect += Iph_Connect;
         iph.Disconnect += Iph_Disconnect;
         label4.Text = "Waiting for devices...";
     }
     catch (Exception e)
     {
         MessageBox.Show(e.Message);
     }
     sp.Hide();
     this.Show();
 }
Ejemplo n.º 4
0
 static void normalMode()
 {
     Console.WriteLine("Waiting for device...");
     iph = new iPhone();
     //GC.KeepAlive(iph);
     iph.Connect += (sender, args) => ccallback(sender, args);
     iph.Disconnect += (sender, args) => cdallback(sender, args);
     while (true)
     { }
 }