By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,249 Members | 1,588 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,249 IT Pros & Developers. It's quick & easy.

How do you read data from a USB port?

P: n/a
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?
Nov 21 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
reffer to the BarCode readers documentation.

If I had to wager , windows should recognize the BCR as an input device &
may simply 'type' the codes in as if they came from a keyboard when
scanned..........


"Darrell Wesley" <Da***********@discussions.microsoft.com> wrote in message
news:14**********************************@microsof t.com...
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?

Nov 21 '05 #2

P: n/a
reffer to the BarCode readers documentation.

If I had to wager , windows should recognize the BCR as an input device &
may simply 'type' the codes in as if they came from a keyboard when
scanned..........


"Darrell Wesley" <Da***********@discussions.microsoft.com> wrote in message
news:14**********************************@microsof t.com...
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?

Nov 21 '05 #3

P: n/a
You cannot read from a USB port the way you can from a serial or parallel
port. You must open a handle to the device attached to the USB. To do that
you need to know information about the device from the manufacturer or what
standard interface class it uses.

Marc Reinig
System Solutions

"Darrell Wesley" <Da***********@discussions.microsoft.com> wrote in message
news:14**********************************@microsof t.com...
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?

Nov 21 '05 #4

P: n/a
You cannot read from a USB port the way you can from a serial or parallel
port. You must open a handle to the device attached to the USB. To do that
you need to know information about the device from the manufacturer or what
standard interface class it uses.

Marc Reinig
System Solutions

"Darrell Wesley" <Da***********@discussions.microsoft.com> wrote in message
news:14**********************************@microsof t.com...
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?

Nov 21 '05 #5

P: n/a
Bar code scanners that have a USB interface normally work one of two
ways.
The first is that the scanner will identify itself as a "keyboard"
device to Windows and when you scan a bar code, the data will go into
the PC as if it were being typed in on the keyboard.
The second way that they can work is to emulate a COM port. If your
bar code scanner came with a "driver" disk, then this is most likely
how it works. After you install the driver and connect the scanner to
the PC, Windows will think that it has another COM port. The COM port
will actually be a "virtual" com port that was created by the driver
and you would then need to run software that open the new virtual COM
port to read in the data from the scanner. One product that is
designed for this is called BC-Wedge and you can download a demo
version of it from:
http://www.taltech.com/products/bcwedge.html

BCWedge is a "software wedge" program that runs in the background and
opens up a COM port (either a real COM port or a Virtual COM port) and
when it receives data from the COM port (i.e. when you scan a bar code
with your bar code scanner) it feeds the data to other Windows
programs by stuffing the keyboard buffer so that the data appears as
if it is being typed in on the keyboard.

You may want to check the documentation that came with your USB bar
code scanner to find out exactly how it is designed to work.

On Wed, 10 Nov 2004 12:53:03 -0800, "Darrell Wesley"
<Da***********@discussions.microsoft.com> wrote:
Is there a good source of information on how to read a USB port, in
particular reading data from a BarCode reader?


Nov 21 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.