HIBC in Datamatrix

HIBC data structure in a Datamatrix in PHP: input rules, code example and SVG output

HIBC data in a Datamatrix symbol. This is the combination that fits on a surgical instrument or a small vial, where a linear symbol has nowhere to go.

Type Token

ItemValue
Type tokenHIBCDM
Enum caseBarcodeType::HIBCDM
Family2D
StandardANSI/HIBC 2.6, ANSI/HIBC 1.3
Class\Com\Tecnick\Barcode\Type\Square\HibcDatamatrix

Input

ItemValue
Character setthe HIBC character set
Lengtha primary structure of 6 to 23 characters, with an optional secondary structure
Checkmodulo 43, appended by the library, plus the Datamatrix error correction
Extra parametersnone

Examples

A primary data structure

<?php

require_once __DIR__ . '/vendor/autoload.php';

$barcode = new \Com\Tecnick\Barcode\Barcode();
$bobj = $barcode->getBarcodeObj(
    type: 'HIBCDM',
    code: '+A123BJC5D6E71',
    width: -4,
    height: -4,
    color: 'black',
    padding: [0, 0, 0, 0],
)->setBackgroundColor('white');

echo $bobj->getInlineSvgCode();

HIBC in Datamatrix barcode encoding +A123BJC5D6E71

Errors

These payloads raise \Com\Tecnick\Barcode\Exception:

PayloadMessage
A123A HIBC data structure starts with the flag character “+”: A123

See Also