Barcodes and QR codes

Author: Kristian Hansen


A barcode is a machine-readable code in the form of vertical lines or a series of pixels that correspond to a value such as a number or a string.


Barcodes can either come in the form of standard barcodes which have been in use for a long time, or in the form of a QR code, which was placed into use parallel to the rise of smartphones. Standard barcodes are a series of 2D vertical black lines against a white backdrop, where each section of the pattern of vertical lines corresponds to a certain character. QR codes however are a pattern of pixels within a square area. Since more pixels can be placed in QR codes, their storage capacity is considerably larger than that of standard barcodes. Standard barcodes have been around since the 1960's, but QR codes have been brought into application very recently, to coincide with smartphones as it provides smartphone users to scan a QR code for links or downloads.

The defining variable for the corresponding character to a vertical line is the width of it. Various widths correspond to various characters.
An example of a standard barcode
An example of a standard barcode

Explanation and application

Barcodes have been used for advertising, product tracking, product identification, and more. Product identification has been the major use of barcodes however. They are widely used in stores for product identification during checkout, as the cashier can scan the barcode and immediately get the item, and the cost of the item. Standard barcodes work as a pattern of vertical lines, with each section of it corresponding to a digit or a letter. A machine picks up the pattern and translates it into the encoded value. However barcodes have been used for a variety of other purposes, such as tracking products during transportation, as each checkpoint can scan the barcode. QR codes - a more modern version have been used for advertising purposes. Most QR codes correspond to a link, so people can scan the code with their smartphones to follow the link to whence advertised.

In terms of the case study, barcodes are used for product identification within the supermarket stores. The barcode of purchased products are scanned, which will bring up the price from a store database and also can be used as a tag for targeted marketing should the user swipe his or her loyalty card.

References and resources