Main Content

Use a webcam and a Raspberry Pi 4 to extract information from QR codes and even make your own with Python

How QR Codes Work
Quick-reference (QR) codes are similar to barcodes, as they are able to encode data that is represented by black and white squares. But instead of using a laser, a camera differentiates between the spaces and then sends that information to be processed. They are comprised of several large squares that help to align and position the edges of the QR code, formatting columns, a version number, and finally, the data itself.

The data they contain can encode a variety of types, including numbers, characters, and binary, which can allow for many creative uses. Advertisers often encode URLs in them that redirect the user to their website. Other companies might place important product information in a QR code, such as a serial number, and attach it to a component.”

Link to article