Results 1 to 16 of 16
-
Question regarding barcode generating
If anyone has experience with those - is it a simple function to create? i.e. can I generate valid barcodes (text and picture) within a few thousand LOCs?
Or what about if I leave the picture separate and only focus on generating a valid barcode number in my code? (the user can use other free exe files to take the number and generate a picture from it)
I saw a few free java barcode generator librarys on the web, but one of them was not actually free and the other one was 60MB file (which I'd need to be crazy to implement in my project since my project is currently only 1.5MB).
Can you point me to any good tutorial for generating valid barcodes or any good, lightweight library that I can use in my project?
thanks
- 04-17-2011, 11:46 AM #2
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
Hi ozzyman,
I am currently writing applications at work that generate bar codes and read them. The first thing you should specify is the type of bar code you need.Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
-
Hi flynn, thanks. I did notice the different names e.g EAN-13 etc, but I don't know what is the most commonly used for the project i'm working on - Point of Sale system?
I wonder if you know whats best?Last edited by ozzyman; 04-17-2011 at 11:53 AM.
- 04-17-2011, 11:53 AM #4
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
I pressume the PoS systems use the stripy bar code. Or do you need to use QR Code
Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
-
Okay, stripy (1D) barcode is definately what I need.
2D barcodes is extra and I don't think many people use it yet. That said, if having both is easy to implement then that would be a bonus.
- 04-17-2011, 12:04 PM #6
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
Ok, well I am not sure about the 1D, but I've seen some info how to generate the ones you need without other libraries. This seems pretty simple. I only work with 2D qrcodes, for which you will need separate libraries if you decide to implement them in the future. QREncode and QRDecode.
Hope any of this helps.Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
-
Ok thanks i'm gonna check out the link now, but I have another question. I plan on automatically generating a barcode when the user creates a new Product (so each Product has a barcode on the system) and then giving the user an option to print the barcode so they can stick it on the physical product (so if the system has a barcode scanner, the code can be read again, and the correct product selected from the system). So QR codes can be used. But is this the right way about doing it? I mean, barcodes aren't globally defined are they? So that - if the business sell products that aren't their own and has its own barcode - it wont interfere sort of thing?
-
Btw I found a nice site on explaining how to validate a code (which is what I actually need to generate valid codes)
EAN-13 - How To
- 04-17-2011, 12:20 PM #9
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
To generate a bar code you will have provide data to be encoded in the bar code. Now, if the product already has a bar code stuck onto it, the company that generated the bar code might have a certain format for the data encoded in their bar code. If you can decode their bar code, i.e. see in what format the data is encoded, you will now how not to encode your bar codes. Another thing, If you clearly mark your bar code, different companies will now that its not their bar code if they need to scan it. They aren't globally defined.
Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
- 04-17-2011, 12:22 PM #10
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
-
Oh right, so after the barcode is scanned with a laser it needs to be decoded first? - I'll focus on that a bit later when I buy the equipment to test my software with. For now I'll just use a 'fake' county code representing my software, and make any 'manufacturer' code based on the user (see the link i posted for the breakdown of EAN-13 codes). Then i'll set up my functions to read the code and match it to the product.
Thanks again for your help.
- 04-17-2011, 12:41 PM #12
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
Yeah, the laser scans it, your software decodes it and displays it as text. Scanner really works as a keyboard. If you have a scanner, open up excel, select a cell and scan some random codes (anything that has a bar code). You will see that the values will look as if they were just typed in very quickly.
Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
-
Ok I read a few guides about UPC/EAN codes and I think I know how to do it now and it should be pretty simple!
Each digit relates to a four-digit set of bars:
0 = 3211; 1 = 2221; 2 = 2122; 3 = 1411; 4 = 1132;
5 = 1231; 6 = 1114; 7 = 1312; 8 = 1213; 9 = 3112
each number in the four-digit set relates to the thickness of the line, 4 being highest, 1 being thinnest
Notice every four-digit code for each number adds up to 7,
so each number only takes up 7 lines.
Every EAN code starts and ends with 101, and has 01010 after 6 digits
Also the black and white bars together make up the code.
The thickness of the line has 4 standard sizes: 1, 2, 3, or 4,
so you can decode the barcode by looking at the thickness and
labelling the thickest lines "4", thinnest "1" and the other two "2" and "3".
The image i attached of the barcode can be decoded to this:
101
2221 (1)
1411 (3)
2122 (2)
3211 (0)
2221 (1)
1411 (3)
01010
1312 (7)
3211 (0)
2221 (1)
1213 (8)
1231 (5)
3211 (0)
101
Also I think the barcode scanner just gives the full code e.g.
101 [XXXX]{6} 01010 [XXXX]{5} 101
so it should be easy to decode it in java using the four-digit sets of barsLast edited by ozzyman; 04-17-2011 at 04:19 PM.
- 04-17-2011, 04:39 PM #14
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
Ahhh man this is very cool. I like the nitty gritty of how things work. :)
Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
-
Yah me too lol :). Btw after all of this....... I just noticed that all the products around me have the companies own random barcodes!! 'Random' meaning not any standard barcode, but their own private barcodes. But its still great to know how this works because now I can make my system read & scan other products and allow them to be sold.
- 04-17-2011, 04:54 PM #16
Senior Member
- Join Date
- Feb 2010
- Posts
- 128
- Rep Power
- 0
Similar Threads
-
Barcode creation
By grupobfx in forum Reviews / AdvertisingReplies: 0Last Post: 04-13-2011, 04:29 PM -
Read Barcode from Specific Area of Img & Create Fixed Size Barcode
By sherazam in forum Java SoftwareReplies: 0Last Post: 03-01-2011, 07:57 AM -
Barcode Reader
By kaotic101 in forum New To JavaReplies: 3Last Post: 01-03-2011, 05:10 PM -
Aztec 2D Barcode Recognition Support is Added in Aspose.BarCode
By sherazam in forum Java SoftwareReplies: 0Last Post: 09-16-2010, 11:54 AM -
How to create a barcode
By naveen.dpt2007 in forum New To JavaReplies: 2Last Post: 02-04-2010, 02:05 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks