Search code examples
.netwindowsweb-servicesweb-applicationsbarcode-scanner

How to connect a barcode scanner in batch mode to a web application using a web service?


I have to interface my web application (RoR) with a barcode scanner, a Motorola DS3578 scanner, running in batch mode.

The way I see this is that each PC (Windows) connected with such a scanner (with craddle), runs a small program (.Net ?) that grabs the barcodes from the scanner when it's inserted into its craddle, then "dumps" these barcodes into my web application using a webservice I still have to develop.

I'm capable of writing this webservice. I haven't worked with .Net programs interfacing directly with scanners though, so that's why my question: how could I write an easy, short, .Net program doing just the communication between the scanner and the web service, preferably without any user interface. (transparent in the background) Or alternatively, does such a tool exist, ready of the shelve?


Solution

  • From the documentation, the Motorola scanner SDK seems to be very simple. And the API is available for C#, C++ and Java. A good C# API conforms to some guidelines that make it usable from any .NET language - I didn't check though. With C# it is also quite simple to use web services. I wouldn't bother to search for an off-the-shelf solution when building it yourself is so easy. With the SDK it is possible to listen to events from the scanner, thereby avoiding an additional manual interaction. You can run a .NET program as a Windows service. Samples available from the MSDN.