ZPL II, ZBI 2, SetGet-Do, Mirror,
WML
Programming Guide
P1099958-005 Rev A
ZEBRA and the stylized Zebra head are trademarks of Zebra Technologies Corporation, registered in many
jurisdictions worldwide. All other trademarks are the property of their respective owners. ©2022 Zebra
Technologies Corporation and/or its affiliates. All rights reserved.
Information in this document is subject to change without notice. The software described in this document
is furnished under a license agreement or nondisclosure agreement. The software may be used or copied
only in accordance with the terms of those agreements.
For further information regarding legal and proprietary statements, please go to:
SOFTWARE: zebra.com/linkoslegal.
COPYRIGHTS: zebra.com/copyright.
WARRANTY: zebra.com/warranty.
END USER LICENSE AGREEMENT: zebra.com/eula.
Terms of Use
Proprietary Statement
This manual contains proprietary information of Zebra Technologies Corporation and its subsidiaries
(“Zebra Technologies”). It is intended solely for the information and use of parties operating and
maintaining the equipment described herein. Such proprietary information may not be used, reproduced,
or disclosed to any other parties for any other purpose without the express, written permission of Zebra
Technologies.
Copyright
Product Improvements
Continuous improvement of products is a policy of Zebra Technologies. All specifications and designs are
subject to change without notice.
Liability Disclaimer
Zebra Technologies takes steps to ensure that its published Engineering specifications and manuals are
correct; however, errors do occur. Zebra Technologies reserves the right to correct any such errors and
disclaims liability resulting therefrom.
Limitation of Liability
In no event shall Zebra Technologies or anyone else involved in the creation, production, or delivery of the
accompanying product (including hardware and software) be liable for any damages whatsoever (including,
without limitation, consequential damages including loss of business profits, business interruption, or loss
of business information) arising out of the use of, the results of use of, or inability to use such product, even
if Zebra Technologies has been advised of the possibility of such damages. Some jurisdictions do not allow
the exclusion or limitation of incidental or consequential damages, so the above limitation or exclusion may
not apply to you.
Contents
Introduction.....................................................................................................................................................45
Firmware.................................................................................................................................................. 45
Who Should Use This Document.....................................................................................................45
ZPL Commands.............................................................................................................................................. 46
How Commands Are Documented..................................................................................................46
Basic ZPL Exercises and Examples................................................................................................. 47
Exercise 1: Specify a Location for an Entered Name.......................................................... 48
Exercise 2:Boxes and Lines.......................................................................................................51
Exercise 3: Bar Codes — ^B3 Code 39 Barcode.................................................................52
Exercise 4: ^SN —Serial Number Command........................................................................53
Exercise 5:Saving a template to memory. ^IS and image save and image load......... 54
Exercise 6: ^DF and ^XF — Download Format and Recall Format.................................55
Exercise 7: Asian and Unicode Encodings............................................................................ 56
Allowed Characters in File Names.................................................................................................. 56
^A............................................................................................................................................................... 58
^A@............................................................................................................................................................60
^B0............................................................................................................................................................ 62
^B1..............................................................................................................................................................64
^B2.............................................................................................................................................................66
^B3.............................................................................................................................................................68
^B4............................................................................................................................................................. 72
^B5.............................................................................................................................................................76
^B7..............................................................................................................................................................77
^B8..............................................................................................................................................................81
3
Contents
^B9.............................................................................................................................................................83
^BA............................................................................................................................................................ 85
^BB............................................................................................................................................................ 88
^BC............................................................................................................................................................ 92
^BD...........................................................................................................................................................104
^BE........................................................................................................................................................... 107
^BF........................................................................................................................................................... 109
^BI..............................................................................................................................................................112
^BJ.............................................................................................................................................................114
^BK............................................................................................................................................................ 116
^BL.............................................................................................................................................................118
^BM.......................................................................................................................................................... 120
^BO.......................................................................................................................................................... 122
^BP........................................................................................................................................................... 124
^BQ.......................................................................................................................................................... 126
^BR........................................................................................................................................................... 133
^BS........................................................................................................................................................... 135
^BT........................................................................................................................................................... 138
^BU...........................................................................................................................................................140
^BX...........................................................................................................................................................142
^BY........................................................................................................................................................... 146
^BZ........................................................................................................................................................... 148
^CC ~CC.................................................................................................................................................150
^CD ~CD..................................................................................................................................................151
^CF........................................................................................................................................................... 152
^CI.............................................................................................................................................................153
^CM..........................................................................................................................................................158
^CN.......................................................................................................................................................... 160
^CO........................................................................................................................................................... 161
^CP........................................................................................................................................................... 163
^CT ~CT.................................................................................................................................................. 164
^CV...........................................................................................................................................................165
^CW..........................................................................................................................................................166
~DB.......................................................................................................................................................... 168
4
Contents
~DE...........................................................................................................................................................170
^DF........................................................................................................................................................... 172
~DG.......................................................................................................................................................... 173
~DN.......................................................................................................................................................... 175
~DS...........................................................................................................................................................176
~DT........................................................................................................................................................... 177
~DU.......................................................................................................................................................... 178
~DY...........................................................................................................................................................179
~EG...........................................................................................................................................................183
^FB........................................................................................................................................................... 184
^FC........................................................................................................................................................... 187
^FD........................................................................................................................................................... 188
^FH...........................................................................................................................................................189
^FL.............................................................................................................................................................191
^FM...........................................................................................................................................................193
^FN...........................................................................................................................................................196
^FO...........................................................................................................................................................197
^FP........................................................................................................................................................... 198
^FR........................................................................................................................................................... 199
^FS.......................................................................................................................................................... 200
^FT........................................................................................................................................................... 201
^FV.......................................................................................................................................................... 203
^FW......................................................................................................................................................... 204
^FX..........................................................................................................................................................205
^GB......................................................................................................................................................... 206
^GC......................................................................................................................................................... 208
^GD......................................................................................................................................................... 209
^GE...........................................................................................................................................................210
^GF............................................................................................................................................................211
^GS...........................................................................................................................................................213
~HB.......................................................................................................................................................... 214
~HD..........................................................................................................................................................215
^HF...........................................................................................................................................................216
^HG...........................................................................................................................................................217
5
Contents
^HH.......................................................................................................................................................... 218
~HI...........................................................................................................................................................220
~HM......................................................................................................................................................... 221
~HQ.........................................................................................................................................................222
~HS......................................................................................................................................................... 229
^HT.......................................................................................................................................................... 233
~HU......................................................................................................................................................... 234
^HV..........................................................................................................................................................235
^HW.........................................................................................................................................................236
^HY..........................................................................................................................................................238
^HZ..........................................................................................................................................................239
^ID............................................................................................................................................................ 241
^IL............................................................................................................................................................ 243
^IM........................................................................................................................................................... 244
^IS............................................................................................................................................................245
~JA...........................................................................................................................................................247
^JB...........................................................................................................................................................248
~JB.......................................................................................................................................................... 249
~JC..........................................................................................................................................................250
~JD...........................................................................................................................................................251
~JE.......................................................................................................................................................... 252
~JF...........................................................................................................................................................253
~JG..........................................................................................................................................................254
^JH.......................................................................................................................................................... 255
^JI............................................................................................................................................................ 259
~JI.............................................................................................................................................................261
^JJ........................................................................................................................................................... 262
~JL...........................................................................................................................................................264
^JM..........................................................................................................................................................265
~JN..........................................................................................................................................................266
~JO..........................................................................................................................................................267
~JP.......................................................................................................................................................... 268
~JQ..........................................................................................................................................................269
~JR...........................................................................................................................................................270
6
Contents
^JS............................................................................................................................................................ 271
~JS...........................................................................................................................................................272
^JT........................................................................................................................................................... 273
^JU...........................................................................................................................................................274
^JW..........................................................................................................................................................275
~JX.......................................................................................................................................................... 276
^JZ........................................................................................................................................................... 277
~KB.......................................................................................................................................................... 278
^KD..........................................................................................................................................................279
^KL.......................................................................................................................................................... 280
^KN...........................................................................................................................................................281
^KP.......................................................................................................................................................... 283
^KV..........................................................................................................................................................284
^LF...........................................................................................................................................................288
^LH.......................................................................................................................................................... 289
^LL...........................................................................................................................................................290
^LR............................................................................................................................................................291
^LS...........................................................................................................................................................292
^LT...........................................................................................................................................................293
^MA......................................................................................................................................................... 294
^MC.........................................................................................................................................................296
^MD......................................................................................................................................................... 297
^MF......................................................................................................................................................... 298
^MI...........................................................................................................................................................299
^ML..........................................................................................................................................................300
^MM......................................................................................................................................................... 301
^MN.........................................................................................................................................................303
^MP......................................................................................................................................................... 304
^MT......................................................................................................................................................... 306
^MU......................................................................................................................................................... 307
^MW........................................................................................................................................................309
^NC.......................................................................................................................................................... 310
~NC........................................................................................................................................................... 311
^ND.......................................................................................................................................................... 312
7
Contents
^NI.............................................................................................................................................................314
~NR...........................................................................................................................................................315
^NS...........................................................................................................................................................316
~NT...........................................................................................................................................................318
^PA........................................................................................................................................................... 319
^PF.......................................................................................................................................................... 320
^PH ~PH................................................................................................................................................. 321
~PL.......................................................................................................................................................... 322
^PM..........................................................................................................................................................323
~PM......................................................................................................................................................... 324
^PN..........................................................................................................................................................325
^PO..........................................................................................................................................................326
^PP ~PP..................................................................................................................................................327
^PQ..........................................................................................................................................................328
~PR..........................................................................................................................................................329
^PR.......................................................................................................................................................... 330
~PS.......................................................................................................................................................... 332
^PW......................................................................................................................................................... 333
~RO......................................................................................................................................................... 334
^SC.......................................................................................................................................................... 336
~SD..........................................................................................................................................................337
^SE...........................................................................................................................................................338
^SF...........................................................................................................................................................339
^SI............................................................................................................................................................342
^SL...........................................................................................................................................................343
^SN..........................................................................................................................................................345
^SO.......................................................................................................................................................... 347
^SP...........................................................................................................................................................348
^SQ......................................................................................................................................................... 350
^SR.......................................................................................................................................................... 352
^SS...........................................................................................................................................................353
^ST.......................................................................................................................................................... 355
^SX.......................................................................................................................................................... 356
^SZ.......................................................................................................................................................... 358
8
Contents
~TA..........................................................................................................................................................359
^TB.......................................................................................................................................................... 360
^TO...........................................................................................................................................................361
~WC.........................................................................................................................................................363
^WD.........................................................................................................................................................365
~WQ........................................................................................................................................................ 367
^XA.......................................................................................................................................................... 374
^XB.......................................................................................................................................................... 375
^XF...........................................................................................................................................................376
^XG.......................................................................................................................................................... 377
^XS.......................................................................................................................................................... 378
^XZ.......................................................................................................................................................... 379
^ZZ.......................................................................................................................................................... 380
ZPL RFID Commands...................................................................................................................................381
^HL or ~HL............................................................................................................................................382
^HR..........................................................................................................................................................384
^RA.......................................................................................................................................................... 393
^RB.......................................................................................................................................................... 395
^RE...........................................................................................................................................................397
^RF.......................................................................................................................................................... 398
^RI............................................................................................................................................................402
^RL...........................................................................................................................................................403
^RM......................................................................................................................................................... 406
^RN..........................................................................................................................................................407
^RQ......................................................................................................................................................... 408
^RR........................................................................................................................................................... 410
^RS........................................................................................................................................................... 412
^RT............................................................................................................................................................417
^RU...........................................................................................................................................................419
~RV...........................................................................................................................................................421
^RW.........................................................................................................................................................422
^RZ.......................................................................................................................................................... 426
^WF......................................................................................................................................................... 429
9
Contents
^WT.......................................................................................................................................................... 431
^WV......................................................................................................................................................... 433
ZPL Wireless Commands........................................................................................................................... 434
^KC.......................................................................................................................................................... 435
^NB..........................................................................................................................................................436
^NN..........................................................................................................................................................437
^NP..........................................................................................................................................................438
^NT.......................................................................................................................................................... 439
^NW.........................................................................................................................................................440
^WA..........................................................................................................................................................441
^WE......................................................................................................................................................... 442
^WL - Set Leap....................................................................................................................................444
~WL - Print Network.......................................................................................................................... 445
^WP..........................................................................................................................................................447
^WR - Set Transmit............................................................................................................................ 448
~WR - Reset Wireless........................................................................................................................449
^WS.........................................................................................................................................................450
^WX.........................................................................................................................................................452
ZBI Commands............................................................................................................................................ 460
Introduction to Zebra Basic Interpreter (ZBI)..............................................................................460
Printers, ZBI Keys, & ZBI Versions........................................................................................ 460
Command and Function Reference Format................................................................................ 461
Function Rules.............................................................................................................................. 461
Command/Function NAME........................................................................................................461
Section Organization......................................................................................................................... 462
Writing ZBI Programs.................................................................................................................463
Editing Commands............................................................................................................................. 463
NEW........................................................................................................................................................465
REM.........................................................................................................................................................466
! (EXCLAMATION MARK).................................................................................................................. 467
LIST......................................................................................................................................................... 468
10
Contents
AUTONUM............................................................................................................................................469
RENUM...................................................................................................................................................470
ECHO.......................................................................................................................................................471
Running and Debugging Commands............................................................................................472
RUN......................................................................................................................................................... 474
CTRL-C................................................................................................................................................... 475
RESTART................................................................................................................................................476
STEP........................................................................................................................................................477
DEBUG................................................................................................................................................... 478
TRACE.................................................................................................................................................... 479
BREAK....................................................................................................................................................480
ADDBREAK............................................................................................................................................ 481
DELBREAK............................................................................................................................................ 482
ZPL.......................................................................................................................................................... 483
Base Types and Expressions..........................................................................................................484
Variable Names........................................................................................................................... 484
Variable Declarations................................................................................................................ 485
Constants...................................................................................................................................... 485
Arrays............................................................................................................................................. 485
Assignment................................................................................................................................... 486
LET...........................................................................................................................................................487
Numeric Expressions................................................................................................................. 487
String Concatenation (&)...........................................................................................................488
Sub-strings.................................................................................................................................... 489
Boolean Expressions................................................................................................................. 490
Combined Boolean Expressions............................................................................................ 492
Control and Flow................................................................................................................................493
IF Statements....................................................................................................................................... 493
DO Loops..............................................................................................................................................494
FOR Loops............................................................................................................................................495
GOTO/GOSUB..................................................................................................................................... 497
SUB......................................................................................................................................................... 498
EXIT........................................................................................................................................................ 499
END........................................................................................................................................................ 500
11
Contents
Input and Output.................................................................................................................................501
OPEN......................................................................................................................................................503
CLOSE....................................................................................................................................................504
DATAREADY........................................................................................................................................ 505
SERVERSOCKET................................................................................................................................. 506
SERVERCLOSE.................................................................................................................................... 507
CLIENTSOCKET...................................................................................................................................508
ACCEPT.................................................................................................................................................509
Reading and Writing...........................................................................................................................510
INPUT....................................................................................................................................................... 511
PRINT.......................................................................................................................................................513
OUTBYTE............................................................................................................................................... 514
INBYTE....................................................................................................................................................515
READ....................................................................................................................................................... 516
WRITE...................................................................................................................................................... 517
SEARCHTO$......................................................................................................................................... 518
Port Usage Examples........................................................................................................................520
Physical Ports (Serial, Parallel, USB, Bluetooth®)............................................................... 520
ZPL Parser.................................................................................................................................... 520
TCP Client......................................................................................................................................521
TCP Server.................................................................................................................................... 521
UDP Client.................................................................................................................................... 522
UDP Server...................................................................................................................................522
E-mail..............................................................................................................................................523
File System...........................................................................................................................................525
Runtime Access.......................................................................................................................... 525
STORE.................................................................................................................................................... 527
LOAD......................................................................................................................................................528
DIR.......................................................................................................................................................... 529
DELETE.................................................................................................................................................. 530
Comma Separated Values (CSV).................................................................................................... 531
CSVLOAD..............................................................................................................................................532
CSV File Information..........................................................................................................................533
CSVSTORE............................................................................................................................................534
12
Contents
TXTLOAD.............................................................................................................................................. 535
TXTSTORE............................................................................................................................................ 536
Events.....................................................................................................................................................537
ZBI Key Names........................................................................................................................... 539
REGISTEREVENT.................................................................................................................................542
UNREGISTEREVENT...........................................................................................................................544
HANDLEEVENT................................................................................................................................... 545
TRIGGEREVENT...................................................................................................................................547
Systems..................................................................................................................................................547
ISERROR................................................................................................................................................ 548
ISWARNING.......................................................................................................................................... 549
SLEEP.....................................................................................................................................................550
SETERR...................................................................................................................................................551
CLRERR..................................................................................................................................................552
ON ERROR............................................................................................................................................553
Applicator Functions..........................................................................................................................554
AUXPORT_STEALPIN........................................................................................................................555
AUXPORT_SETPIN.............................................................................................................................556
AUXPORT_GETPIN.............................................................................................................................557
AUXPORT_RELEASEPIN...................................................................................................................558
String Functions.................................................................................................................................. 559
LCASE$................................................................................................................................................. 560
CHR$.......................................................................................................................................................561
LTRIM$...................................................................................................................................................562
REPEAT$............................................................................................................................................... 563
RTRIM$.................................................................................................................................................. 564
SPLIT...................................................................................................................................................... 565
SPLITCOUNT....................................................................................................................................... 569
UCASE$.................................................................................................................................................570
EXTRACT$............................................................................................................................................. 571
ORD.........................................................................................................................................................573
POS......................................................................................................................................................... 574
LEN..........................................................................................................................................................575
Math Functions.................................................................................................................................... 576
13
Contents
STR$........................................................................................................................................................577
MAX........................................................................................................................................................ 578
MIN..........................................................................................................................................................579
MAXNUM.............................................................................................................................................. 580
MOD........................................................................................................................................................ 581
VAL......................................................................................................................................................... 582
INTTOHEX$..........................................................................................................................................583
HEXTOINT............................................................................................................................................ 585
Array Functions................................................................................................................................... 587
REDIM.....................................................................................................................................................588
INSERTROW......................................................................................................................................... 589
DELROW................................................................................................................................................590
ROWSIZE................................................................................................................................................591
COLUMNSIZE...................................................................................................................................... 592
FIND........................................................................................................................................................593
Time and Date Functions................................................................................................................ 595
DATE$....................................................................................................................................................596
TIME$..................................................................................................................................................... 597
DATE...................................................................................................................................................... 598
TIME........................................................................................................................................................599
Set/Get/Do Interactions.................................................................................................................... 600
SETVAR.................................................................................................................................................. 601
GETVAR$.............................................................................................................................................. 602
Example Programs............................................................................................................................. 603
Array Program............................................................................................................................. 603
CSV Program............................................................................................................................... 604
DPI Conversion Program.......................................................................................................... 607
Email Program.............................................................................................................................. 610
Extraction 1 Program.................................................................................................................... 611
Extraction 2 Program..................................................................................................................612
Front Panel Control..................................................................................................................... 614
Recall Program............................................................................................................................. 616
Scale Program...............................................................................................................................617
14
Contents
About SGD Printer Commands.................................................................................................................. 619
Overview...............................................................................................................................................620
setvar Command........................................................................................................................ 620
getvar Command........................................................................................................................ 620
do Command............................................................................................................................... 620
Command Structure............................................................................................................................621
How to Send Multiple SGD Commands................................................................................621
JSON (JavaScript Object Notation)................................................................................................ 621
Configuring JSON Usage for Communications................................................................. 622
Get an SGD Branch................................................................................................................... 623
Get an allvalues Report............................................................................................................ 623
Get an allconfig Report.............................................................................................................624
SGD Command Reference......................................................................................................................... 625
alerts.add.............................................................................................................................................. 626
alerts.conditions.................................................................................................................................. 628
alerts.configured................................................................................................................................. 629
alerts.destinations...............................................................................................................................630
alerts.http.authentication.add........................................................................................................... 631
alerts.http.authentication.entries.....................................................................................................633
alerts.http.authentication.remove................................................................................................... 634
alerts.http.logging.clear.....................................................................................................................635
alerts.http.logging.entries................................................................................................................. 636
alerts.http.logging.max_entries....................................................................................................... 637
alerts.http.proxy...................................................................................................................................639
alerts.send_current_status_alerts...................................................................................................641
alerts.tracked_settings.clear_log................................................................................................... 642
alerts.tracked_settings.log_tracked...............................................................................................643
alerts.tracked_settings.max_log_entries......................................................................................644
alerts.tracked_sgds.log..................................................................................................................... 645
alerts.tracked_sgds.max_log_entries........................................................................................... 646
alerts.tracked_sgds.zbi_notified..................................................................................................... 647
apl.enable..............................................................................................................................................648
apl.framework_version......................................................................................................................649
15
Contents
apl.settings........................................................................................................................................... 650
apl.version.............................................................................................................................................652
appl.link_os_version.......................................................................................................................... 653
appl.option_board_version..............................................................................................................654
appl.bootblock.....................................................................................................................................655
appl.date............................................................................................................................................... 656
appl.name..............................................................................................................................................657
capture.channel1.count..................................................................................................................... 658
capture.channel1.data.mime............................................................................................................ 659
capture.channel1.data.raw................................................................................................................660
capture.channel1.delimiter.................................................................................................................661
capture.channel1.max_length..........................................................................................................662
capture.channel1.port.........................................................................................................................663
CISDFCRC16 Download Files..........................................................................................................664
comm.baud...........................................................................................................................................666
comm.halt..............................................................................................................................................667
comm.mode..........................................................................................................................................668
comm.pnp_option...............................................................................................................................669
comm.type............................................................................................................................................ 670
comm.parity........................................................................................................................................... 671
comm.stop_bits................................................................................................................................... 672
cradle.comm.baud.............................................................................................................................. 673
cradle.comm.handshake................................................................................................................... 674
cutter.clean_cutter..............................................................................................................................675
device.allow_firmware_downloads................................................................................................676
device.applicator.data_ready...........................................................................................................677
device.applicator.end_print..............................................................................................................678
device.applicator.feed....................................................................................................................... 679
device.applicator.media_out........................................................................................................... 680
device.applicator.pause..................................................................................................................... 681
device.applicator.reprint................................................................................................................... 682
device.applicator.rfid_void............................................................................................................... 683
device.applicator.ribbon_low.......................................................................................................... 684
device.applicator.ribbon_out...........................................................................................................685
16
Contents
device.applicator.service_required................................................................................................686
device.applicator.start_print.............................................................................................................687
device.bluetooth_installed............................................................................................................... 688
device.command_override.active.................................................................................................. 689
device.command_override.add......................................................................................................690
device.command_override.clear..................................................................................................... 691
device.command_override.list........................................................................................................ 692
device.company_contact..................................................................................................................693
device.configuration_number..........................................................................................................694
device.cpcl_synchronous_mode....................................................................................................695
device.cutter_installed...................................................................................................................... 696
device.download_connection_timeout.........................................................................................697
device.download_interactive_mode............................................................................................. 698
device.epl_legacy_mode................................................................................................................. 699
device.feature.bluetooth_le............................................................................................................. 702
device.feature.mcr.............................................................................................................................. 703
device.feature.nfc................................................................................................................................704
device.feature.ribbon_cartridge..................................................................................................... 705
device.feature.802_11ac....................................................................................................................706
device.feature.head_element_test................................................................................................ 707
device.friendly_name.........................................................................................................................708
device.frontpanel.feedenabled....................................................................................................... 709
device.frontpanel.key_press.............................................................................................................710
device.frontpanel.line1........................................................................................................................ 712
device.frontpanel.line2....................................................................................................................... 713
device.frontpanel.xml.......................................................................................................................... 714
device.host_identification..................................................................................................................715
device.host_status...............................................................................................................................716
device.idle_display_format.............................................................................................................. 720
device.idle_display_value..................................................................................................................721
device.internal_wired_setting_location........................................................................................722
device.jobs_print.................................................................................................................................723
device.job_log.total_jobs_logged..................................................................................................724
device.languages................................................................................................................................ 725
17
Contents
device.light.cover_open_brightness............................................................................................. 726
device.light.head_open_brightness...............................................................................................727
device.location.....................................................................................................................................728
device.loader_version....................................................................................................................... 729
device.ltu_installed.............................................................................................................................730
device.mcu_communication.revision..............................................................................................731
device.mcu_cutter.revision...............................................................................................................732
device.mcu_cutter.desired_revision..............................................................................................733
device.mcu_io_expand_rev.............................................................................................................734
device.mcu_io_expand.desired_rev..............................................................................................735
device.orientation................................................................................................................................736
device.pause.........................................................................................................................................737
device.pnp_option.............................................................................................................................. 738
device.pmcu.revision..........................................................................................................................739
device.position.accuracy...................................................................................................................740
device.position.altitude.......................................................................................................................741
device.position.latitude......................................................................................................................742
device.position.longitude.................................................................................................................. 743
device.print_2key................................................................................................................................744
device.print_reprogram_2key......................................................................................................... 745
device.printhead.test.summary....................................................................................................... 746
device.printhead.odometer...............................................................................................................747
device.printhead.test.detail.............................................................................................................. 748
device.product_name_submodel...................................................................................................749
device.prompted_network_reset................................................................................................... 750
device.prompted_default_network.................................................................................................751
device.prompted_reset..................................................................................................................... 752
device.protected_mode.................................................................................................................... 753
device.protected_mode_allowed...................................................................................................754
device.reset.......................................................................................................................................... 755
device.reset_button_enable............................................................................................................756
device.restore_defaults..................................................................................................................... 757
device.rewinder_installed.................................................................................................................758
device.save_2key............................................................................................................................... 759
18
Contents
device.sensor_select......................................................................................................................... 760
device.sensor_profile..........................................................................................................................761
device.serial_number.option_board_date...................................................................................762
device.serial_numbers.control_panel_date................................................................................ 763
device.serial_numbers.mlb_date....................................................................................................764
device.serial_numbers.processor...................................................................................................765
device.serial_numbers.applicator_option_board_date........................................................... 766
device.serial_numbers.wired_ethernet_option_board.............................................................767
device.serial_numbers.wired_ethernet_option_board_date................................................. 768
device.serial_numbers.applicator_option_board...................................................................... 769
device.serial_numbers.cutter...........................................................................................................770
device.serial_numbers.cutter_date.................................................................................................771
device.serial_numbers.printhead....................................................................................................772
device.serial_numbers.printhead_date.........................................................................................773
device.serial_numbers.usb_host_option_board_date............................................................. 774
device.serial_numbers.usb_host_option_board........................................................................ 775
device.serial_numbers.parallel_option_board............................................................................776
device.serial_numbers.parallel_option_board_date................................................................. 777
device.set_clock_to_build_date..................................................................................................... 778
device.slot_1......................................................................................................................................... 779
device.slot_2........................................................................................................................................ 780
device.super_host_status..................................................................................................................781
device.syslog.clear_log..................................................................................................................... 782
device.syslog.configuration..............................................................................................................783
device.syslog.enable..........................................................................................................................785
device.syslog.entries..........................................................................................................................786
device.syslog.log_max_file_size.....................................................................................................787
device.syslog.save_local_file.......................................................................................................... 788
device.applicator.data_ready_activation......................................................................................789
device.applicator.error_on_pause................................................................................................. 790
device.applicator.start_print_mode................................................................................................ 791
device.applicator.voltage..................................................................................................................792
device.unique_id.................................................................................................................................793
device.unpause....................................................................................................................................794
19
Contents
device.uptime.......................................................................................................................................795
device.user_p1..................................................................................................................................... 796
device.user_p2.................................................................................................................................... 797
device.user_vars.set_range.............................................................................................................798
device.user_vars.create.................................................................................................................... 799
device.xml.enable................................................................................................................................801
device.feature.lighted_arrows.........................................................................................................802
device.light.ribbon_path_brightness.............................................................................................803
device.light.media_path_brightness............................................................................................. 804
device.zuid............................................................................................................................................805
display.backlight................................................................................................................................. 806
display.backlight_on_time................................................................................................................807
display.batch_counter....................................................................................................................... 808
display.bluetooth.mac........................................................................................................................809
display.calibrate................................................................................................................................... 810
display.language................................................................................................................................... 811
display.load_card.................................................................................................................................813
display.password.level........................................................................................................................814
display.root_wml.................................................................................................................................. 815
display.text.............................................................................................................................................816
file.capture_response.destination................................................................................................... 817
head.resolution.in_dpi........................................................................................................................818
ezpl.head_close_action..................................................................................................................... 819
ezpl.label_length_max...................................................................................................................... 820
ezpl.label_sensor.................................................................................................................................821
ezpl.manual_calibration.................................................................................................................... 822
ezpl.media_type..................................................................................................................................823
ezpl.power_up_action.......................................................................................................................824
ezpl.print_method...............................................................................................................................825
ezpl.print_width...................................................................................................................................826
ezpl.reprint_mode...............................................................................................................................827
ezpl.take_label.................................................................................................................................... 828
ezpl.tear_off......................................................................................................................................... 829
file.cert.expiration............................................................................................................................... 830
20
Contents
file.cert.supported_curves.................................................................................................................831
file.delete...............................................................................................................................................832
file.dir......................................................................................................................................................833
file.dir_format....................................................................................................................................... 834
file.type.................................................................................................................................................. 835
file.run.....................................................................................................................................................836
formats.cancel_all............................................................................................................................... 837
head.authenticated.............................................................................................................................838
head.darkness_switch_enable....................................................................................................... 839
head.darkness_switch.......................................................................................................................840
head.element_test...............................................................................................................................841
head.latch..............................................................................................................................................842
input.capture........................................................................................................................................ 843
interface.network.active.arp_interval............................................................................................ 845
interface.network.active.cable_type..............................................................................................846
interface.network.active.dhcp_received_host_name...............................................................847
interface.network.active.gateway...................................................................................................848
interface.network.active.ip_addr.................................................................................................... 849
interface.network.active.mac_addr................................................................................................850
interface.network.active.mac_raw...................................................................................................851
interface.network.active.netmask...................................................................................................852
interface.network.active.protocol................................................................................................... 853
interface.network.active.protocol_error....................................................................................... 854
interface.network.active.rx_errors..................................................................................................855
interface.network.active.rx_packets..............................................................................................856
interface.network.active.server_address......................................................................................857
interface.network.active.speed.......................................................................................................858
interface.network.active.tx_errors..................................................................................................859
interface.network.active.tx_packets..............................................................................................860
interface.network.active.wins_addr................................................................................................ 861
interface.network.settings_require_reset.................................................................................... 862
ip.firewall.authentication.add........................................................................................................... 863
ip.firewall.authentication.entries..................................................................................................... 864
ip.firewall.authentication.remove....................................................................................................865
21
Contents
ip.firewall.proxy....................................................................................................................................866
ip.firewall.whitelist_in......................................................................................................................... 867
ip.https.enable..................................................................................................................................... 868
ip.https.port...........................................................................................................................................869
ip.ping_gateway_interval..................................................................................................................870
ip.pop3.print_body...............................................................................................................................871
ip.pop3.print_headers........................................................................................................................872
ip.pop3.save_attachments................................................................................................................873
ip.pop3.verbose_headers.................................................................................................................874
ip.tls.enable...........................................................................................................................................875
ip.tls.port................................................................................................................................................ 876
ip.tls.port_json_config........................................................................................................................877
log.reboot.code................................................................................................................................... 878
log.reboot.codes................................................................................................................................. 879
log.reboot.reason............................................................................................................................... 880
log.reboot.report.................................................................................................................................. 881
mcr.crypt.enabled............................................................................................................................... 882
mcr.cancel.............................................................................................................................................883
mcr.crypt.key_mgmt...........................................................................................................................884
mcr.crypt.algorithm............................................................................................................................885
mcr.out...................................................................................................................................................886
mcr.revision......................................................................................................................................... 887
media.bar_location.............................................................................................................................888
media.cartridge.darkness................................................................................................................. 889
media.cartridge.labels_remaining..................................................................................................890
media.cartridge.width......................................................................................................................... 891
media.cartridge.total_label_cnt...................................................................................................... 892
media.cartridge.speed.......................................................................................................................893
media.cartridge.length.......................................................................................................................894
media.cartridge.inserted...................................................................................................................895
media.cartridge.part_number..........................................................................................................896
media.cut_now.................................................................................................................................... 897
media.darkness_mode......................................................................................................................898
media.draft_mode.............................................................................................................................. 899
22
Contents
media.dynamic_length_calibration................................................................................................900
media.feed_skip...................................................................................................................................901
media.media_low.external............................................................................................................... 902
media.media_low.warning............................................................................................................... 903
media.part_number............................................................................................................................904
media.present.cut_amount.............................................................................................................. 905
media.present.eject............................................................................................................................906
media.present.length_addition....................................................................................................... 907
media.present.loop_length..............................................................................................................908
media.present.loop_length_max....................................................................................................909
media.present.cut_margin.................................................................................................................910
media.present.present_timeout........................................................................................................911
media.present.present_type.............................................................................................................912
media.printmode.................................................................................................................................. 913
media.speed..........................................................................................................................................915
media.serial_number.......................................................................................................................... 916
media.tof.................................................................................................................................................917
memory.flash_free...............................................................................................................................919
memory.flash_size..............................................................................................................................920
memory.ram_free.................................................................................................................................921
memory.ram_size............................................................................................................................... 922
mqtt.enable...........................................................................................................................................923
mqtt.logging.clear............................................................................................................................... 924
mqtt.logging.entries........................................................................................................................... 925
mqtt.logging.max_entries.................................................................................................................926
mqtt.restore_defaults.........................................................................................................................927
mqtt.conn[1|2].clean_session_flag..................................................................................................928
mqtt.conn[1|2].password....................................................................................................................929
mqtt.conn[1|2].ping_interval............................................................................................................. 930
mqtt.conn[1|2].reset_now................................................................................................................... 931
mqtt.conn[1|2].reset_required.......................................................................................................... 932
mqtt.conn[1|2].retry_interval_random_max..................................................................................933
mqtt.conn[1|2].server_address.........................................................................................................934
mqtt.conn[1|2].tenant_id.................................................................................................................... 935
23
Contents
mqtt.conn[1|2].username................................................................................................................... 936
netmanage.avalanche.agent_addr.................................................................................................937
netmanage.avalanche.available_agent........................................................................................ 938
netmanage.avalanche.available_port........................................................................................... 939
netmanage.avalanche.encryption_type....................................................................................... 940
netmanage.avalanche.interval..........................................................................................................941
netmanage.avalanche.interval_update.........................................................................................942
netmanage.avalanche.model_name..............................................................................................943
netmanage.avalanche.set_property.............................................................................................. 944
netmanage.avalanche.startup_update......................................................................................... 945
netmanage.avalanche.tcp_connection_timeout........................................................................946
netmanage.avalanche.terminal_id................................................................................................. 947
netmanage.avalanche.text_msg.beep..........................................................................................948
netmanage.avalanche.text_msg.display...................................................................................... 949
netmanage.avalanche.text_msg.print...........................................................................................950
netmanage.avalanche.udp_timeout............................................................................................... 951
netmanage.error_code..................................................................................................................... 952
netmanage.state_code..................................................................................................................... 953
netmanage.status_code.................................................................................................................. 954
odometer.cut_marker_count...........................................................................................................955
odometer.headclean..........................................................................................................................956
odometer.headnew............................................................................................................................ 957
odometer.label_dot_length............................................................................................................. 958
odometer.media_marker_count.....................................................................................................959
odometer.media_marker_count1................................................................................................... 960
odometer.media_marker_count2................................................................................................... 961
odometer.net_media_length...........................................................................................................962
odometer.net_ribbon_length.......................................................................................................... 963
odometer.retracts_count.................................................................................................................. 964
odometer.rfid.valid_resettable........................................................................................................965
odometer.rfid.void_resettable......................................................................................................... 967
odometer.total_cuts...........................................................................................................................969
odometer.total_print_length............................................................................................................ 970
odometer.total_label_count..............................................................................................................971
24
Contents
odometer.user_label_count.............................................................................................................972
odometer.user_total_cuts.................................................................................................................973
odometer.user_label_count[1|2]......................................................................................................974
odometer.latch_open_count........................................................................................................... 975
parallel_port.mode..............................................................................................................................976
parallel_port.present.......................................................................................................................... 977
power.average_current.....................................................................................................................978
power.battery_led_blink_rate........................................................................................................ 979
power.battery_led_enable...............................................................................................................980
power.battery_led_off_duration.....................................................................................................981
power.battery_led_on_duration.....................................................................................................982
power.battery_type............................................................................................................................ 983
power.dtr_power_off......................................................................................................................... 984
power.energy_star.enable............................................................................................................... 985
power.energy_star.timeout..............................................................................................................986
power.label_queue.shutdown........................................................................................................987
power.power_on_mode................................................................................................................... 988
power.shutdown..................................................................................................................................989
power.voltage......................................................................................................................................990
power.wake.radio................................................................................................................................ 991
power.current.......................................................................................................................................992
power.temperature.............................................................................................................................993
power.percent_health....................................................................................................................... 994
power.part_number............................................................................................................................995
power.sleep.cradle.............................................................................................................................996
power.remaining_capacity............................................................................................................... 997
power.cycle_count............................................................................................................................. 998
print.legacy_compatibility.................................................................................................................999
print.tone............................................................................................................................................. 1000
print.troubleshooting_label_print.................................................................................................. 1001
rfid.adaptive_antenna...................................................................................................................... 1002
rfid.antenna_sweep..........................................................................................................................1003
rfid.country_code.............................................................................................................................. 1004
rfid.enable........................................................................................................................................... 1005
25
Contents
rfid.error.response............................................................................................................................ 1006
rfid.hop_table_version..................................................................................................................... 1007
rfid.position.program........................................................................................................................ 1008
rfid.reader_1.antenna_port.............................................................................................................1010
rfid.reader_1.power.read.................................................................................................................. 1012
rfid.reader_1.power.write..................................................................................................................1014
rfid.reader_1.power.single_power................................................................................................. 1016
rfid.reader_1.firmware_version........................................................................................................1017
rfid.reader_1.hardware_version......................................................................................................1018
rfid.reader_1.model............................................................................................................................ 1019
rfid.recipe_version........................................................................................................................... 1020
rfid.region_code................................................................................................................................. 1021
rfid.tag.calibrate................................................................................................................................. 1022
rfid.tag.data......................................................................................................................................... 1023
rfid.tag.read.content......................................................................................................................... 1024
rfid.tag.read.execute........................................................................................................................ 1025
rfid.tag.read.result_line1.................................................................................................................. 1026
rfid.tag.read.result_line2..................................................................................................................1027
rfid.tag.read.result_line1_alternate............................................................................................... 1028
rfid.tag.read.result_line2_alternate.............................................................................................. 1029
rfid.tag.test.......................................................................................................................................... 1030
rfid.tag.test.content............................................................................................................................ 1031
rfid.tag.test.execute.......................................................................................................................... 1032
rfid.tag.test.result_line1.................................................................................................................... 1033
rfid.tag.test.result_line2................................................................................................................... 1034
rfid.tag.type......................................................................................................................................... 1035
rfid.log.enabled.................................................................................................................................. 1037
rfid.log.entries.....................................................................................................................................1038
rfid.log.clear........................................................................................................................................ 1039
ribbon.serial_number....................................................................................................................... 1040
ribbon.part_number...........................................................................................................................1041
ribbon.cartridge.part_number........................................................................................................1042
ribbon.cartridge.length_remaining............................................................................................... 1043
ribbon.cartridge.length.....................................................................................................................1044
26
Contents
ribbon.cartridge.authenticated...................................................................................................... 1045
ribbon.cartridge.inserted.................................................................................................................1046
ribbon.coating.....................................................................................................................................1047
ribbon.tension.................................................................................................................................... 1048
rtc.exists............................................................................................................................................... 1049
rtc.date................................................................................................................................................. 1050
rtc.time...................................................................................................................................................1051
rtc.timezone....................................................................................................................................... 1052
rtc.unix_timestamp............................................................................................................................1054
sensor.air_pressure.current_reading.......................................................................................... 1055
sensor.ambient_light.current_reading........................................................................................ 1056
sensor.battery.in_volts..................................................................................................................... 1057
sensor.back_bar.brightness...........................................................................................................1058
sensor.back_bar.ppr_out_thold....................................................................................................1059
sensor.back_bar.cur.........................................................................................................................1060
sensor.cover_open............................................................................................................................1061
sensor.front_bar.ppr_out_thold.................................................................................................... 1062
sensor.front_bar.cur......................................................................................................................... 1063
sensor.front_bar.thold......................................................................................................................1064
sensor.front_bar.gain....................................................................................................................... 1065
sensor.front_bar.brightness........................................................................................................... 1066
sensor.front_bar.offset.....................................................................................................................1067
sensor.back_bar.offset.................................................................................................................... 1068
sensor.gap.thold................................................................................................................................1069
sensor.gap.offset............................................................................................................................... 1070
sensor.gap.gain...................................................................................................................................1071
sensor.gap.brightness......................................................................................................................1072
sensor.head.temp_avg.....................................................................................................................1073
sensor.head.temp_celsius.............................................................................................................. 1074
sensor.head.temp..............................................................................................................................1075
sensor.magnetometer.current_reading.......................................................................................1076
sensor.object_temperature.current_reading............................................................................. 1077
sensor.peel.thold............................................................................................................................... 1078
sensor.peel.gain.................................................................................................................................1079
27
Contents
sensor.paper_supply.......................................................................................................................1080
sensor.peeler.......................................................................................................................................1081
sensor.peel.brightness.....................................................................................................................1082
sensor.proximity.current_reading................................................................................................. 1083
sensor.width.in_dots.........................................................................................................................1084
sensor.width.cur.................................................................................................................................1085
sensor.self_adjusting_enable........................................................................................................1086
usb.device.device_id_string...........................................................................................................1087
usb.device.device_unique_id........................................................................................................1088
usb.device.device_version............................................................................................................. 1089
usb.device.manufacturer_string....................................................................................................1090
usb.device.product_id...................................................................................................................... 1091
usb.device.product_string.............................................................................................................. 1092
usb.device.serial_string...................................................................................................................1093
usb.device.vendor_id.......................................................................................................................1094
usb.halt.................................................................................................................................................1095
usb.host.config_info_to_usb..........................................................................................................1096
usb.host.fn_field_data......................................................................................................................1097
usb.host.fn_last_field....................................................................................................................... 1098
usb.host.hid_count........................................................................................................................... 1099
usb.host.keyboard_input................................................................................................................. 1100
usb.host.lock_out................................................................................................................................ 1101
usb.host.mass_storage_count........................................................................................................1102
usb.host.read_list............................................................................................................................... 1103
usb.host.read_list_print_delay........................................................................................................1104
usb.host.template_list....................................................................................................................... 1105
usb.host.template_print_amount................................................................................................... 1106
usb.host.write_list...............................................................................................................................1107
usb.mirror.appl_path......................................................................................................................... 1108
usb.mirror.auto.................................................................................................................................... 1109
usb.mirror.enable.................................................................................................................................1110
usb.mirror.enabled............................................................................................................................... 1111
usb.mirror.error_retry......................................................................................................................... 1112
usb.mirror.feedback.auto...................................................................................................................1113
28
Contents
usb.mirror.feedback.odometer........................................................................................................ 1114
usb.mirror.feedback.path.................................................................................................................. 1115
usb.mirror.fetch.................................................................................................................................... 1116
usb.mirror.last_error............................................................................................................................1117
usb.mirror.last_time............................................................................................................................ 1118
usb.mirror.path..................................................................................................................................... 1119
usb.mirror.reset_delay...................................................................................................................... 1120
usb.mirror.success.............................................................................................................................. 1121
usb.mirror.success_time...................................................................................................................1122
zbi.control.add_breakpoint..............................................................................................................1123
zbi.control.break................................................................................................................................. 1124
zbi.control.clear_breakpoints..........................................................................................................1125
zbi.control.delete_breakpoint.........................................................................................................1126
zbi.control.line_number.................................................................................................................... 1127
zbi.control.restart................................................................................................................................1128
zbi.control.run......................................................................................................................................1129
zbi.control.step....................................................................................................................................1130
zbi.control.terminate........................................................................................................................... 1131
zbi.control.variable_name................................................................................................................ 1132
zbi.control.variable_value.................................................................................................................1133
zbi.enable............................................................................................................................................. 1134
zbi.key....................................................................................................................................................1135
zbi.last_error........................................................................................................................................ 1136
zbi.program_list...................................................................................................................................1137
zbi.reseller_key...................................................................................................................................1139
zbi.revision........................................................................................................................................... 1140
zbi.running_program_name............................................................................................................. 1141
zbi.start_info.execute........................................................................................................................ 1142
zbi.start_info.file_name.....................................................................................................................1143
zbi.start_info.memory_alloc.............................................................................................................1144
zbi.state................................................................................................................................................. 1145
zpl.calibrate.......................................................................................................................................... 1146
zpl.format_prefix................................................................................................................................. 1147
zpl.caret.................................................................................................................................................1148
29
Contents
zpl.control_character.........................................................................................................................1149
zpl.delimiter..........................................................................................................................................1150
zpl.label_length....................................................................................................................................1151
zpl.label_length_always................................................................................................................... 1152
zpl.left_position...................................................................................................................................1153
zpl.system_error................................................................................................................................. 1154
zpl.system_status............................................................................................................................... 1156
zpl.zpl_mode....................................................................................................................................... 1159
zpl.zpl_override.................................................................................................................................. 1160
zpl.relative_darkness..........................................................................................................................1161
SGD Wired Commands.............................................................................................................................. 1162
external_wired.check........................................................................................................................ 1163
external_wired.ip.addr...................................................................................................................... 1164
external_wired.ip.arp_interval........................................................................................................ 1165
external_wired.ip.default_addr_enable....................................................................................... 1166
external_wired.ip.dhcp.cid_all........................................................................................................ 1167
external_wired.ip.dhcp.cid_enable............................................................................................... 1168
external_wired.ip.dhcp.cid_prefix..................................................................................................1169
external_wired.ip.dhcp.cid_suffix...................................................................................................1170
external_wired.ip.dhcp.cid_type..................................................................................................... 1171
external_wired.ip.gateway............................................................................................................... 1172
external_wired.ip.netmask............................................................................................................... 1173
external_wired.ip.port........................................................................................................................1174
external_wired.ip.protocol............................................................................................................... 1175
external_wired.ip.timeout.enable...................................................................................................1176
external_wired.ip.timeout.value......................................................................................................1177
external_wired.ip.v6.addr.................................................................................................................1178
external_wired.ip.v6.gateway......................................................................................................... 1179
external_wired.ip.v6.prefix_length................................................................................................ 1180
external_wired.mac_addr................................................................................................................. 1181
external_wired.mac_raw.................................................................................................................. 1182
internal_wired.8021x.password......................................................................................................1183
internal_wired.8021x.peap.validate_server_certificate........................................................... 1184
30
Contents
internal_wired.8021x.peap.anonymous_identity....................................................................... 1185
internal_wired.8021x.private_key_password............................................................................. 1186
internal_wired.8021x.security..........................................................................................................1187
internal_wired.8021x.ttls_tunnel.................................................................................................... 1188
internal_wired.8021x.username..................................................................................................... 1189
internal_wired.activity_led..............................................................................................................1190
internal_wired.auto_switchover...................................................................................................... 1191
internal_wired.enable........................................................................................................................1192
internal_wired.installed.....................................................................................................................1193
internal_wired.ip.addr........................................................................................................................1194
internal_wired.ip.arp_interval..........................................................................................................1195
internal_wired.ip.default_addr_enable........................................................................................ 1196
internal_wired.ip.dhcp.arp_verify...................................................................................................1197
internal_wired.ip.dhcp.cache_ip.................................................................................................... 1198
internal_wired.ip.dhcp.cid_all......................................................................................................... 1199
internal_wired.ip.dhcp.cid_enable............................................................................................... 1200
internal_wired.ip.dhcp.cid_prefix...................................................................................................1201
internal_wired.ip.dhcp.cid_suffix.................................................................................................. 1202
internal_wired.ip.dhcp.cid_type.................................................................................................... 1203
internal_wired.ip.dhcp.lease.last_attempt..................................................................................1204
internal_wired.ip.dhcp.lease.length............................................................................................. 1205
internal_wired.ip.dhcp.lease.server............................................................................................. 1206
internal_wired.ip.dhcp.lease.time_left.........................................................................................1207
internal_wired.ip.dhcp.option12.................................................................................................... 1208
internal_wired.ip.dhcp.option12_format......................................................................................1209
internal_wired.ip.dhcp.option12_value.........................................................................................1210
internal_wired.ip.dhcp.requests_per_session.............................................................................1211
internal_wired.ip.dns.servers.......................................................................................................... 1212
internal_wired.ip.gateway................................................................................................................ 1213
internal_wired.ip.netmask................................................................................................................ 1214
internal_wired.ip.port........................................................................................................................ 1215
internal_wired.ip.port_alternate..................................................................................................... 1216
internal_wired.ip.port_json_config................................................................................................ 1217
internal_wired.ip.protocol................................................................................................................ 1218
31
Contents
internal_wired.ip.timeout.enable....................................................................................................1219
internal_wired.ip.timeout.value..................................................................................................... 1220
internal_wired.ip.wins.addr..............................................................................................................1221
internal_wired.ip.wins.permanent_source................................................................................. 1222
internal_wired.mac_addr.................................................................................................................1223
internal_wired.mac_raw.................................................................................................................. 1224
SGD Wireless Commands.........................................................................................................................1225
bluetooth.address............................................................................................................................. 1226
bluetooth.afh_map............................................................................................................................ 1227
bluetooth.afh_map_curr..................................................................................................................1228
bluetooth.afh_mode......................................................................................................................... 1229
bluetooth.allow_non_display_numeric_comparison...............................................................1230
bluetooth.authentication...................................................................................................................1231
bluetooth.bluetooth_pin.................................................................................................................. 1232
bluetooth.clear_bonding_cache................................................................................................... 1233
bluetooth.date.................................................................................................................................... 1234
bluetooth.discoverable.................................................................................................................... 1235
bluetooth.enable................................................................................................................................1236
bluetooth.enable_reconnect.......................................................................................................... 1237
bluetooth.friendly_name................................................................................................................. 1238
bluetooth.json_config_channel_enable......................................................................................1239
bluetooth.power_class.....................................................................................................................1240
bluetooth.le.controller_mode..........................................................................................................1241
bluetooth.le.power_class................................................................................................................ 1242
bluetooth.le.minimum_security......................................................................................................1243
bluetooth.page_scan_window.......................................................................................................1244
bluetooth.local_name.......................................................................................................................1245
bluetooth.minimum_security_mode.............................................................................................1246
bluetooth.radio_auto_baud............................................................................................................1248
bluetooth.radio_version...................................................................................................................1249
bluetooth.short_address................................................................................................................. 1250
bluetooth.version................................................................................................................................1251
card.mac_addr................................................................................................................................... 1252
32
Contents
card.inserted.......................................................................................................................................1253
ip.active_network.............................................................................................................................. 1254
ip.addr...................................................................................................................................................1255
ip.arp_interval.....................................................................................................................................1256
ip.bootp.enable.................................................................................................................................. 1257
ip.dhcp.arp_verify..............................................................................................................................1258
ip.dhcp.auto_provision_enable.....................................................................................................1259
ip.dhcp.cache_ip............................................................................................................................... 1260
ip.dhcp.cid_all..................................................................................................................................... 1261
ip.dhcp.cid_enable............................................................................................................................1262
ip.dhcp.cid_prefix.............................................................................................................................. 1263
ip.dhcp.cid_suffix...............................................................................................................................1264
ip.dhcp.cid_type................................................................................................................................ 1265
ip.dhcp.cid_value.............................................................................................................................. 1266
ip.dhcp.enable....................................................................................................................................1267
ip.dhcp.lease.last_attempt..............................................................................................................1268
ip.dhcp.lease.server..........................................................................................................................1269
ip.dhcp.lease.time_left..................................................................................................................... 1270
ip.dhcp.ntp.enable.............................................................................................................................1271
ip.dhcp.ntp.received_servers........................................................................................................1272
ip.dhcp.option12................................................................................................................................. 1273
ip.dhcp.option12_format.................................................................................................................. 1274
ip.dhcp.option12_value.................................................................................................................... 1275
ip.dhcp.request_timeout..................................................................................................................1276
ip.dhcp.requests_per_session....................................................................................................... 1277
ip.dhcp.session_interval.................................................................................................................. 1278
ip.dhcp.user_class_id.......................................................................................................................1279
ip.dhcp.vendor_class_id................................................................................................................. 1280
ip.dns.domain...................................................................................................................................... 1281
ip.dns.servers..................................................................................................................................... 1282
ip.ftp.enable........................................................................................................................................ 1283
ip.ftp.execute_file.............................................................................................................................. 1284
ip.ftp.request_password..................................................................................................................1285
ip.gateway........................................................................................................................................... 1286
33
Contents
ip.http.admin_name.......................................................................................................................... 1287
ip.http.admin_password.................................................................................................................. 1288
ip.http.custom_link_name...............................................................................................................1289
ip.http.custom_link_url.....................................................................................................................1290
ip.http.enable.......................................................................................................................................1291
ip.http.faq_url......................................................................................................................................1292
ip.http.port........................................................................................................................................... 1293
ip.lpd.enable....................................................................................................................................... 1294
ip.mac_raw..........................................................................................................................................1295
ip.mirror.appl_path............................................................................................................................1296
ip.mirror.auto.......................................................................................................................................1297
ip.mirror.error_retry...........................................................................................................................1298
ip.mirror.feedback.auto....................................................................................................................1299
ip.mirror.feedback.freq.....................................................................................................................1300
ip.mirror.feedback.odometer...........................................................................................................1301
ip.mirror.feedback.path....................................................................................................................1302
ip.mirror.fetch......................................................................................................................................1303
ip.mirror.freq........................................................................................................................................1304
ip.mirror.freq_hours.......................................................................................................................... 1305
ip.mirror.interface.............................................................................................................................. 1306
ip.mirror.last_error............................................................................................................................. 1307
ip.mirror.last_time..............................................................................................................................1308
ip.mirror.mode.................................................................................................................................... 1309
ip.mirror.password..............................................................................................................................1310
ip.mirror.path.........................................................................................................................................1311
ip.mirror.reset_delay..........................................................................................................................1312
ip.mirror.server.................................................................................................................................... 1313
ip.mirror.success................................................................................................................................. 1314
ip.mirror.success_time...................................................................................................................... 1315
ip.mirror.username............................................................................................................................. 1316
ip.mirror.version...................................................................................................................................1317
ip.netmask............................................................................................................................................ 1318
ip.ntp.enable........................................................................................................................................ 1319
ip.ntp.log.............................................................................................................................................. 1320
34
Contents
ip.ntp.servers....................................................................................................................................... 1321
ip.pop3.enable................................................................................................................................... 1322
ip.pop3.password.............................................................................................................................. 1323
ip.pop3.poll..........................................................................................................................................1324
ip.pop3.server_addr......................................................................................................................... 1325
ip.pop3.username..............................................................................................................................1326
ip.port.................................................................................................................................................... 1327
ip.port_alternate................................................................................................................................ 1328
ip.port_json_config........................................................................................................................... 1329
ip.port_single_conn.......................................................................................................................... 1330
ip.port_single_conn_idle_timeout................................................................................................. 1331
ip.primary_network........................................................................................................................... 1332
ip.smtp.domain................................................................................................................................... 1333
ip.smtp.enable.................................................................................................................................... 1334
ip.smtp.server_addr.......................................................................................................................... 1335
ip.snmp.get_community_name..................................................................................................... 1336
ip.snmp.set_community_name...................................................................................................... 1337
ip.snmp.trap_community_name.................................................................................................... 1338
ip.snmp.enable................................................................................................................................... 1339
ip.tcp.enable....................................................................................................................................... 1340
ip.telnet.enable....................................................................................................................................1341
ip.tcp.nagle_algorithm......................................................................................................................1342
ip.udp.enable...................................................................................................................................... 1343
weblink.cloud_connect.enable...................................................................................................... 1344
weblink.enable................................................................................................................................... 1345
weblink.ip.conn[1|2].authentication.add.......................................................................................1346
weblink.ip.conn[1|2].authentication.entries................................................................................. 1348
weblink.ip.conn[1|2].authentication.remove................................................................................1349
weblink.ip.conn[1|2].location........................................................................................................... 1350
weblink.ip.conn[1|2].num_connections......................................................................................... 1351
weblink.ip.conn[1|2].maximum_simultaneous_connections...................................................1352
weblink.ip.conn[1|2].proxy................................................................................................................1353
weblink.ip.conn[1|2].retry_interval................................................................................................. 1355
weblink.ip.conn1.test.location.........................................................................................................1356
35
Contents
weblink.ip.conn[1|2].test.retry_interval......................................................................................... 1358
weblink.ip.conn1.retry_interval_random_max........................................................................... 1359
weblink.ip.conn1.test.test_on......................................................................................................... 1360
weblink.logging.clear........................................................................................................................1362
weblink.logging.entries....................................................................................................................1363
weblink.logging.max_entries..........................................................................................................1364
weblink.printer_reset_required.....................................................................................................1366
weblink.restore_defaults................................................................................................................. 1367
weblink.zebra_connector.authentication.add........................................................................... 1368
weblink.zebra_connector.authentication.entries......................................................................1369
weblink.zebra_connector.authentication.remove.................................................................... 1370
weblink.zebra_connector.enable................................................................................................... 1371
weblink.zebra_connector.proxy.................................................................................................... 1372
weblink.zebra_connector.version................................................................................................. 1374
wlan.11ac.80mhz_enable................................................................................................................. 1375
wlan.11d.enable...................................................................................................................................1376
wlan.11n.20mhz_only.........................................................................................................................1377
wlan.11n.aggregation.........................................................................................................................1378
wlan.11n.greenfield.............................................................................................................................1379
wlan.11n.rifs..........................................................................................................................................1380
wlan.11n.short_gi_40mhz..................................................................................................................1381
wlan.11n.short_gi_20mhz.................................................................................................................1382
wlan.8021x.enable.............................................................................................................................1383
wlan.8021x.validate_peap_server_certificate........................................................................... 1384
wlan.8021x.peap.anonymous_identity........................................................................................ 1385
wlan.8021x.authentication...............................................................................................................1386
wlan.8021x.eap.password............................................................................................................... 1387
wlan.8021x.eap.privkey_password...............................................................................................1388
wlan.8021x.peap.peap_password................................................................................................ 1389
wlan.8021x.peap.privkey_password............................................................................................ 1390
wlan.8021x.peap.peap_username.................................................................................................1391
wlan.8021x.eap.username...............................................................................................................1392
wlan.active_channels....................................................................................................................... 1393
wlan.adhoc_last_channel................................................................................................................1394
36
Contents
wlan.authenticated............................................................................................................................1395
wlan.authentication_error............................................................................................................... 1396
wlan.available..................................................................................................................................... 1397
wlan.allowed_band...........................................................................................................................1398
wlan.adhocautomode.......................................................................................................................1399
wlan.adhocchannel...........................................................................................................................1400
wlan.associated...................................................................................................................................1401
wlan.auth_type...................................................................................................................................1402
wlan.band_preference.....................................................................................................................1403
wlan.bssid............................................................................................................................................1404
wlan.channel.......................................................................................................................................1405
wlan.channel_mask.......................................................................................................................... 1406
wlan.country_code............................................................................................................................1407
wlan.current_tx_rate.........................................................................................................................1408
wlan.enable.........................................................................................................................................1409
wlan.encryption_index......................................................................................................................1410
wlan.encryption_key...........................................................................................................................1411
wlan.encryption_mode......................................................................................................................1413
wlan.essid............................................................................................................................................. 1414
wlan.firmware_version...................................................................................................................... 1415
wlan.ip.addr..........................................................................................................................................1416
wlan.ip.arp_interval............................................................................................................................ 1417
wlan.ip.default_addr_enable...........................................................................................................1418
wlan.ip.dhcp.arp_verify..................................................................................................................... 1419
wlan.ip.dhcp.cache_ip......................................................................................................................1420
wlan.ip.dhcp.cid_all............................................................................................................................1421
wlan.ip.dhcp.cid_enable..................................................................................................................1422
wlan.ip.dhcp.cid_prefix.................................................................................................................... 1423
wlan.ip.dhcp.cid_suffix..................................................................................................................... 1424
wlan.ip.dhcp.cid_type.......................................................................................................................1425
wlan.ip.dhcp.lease.last_attempt.................................................................................................... 1426
wlan.ip.dhcp.lease.length................................................................................................................ 1427
wlan.ip.dhcp.lease.server................................................................................................................1428
wlan.ip.dhcp.lease.time_left........................................................................................................... 1429
37
Contents
wlan.ip.dhcp.option12.......................................................................................................................1430
wlan.ip.dhcp.option12_format......................................................................................................... 1431
wlan.ip.dhcp.option12_value.......................................................................................................... 1432
wlan.ip.dhcp.request_timeout........................................................................................................1433
wlan.ip.dhcp.requests_per_session............................................................................................. 1434
wlan.ip.dhcp.session_interval........................................................................................................ 1435
wlan.ip.dns.servers............................................................................................................................1436
wlan.ip.gateway..................................................................................................................................1437
wlan.ip.netmask..................................................................................................................................1438
wlan.ip.port..........................................................................................................................................1439
wlan.ip.port_alternate.......................................................................................................................1440
wlan.ip.port_json_config...................................................................................................................1441
wlan.ip.protocol..................................................................................................................................1442
wlan.ip.timeout.enable..................................................................................................................... 1443
wlan.ip.timeout.value........................................................................................................................ 1444
wlan.ip.wins.addr............................................................................................................................... 1445
wlan.ip.wins.permanent_source....................................................................................................1446
wlan.keep_alive.enable....................................................................................................................1447
wlan.keep_alive.timeout..................................................................................................................1448
wlan.kerberos.kdc............................................................................................................................. 1449
wlan.kerberos.mode.........................................................................................................................1450
wlan.kerberos.password...................................................................................................................1451
wlan.kerberos.realm......................................................................................................................... 1452
wlan.kerberos.username................................................................................................................. 1453
wlan.leap_mode.................................................................................................................................1454
wlan.leap_password.........................................................................................................................1455
wlan.leap_username........................................................................................................................ 1456
wlan.mac_addr................................................................................................................................... 1457
wlan.mac_raw.....................................................................................................................................1458
wlan.operating_mode...................................................................................................................... 1459
wlan.password................................................................................................................................... 1460
wlan.permitted_channels................................................................................................................. 1461
wlan.pmf...............................................................................................................................................1462
wlan.poor_signal_threshold........................................................................................................... 1463
38
Contents
wlan.preamble.................................................................................................................................... 1464
wlan.private_key_password...........................................................................................................1465
wlan.region_code..............................................................................................................................1466
wlan.roam.interchannel_delay....................................................................................................... 1467
wlan.roam.interval............................................................................................................................. 1468
wlan.roam.max_chan_scan_time..................................................................................................1469
wlan.roam.max_fail............................................................................................................................1470
wlan.roam.monitor.............................................................................................................................. 1471
wlan.roam.rssi..................................................................................................................................... 1472
wlan.roam.signal.................................................................................................................................1473
wlan.rts_cts_enabled........................................................................................................................1474
wlan.security....................................................................................................................................... 1475
Supporting SGDs for Different Security Types..................................................................1477
wlan.signal_noise.............................................................................................................................. 1484
wlan.signal_quality............................................................................................................................1485
wlan.signal_strength.........................................................................................................................1486
wlan.station_name.............................................................................................................................1487
wlan.tx_power.................................................................................................................................... 1488
wlan.tx_rate.........................................................................................................................................1489
wlan.user_channel_list.................................................................................................................... 1490
wlan.username.................................................................................................................................... 1491
wlan.waveagent.enable...................................................................................................................1492
wlan.waveagent.udp_port...............................................................................................................1493
wlan.wep.auth_type..........................................................................................................................1494
wlan.wep.index.................................................................................................................................. 1495
wlan.wep.key1.....................................................................................................................................1496
wlan.wep.key2....................................................................................................................................1497
wlan.wep.key3....................................................................................................................................1498
wlan.wep.key4....................................................................................................................................1499
wlan.wpa.psk......................................................................................................................................1500
wlan.wep.key_format........................................................................................................................ 1501
wlan.wpa.groupkey_ciphersuite................................................................................................... 1502
wlan.wpa.pairwise_ciphersuite......................................................................................................1503
wlan.wpa.timecheck......................................................................................................................... 1504
39
Contents
wlan.wpa.wpa_version.................................................................................................................... 1505
Zebra Code Pages..................................................................................................................................... 1506
Zebra Code Page 850 — Latin Character Set......................................................................... 1507
Zebra Code Page 1250 — Central and Eastern European Latin Character Set...............1509
Zebra Code Page 1252— Latin Character Set........................................................................... 1511
Zebra Code Page 1253 — Modern Greek Character Set....................................................... 1513
Zebra Code Page 1254 — Turkish Character Set.................................................................... 1515
Zebra Code Page 1255 — Hebrew Character Set................................................................... 1517
ASCII............................................................................................................................................................. 1519
Fonts and Barcodes................................................................................................................................... 1521
Standard Printer Fonts..................................................................................................................... 1521
Proportional and Fixed Spacing................................................................................................... 1522
Scalable Versus Bitmapped Fonts...............................................................................................1524
Font Matrices......................................................................................................................................1524
Barcodes..............................................................................................................................................1526
Basic Format for Bar Codes.......................................................................................................... 1527
Barcode Field Instructions..............................................................................................................1528
Bar Code Command Groups.........................................................................................................1529
Mod 10 and Mod 43 CheckDigits.......................................................................................................... 1532
Mod 10 Check Digit..........................................................................................................................1532
Mod 43 Check Digit.........................................................................................................................1533
Error Detection Protocol........................................................................................................................... 1535
Introduction......................................................................................................................................... 1535
What is a Protocol?.................................................................................................................. 1535
How Protocols Work................................................................................................................ 1535
Request Packet Formats from the Host Computer................................................................. 1536
Header Block Fields.................................................................................................................1536
40
Contents
Data Block Fields...................................................................................................................... 1537
Response From the Zebra Printer................................................................................................1537
Zebra Packet Response.......................................................................................................... 1537
Header Block Fields................................................................................................................. 1538
Data Block Fields...................................................................................................................... 1538
Disguising Control Code Characters...................................................................................1539
Error Detection Protocol Application...................................................................................1540
Error Conditions and System Faults....................................................................................1540
How the Zebra Printer Processes a Request Packet.......................................................1541
How the Zebra Printer Responds to Host Status.............................................................1542
ZB64 Encoding and Compression.......................................................................................................... 1543
Introduction to B64 and Z64......................................................................................................... 1543
B64 and Z64 Encoding................................................................................................................... 1545
Field Interactions........................................................................................................................................1547
Real Time Clock......................................................................................................................................... 1554
Control Panel Programming.......................................................................................................... 1555
Real Time Clock Parameters......................................................................................................... 1555
Idle Display................................................................................................................................. 1555
RTC Date..................................................................................................................................... 1555
RTC Time.....................................................................................................................................1556
RTC General Information.........................................................................................................1557
First Day of the Week Affects Calendar Week.................................................................1558
Time and Date Precision........................................................................................................ 1559
ZPL II Samples...........................................................................................................................1560
ZBI Character Set...................................................................................................................................... 1564
SGD Command Support............................................................................................................................1567
SGDs Supported for Industrial Printers.......................................................................................1567
41
Contents
SGDs Supported for Desktop Printers.........................................................................................1591
SGDs Supported for Mobile Printers............................................................................................1614
Mirror............................................................................................................................................................1640
Mirror Overview.................................................................................................................................1640
Benefits........................................................................................................................................ 1640
Professional Services for Mirror Configuration..................................................................1641
Requirements...............................................................................................................................1641
Wireless Markup Language (WML)......................................................................................................... 1657
WML Overview...................................................................................................................................1657
WML Details........................................................................................................................................1657
Supported Printers............................................................................................................................1658
Professional Services for WML Content Creation................................................................... 1659
WML Tags........................................................................................................................................... 1659
Using WML..........................................................................................................................................1659
Create a Sample index.wml File...........................................................................................1659
Prepare the Printer to Receive WML Content via FTP................................................... 1660
Send WML Content to the Printer via FTP................................................................................. 1661
Resetting the ip.ftp.execute_file Setting.................................................................................... 1662
Sending WML Content to the Printer via the CISDFCRC16 Command.............................. 1662
Retrieving WML Content from the Printer using the file.type Command...........................1663
Using .nrd Files from WML Menus...............................................................................................1663
Removing WML or .nrd Files from the Printer using the file.delete Command................ 1664
WML Examples.................................................................................................................................. 1664
Example 1.....................................................................................................................................1664
Example 2................................................................................................................................... 1665
Example 3....................................................................................................................................1666
Example 4....................................................................................................................................1668
Example 5....................................................................................................................................1670
Troubleshooting Scenarios.............................................................................................................1674
Using Weblink.............................................................................................................................................1676
42
Contents
When Should Weblink be Used?................................................................................................. 1676
Configuring Weblink.........................................................................................................................1676
Basic Configuration...................................................................................................................1676
When a Proxy Server is Part of the Network Configuration.................................................. 1677
When HTTP Authentication is Necessary.................................................................................. 1678
Additional Firewall Configuration................................................................................................. 1678
Difference Between Conn1 and Conn2...................................................................................... 1679
Enable Logging..................................................................................................................................1679
Navigating the Log Output............................................................................................................ 1680
SSL/TLS Certificate Errors.............................................................................................................. 1680
Other Typical Errors......................................................................................................................... 1682
Troubleshooting.................................................................................................................................1683
HTTP Messages................................................................................................................................ 1684
HTTP POST Alerts..................................................................................................................................... 1686
Configuring Alerts Where the Alert Destination is HTTP POST...........................................1686
How to Parse via PHP.....................................................................................................................1687
Basic Configuration...........................................................................................................................1687
When a Proxy Server is Part of the Network Configuration................................................. 1688
When HTTP Authentication is Necessary..................................................................................1689
Enabling Logging.............................................................................................................................. 1690
Navigating the Log Output............................................................................................................ 1690
Understanding Errors in the Alerts HTTP Log...........................................................................1691
Troubleshooting..................................................................................................................................1691
HTTP Messages................................................................................................................................ 1692
Advanced Techniques...............................................................................................................................1693
Special Effects for Print Fields...................................................................................................... 1693
Serialized Data...................................................................................................................................1693
Variable Data......................................................................................................................................1694
Stored Formats.................................................................................................................................. 1694
Initialize/Erase Stored Formats..................................................................................................... 1694
Download Format Command........................................................................................................ 1694
43
Contents
Field Number Command................................................................................................................ 1694
Recall Stored Format Command.................................................................................................. 1695
Control Commands.......................................................................................................................... 1695
Test and Setup Commands........................................................................................................... 1696
Calibration and Media Feed Commands................................................................................... 1697
Cancel/Clear Commands................................................................................................................ 1697
Printer Control Commands.............................................................................................................1697
Set Dots/Millimeter........................................................................................................................... 1698
Host Status Commands.................................................................................................................. 1699
Changing Delimiters and Command Prefixes...........................................................................1699
Communication Diagnostics Commands................................................................................... 1700
Graphic Commands..........................................................................................................................1700
Image Move......................................................................................................................................... 1701
Working with Label Formats as Graphics........................................................................... 1701
Working with Hex Graphic Images............................................................................................... 1701
Alternative Data Compression Scheme for ~DG and ~DB Commands...............................1701
Recalling a Hexadecimal Graphic Image................................................................................... 1702
Reducing Download Time of Graphic Images..........................................................................1702
Transferring Object Between Storage Devices........................................................................1703
Deleting Graphics from Memory...................................................................................................1703
Defining and Using the AUTOEXEC.ZPL Function.................................................................. 1704
Memory, Flash Cards, and Font Cards....................................................................................... 1704
Shortcuts and Alternate Schemes for Writing ZPL II Scripts.................................................1706
Font Shortcuts............................................................................................................................ 1707
PDFium License..........................................................................................................................................1709
44
Introduction
Introduction
This guide is the unabridged, alphabetical reference of programming commands supported in the
firmware. This includes all ZPL commands and SGD commands.
IMPORTANT: These are important points to note when using ZPL and SGD commands:
• ZPL and SGD commands should be sent to the printer as separate files.
• Certain settings can be controlled by both ZPL and SGD. Configuration changes made in ZPL can affect
configuration changes made in SGD.
To contact Zebra or for technical support, visit www.zebra.com/contact.
Firmware
You can find the printer’s firmware version by printing a configuration label. For instructions to do so, see
your printer’s user guide. For firmware upgrades go to: www.zebra.com/firmware.
IMPORTANT: These are important points to note when using a Zebra G-Series printer:
• You can send instructions to the printer using multiple programming languages: EPL, ZPL, or SGD.
EPL and ZPL commands configure the printer, print labels, and get device status information. SGD
commands set and get configuration details. These three languages can be used without the need to
send the printer instructions to switch from one language to another.
• EPL, ZPL, and SGD commands must be sent to the printer as separate files. They cannot be used
together in one format, or set of commands. For example, if you send a series of SGD commands to the
printer and they are followed by a printable format, this needs to be done using separate files.
Many text editors and word processors can recreate most examples in this guide in ASCII format. However,
for other encodings such as Unicode, a text editor such as Microsoft Notepad is needed.
Who Should Use This Document
This is for programmers who are familiar working with programming languages.
45
ZPL Commands
ZPL Commands
This section contains the complete alphabetical listing of ZPL II commands.
How Commands Are Documented
Description: The first paragraph(s) provides an explanation of how the command is used, what it is capable
of, and any defining characteristics it has.
Format: The format explains how the command is syntactically arranged and what parameters it
contains. For example, the ^B8 command prints a EAN-8 bar code. The format of the ^B8 command is:
^B8o,h,f,g . It is arranged with the caret symbol (^ ), the command code (B8 ), and the parameters and are
replaced with supported values.
Parameters: In the parameters table, if a command has values that can be defined to make its function
more specific, these are outlined as parameters.
Still using the ^B8 example, the h parameter is defined as:
h = bar code height (in
dots)
If the command has no parameters – for example ~JA (Cancel All) – the parameter section is removed,
indicating that the format of the command (~JA ) is acceptable ZPL II code.
Examples: When the command is best clarified in context, an example of the ZPL II code is provided. Text
indicating exact code entered is printed in an easily recognizable Courier font. An example of code using
the ^B8 command looks like this:
^XA
^FO50,50
^B8N,100,Y,N
^FD1234567^FS
^XZ
Notice that the ^B8 parameter letters have been replaced with real values that apply to the command. In
this example N ,100 ,Y ,N have been entered.
Comments: A Comments section (if used) will show notes that are of value to a programmer, warnings of
potential command interactions, or command-specific information that should be taken into consideration.
Comments are also included next to parameters if they apply directly to a particular setting.
Values: 1 to 32000
Default: value set by ^BY
46
ZPL Commands
Basic ZPL Exercises and Examples
The purpose of these exercises is to introduce basic ZPL commands to novice ZPL users.
Make sure this checklist is complete
• Load the printer with labels that are big enough to give you ample space to work with.
• Print a configuration label.
• Look at the configuration label and make sure that the LEFT POSITION is set to 000 and LABEL TOP
is set to 000 .
• Determine the printer’s resolution. It is listed on the configuration label. 8/MM = 200 dpi, 12/MM = 300
dpi and 24/MM = 600 dpi.
Tips
These are some tips when using ZPL:
• Use the DOS text editor to write ZPL files.
• Save the file as a .txt file and copy it to the printer from DOS command line.
Before You Begin
Some things that are important to understand before you begin are:
• 200 dpi means the resolution of the printhead is 200 dots per inch. If you program the printer to draw a
line 100 dots long that equals a half inch. 100 dots on a 300 dpi printer prints a line 1/3 inch long.
• The home position that all your coordinates are referencing is at the left-hand trailing edge of the label
as the label comes out of the printer. (There are some exceptions to this.)
Exercises
The exercises start simple and gradually progress to give you an opportunity to try a variety of commonly
used ZPL commands. Not all commands are covered, but this should be a good core of commands to
learn. Some commands may not be supported due to the firmware version in your printer.
47
ZPL Commands
Exercise 1: Specify a Location for an Entered Name
1. Print your name on the label.
2. Start by printing just your name on the label. Use this format as a model:
3. Send this format to the printer:
1 Every format starts with the ^XA command
2 ^FO (field origin) command
3 ^FS (field separator) command
4 Every format ends with the ^XZ command
5 ^FD (field data) command. Insert your name in place of the xxxxxxxxxxx shown.
4. When the label prints correctly, alter the first number after the ^FOx. See how that change affects the
print position. Alter the second number after the ^FO50,x and see how that the print position.
Font instruction
^ADN
1. Alter the numbers after the ^ADN,x,x command.
• 18,10 is the smallest size you can make the D font.
• The first number is the height of the font in dots. The second number is the width in dots.
• You can use direct multiples up to ten times that size as a maximum.
180,100 is the largest you can make the D font.
• 25,18 would not be a valid size. The printer rounds to the next recognizable size.
2. Check the font matrices tables for other fonts to try. See Fonts andBarcodes on page 1521.
3. Try the zero scalable font ^A0N,x,x .
This font is scalable, and you can choose any height and width.
Rotation Commands
1. Change ^ADN to ^ADR , and then ^ADI , and then ^ADB .
See how the print position changes.
2. Add more fields.
48
ZPL Commands
3. Add two more fields to print directly under your name using the ^ADN,36,20 font and size:
Your street address
Your city, state, zip
4. You must add two more lines of code that start off with:
^XA
^FO50,50^ADN,36,20^FDxxxxxxxxxxx^FS
^FO (fill in the rest)
^FO (fill in the rest)
^XZ
Make sure all these fields print in the same font and size and left side of fields has same vertical
alignment.
Your name
1200 W Main Street
Anytown, Il 60061
Reverse Printing a Field
Write the following format and send to the printer:
^XA
^PR1
^FO100,100
^GB70,70,70,,3^FS
^FO200,100
^GB70,70,70,,3^FS
^FO300,100
^GB70,70,70,,3^FS
^FO400,100
^GB70,70,70,,3^FS
^FO107,110^CF0,70,93
^FR^FDREVERSE^FS
^XZ
To see the effects, remove:
^FR^FDREVERSE^FS
To see the effects, try removing one of the ^GB lines of code.
Label Reverse Print
Write the following format and send to the printer:
^XA^LRY
^FO100,50
^GB195,203,195^FS
49
^FO180,110^CFG
^FDLABEL^FS
^FO130,170
^FDREVERSE^FS
^XZ
To see the effects, remove:
^GB195,203,195^FS
Mirror Image of Label
Write the following format and send to the printer:
^XA^PMY
^FO100,100
^CFG
^FDMIRROR^FS
^FO100,160
^FDIMAGE^FS
^XZ
ZPL Commands
To see the effects, in the first line of code change ^PMY to ^PMN .
Print Orientation
Write the following format and send to the printer:
^XA^CFD
^POI
^LH330,10
^FO50,50
^FDZEBRA TECHNOLOGIES^FS
^FO50,75
^FDVernon Hills, IL^FS
^XZ
To see the effects, in the second line of code change ^POI to ^PON .
50
Exercise 2:Boxes and Lines
Use the address format from <X-refBlue>Exercise.
Add this new line to your existing format:
^FO50,200^GB200,200,2^FS
This prints a box one wide by one inch long and the thickness of the line is 2 dots.
Reposition and resize the square so that it goes around the name and address uniformly.
Print a line by adding:
^FO50,300^GB400,1,4,^FS
This prints a horizontal line two inches wide by 4 dots thick.
Print a vertical line using this code:
^FO100,50^GB1,400,4^FS
ZPL Commands
51
ZPL Commands
Exercise 3: Bar Codes — ^B3 Code 39 Barcode
Write the following format and send to the printer:
^XA
^FO50,50^B3N,N,100,Y,N^FD123456^FS
^XZ
Try changing each of the parameters in the ^B3 string so you can see the effects.
^B3o,e,h,f,g
^BY
For valid parameter choices, see ^B3 .
Insert the ^BY command just before the ^B3 to see how the narrow bar width can be altered.
^FO50,50^BY2^B3..etc ^BYx
Acceptable values for x are 1 through 10
Alter the ratio of the narrow to wide bar.
^FO50,50^BY2,3^B3..etc ^BY2,x
Acceptable values for x are 2.1 through 3 in .1 increments
Print out a ^B3 bar code with the interpretation line on top of the bar code and the bar code rotated 90
degrees.
Add a ^PQ just before the ^XZ to print several labels.
^PQ4
^XZ
^PR Print rate (in inches per second)
Add a ^PR command after the ^XA at the beginning of the format to change the print rate (print speed).
^XA
^PR4
then try ^PR6 . ^PRx acceptable values for x are 2 through 12 (check printer specs)
See how the print speed affects the print quality of the bar code. You may need to increase the printer
darkness setting at higher print speeds.
52
ZPL Commands
Exercise 4: ^SN —Serial Number Command
Send this format to the printer:
^XA
^FO100,100^ADN,36,20^SN001,1,Y^FS
^PQ3
^XZ
To vary the ^SNv,n,z to exercise increment/decrement and leading zeros functions, consult this guide.
If your serial number contains alpha and numeric characters, you can increment or decrement a specific
segment of the data even if it is in the middle, as this sample sequence shows:
ABCD1000EFGH, ABCD1001EFGH, ABCD1002EFGH
Send this file to the printer and to see how it increments the serial number. The ^SF command can also
work with alpha characters.
^XA
^FO100,100^ADN,36,20^FDABCD1000EFGH^SF%%%%dddd%%%%,10000^FS
^PQ15
^XZ
Notice how the field data character position aligns with the ^SF data string:
^ F D A B C D 1 0 0 0 E F G H
^ S F % % % % d d d d % % % %
1 0 0 0 0
2 0 0 0 0
3 0 0 0 0
And on through…
1 0 1 4 0 0 0 0
The last label prints ABCD1014EFGH .
The % is placed in positions that you do not want to increment or decrement, d = decimal, 10000 =
increment value.
For more details on ^SF , see ^SF .
53
ZPL Commands
Exercise 5:Saving a template to memory. ^IS and image save and image load.
This exercise helps you troubleshoot your code against the errors you see on your labels.
Send this format to the printer:
^XA
^FO20,30^GB750,1100,4^FS
^FO20,30^GB750,200,4^FS
^FO20,30^GB750,400,4^FS
^FO20,30^GB750,700,4^FS
^FO20,226^GB325,204,4^FS
^FO30,40^ADN,36,20^FDShip to:^FS
^FO30,260^ADN,18,10^FDPart number #^FS
^FO360,260^ADN,18,10^FDDescription:^FS
^FO30,750^ADN,36,20^FDFrom:^FS
^ISR:SAMPLE.GRF^FS
^XZ
Send this format:
^XA
^ILR:SAMPLE.GRF^FS
^FO150,125^ADN,36,20^FDAcme Printing^FS
^FO60,330^ADN,36,20^FD14042^FS
^FO400,330^ADN,36,20^FDScrew^FS
^FO70,480^BY4^B3N,,200^FD12345678^FS
^FO150,800^ADN,36,20^FDMacks Fabricating^FS
^XZ
In this way the template only needs to be sent one time to the printer’s memory. Subsequent formats can
be sent recalling the template and merging variable data into the template. In this exercise, the file was
saved in the printers R: memory, which is volatile.
54
ZPL Commands
Exercise 6: ^DF and ^XF — Download Format and Recall Format
Similar concept to ^IS and ^IL command. ^IS and ^IL processes faster in the printer than ^DF and ^XF .
This is how the ^DF and ^XF format structure produces a label similar to the ^IS /^IL sample you just
tried.
Figure 1 Download and Recall Format
1 Download format code
2 Recall format call that generates the generated label.
55
ZPL Commands
Exercise 7: Asian and Unicode Encodings
This exercise works on printers with firmware version V60.14, V50.14, or later.
In each of the following examples, the format is saved in the corresponding encoding before being sent
down to the printer and the ZPL script was made in Microsoft Notepad, a basic text editor. The characters
were inserted from the character map in Windows or typed from the keyboard.
Example: This is an example of using an Asian encoding, such as UHANGUL, with ASCII text. Using the
CI26 command tells the printer to recognize any byte less than 7F as ASCII text and every byte above as
the first byte of UHANGUAL encoding:
Example: This is an example of using the Unicode encoding, UTF-8:
Allowed Characters in File Names
Files on the internal printer drives (R:, E:, etc.) can be created or accessed using several different
commands (for example, ^DF , ^XF , ^TO ,etc.). The names of the file can contain ONLY the characters
shown here
Shaded areas indicate characters which cannot be used. The command and control characters (normally ^
and ~) cannot be used unless the control characters are changed to something else using the ^CC~CC ZPL
command.
56
ZPL Commands
Char. DEC OCT HEX Char. DEC OCT HEX Char. DEC OCT HEX
(sp) 32 0040 0x20 @ 64 0100 0x40 ` 96 0140 0x60
! 33 0041 0x21 A 65 0101 0x41 a 97 0141 0x61
" 34 0042 0x22 B 66 0102 0x42 b 98 0142 0x62
# 35 0043 0x23 C 67 0103 0x43 c 99 0143 0x63
$ 36 0044 0x24 D 68 0104 0x44 d 100 0144 0x64
% 37 0045 0x25 E 69 0105 0x45 e 101 0145 0x65
& 38 0046 0x26 F 70 0106 0x46 f 102 0146 0x66
' 39 0047 0x27 G 71 0107 0x47 g 103 0147 0x67
( 40 0050 0x28 H 72 0110 0x48 h 104 0150 0x68
) 41 0051 0x29 I 73 0111 0x49 i 105 0151 0x69
* 42 0052 0x2a J 74 0112 0x4a j 106 0152 0x6a
+ 43 0053 0x2b K 75 0113 0x4b k 107 0153 0x6b
, 44 0054 0x2c L 76 0114 0x4c l 108 0154 0x6c
- 45 0055 0x2d M 77 0115 0x4d m 109 0155 0x6d
. 46 0056 0x2e N 78 0116 0x4e n 110 0156 0x6e
/ 47 0057 0x2f O 79 0117 0x4f o 111 0157 0x6f
0 48 0060 0x30 P 80 0120 0x50 p 112 0160 0x70
1 49 0061 0x31 Q 81 0121 0x51 q 113 0161 0x71
2 50 0062 0x32 R 82 0122 0x52 r 114 0162 0x72
3 51 0063 0x33 S 83 0123 0x53 s 115 0163 0x73
4 52 0064 0x34 T 84 0124 0x54 t 116 0164 0x74
5 53 0065 0x35 U 85 0125 0x55 u 117 0165 0x75
6 54 0066 0x36 V 86 0126 0x56 v 118 0166 0x76
7 55 0067 0x37 W 87 0127 0x57 w 119 0167 0x77
8 56 0070 0x38 X 88 0130 0x58 x 120 0170 0x78
9 57 0071 0x39 Y 89 0131 0x59 y 121 0171 0x79
: 58 0072 0x3a Z 90 0132 0x5a z 122 0172 0x7a
; 59 0073 0x3b [ 91 0133 0x5b { 123 0173 0x7b
< 60 0074 0x3c \ 92 0134 0x5c 124 0174 0x7c
= 61 0075 0x3d ] 93 0135 0x5d } 125 0175 0x7d
> 62 0076 0x3e ^ 94 0136 0x5e ~ 126 0176 0x7e
? 63 0077 0x3f _ 95 0137 0x5f (del) 127 0177 0x7f
57
^A
ZPL Commands
The ^A command specifies the font to use in a text field. ^A designates the font for the current ^FD
statement or field. The font specified by ^A is used only once for that ^FD entry. If a value for ^A is not
specified again, the default ^CF font is used for the next ^FD entry.
Scalable/Bitmapped Font
Format: ^Afo,h,w
Parameter Details
f = font name
o = field
orientation
h = Character
Height (in dots)
Values: A through Z , and 0 to 9
Any font in the printer (downloaded, EPROM, stored fonts, fonts A through Z and 0
to 9 ).
IMPORTANT: Parameter f is required. If f is omitted it defaults to the last
value of the ^CF command.
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: the last accepted ^FW value or the ^FW default
Scalable
Values: 10 to 32000
Default: last accepted ^CF
Bitmapped
Values: multiples of height from 1 to 10 times the standard height, in increments of
1
Default: last accepted ^CF
w = width (in dots)
Scalable Font Command
Example: This is an example of a scalable font command:
Scalable
Values: 10 to 32000
Default: last accepted ^CF
Bitmapped
Values: multiples of width from 1 to 10 times the standard width, in increments of 1
Default: last accepted ^CF
58
ZPL Commands
Bitmap Font Command
Example: This is an example of a bitmap font command:
Comments:
Fonts are built using a matrix that defines standard height-to-width ratios. If you specify only the height or
width value, the standard matrix for that font automatically determines the other value. If the value is not
given or a 0 (zero) is entered, the height or width is determined by the standard font matrix.
This command interacts with the justification parameters of ^FO and ^FT and with the field direction
parameter of ^FP . For output and examples, see Field Interactions on page 1547.
59
^A@
ZPL Commands
The ^A@ command uses the complete name of a font, rather than the character designation used in ^A .
Once a value for ^A@ is defined, it represents that font until a new font name is specified by ^A@ .
Use Font Name to Call Font
Format: ^A@o,h,w,d:f.x
Parameter Details
o = field orientation
h = character height (in
dots)
w = width (in dots)
Values:
N = normal
R = rotates 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: N or the last ^FW value
Default:
Specifies magnification by w (character width) or the last accepted ^CF
value. Uses the base height if none is specified.
• Scalable - The value is the height in dots of the entire character block.
Magnification factors are unnecessary, because characters are scaled.
• Bitmapped - The value is rounded to the nearest integer multiple of
the font’s base height, then divided by the font’s base height to give a
magnification nearest limit.
Default: Specifies magnification by h (height) or the last accepted ^CF
value. Specifies the base width is used if none is specified.
• Scalable - The value is the width in dots of the entire character block.
Magnification factors are unnecessary, because characters are scaled.
• Bitmapped - The value rounds to the nearest integer multiple of the
font’s base width, then divided by the font’s base width to give a
magnification nearest limit.
d = drive location of font
f = font name
x = extension
.TTE is only supported in
firmware version V60.14.x,
V50.14.x, or later.
Values: R: , E: , B: , and A:
Default: R :
Values: any valid font
Default: if an invalid or no name is entered, the default set by ^CF is used If
no font has been specified in ^CF , font A is used.
The font named carries over on all subsequent ^A@ commands without a
font name.
Values:
.FNT = font
.TTF = TrueType Font
.TTE = TrueType Extension
60
ZPL Commands
Example: This example identifies the purpose of each line of code for this label:
1 Starts the label format.
2 Searches non-volatile printer memory (B: ) for CYRI_UB.FNT . When the font is found, the ^A@
command sets the print orientation to normal and the character size to 50 dots by 50 dots.
3 Sets the field origin at 100,100.
4 Prints the field data, Zebra Printer Fonts on the label.
5 Calls the font again and character size is decreased to 40 dots by 40 dots.
6 Sets the new field origin at 100,150.
7 Prints the field data, This uses the B:CYRI_UB.FNT on the label.
8 Ends the label format.
For reference, see Zebra Code Page 850 — Latin Character Set on page 1507, Fonts andBarcodes on
page 1521, and ASCII on page 1519.
61
^B0
ZPL Commands
The ^B0 command creates a two-dimensional matrix symbology made up of square modules arranged
around a bulls-eye pattern at the center.
Aztec Barcode Parameters
NOTE: The Aztec barcode works with firmware version V60.13.0.11A and V50.13.2 or later.
Format: ^B0a,b,c,d,e,f,g
Parameters Details
a = orientation
b = magnification factor
c = extended channel
interpretation code
indicator
d = error control and
symbol size/type indicator
Values:
N = normal
R = rotated
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 10
Default:
1 on 150 dpi printers
2 on 200 dpi printers
3 on 300 dpi printers
6 on 600 dpi printers
Values:
Y = if data contains ECICs
N = if data does not contain ECICs
Default: N
Values:
0 = default error correction level
01 to 99 = error correction percentage (minimum)
101 to 104 = 1 to 4-layer compact symbol
201 to 232 = 1 to 32-layer full-range symbol
300 = a simple Aztec “Rune”
Default: 0
e = menu symbol
indicator
f = number of symbols
for structured append
Values:
Y = if this symbol is to be a menu (bar code reader initialization) symbol
N = if it is not a menu symbol
Default: N
Values: 1 through 26
Default: 1
62
ZPL Commands
Parameters Details
g = optional ID field for
structured append
Example: This is an example of the ^B0 command:
The ID field is a text string with 24-character maximum
Default: no ID
63
^B1
ZPL Commands
The ^B1 command produces the Code 11 bar code , also known as USD-8 code. In a Code 11 barcode,
each character is composed of three bars and two spaces, and the character set includes 10 digits and the
hyphen (-).
Code 11 Barcode
• ^B1 supports print ratios of 2.0:1 to 3.0:1.
• Field data (^FD ) is limited to the width (or length, if rotated) of the label.
IMPORTANT: If additional information about this barcode is required, go to aimglobal.org .
Format: ^B1o,e,h,f,g
Parameters Details
o = orientation
e = check digit
h = barcode height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values:
Y = 1 digit
N = 2 digits
Default: N
Values: 1 to 32000
Default: Value set by ^BY
Values:
Y = yes
N = no
Default: Y
Values:
Y = yes
N = no
Default: N
Example: This is an example of the Code 11 barcode:
64
ZPL Commands
65
^B2
ZPL Commands
The ^B2 command produces the Interleaved 2 of 5 bar code, a high-density, self-checking, continuous,
numeric symbology.
Interleaved 2 of 5 Bar Code
Each data character for the Interleaved 2 of 5 bar code is composed of five elements: five bars or five
spaces. Of the five elements, two are wide and three are narrow. The bar code is formed by interleaving
characters formed with all spaces into characters formed with all bars.
• ^B2 supports print ratios of 2.0:1 to 3.0:1.
• Field data (^FD ) is limited to the width (or length, if rotated) of the label.
IMPORTANT: If additional information about this bar code is required, go to aimglobal.org .
Format: ^B2o,h,f,g,e,j
Parameters Details
o = orientation
h = bar code height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
e = calculate and print
Mod 10 check digit
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 32000
Default: value set by ^BY
Values:
Y = yes
N = no
Default: Y
Values:
Y = yes
N = no
Default: N
Values:
Y = yes
N = no
Default: N
Example: This is an example of an Interleaved 2 of 5 bar code:
66
ZPL Commands
Comments: The total number of digits in an Interleaved 2 of 5 bar code must be even. The printer
automatically adds a leading 0 (zero) if an odd number of digits is received.
The Interleaved 2 of 5 bar code uses the Mod 10 check-digit scheme for error checking. For more
information on Mod 10 check digits, see Mod 10 Check Digit on page 1532.
67
^B3
ZPL Commands
The Code 39 barcode is the standard for many industries, including the U.S. Department of Defense.
It is one of three symbologies identified in the American National Standards Institute (ANSI) standard
MH10.8M-1983. Code 39 is also known as USD-3 Code and 3 of 9 Code.
Code 39 Barcode
Each character in a Code 39 barcode is composed of nine elements: five bars, four spaces, and an intercharacter gap. Three of the nine elements are wide; the six remaining elements are narrow.
• ^B3 supports print ratios of 2.0:1 to 3.0:1.
• Field data (^FD ) is limited to the width (or length, if rotated) of the label.
• Code 39 automatically generates the start and stop character (*).
• Asterisk (*) for start and stop character prints in the interpretation line, if the interpretation line is turned
on.
• Code 39 is capable of encoding the full 128-character ASCII set.
IMPORTANT: If additional information about this bar code is required, go to aimglobal.org .
Format: ^B3o,e,h,f,g
Parameters Details
o = orientation
e = Mod-43 check digit
h = bar code height (in
dots)
f = print interpretation
line
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values:
Y = yes
N = no
Default: N
Values: 1 to 32000
Default: value set by ^BY
Values:
Y = yes
N = no
Default: Y
g = print interpretation
line above code
Values:
Y = yes
N = no
Default: N
68
ZPL Commands
Example: This is an example of a Code 39 bar code:
Comments: Extended ASCII is a function of the scanner, not of the bar code. Your scanner must have
extended ASCII enabled for this feature to work. To enable extended ASCII in the Code 39, you must first
encode +$ in your ^FD statement. To disable extended ASCII, you must encode -$ in your ^FD statement.
Example: This example encodes a carriage return with line feed into a Code 39 bar code:
Full ASCII Mode for Code 39
Code 39 can generate the full 128-character ASCII set using paired characters as shown in thIS tables:
Table 1Code 39ASCII Set
ASCII CODE 39 ASCII Code 39
SP Space SOH $A
! /A STX $B
'' /B ETX $C
# /C EOT $D
$ /D ENQ $E
% /E ACK $F
& /F BEL $G
69
ZPL Commands
Table 1Code 39ASCII Set(Continued)
ASCII CODE 39 ASCII Code 39
' /G BS $H
( /H HT $I
) /I LF $J
* /J VT $K
+ /K FF $L
, /L CR $M
- - SO $N
. . SI $O
/ /O DLE $P
0 0 DC1 $Q
1 1 DC2 $R
2 2 DC3 $S
3 3 DC4 $T
4 4 NAK $U
5 5 SYN $V
6 6 ETB $W
7 7 CAN $X
8 8 EM $Y
9 9 SUB $Z
: /Z ESC %A
; %F FS %B
< %G FS %C
= %H RS %D
> %I US %E
? %J
@ %V ' %W
A A a +A
B B b +B
C C c +C
D D d +D
E E e +E
F F f +F
G G g +G
70
ZPL Commands
Table 1Code 39ASCII Set(Continued)
ASCII CODE 39 ASCII Code 39
H H h +H
I I i +I
J J j +J
K K k +K
L L l +L
M M m +M
N N n +N
O O o +O
P P p +P
Q Q q +Q
R R r +R
S S s +S
T T t +T
U U u +U
V V v +V
W W w +W
X X x +X
Y Y y +Y
Z Z z +Z
[ %K { %P
\ %L | %Q
] %M } %R
^ %N ~ %S
_ %O DEL %T, %T
71
^B4
ZPL Commands
The ^B4 command creates a multi-row, continuous, variable-length symbology capable of encoding the full
128-character ASCII set. It is ideally suited for applications requiring large amounts of data in a small space.
Code 49 Barcode
The code consists of two to eight rows. A row consists of a leading quiet zone, four symbol characters
encoding eight code characters, a stop pattern, and a trailing quiet zone. A separator bar with a height of
one module separates each row. Each symbol character encodes two characters from a set of Code 49
characters.
• ^B4 has a fixed print ratio.
• Rows can be scanned in any order.
IMPORTANT: If additional information about this barcode is required, go to aimglobal.org .
Format: ^B4o,h,f,m
Parameters Details
o = orientation
h = height multiplier of
individual rows
f = print interpretation
line
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to height of label
Default: value set by ^BY
This number multiplied by the module equals the height of the individual
rows in dots. 1 is not a recommended value.
Values:
N = no line printed
A = print interpretation line above code
B = print interpretation line below code
Default: N
When the field data exceeds two rows, expect the interpretation line to
extend beyond the right edge of the barcode symbol.
72
ZPL Commands
Parameters Details
m = starting mode
Example: This is an example of a Code 49 barcode:
Values:
0 = Regular Alphanumeric Mode
1 = Multiple Read Alphanumeric
2 = Regular Numeric Mode
3 = Group Alphanumeric Mode
4 = Regular Alphanumeric Shift 1
5 = Regular Alphanumeric Shift 2
A = Automatic Mode. The printer determines the starting mode by
analyzing the field data.
Default: A
73
ZPL Commands
74
ZPL Commands
Code 49 Field Data Character Set
The ^FD data sent to the printer when using starting modes 0 to 5 is based on the Code 49 Internal
Character Set. This is shown in the first column of the Code 49 table on the previous page. These
characters are Code 49 control characters:
: ; < = > ?
Valid field data must be supplied when using modes 0 to 5. Shifted characters are sent as a two-character
sequence of a shift character followed by a character in the unshifted character set.
To encode a lowercase a , send a > (Shift 2) followed by an uppercase A . If interpretation line printing
is selected, a lowercase a prints in the interpretation line. This reflects what the output from the scanner
reads. Code 49 uses uppercase alphanumeric characters only.
If an invalid sequence is detected, the Code 49 formatter stops interpreting field data and prints a symbol
with the data up to the invalid sequence. These are examples of invalid sequences:
• Terminating numeric mode with any characters other than 0 to 9 or a Numeric Space.
• Starting in Mode 4 (Regular Alphanumeric Shift 1) and the first field data character is not in the Shift 1 set.
• Starting in Mode 5 (Regular Alphanumeric Shift 2) and the first field data character is not in the Shift 2
set.
• Sending Shift 1 followed by a character not in the Shift 1 set.
• Sending Shift 2 followed by a character not in the Shift 2 set.
• Sending two Shift 1 or Shift 2 control characters.
Advantages of Using the Code 49 Automatic Mode
Using the default (Automatic Mode) completely eliminates the need for selecting the starting mode or
manually performing character shifts. The Automatic Mode analyzes the incoming ASCII string, determines
the proper mode, performs all character shifts, and compacts the data for maximum efficiency.
Numeric Mode is selected or shifted only when five or more continuous digits are found. Numeric
packaging provides no space advantage for numeric strings consisting of fewer than eight characters.
75
^B5
ZPL Commands
The ^B5 command is supported in all printers as a resident bar code. Accepted bar code characters are
0-9.
Planet Code Barcode
Format: ^B5o,h,f,g
Parameters Details
o = orientation code Values:
N = normal
R = rotated
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
h = bar code height (in
dots)
f = interpretation line
g = determines if the
interpretation line is
printed above the bar
code
Example: This is an example of a Planet Code bar code:
Values: 1 to 9999
Default: value set by ^BY
Values:
N = no
Y = yes
Default: N
Values:
N = no
Y = yes
Default: N
76
^B7
ZPL Commands
The ^B7 command produces the PDF417 bar code, a two-dimensional, multirow, continuous, stacked
symbology. PDF417 is capable of encoding over 1,000 characters per bar code. It is ideally suited for
applications requiring large amounts of information at the time the bar code is read.
PDF417 Bar Code
The bar code consists of three to 90 stacked rows. Each row consists of start and stop patterns and symbol
characters called code-words . A code-word consists of four bars and four spaces. A three code-word
minimum is required per row.
The PDF417 bar code is also capable of using the structured append option (^FM ), which allows you to
extend the field data limitations by printing multiple bar codes. For more information on using structured
append, see ^FM .
• PDF417 has a fixed print ratio.
• Field data (^FD) is limited to 3K of character data.
Format: ^B7o,h,s,c,r,t
Parameters Details
o = orientation
h = bar code height
for individual rows (in
dots)
s = security level
c = number of data
columns to encode
Values:
N = normal R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to height of label
Default: value set by ^BY
This number multiplied by the module equals the height of the individual rows
in dots. If this number is not specified, the overall bar code height, divided
by the number of rows, equals the height of the individual rows in dots,
where the overall bar code height is defined by the ^BY command. 1 is not a
recommended value.
Values: 1 to 8 (error detection and correction)
Default: 0 (error detection only)
This determines the number of error detection and correction code-words to
be generated for the symbol. The default level provides only error detection
without correction. Increasing the security level adds increasing levels of error
correction and increases the symbol size.
Values: 1 to 30
Default: 1:2 (row-to-column aspect ratio)
You can specify the number of code-word columns giving control over the width
of the symbol.
77
ZPL Commands
Parameters Details
r = number of rows
to encode
t = truncate right
row indicators and
stop pattern
Example: This is an example of a PDF417 bar code:
Values: 3 to 90
Default: 1:2 (row-to-column aspect ratio)
You can specify the number of symbol rows giving control over the height of
the symbol. For example, with no row or column values entered, 72 code-words
would be encoded into a symbol of six columns and 12 rows. Depending on
code-words, the aspect ratio is not always exact.
Values:
N = no truncation
Y = perform truncation
Default: N
Example: This is an example of a PDF417 without and with truncation selected:
78
ZPL Commands
Example: This example shows the ^B7 command used with field hex (^FH ) characters:
Comments: Noted in this bulleted list:
• If both columns and rows are specified, their product must be less than 928.
• No symbol is printed if the product of columns and rows is greater than 928.
• No symbol is printed if total code-words are greater than the product of columns and rows.
• Serialization is not allowed with this bar code.
• The truncation feature can be used in situations where label damage is not likely. The right row
indicators and stop pattern is reduced to a single module bar width. The difference between a non
truncated and a truncated bar code is shown in the previous examples.
Special Considerations for^BYWhen Using PDF417
When used with ^B7, the parameters for the ^BY command are:
w = module width (in dots)
Values: 2 to 10
79
ZPL Commands
Default: 2
r = ratio
Fixed Value: 3 (ratio has no effect on PDF417)
h = height of bars (in dots)
Values: 1 to 32000
Default: 10
PDF417 uses this only when row height is not specified in the ^B7 h parameter.
Special Considerations for ^FD When Using PDF417
The character set sent to the printer with the ^FD command includes the full ASCII set, except for those
characters with special meaning to the printer.
See Zebra Code Page 850 — Latin Character Set on page 1507, ^CC ~CC on page 150, and ^CT ~CT on
page 164.
• CR and LF are also valid characters for all ^FD statements. This scheme is used:
\& = carriage return/line feed
\\ = backslash (\)
• ^CI13 must be selected to print a backslash (\).
80
^B8
ZPL Commands
The ^B8 command is the shortened version of the EAN-13 bar code. EAN is an acronym for European
Article Numbering. Each character in the EAN-8 bar code is composed of four elements: two bars and two
spaces.
EAN-8 Barcode
• ^B8 supports a fixed ratio.
• Field data (^FD ) is limited to exactly seven characters. ZPL II automatically pads or truncates on the left
with zeros to achieve the required number of characters.
• When using JAN-8 (Japanese Article Numbering), a specialized application of EAN-8, the first two nonzero digits sent to the printer are always 49.
IMPORTANT: If additional information about this bar code is required, go to aimglobal.org .
Format: ^B8o,h,f,g
Parameters Details
o = orientation
h = bar code height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
Example: This is an example of an EAN-8 bar code:
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 32000
Default: value set by ^BY
Values:
N = no
Y = yes
Default: Y
Values:
N = no
Y = yes
Default: N
81
ZPL Commands
82
^B9
ZPL Commands
The ^B9 command produces a variation of the UPC symbology used for number system 0. It is a shortened
version of the UPC-A barcode, where zeros are suppressed, resulting in codes that require less printing
space.
UPC-E Barcode
The 6dot/mm, 12dot/mm, and 24dot/mm printheads produce the UPC and EAN symbologies at 100
percent of their size. However, an 8dot/mm printhead produces the UPC and EAN symbologies at a
magnification factor of 77 percent.
Each character in a UPC-E barcode is composed of four elements: two bars and two spaces. The ^BY
command must be used to specify the width of the narrow bar.
• ^B9 supports a fixed ratio.
• Field data (^FD) is limited to exactly 10 characters, requiring a five-digit manufacturer’s code and fivedigit product code.
• When using the zero-suppressed versions of UPC, you must enter the full 10-character sequence. ZPL II
calculates and prints the shortened version.
IMPORTANT: If additional information about this barcode is required, go to aimglobal.org .
Format: ^B9,h,f,g,e
Parameters Details
o = orientation
h = barcode height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 32000
Default: value set by ^BY
Values:
N = no
Y = yes
Default: Y
Values:
N = no
Y = yes
Default: N
e = print check digit
Values:
N = no
Y = yes
Default: Y
83
ZPL Commands
Example: This is an example of a UPC-E barcode:
Rules for Proper Product Code Numbers
• If the last three digits in the manufacturer’s number are 000, 100, or 200, valid product code numbers
are 00000 to 00999.
• If the last three digits in the manufacturer’s number are 300, 400, 500, 600, 700, 800, or 900, valid
product code numbers are 00000 to 00099.
• If the last two digits in the manufacturer’s number are 10, 20, 30, 40, 50, 60, 70, 80, or 90, valid product
code numbers are 00000 to 00009.
• If the manufacturer’s number does not end in zero (0), valid product code numbers are 00005 to
00009.
84
^BA
ZPL Commands
The ^BA command creates a variable length, continuous symbology. The Code 93 bar code is used in
many of the same applications as Code 39. It uses the full 128-character ASCII set. ZPL II, however, does
not support ASCII control codes or escape sequences. It uses the substitute characters shown below.
Code 93 Barcode
Control Code ZPL II Substitute
Ctrl $ &
Ctrl % ‘
Ctrl / (
Ctrl + )
Each character in the Code 93 bar code is composed of six elements: three bars and three spaces.
Although invoked differently, the human-readable interpretation line prints as though the control code has
been used.
• ^BA supports a fixed print ratio.
• Field data (^FD ) is limited to the width (or length, if rotated) of the label.
IMPORTANT: If additional information about this bar code is required, go to www.aimglobal.org .
Format: ^BAo,h,f,g,e
Parameters Details
o = orientation
h = bar code height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 32000
Default: value set by ^BY
Values:
N = no
Y = yes
Default: Y
Values:
N = no
Y = yes
Default: N
85
ZPL Commands
Parameters Details
e = print check digit
Example: This is an example of a Code 93 bar code:
Values:
N = no
Y = yes
Default: N
Comments: All control codes are used in pairs. Code 93 is also capable of encoding the full 128-character
ASCII set.
Full ASCII Mode for Code 93
Code 93 can generate the full 128-character ASCII set using paired characters as shown in the following
tables.
86
ZPL Commands
0
1
2
3
4
5
6
7
8
9
:
;
<
=
>
?
Space
.
/
O
1
2
3
4
5
6
7
8
9
(Z
‘F
‘G
‘H
‘I
‘J
87
^BB
ZPL Commands
The ^BB command produces a two-dimensional, multirow, stacked symbology. It is ideally suited for
applications that require large amounts of information.
CODABLOCK Barcode
Depending on the mode selected, the code consists of one to 44 stacked rows. Each row begins and ends
with a start and stop pattern.
• CODABLOCK A supports variable print ratios.
• CODABLOCK E and F support only fixed print ratios.
IMPORTANT: If additional information about this bar code is required, go towww.aimglobal.org .
Format: ^BBo,h,s,c,r,m
Parameters Details
o = orientation
h = bar code height for
individual rows (in dots)
s = security level
c = number of characters
per row (data columns)
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: N
Values: 2 to 32000
Default: 8 This number, multiplied by the module, equals the height of the
individual row in dots.
Values:
N = no
Y = yes
Default: Y
Security level determines whether symbol check-sums are generated and
added to the symbol. Check sums are never generated for single-row
symbols. This can be turned off only if parameter m is set to A .
Values: 2 to 62 characters
This is used to encode a CODABLOCK symbol. It gives the you control over
the width of the symbol.
88
ZPL Commands
Parameters Details
r = number of rows to
encode-
m = mode
Values:
for CODABLOCK A: 1 to 22
for CODABLOCK E and F: 2 to 4
• If values for c and r are not specified, a single row is produced.
• If a value for r is not specified, and c exceeds the maximum range, a
single row equal to the field data length is produced.
• If a value for c is not specified, the number of characters per row is
derived by dividing the field data by the value of r .
• If the s parameter is set to the default of Y, then the checksum
characters that are included count as two data characters . For example,
if c = 6, r is set to 3 and s is set to N, then up to 18 characters can be
used (6 x 3). However, if s is set to Y, then only 16 character can be
used.
• If the data field contains primarily numeric data, fewer than the specified
rows might be printed. If the field data contains several shift and codeswitch characters, more than the specified number of rows might be
printed.
Values: A , E , F
CODABLOCK A uses the Code 39 character set.
CODABLOCK F uses the Code 128 character set.
CODABLOCK E uses the Code 128 character set and automatically adds
FNC1.
Default: F
Example: This is an example of a CODABLOCK bar code:
89
ZPL Commands
Special Considerations for the ^BY Command When Using ^BB
The parameters for the ^BYw,r,h command, when used with a ^BB code, are as follows:
w = module width (in dots)
Values: 2 to 10 (CODABLOCK A only)
Default: 2
r = ratio
Fixed Value: 3 (ratio has no effect on CODABLOCK E or F)
h = height of bars (in dots)
Values: 1 to 32,32000
Default: 10
CODABLOCK uses this as the overall symbol height only when the row height is not specified in the ^BB h
parameter.
Special Considerations for ^FD Character Set When Using ^BB
The character set sent to the printer depends on the mode selected in parameter m.
CODABLOCK A: CODABLOCK A uses the same character set as Code 39. If any other character is used in
the ^FD statement, either no bar code is printed or an error message is printed (if ^CV is active).
CODABLOCK E:
The Automatic Mode includes the full ASCII set except for those characters with special meaning to the
printer. Function codes or the Code 128 Subset A <nul > character can be inserted using of the ^FH
command.
<fnc1> = 80 hex <fnc3> = 82 hex
90
ZPL Commands
<fnc2> = 81 hex <fnc4> = 83 hex
<nul> = 84 hex
For any other character above 84 hex, either no bar code is printed or an error message is printed (if ^CV is
active).
CODABLOCK F: CODABLOCK F uses the full ASCII set, except for those characters with special meaning
to the printer. Function codes or the Code 128 Subset A <nul > character can be inserted using of the ^FH
command.
<fnc1> = 80 hex <fnc3> = 82 hex
<fnc2> = 81 hex <fnc4> = 83 hex
<nul> = 84 hex
91
^BC
ZPL Commands
The ^BC command creates the Code 128 barcode, a high-density, variable length, continuous,
alphanumeric symbology. It was designed for complexly encoded product identification.
Code 128 Barcode (Subsets A, B, and C)
Code 128 has three subsets of characters. There are 106 encoded printing characters in each set, and each
character can have up to three different meanings, depending on the character subset being used. Each
Code 128 character consists of six elements: three bars and three spaces.
• ^BC supports a fixed print ratio.
• Field data (^FD ) is limited to the width (or length, if rotated) of the label.
IMPORTANT: If additional information about this barcode is required, go to aimglobal.org .
Format: ^BCo,h,f,g,e,m
Parameters Details
o = orientation
h = barcode height (in
dots)
f = print interpretation
line
g = print interpretation
line above code
e = UCC check digit
Values:
N = normal
R = rotated 90 degrees (clockwise)
I = inverted 180 degrees
B = read from bottom up, 270 degrees
Default: current ^FW value
Values: 1 to 32000
Default: value set by ^BY
Values: Y (yes) or N (no)
Default: Y
The interpretation line can be printed in any font by placing the font
command before the barcode command.
Values: Y (yes) or N (no)
Default: N
Values: Y (turns on) or N (turns off)
Mod 103 check digit is always there. It cannot be turned on or off. Mod 10
and 103 appear together with e turned on.
Default: N
92
ZPL Commands
Parameters Details
m = mode
Example: This is an example of a Code 128 barcode:
Values:
N = no selected mode
U = UCC Case Mode
• More than 19 digits in ^FD or ^SN are eliminated.
• Fewer than 19 digits in ^FD or ^SN add zeros to the right to bring the
count to 19. This produces an invalid interpretation line.
A = Automatic Mode
This analyzes the data sent and automatically determines the best packing
method. The full ASCII character set can be used in the ^FD statement
— the printer determines when to shift subsets. A string of four or more
numeric digits causes an automatic shift to Subset C.
D = UCC/EAN Mode (x.11.x and newer firmware)
This allows dealing with UCC/EAN with and without chained application
identifiers. The code starts in the appropriate subset followed by FNC1
to indicate a UCC/EAN 128 barcode. The printer automatically strips out
parentheses and spaces for encoding, but prints them in the humanreadable section. The printer automatically determines if a check digit is
required, calculate it, and print it. Automatically sizes the human readable.
Default: N
Figure 2Code 128 Barcode
Code 128 Subsets
The Code 128 character subsets are referred to as Subset A, Subset B, and Subset C. A subset can be
selected in these ways:
• A special Invocation Code can be included in the field data (^FD ) string associated with that barcode.
• The desired Start Code can be placed at the beginning of the field data. If no Start Code is entered,
Subset B are used.
To change subsets within a barcode, place the Invocation Code at the appropriate points within the field
data (^FD ) string. The new subset stays in effect until changed with the Invocation Code. For example, in
Subset C, >7 in the field data changes the Subset to A.
The table below shows the Code 128 Invocation Codes and Start Characters for the three subsets.
93
ZPL Commands
Table 2 Code 128 Invocation Characters
Invocation Code Decimal Value Subset A
Character
>< 62
>0 30 > >
>= 94 ~
>1 95 USQ DEL
>2 96 FNC 3 FNC 3
>3 97 FNC 2 FNC 2
>4 98 SHIFT SHIFT
>5 99 CODE C CODE C
>6 100 CODE B FNC 4 CODE B
>7 101 FNC 4 CODE A CODE A
>8 102 FNC 1 FNC 1 FNC 1
Start Characters
>9 103 Start CodeA (Numeric Pairs
>: 104 Start CodeB (Normal Alpha/
Subset B
Character
give Alpha/
Numerics)
Numeric)
Subset C
Character
>; 105 Stat CodeC (All Numeric(00 -
99)
The table belowshows the character sets for Code 128:
Table 3Code128Character Sets
Value CodeA CodeB CodeC Value CodeA CodeB CodeC
0 SP SP 00 53 U U 53
1 ! ! 01 54 V V 54
2 '' '' 02 55 W W 55
3 # # 03 56 X X 56
4 $ $ 04 57 Y Y 57
5 % % 05 58 Z Z 58
6 & & 06 59 [ [ 59
7 ' ' 07 60 \ \ 60
8 ( ( 08 61 ] ] 61
9 ) ) 09 62 ^ ^ 62
10 * * 10 63 _ _ 63
94
ZPL Commands
Table 3Code128Character Sets(Continued)
Value CodeA CodeB CodeC Value CodeA CodeB CodeC
11 + + 11 64 NUL . 64
12 , , 12 65 SOH a 65
13 - - 13 66 STX b 66
14 . . 14 67 ETX c 67
15 / / 15 68 EOT d 68
16 0 0 16 69 ENQ e 69
17 1 1 17 70 ACK f 70
18 2 2 18 71 BEL g 71
19 3 3 19 72 BS h 72
20 4 4 20 73 HT i 73
21 5 5 21 74 LF j 74
22 6 6 22 75 VT k 75
23 7 7 23 76 FF l 76
24 8 8 24 77 CR m 77
25 9 9 25 78 SO n 78
26 : : 26 79 SI o 79
27 ; ; 27 80 DLE p 80
28 < < 28 81 DC1 q 81
29 = = 29 82 DC2 r 82
30 > > 30 83 DC3 s 83
31 ? ? 31 84 DC4 t 84
32 @ @ 32 85 NAK u 85
33 A A 33 86 SYN v 86
34 B B 34 87 ETB w 87
35 C C 35 88 CAN x 88
36 D D 36 89 EM y 89
37 E E 37 90 SUB z 90
38 F F 38 91 ESC { 91
39 G G 39 92 FS | 92
40 H H 40 93 GS } 93
41 I I 41 94 RS ~ 94
42 J J 42 95 US DEL 95
43 K K 43 96 FNC3 FNC3 96
95
ZPL Commands
Table 3Code128Character Sets(Continued)
Value CodeA CodeB CodeC Value CodeA CodeB CodeC
44 L L 44 97 FNC2 FNC2 97
45 M M 45 98 SHIFT SHIFT 98
46 N N 46 99 CodeC CodeC 99
47 O O 47 100 CodeB FNC4 CodeB
48 P P 48 101 FNC4 CodeA CodeA
49 Q Q 49 102 FNC1 FNC1 FNC1
50 R R 50 103 START
(CodeA)
51 S S 51 104 START
(CodeB)
52 T T 52 105 START
(CodeC)
Example: The following figures are examples of identical barcodes.
Figure 3Subset B with no Start Character
Figure 4Subset B with Start Character
Example: Because Code 128 Subset B is the most commonly used subset, ZPL II defaults to Subset B if no
start character is specified in the data string.
This figure is an example of switching from Subset C to B to A.
Figure 5 Switching from Subset C to B to A
96
ZPL Commands
How^BCWorks Within a ZPL II Script
^XA – the first command starts the label format.
^FO100,75 – the second command sets the field origin at 100 dots across the x-axis and 75 dots down
the y-axis from the upper-left corner.
^BCN,100,Y,N,N – the third command calls for a Code 128 barcode to be printed with no rotation (N)
and a height of 100 dots. An interpretation line is printed (Y) below the barcode (N). No UCC check digit is
used (N).
^FDCODE128^FS (Figure A) ^FD>:CODE128^FS (Figure B) – the field data command specifies the content
of the barcode.
^XZ – the last command ends the field data and indicates the end of the label.
The interpretation line prints below the code with the UCC check digit turned off.
The ^FD command for Figure A does not specify any subset, so Subset B is used. In Figure B, the ^FD
command specifically calls Subset B with the >: Start Code. Although ZPL II defaults to Code B, it is good
practice to include the Invocation Codes in the command.
Code 128 – Subset B is programmed directly as ASCII text, except for values greater than 94 decimal and a
few special characters that must be programmed using the invocation codes. Those characters are:
^ > ~
Code 128 – Subsets A and C
Code 128, Subsets A and C are programmed in pairs of digits, 00 to 99, in the field data string. For details,
see Table 2Code 128 Invocation Characters on page 94.
In Subset A, each pair of digits results in a single character being encoded in the barcode; in Subset C,
characters are printed as entered. Figure E below is an example of Subset A (>9 is the Start Code for
Subset A).
Nonintegers programmed as the first character of a digit pair (D2) are ignored. However, nonintegers
programmed as the second character of a digit pair (2D) invalidate the entire digit pair, and the pair is
ignored. An extra unpaired digit in the field data string just before a code shift is also ignored.
The figures below are examples of Subset C. Notice that the barcodes are identical.
Figure 6Subset C with Normal Data
Figure 7Subset C with Ignored Alpha Character
97
ZPL Commands
In the program code for the figure below, the D is ignored and the 2 is paired with the 4.
Figure 8Subset A
The UCC/EAN-128 Symbology
The symbology specified for the representation of Application Identifier data is UCC/EAN-128, a variant of
Code 128, exclusively reserved to EAN International and the Uniform Code Council (UCC).
NOTE: It is not intended to be used for data to be scanned at the point of sales in retail outlets.
UCC/EAN-128 offers several advantages. It is one of the most complete, alphanumeric, one-dimensional
symbologies available today. The use of three different character sets (A, B and C), facilitates the encoding
of the full 128 ASCII character set. Code 128 is one of the most compact linear barcode symbologies.
Character set C enables numeric data to be represented in a double density mode. In this mode, two
digits are represented by only one symbol character saving valuable space. The code is concatenated.
That means that multiple AIs and their fields may be combined into a single barcode. The code is also
very reliable. Code 128 symbols use two independent self-checking features which improves printing and
scanning reliability.
UCC/EAN-128 barcodes always contain a special non-data character known as function 1 (FNC 1),
which follows the start character of the barcode. It enables scanners and processing software to autodiscriminate between UCC/EAN-128 and other barcode symbologies, and subsequently only process
relevant data.
The UCC/EAN-128 barcode is made up of a leading quiet zone, a Code 128 start character A, B, or C, a FNC
1 character, Data (Application Identifier plus data field), a symbol check character, a stop character, and a
trailing quiet zone.
UCC/EAN, UCC/128 are a couple of ways you'll hear someone refer to the code. This just indicates that the
code is structured as dictated by the application identifiers that are used.
SSCC (Serial Shipping Container Code) formatted following the data structure layout for Application
Identifier 00. See Table 4UCC/EAN Application Identifier on page 101. It could be 00 which is the
SSCC code. The customer needs to let us know what application identifiers are used for their barcode so
we can help them.
There are several ways of writing the code to print the code to Application Identifier '00' structure.
Using N for the Mode (m) Parameter
This example shows with application identifier 00 structure:
98
ZPL Commands
Figure 9 N for the M Parameter
• >;>8' sets it to subset C, function 1
• '00' is the application identifier followed by '17 characters', the check digit is selected using the 'Y' for
the (e) parameter to automatically print the 20th character.
• you are not limited to 19 characters with mode set to N
Using U for the Mode (m) Parameter
The example shows the application identifier 00 format:
Figure 10 U for the M Parameter
UCC Case Mode
• Choosing U selects UCC Case mode. You will have exactly 19 characters available in ^FD .
• Subset C using FNC1 values are automatically selected.
• Check digit is automatically inserted.
Using D for the Mode (m) Parameter
This example shows application identifier 00 format ((x.11.x or later):
Figure 11 D for the M Parameter
99
ZPL Commands
(0 at end of field data is a bogus character that is inserted as a place holder for the check digit the printer
will automatically insert.
• Subset C using FNC1 values are automatically selected.
• Parentheses and spaces can be in the field data. '00' application identifier, followed by 17 characters,
followed by bogus check digit place holder.
• Check digit is automatically inserted. The printer will automatically calculate the check digit and put it
into the barcode and interpretation line.
• The interpretation line will also show the parentheses and spaces but will strip them out from the actual
barcode.
Printing the Interpretation Line
This example shows printing the interpretation in a different font with firmware x.11.x or later:
Figure 12 Interpretation Line
The font command (^A0N,40,30 ) can be added and changed to alter the font and size of the
interpretation line.
With firmware version later than x.10.x
• A separate text field needs to be written.
• The interpretation line needs to be turned off.
• ^A0N,50,40 is the font and size selection for the separate text field.
• You have to make sure you enter the correct check digit in the text field.
• Creating a separate text field allows you to format the interpretation line with parentheses and spaces.
Figure 13 Firmware Older Than X.10.X
100