ZPLToolkit

^BR

GS1 DataBar Bar CodePreview: partial

Six symbologies behind one command, built to put a full GTIN on items too small for a UPC — fresh produce most of all.

Syntax

^BRo,t,f,s,h,w,r

Parameters

ParameterDescription and accepted valuesIf omitted
oRotation of the bar code on the label.N normal, R 90°, I 180°, B 270°Last ^FW value, else N
tWhich member of the family to print. 1 is omnidirectional, the retail default.1 omnidirectional, 2 truncated, 3 stacked, 4 stacked omnidirectional, 5 limited, 6 expanded, 7 UPC-A1
fMagnification factor.1 to 10 — magnification factorChosen from the print head
sHeight of the separator pattern between rows, in dots.1 to 10 — separator height1
hBar code height in dots.1 to 32000 dots — bar code height25
wSegment width, for the expanded variant only.2 to 22 — segment width, expanded only22
rReserved.ReservedNone

How it works

^BR prints GS1 DataBar, formerly RSS. The `t` parameter picks which of the family you get: omnidirectional, truncated, stacked, stacked omnidirectional, limited, or expanded. They encode the same kind of data in very different footprints.

The family exists because a UPC-A is too wide for a loose tomato or a pharmacy vial. Omnidirectional is the retail point-of-sale variant; stacked folds it into two rows for a narrow label; limited is for items that will never cross a scanner at the till; expanded is the only one that carries more than a GTIN, taking application identifiers for weight, lot and expiry.

In ZPL the field data is the plain GTIN — fourteen digits, or thirteen and let the printer compute the check. Expanded is the exception: it takes a full AI string, written the way GS1 writes it, with the identifiers in parentheses.

Example

ZPL
^XA
^BY2,3,80
^FO60,60^BRN,1,2,1,80^FD01234567890128^FS
^XZ

Rendering…

A GS1 DataBar Omnidirectional carrying a 14-digit GTIN.
Open in the viewer

How the preview on this site handles it

All six variants are drawn with real GS1 DataBar encoders, so they scan, and rotation is applied — including the two stacked forms, which the preview draws as the two-row symbols they are. The separator height from `s` and the segment width from `w` are left to the encoder.

Common mistakes

  • Sending AIs to the wrong variant. Only expanded (t=6) carries application identifiers; the others take a bare GTIN and will not encode a parenthesised string.
  • Picking limited for a till. GS1 forbids DataBar Limited at point of sale — it is for items that will never be scanned there.
  • Printing it too small. DataBar's magnification range is defined by GS1, and going under it is the usual cause of a rejected retail item.

See also