Ejemplo n.º 1
0
        /// <summary>
        /// when device is not specified all usb devices will be watched
        /// during the start only active devices are sent to WatchMessage event
        /// </summary>
        /// <param name="device"></param>
        /// <returns></returns>
        public static UsbWatcher Create(BcDeviceType device = null)
        {
            DeviceWatcher watch = device != null?DeviceInformation.CreateWatcher(device.DeviceSelector) : DeviceInformation.CreateWatcher();

            return(new UsbWatcher(watch));
        }
Ejemplo n.º 2
0
 private BcSerialPort(string com, BcDeviceType type)
 {
     Com        = com;
     DeviceType = type;
 }