How to send data using USB Port ?  
Author Message
Nody Online





PostPosted: Visual C# General, How to send data using USB Port ? Top

Hi

I am developing a program and I need to send data using USB port , but I could not find a class as the one for Serial Port to use it to transfer data.

So I searched on the Net for any USB class but I didn't find.

Can anyone help




Visual C#4  
 
 
swemaniac





PostPosted: Visual C# General, How to send data using USB Port ? Top

As low level IO isn't a part of .NET you'll have to look for C++ wrapper classes, as I googled a bit I found some interesting articles and threads. Maybe you already read them, but anyways:

http://www.thescripts.com/forum/thread253550.html
http://www.developerfusion.co.uk/show/4392/
http://www.vsj.co.uk/articles/display.asp id=600

Cheers

 
 
Evan Mulawski





PostPosted: Visual C# General, How to send data using USB Port ? Top

Try using DriveInfo and DriveType to identify Removable Storage, then get the drive letter and use File.Copy or File.Move to send the file.

 
 
ahmedilyas





PostPosted: Visual C# General, How to send data using USB Port ? Top

regarding serial port transfers, in .NET 2.0 there is a System.IO.Ports namespace, which allows you to connect to serial port and transfer data to/from the device. I'm no expert on this but thought I would let you know. There are plenty examples on the forums as well as in the MSDN docs ;-)

 
 
Nody Online





PostPosted: Visual C# General, How to send data using USB Port ? Top

Thanks for help