Can someone please provide me the sample code for USB port programming in VB6?
email: to.go @ gmx. de
There is no such thing as simply writing to a USB port in VB6. You write to devices that just happen to be on the USB port. Each device can have its own driver and therefore its own interface with VB6.
If you are thinking of writing to a USB-hosted serial port, then you would just access that port the same as if it were a legacy serial port, by name ("COM1", "COM2", etc.). So instead of trying to figure out how to talk to USB, just figure out how to call a serial port in VB6. I know how to do it in C++ using the Win32 API, but I don't know the VB6 equivalent.
Can you send your C++ implementation of USB to me?
I'm trying to do this but I'm not finding much content on the internet.
Jose Augusto Stuchi
gutousp @ gmail. com
University of Sao Paulo - Brazil
I said there is no such thing. Most people who ask for USB code are really asking for serial code to talk to a USB-to-serial converter. If this is what you want, then don't look for code for USB. Look for code for serial communication. A good place to start is Microsoft's MSDN web site:
Embedded Systems Consulting
This is merely a link to some resources. I will not support or explain the code.
Does it work the same way with a parallel port device converter to usb; Cause i have a code on C++ builder to control a device from parallel port. The same code would control the device with the converter.
I am also looking around for docs in serial communication with C++ but I cannot find anything. Is there a component in C++ like the MSCOMM in VB for serial com? If yes, what is it in C++? Can you please give me some clues or send files which can help me for a start?
I would realy appreciate that. Thanks.
Since you are using C++, you do not need an object like MSCOMM. Use the file I/O API to open, read and write a COMx port. It is not difficult.
But how do I do that Bill? I have never done port communication or such things. Can you please give the procedure and a sample of code? Thanks.
nnalarissa @ gmail. com
I also want to make project on port programming but coding must be in VB 6.0, it's a strict rule in our university.
So will you please tell me some basics about how to use the USB ports in VB? Please reply to me, it's compulsory for me... I hope you will help me...
If anybody what to use their parallel port for controlling devices, you can relay on me. I have the program in VB6. I will help you.If interested contact me.
email:staytunedfriends [at] gmail.com
Hi, if you still want a USB example for VB6, please write me at my e-mail, IŽll send back you a example in VB6 code.
Something I threw together a while back. Useful for generic playback of captured USB HID stream to devices.
Do you get any sample code for USB port programming in VB6?
plz send me any of it
If you google:vb6 com port
you quickly find your information.
What also might be of interest is
how we do it in C++:
What type of trouble you might have with USB/Serial adapters under Windows:
PS: http://pvbrowser.org together with scripting in Lua might be easier for you than Basic.
i understand about parallel ports but not bout usb ports.
like the 8 bit data is send through 8 data pins in parallel ports, then how is it done in usb port?
pls help me out this.....
Its not called a universal SERIAL port for nothing.
ok, whatever it is .... i said, i didn't have knowledge about it.
plz can you tell me something worth telling... ???
The best reference I have found to USB workings is the book "USB Complete" by Jan Axelson. But be advised that if you intend to do anything original with USB itself then you are going to have to do a lot of work - I mean years. Most people who use USB do not do anything original with it. They use manufacturer-supplied drivers for specific USB devices, like serial ports, printers, mice, and custom data acquisition equipment. Unless you are a top-level USB developer with years of experience in the field you are not going to use USB without going through one of these manufacturer-supplied device drivers, and these drivers are custom made for each device that plugs into the USB.