|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Bar codes. They're little bunches of black lines which can be read by a
scanner. Right?
Hahaha, well... it turns out there are actually a miriad of different
kinds. And they're ALL COMPLETELY DIFFERENT to each other.
I just did a cursory scan of my office. Here's what I found:
Fruit bottle: EAN-13 barcode.
Can of Dust-off: UPC-A barcode.
Diary: EAN-13 barcode.
SIIG USB-serial box: UPC-A barcode plus one of unknown type.
StarTech USB-serial box: UPC-A barcode.
Imation CD-R box: UPC-A barcode.
Maxtor drive: 5 barcodes of unknown type.
Integral RAM box: One barcode (from Insight UK) of unknown type.
TNT shipping box: Two barcodes of unknown type.
Gobel, Escher, Bach: EAN-13 barcode.
Integral USB HD box: EAN-13 barcode.
Other USB HD box: EAN-13 barcode.
HP laptop adaptor: 3 barcodes of unknown type.
It's actually surprisingly hard to find barcodes. Usually you purposely
ignore them, so when you *want* to see them they're actually quite hard
to find.
It's great fun. EAN-13 is apparently an "extension" of UPC-A, and yet
it's COMPLETELY DIFFERENT. The encoding is entirely unrelated. Of
course, EAN-13 and UPC-A only encode digits. (And these digits encode a
manufacturer ID and product ID.) Other codes can encode various
additional characters. In particular, Code39 and Code128 allow text as
well as digits.
The impressive thing is, as far as I can tell, almost all barcode
scanners support almost all kinds of barcodes. Even though each coding
scheme is utterly unrelated to any of the others. God only knows how
this is physically possible...
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
On 10/13/2009 10:23 AM, Invisible wrote:
> scheme is utterly unrelated to any of the others. God only knows how
> this is physically possible...
usually using a diode laser, a rotating mirror and a photo sensor, which
turns photons into electrons, where the circuitry then interprets the
variations of electron flow into digital signals, which is then
processed by a processor, running software that can interpret the
encoding schemes of many different types of barcodes. It then sends
signals (either by RS-232 or USB protocol) to the computer, a device
driver reads the incoming signal, and interprets the signals as a series
of characters, output to the desired application.
--
~Mike
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Isn't there some bars at the beginning or the end that indicate the encoding ?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Invisible schrieb:
> The impressive thing is, as far as I can tell, almost all barcode
> scanners support almost all kinds of barcodes. Even though each coding
> scheme is utterly unrelated to any of the others. God only knows how
> this is physically possible...
Not much magic in there.
Barcodes are designed to have a lot of redundancy, so that reading
errors can be detected.
So a barcode scanner just checks whether the code it just read makes
sense (i.e. check digits match etc.) when interpreted as any of the
codes it supports.
Conflicts seldom occur /because/ the barcodes are so dissimilar. Still,
it is a good idea to configure the scanner to recognize only barcodes
you actually expect to use, especially if you expect to work with
barcodes that may be smudged or otherwise messed up.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Gyscos schrieb:
> Isn't there some bars at the beginning or the end that indicate the encoding ?
No, not really. Though many barcodes include some "frame" to (a)
identify the side at which the barcode starts, and/or (b) calibrate for
the size of the barcode; such frames can often double-act to prevent
misinterpreting other barcode types.
For instance, Code39 IIRC always starts and ends with the bars it uses
for the Asterisk (*).
EAN-13, on the other hand, uses one pair of simple bars at the
beginning, end, and in the middle, respectively, to calibrate for size,
while the reading direction can unambiguously be inferred from any
"character" of the barcode "payload".
But these "frames" are only standardized for each individual barcode
type, and there is no universal scheme to identify the type. All you can
do is test for which types of barcode this particular specimen reads
without error.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> It's great fun. EAN-13 is apparently an "extension" of UPC-A,
Those are used in supermarkets mainly, which is why you find them on all
products sold to the public.
For non-public uses (eg on shipping cartons, internal parts of products etc)
the company is obviously free to make up or use their own standard for the
bar code. You didn't find any 2D barcodes?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
scott wrote:
>> It's great fun. EAN-13 is apparently an "extension" of UPC-A,
>
> Those are used in supermarkets mainly, which is why you find them on all
> products sold to the public.
Yeah, apparently UPC-A is for America, EAN-13 is supposedly for
everywhere, but almost all scanners support both. They can only encode
numbers though - usually standardised product codes.
> For non-public uses (eg on shipping cartons, internal parts of products
> etc) the company is obviously free to make up or use their own standard
> for the bar code.
Yeah, the shipping box I've got has several extremely wide barcodes.
These codes encode letters as well, but I can't determine exactly which
system they are. (Assuming they're even a standard one...)
> You didn't find any 2D barcodes?
None.
However... The Royal Mail allow you to print your own stamps, for a fee.
You give them money, they give you a PDF file containing a 2D barcode
[which presumably encodes the date of purchase, since it apparently
expires after so many days].
Now I'm thinking... it appears to be a standard Data Matrix barcode, so
if I could figure out WTF the data encoded in it is, I could print as
many of them as I like, without a fee...
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Interesting fact: I actually have a barcode scanner here. Specifically,
our tape robot has a barcode scanner. We've never used it, but
apparently our Director of IT has suddenly decided that we're going to.
In a few days' time I should have a stack of preprinted barcode labels.
I wonder what kinds the scanner can read?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Now I'm thinking... it appears to be a standard Data Matrix barcode, so if
> I could figure out WTF the data encoded in it is, I could print as many of
> them as I like, without a fee...
Won't they encode a serial number in there? As soon as they detect a 2nd
stamp in the system with the same serial number (or with one they know they
haven't sold yet) there will be trouble.
Also it probably has some checksum, you'd need a shed load of stamps to
figure it out probably.
And hope they don't encode your IP address or payment details in there too.
A bit like that system on Blu-Ray discs, where every player plays back a
very slightly different version, so when someone rips and uploads to
BitTorrent, they can tell exactly which player it was ripped from.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
>> Now I'm thinking... it appears to be a standard Data Matrix barcode,
>> so if I could figure out WTF the data encoded in it is, I could print
>> as many of them as I like, without a fee...
>
> Won't they encode a serial number in there? As soon as they detect a 2nd
> stamp in the system with the same serial number (or with one they know
> they haven't sold yet) there will be trouble.
Yeah, this is probably the main problem. If they know which numbers
they've actually sold and which ones have actually been used, there's
not much you can do.
> Also it probably has some checksum, you'd need a shed load of stamps to
> figure it out probably.
Well, if you were going to reverse-engineer it, sure. But if you could
figure out the algorithm...
It's like Windows license keys. Each one is a 20-character alphanumeric
string. There must be some algorithm that Windows uses to decide whether
the key you just entered is valid. If you somehow knew what that
algorithm is.......
> And hope they don't encode your IP address or payment details in there too.
If you *knew* how they generate the barcode, you could put an arbitrary
IP address in there. (Besides, knowing somebody's IP address doesn't
really tell you a whole heap.) Payment details might be more fun...
> A bit like that system on Blu-Ray discs, where every player plays back a
> very slightly different version, so when someone rips and uploads to
> BitTorrent, they can tell exactly which player it was ripped from.
Really? That's news...
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |