How to get the data from a USB port in VB.NET

久未见 提交于 2019-11-27 23:07:30
John Woo

Here is what I found. You use the HID.dll to interface the usb ports. And you know the best part? I found some examples.

Here's a link that contains basic examples and tutorial for usb interfacing. The HID Page

Sample Project File

You loop those : IO.DriveInfo.GetDrives() and check where DeviceType = IO.DriveType.Removable then the device name to use it copying data or other stuff

for details check this out : Detect USB drive

Abhilash (I only asked this question)

I am adding this, Just to let you people know, my current understanding about the topic...

I actually asked for the question from one of my know person....

He explained me this:-

There are basically two ways to get data from an external instrument. The fist method is to use the software than came with the instrument. If the instrument has an interface of any type, there should be some software that reads the data. You can use this software to store the data to a file and your application will read a file with s fixed structure. very simple.

If the instrument provides a serial port but no software, then you can use the My.Computer.Port namespace to access the instrument's serial port. It's easy to send commands to a serial port and read back the response, but you have to know the commands that the other end recognizes. You will need detailed documentation about the device, which you will most likely find on the Internet.

The first approach is always preferrable. Of course, you have to associate the data with patients. This can be tricky. If you can find the software that allows you to download data from the instrument to your computer, it will be straightforward to acquire the data. Since someone must connect the device to a computer, they can also start the application and save the data to a file.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!