Forkcasting
As clear as a puddle of mud

Barcodes: Who cares? Part 1

Part 1: A bit of an introduction to barcodes

We use barcodes to track many physical things. Groceries, over-the-counter medications, computer parts, housewares, books, CDs, DVDs. Barcodes even make their way into weird places. My health card has a barcode on it, as does my library card. Even some medical samples get a barcode. Barcodes are everywhere.

An example UPC-A barcode

Recognise me?

Of these, UPC-A [1] is probably the most recognisable. This is the "Universal Product Code" and you'll see it on most things you buy day-to-day. You can even get a blood sugar monitor over-the-counter with a UPC-A barcode on it. Almost everyone has used a UPC-A barcode.

There are other barcode formats, but none quite so pervasive. Almost everything in my kitchen has (or had) one. The packaged food, the utensils, cutting boards, my kettle, my tea, that one lonely block of tofu. The only things I can think of that didn't were the loose fruit and veg.

We started using UPC-A barcodes in 1974. It took 22 years from the first barcode-like patent until the first ever UPC-A scan: a pack of gum in an Ohio store. We put people on the moon before we put barcodes on bread.

We started experimenting with barcode-like systems in the late 40s, but it (like many things) turned out to be really hard. The idea is simple: shine light on the code, measure the return signal.

But we want to use these in The Real World. The hardware needs to be cheap and the system needs to be reliable. The system includes those messy humans who hold the items to scan. This causes all kinds of problems.

People move, even when they try not to. The scanner has to be fast enough to make a person's normal shakes irrelevant. We don't always hold things just right; the code might be closer or further away, rotated or tilted away from the reader. Even upside down.

We need to barcode lots of different products. The packaging may be shiny, curved, or wrinkled. The barcode on a plastic bag of apples is going to be a hassle.

Shipping and stocking the products will occasionally damage the barcode. They're shipped a long distance, moved around in stock rooms, bumped, knocked, dropped, scrapped. It needs to be usable given all this "non-ideal" handling.

Oh, and you need to print the damn thing. You can't rely on printers for extreme precision. Ink smudges and smears. Different manufacturers use different printing technologies. The system needed to handle little differences caused by printing it.

Finally, we need to solve all of these problems with, and I cannot stress this enough, 1970s era electronics. The PDP-11 computer was released in 1970 and was about the size of a refrigerator. Microcomputers like the Altair 8088 were released after the barcode, and even they were too big. Plus, the Altair's main output was a line of LEDs and cost thousands of dollars in today's money. The Intel 8008 CPU was available, but it would've cost about 680 USD in today's money. It ran at a miniscule 200 kHz to 800 kHz. This needed something we build with basic electronics. Logic gates, flip-flips, and op-amps.

All of this is to say: Barcodes are everywhere, especially the UPC-A barcode. They solve a surprisingly difficult, and important problem. Our supermarkets would look very different if we couldn't track items the way we do. Inventory management would take far more effort and be far more error-prone. Things would probably cost more, and we'd probably spend more time waiting in checkout lines for the privilege.

Next post, I'll explore the troubled history of the barcode, it's many failed implementations (including an oddly phallic scanning wand), and how the "modern." 1970s-era barcode was born -- and survived.

[1]Technically, UPC-A is a sub-type of the broader EAN-13 stadard. All UPC-A barcodes are valid EAN-13 barcodes, but the reverse is not true. EAN-13 uses some trickery to encode one extra digit in the same space. That digit is usually used for a country code. EAN-13 came after UPC-A.