Beispiel #1
0
        public static KmsUsbDevice FindDevice(Int32 vid, Int32 pid)
        {
            var returnValue = new KmsUsbDevice(vid, pid);

            returnValue.FindDevice();

            return(returnValue);
        }
Beispiel #2
0
        public static KmsUsbDevice FindDeviceAsync(Int32 vid, Int32[] pids)
        {
            var returnValue = new KmsUsbDevice(vid, pids);

            returnValue.FindDeviceAsync();

            return(returnValue);
        }
Beispiel #3
0
        public KmsUsbDeviceRequestAsync(KmsUsbDevice device, KMS.Interop.Blockity.BlockityCommand <T> command)
        {
            if (device == null)
            {
                throw new ArgumentNullException("device");
            }

            if (!device.IsOpen)
            {
                throw new InvalidOperationException("Device is closed.");
            }

            m_worker.DoWork             += m_worker_DoWork;
            m_worker.RunWorkerCompleted += m_worker_RunWorkerCompleted;

            m_worker.RunWorkerAsync(new Object[] { device, command });
        }
Beispiel #4
0
 public KmsUsbDeviceFoundEventArgs(KmsUsbDevice device)
 {
     Device = device;
 }