Example #1
0
 public bool ControlTransfer(IntPtr InterfaceHandle, WINUSB_SETUP_PACKET SetupPacket,
                             byte[] Buffer, int BufferLength, ref int LengthTransferred, IntPtr Overlapped)
 {
     return(WinUsb_ControlTransfer(InterfaceHandle, SetupPacket, Buffer, BufferLength, ref LengthTransferred,
                                   Overlapped));
 }
Example #2
0
 private static extern bool WinUsb_ControlTransfer(IntPtr InterfaceHandle, WINUSB_SETUP_PACKET SetupPacket,
                                                   byte[] Buffer, int BufferLength, ref int LengthTransferred, IntPtr Overlapped);
Example #3
0
 public static bool ControlTransfer(IntPtr InterfaceHandle, WINUSB_SETUP_PACKET SetupPacket,
     byte[] Buffer, int BufferLength, ref int LengthTransferred, IntPtr Overlapped)
 {
     return WinUsb_ControlTransfer(InterfaceHandle, SetupPacket, Buffer, BufferLength, ref LengthTransferred,
         Overlapped);
 }
Example #4
0
        protected bool SendTransfer(byte requestType, byte request, ushort value, byte[] buffer, ref int transfered)
        {
            if (!IsActive) return false;

            var setup = new WINUSB_SETUP_PACKET
            {
                RequestType = requestType,
                Request = request,
                Value = value,
                Index = 0,
                Length = (ushort)buffer.Length
            };

            return Usb.ControlTransfer(_winUsbHandle, setup, buffer, buffer.Length, ref transfered, IntPtr.Zero);
        }
Example #5
0
 private static extern bool WinUsb_ControlTransfer(IntPtr InterfaceHandle, WINUSB_SETUP_PACKET SetupPacket,
     byte[] Buffer, int BufferLength, ref int LengthTransferred, IntPtr Overlapped);