Barcode API's (Reading, Generation)

martinmsj

[H]ard|Gawd
Joined
Mar 3, 2005
Messages
1,581
I am putting together a project to help my father at his business. In addition, I'm also building this project to use as a portfolio for the ever long job hunting race.

I've been doing searches and so far I'm just taking in everything I can. I am curious if anyone has ever worked with a Barcode API to incorporate it into your applications. I found 2 that require a licensing fee of about 2K and up. Obviously that isn't practically.


I've never worked with such an element thus I'm not sure what to expect. What I would like to happen is that I can created a barcorde image which I can then take and have a printed on an 8.5 X 11 sheet of labels. (It is going to be "fun" formating that print out.) In addition read barcodes to access data items in a database.

I don't know what to expect simply because this is a first.

OOPS:

I want to do this in either C++ or C#. I'm tempted to go java as the Sun developer forums seem to have some information.


Any information is greatly appreciated.
 
All forums have some information, I think you need to pick a language as C++ will differ GREATLY than java or C# as far as syntax, length of code, and library support goes. I'd pick a language first, It's relatively easy to get a basic reader/writer. going. I did one in PHP last year sometime and it just reads the width of the lines to determine a numeric value.
 
Well when I programmed a project that required barcodes we actually just got a hold of some barcode fonts and then when ever we printed things that required them we would use that font in the required section.
 
I'm not sure if you're required to use standard barcode format but there's a guy here at work using qrcode for a website and he's having success getting it all implemented. I'm pretty sure there is NO fee for using qrcode but don't quote me on that. It may or may not be what you're looking for but its a start... a quick google for qrcode brings up several good links.
 
I don't think you're getting very good answers; at least in part, that's because your question isn't too crisp.

What previous development experience do you have?

What are you using the bar code for? Are you going to print labels? Do you have to be compatible with an existing system or some format of labels?

How much information will you store on your bar codes? Do you need a 1D or 2D barcode?

Is your application scanning hand-held objects? Flat? With what surface? Or are you scanning something that's going by on a conveyor belt or some other product handling mechanism? Are the objects consistently oriented, or randomly positioned?

For generating bar codes, it's easy to find fonts that are free for the simpler encodings; CODE 39, for example, can just be printed using that font. Your application would then just generate the text you wanted in that font, and send it to the printer. Maybe you need to do some layout and spacing for the labels.


For reading bar codes, the code you'll write depends heavily on your hardware. There's hardware that will do a great job for random and 3D orientation applications, but it's expensive. You'll have to do some programming, and deal with misread objects. If it's just a 1D scan, you'll can buy devices off eBay which do the work and "stuff" keystrokes into your application. The CueCat is dirt cheap and easy to program, if you can find it.

Let us know when you can provide some details about your requirements, and perhaps you'll receive some more useful answers.
 
Thank you all for the responses. The language can be C++ or Java. I was preferring C++ however I'm leaning more towards Java because of an open source Barcode API called Barbeque.

I don't think you're getting very good answers; at least in part, that's because your question isn't too crisp.

What previous development experience do you have?

Nothing out of college. Although I've done some pretty extensive projects in eingeering involving programming. (DirectX/C++) I feel stronger in C++ for the simple fact that whatever I code I can have a nice stand alone package (without any debug and not having to be run through an IDE which I haven't done with Java.)

What are you using the bar code for? Are you going to print labels? Do you have to be compatible with an existing system or some format of labels?

This is a fresh start to help inventory at my fathers business. Think of this as a project to help build a portfolio. The idea is to have an application that can generate and print labels as well as scan and identify items for the purposes of keeping inventory and the like. The format of the barcode (which I presume you refer to the barcode symbology) is one that is compatible with any cheap barcode scanner I can find. (Think I found one which comes from the website you posted on Code 39, go figure.)


How much information will you store on your bar codes? Do you need a 1D or 2D barcode?

The information on the barcade will be minimal. Basically a reference number to be able to query a database with.


Is your application scanning hand-held objects? Flat? With what surface? Or are you scanning something that's going by on a conveyor belt or some other product handling mechanism? Are the objects consistently oriented, or randomly positioned?

The type of objects range from flat to round. However mostly flat. These scans will be done by hand.

For generating bar codes, it's easy to find fonts that are free for the simpler encodings; CODE 39, for example, can just be printed using that font. Your application would then just generate the text you wanted in that font, and send it to the printer. Maybe you need to do some layout and spacing for the labels.

Yes I will be doing layout and spacing for the labels. I am not looking forward to this. These are 1"X 2 5/8" labels that come in 30 per sheet. I have 2K of these that I have to make some use of. I remember being frustrated formating a simple letter to print in java. /cry

For reading bar codes, the code you'll write depends heavily on your hardware. There's hardware that will do a great job for random and 3D orientation applications, but it's expensive. You'll have to do some programming, and deal with misread objects. If it's just a 1D scan, you'll can buy devices off eBay which do the work and "stuff" keystrokes into your application. The CueCat is dirt cheap and easy to program, if you can find it.

Let us know when you can provide some details about your requirements, and perhaps you'll receive some more useful answers.



I appreciate the post. As of right now I'm trying to keep it simple as possible to have a working model. Once I feel strong about it and understand it more I'll begin working on the "meat" of it all.

I'm really liking Java more. I like that I have minimal things to worry about when dealing with the scanner (from what I read in the forums about certain aspects being transparent.) I've been busy learning ASP.NET and getting familiar with MS VWD. I admit, I'm blind to a Java program run outside of an IDE/Debugger since I've never had to do that.
 
Most barcode scanners can work in "keyboard wedge" mode. i.e., they just dump the characters to whatever has focus.

Last year I developed an app for a company for a Symbol PocketPC w/integrated barcode scanner & 802.11b for instant storage into an MSSQL database. It was pretty easy as far as .NET development goes - just capture the barcode digits into a textbox, validate and submit to a web service.

I haven't worked with printing barcodes yet, but it looks like there are some good links in this thread already.
 
Most barcode scanners can work in "keyboard wedge" mode. i.e., they just dump the characters to whatever has focus.

Last year I developed an app for a company for a Symbol PocketPC w/integrated barcode scanner & 802.11b for instant storage into an MSSQL database. It was pretty easy as far as .NET development goes - just capture the barcode digits into a textbox, validate and submit to a web service.

I haven't worked with printing barcodes yet, but it looks like there are some good links in this thread already.

Yeah, one of the barcodes I worked with recently just required that you set up (in .NET) a SerialPort connection on the appropriate COM port (and baud rate, stop bits, etc.) From there the inputs came as '\n'-delimited lines. It was rediculously easy for me to read the input and do whatever I wanted with the data (often just throwing an event that would get handled elsewhere.)

Also, I had the opportunity to work with a wireless scanner that had a dock w/ an ethernet port on the back. Same thing here--connect using TcpClient and the data is newline-delimited as it's read in via the barcode scanner.

202276


EDIT: As with most, I have little experience in generating a barcode, however Mike's comment about using a barcode-based font has merit. Some barcodes don't lend themselves well to being generated via a font due to encoding issues; however, I'm confident that you can find what you need. I've never used Barbeque (sp?) so I'm not sure what's involved to work with different standards.
 
Simple codes like 39 can be easily rendered with a font. Remember, 3-of-9 was invented for UPC scanners ... in the 70's! The biggest problem will actually be the labels; if they're too shiny, then they may be hard to read with a bargain scanner.
 
Back
Top