Encode the null function char (ASCII 0) in a barcode

< Back
You are here:
Print

Encode the null function char (ASCII 0) in a barcode

Solution(s):

Null characters may be encoded in Code 39Code 128, and most 2D barcode types such as QR Code and Data Matrix. However, the null character represents the end of a data string in most applications. Therefore, any data encoded after it will usually be truncated by the barcode scanner or the application itself.

In Data Matrix and QR Code, the format ~dNNN represents the ASCII character encoded where NNN is the ASCII number. For example, ~d009 encodes a tab, ~d013 encodes a return and ~d000 encodes the null character.

When encoding these hidden control commands, IDAutomation recommends testing the result with the Barcode Scanner Decoder App because it can show these non-printable ASCII commands in the data such as this example below that shows the GS, RS, and EOT functions.

The Barcode Scanner Decoder App shows non-printable ASCII commands.