Ways of writing that hide nothing by design — number bases, Unicode, Morse, Braille and signal codes, QR codes, Roman numerals, computer timestamps — read and written both ways.
QR Code
Makes a QR code by ISO/IEC 18004 and shows each choice the standard leaves to the encoder: the version, the error-correction level, the Reed–Solomon blocks and the eight masks with their penalties. Reads a QR code from an image and marks the modules its correction repaired. Checked against the standard’s worked example (Annex I) and symbols made by segno.
About this tool
History
DENSO WAVE announced the QR code in 1994: a team led by Masahiro Hara made it for factories that wanted more than a barcode’s twenty or so characters, kanji included, and the car industry used it first to track parts. DENSO WAVE kept its patent but declared it would not exercise it. It became an AIM standard in 1997, a Japanese Industrial Standard in 1999 and an ISO standard in 2000; this tool follows ISO/IEC 18004:2006.
How it works
Making a code: the text is written in one of four modes (numeric, alphanumeric, byte, kanji), padded to the version’s capacity and split into blocks, each with its own Reed–Solomon codewords over GF(256). The blocks are interleaved and laid in two-module columns from the bottom right, around the finder, timing and alignment patterns. Each of the eight masks is scored on the whole symbol for runs, 2 × 2 blocks, finder-like patterns and the balance of dark and light (§6.8.3); the lowest penalty is kept, and the level and mask are written twice as the format information.
Reading a code: the finder patterns are found by their 1:1:3:1:1 rings, a perspective is fitted and the grid sampled; the format information is read as the nearest of its 32 codes, the mask removed, each block corrected (Berlekamp–Massey and Forney) and the segments read, ECI and structured append included.
How it was checked
The standard’s worked example (Annex I, 01234567 at 1-M) gives the printed codewords, mask and format bits. All 32 format codes and 34 version codes match Tables C.1 and D.1 as segno transcribes them. Forty symbols made by segno, in every mode, level and mask across eleven versions from 1 to 40, are made identically here and read back; twelve more (ECI, Shift JIS, structured append) are read. Damage up to a block’s capacity is repaired; one codeword more is refused, never misread. Eight images, rotated, keystoned, noisy, inverted or damaged, are read.
Limits
A text is written in one mode throughout, not the shortest mix of segments. Micro QR and rectangular codes are not handled. The reader fits one perspective, so a code on a curved surface can fail; images are reduced to 1,000 pixels first. segno scores masks before drawing the format information, so it picks another for 8 of 26 test texts; both read the same. Kanji mode keeps to JIS X 0208: Windows’s extra signs (① № ㍻) go in byte mode.