Re: Talking to USB

From: Don (phoney.email_at_yahoo.com)
Date: 12/02/04


Date: Thu, 02 Dec 2004 13:19:45 GMT

Hi Thomas,

I have located the low level driver DLL but there is no documentation
in the SDK about the calls. The SDK was supplied on "as is" basis, so
I can't ask. There is a well documented TWAIN driver, of course, but I
want to use the low level commands which bypass it. The SDK enumerates
them but doesn't explain how to send them down the USB pipe.

The driver DLL has a single entry and I've disassembled it to discover
there are 9 routines in there, but finding out what they do and the
call setup is very time consuming.

I had hoped that USB has some canonical low level (very basic) comms
protocol. Of course, each device uses different commands, but I
expected the basics to be the same e.g. send command, receive command,
send byte, receive byte and status.

Don.

On Wed, 1 Dec 2004 06:03:02 -0800,
"=?Utf-8?B?VGhvbWFzIFNlZGxhY3plaw==?="
<ThomasSedlaczek@discussions.microsoft.com> wrote:

>Hi Don,
>
>there is no way to talk direct to a USB device from VB6. You will allways
>need a driver dll or a control (which hadels the driver access) between. What
>you can use depends on that device you will use and what the device
>manufacture offers. If there isnt such things offert for your device you will
>have to write it your self in C++. Or look for a different device. FTDI-chip
>(www.ftdichip.com) for e.g. offers direct driver dll for there UART and
>parallel FIFO devices. They have also a VB sample program on there web page.
>Braintechnology(www.braintechnology.de) has Active-x controlls for USB1.0 and
>USB2.0 chips from Cypress.
>
>Best regards,
>Thomas
>
>"Don" wrote:
>
>> Environment: VB6 under W98
>>
>> I have a USB hardware device I wish to program directly. The original
>> software installed a low level driver and the hardware is both
>> registered and operational.
>>
>> Now then, I'd like to have access to this device directly. In other
>> words, I'd like to enumerate all devices on the USB bus, pick the one
>> I want, and then communicate with it (send commands, get data, etc).
>>
>> So, how does one go about talking to the USB? VB6/W98 combo doesn't
>> seem to have any dedicated USB routines.
>>
>> What I need - I guess - is the USB equivalent of the MSComm control.
>> Is there such a thing as a "USB Control"? What's the canonical way of
>> talking to USB from VB?
>>
>> I did google around a bit but couldn't find anything applicable. Most
>> sites and pages I came across seem to focus on actually writing a low
>> level USB driver.
>>
>> Thanks!
>>
>> Don.
>>



Relevant Pages

  • Re: Talking to USB
    ... That Cypress/FTDI information is very good to know! ... In the meantime I found out that the supplied USB driver calls STI.DLL ... Of course, each device uses different commands, but I ...
    (microsoft.public.vb.syntax)
  • Re: Talking to USB
    ... I did locate the (USB) driver which TWAIN uses but unfortunately there ... >connected to the USB bus or to some wire: the driver is taking care about ... >> know all the low level commands and what to expect back. ...
    (microsoft.public.dotnet.languages.vb.controls)
  • Re: USB test
    ... The problem here is that USB, is not a simple interface like the serial port. ... The 'host', will normally send a packet, with a type, direction, device address, and endpoint number defined. ... At the driver 'end', there is the USB stack, and then the PC side driver, talking to this. ... In fact I'm working on a project that involves a PICDEM FS USB board and in a older project an ex-colleague was using a basic GUI to send commands to the same board. ...
    (sci.electronics.design)
  • Re: [PATCH 0/7] [RFC] Sizing zones and holes in an architecture independent manner V2
    ... RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize ... SCSI device sda: drive cache: write back w/ FUA ... usbcore: registered new driver hub ... hub 1-0:1.0: USB hub found ...
    (Linux-Kernel)
  • WARNING: at net/ipv4/tcp_input.c:2927 tcp_ack+0xd55/0x1991()
    ... I'm running the latest git kernel and I've got ... # Bus options (PCI etc.) ... # Generic Driver Options ... # USB Network Adapters ...
    (Linux-Kernel)