コード例 #1
0
        void App_Startup(object sender, StartupEventArgs e)
        {
            _hasHomed = false;

            _kflop.InitDevice();
            usbController           = new UsbDevice(0x04D8, 0x0042);
            usbController.usbEvent += new UsbDevice.usbEventsHandler(usbEvent_receiver);
            usbController.findTargetDevice();
            usbController.RunBoardInit(false, 250, 250);
        }
コード例 #2
0
        void App_Startup(object sender, StartupEventArgs e)
        {
            _hasHomed = false;

            try
            {
                _kflop.InitDevice();
                usbController           = new UsbDevice(0x04D8, 0x0042);
                usbController.usbEvent += new UsbDevice.usbEventsHandler(usbEvent_receiver);
                usbController.findTargetDevice();
                usbController.RunBoardInit(false, 250, 250);
            }
            catch {
                MessageBox.Show("Error connecting to controller");
            }
        }