Man ual No. 980352-001 Rev.D©2003 ZIH Corp.EPL2Programmer’sManualProgramming for Page ModePrinting
Placing Elements inthe Print ImageIm age el e ments are lo cated in the im age printbuffer on a X-Y grid ex pressed in dots. The Xvalue rep re sents t
oW Command - Customize Bar Code Parameters Description: This com mand al lows the ad vanced pro gram -mer to mod ify spe cific bar code pa ram e ters
oW Com mand - Cus tom ize Bar Code Pa ram e tersRe set the printer with a ^@ or o com mandswith flash firm ware print ers or cy cle printerpower to cl
O Command - Hardware Options Description Use this com mand to se lect var i ous printer op -tions. Op tions avail able vary by printer con fig u -ra
O Com mand - Hard ware Op tions C = En able op tional La bel Liner Cut ter.The cut ter will cut at the end of eachform as spec i fied by the Q com m
OEPL1 Command - Set Line Mode Description: This com mand is used to switch the printer op -er at ing mode from Page Mode (EPL2) to LineMode (EPL1
P Command - Print Description Use this com mand to print the con tents of theim age buffer.Syntax Pp1, [p2]Parameters p1 = Num ber of la bel sets. R
PA Command - Print Automatic Description Use this com mand in a stored form se quence toau to mat i cally print the form (as soon as all vari -able d
q Command - Set Label Width Description Use this com mand to set the width of the print -able area of the me dia.Syntax qp1Parameters p1 = The width
q Com mand - Set La bel WidthAll Printers (Ex cep tions - 2746, 2746e & 2348)This com mand will au to mat i cally set the left mar ginac cord ing
Q Command - Set Form Length Description Use this com mand to set the form and gap length orblack line thick ness when us ing the transmissive(gap) s
Text (Fonts) The stan dard EPL2 printer has five (1-5) res i -dent mono-spaced dot fonts. Fonts A-Z and a-z(up per and lower case al pha char ac ters)
Q Com mand - Set Form LengthAutoSense rou tine does not de tect black lineor continuous media.All EPL2 print ers have a transmissive (gap) sen -sor de
Q Com mand - Set Form LengthExamples:980352-001 Rev.D 3-93p1p2p3p2Standard LabelButterfly LabelWhere:p = 20.0 mm (160 dots)1p = 3.0mm (24 dots)2The
Q Com mand - Set Form Length3-94 980352-001 Rev.Dp2p3Where:123p1p2p3Where:123p1p2p3Black Line Between PerforationWhere:p = 31.0 mm (248 dots)1p = 7.
r Command - Set Double Buffer Mode Description: Use this com mand to dis able or reenable thedou ble buffer im age (la bel) print ing. The dou -ble b
R Command - Set Reference Point Description Use this com mand to move the ref er ence pointfor the X and Y axes. All hor i zon tal and ver ti calmea
S Command - Speed Select Description Use this com mand to se lect the print speed. Mo bile print ers, such as the TR 220, ig nore thiscom mand and a
TD Command - Date Recall & Format Layout Description Use this com mand to de fine the date for mat and print date data. The TD vari able is in s
TS Command - Set Real Time Clock Description Use this com mand to set the time and date inprint ers equipped with the Real Time Clock op -tion.Syntax
TT Command - Time Recall & Format Layout Description Use this com mand to de fine the time for mat and print time data. The TT vari able is in s
U Command - Print Configuration (General) Description Use this com mand to print the cur rent printercon fig u ra tion for page mode print ing.
The text is placed into the im age buffer. See thefol low ing ex am ple.The ref er ence point of the first char ac ter in a textstring is not af fect
UA Command - Enable Clear Label Counter Mode Description This com mand sets the printer to clear (empty)the print buffer if a me dia out con di tion
UB Command - Reset Label Counter Mode Description Use this com mand to clear the UA com mandand re store the de fault set ting to al low theprinter t
UE Command - External Font Information Inquiry Description This com mand will cause the printer to send in -for ma tion about ex ter nal fonts c
UF Command - Form Information Inquiry Description This com mand will cause the printer to send in -for ma tion about forms cur rently stored in thepr
UG Command - Graphics Information Inquiry Description This com mand will cause the printer to send in -for ma tion about graph ics cur rently stored
UI Command - Host Prompts/Codepage Inquiry Description This com mand will cause the printer to en ableprompts to be sent to the host and it will send
UM Command - Codepage & Memory Inquiry DescriptionThis com mand will cause the printer to send tothe host the cur rently se lected codepage andme
UN Command - Disable Error Reporting Description Can cels US com mandSyntax UN980352-001 Rev.D 3-109
UP Command - Codepage & Memory Inquiry/Print DescriptionThis com mand will cause the printer to printand send the cur rently se lected codepage a
UQ Command - Configuration Inquiry Description Use this com mand to send the printer con fig u -ra tion in for ma tion back to the host via the se ri
Bar Codes All bar codes sup ported by the EPL2 lan guagehave as so ci ated in dus try spec i fi ca tions that thepro gram mer should be aware of
US Command - Enable Error Reporting Description Use this com mand to en able the printer’s sta tusre port ing fea ture.• Se rial Port - If an er ro
US Command - Enable Error ReportingCode Error/Status Description00 No Error01 Syntax Error02 Object Exceeded Label Border03Bar Code Data Length Error(
U% Command - Host Promts/Motor Temperature Description EPL Mo bile Printers Only (TR 220) - This com -mand will cause the printer to send to the host
U$ Command - Host Prompts/Battery Status Description Mo bile Printers Only (TR 220) - This com mandwill cause the printer to send to the host thebat
V Command - Define Variable Description Use this com mand to de fine vari able data forthe text and bar code data fields in stored forms.Vari able da
V Com mand - De fine Vari ableUse this com mand in forms that re quire uniquedata on each la bel. When initializing vari ables:• They must be de fined
W Command - Windows Mode Description This com mand is used to dis able/re-en able theWin dows com mand mode.Syntax Wp1Parameters p1 = Win dows Mode
xa Command - AutoSense Description This com mand is used to have the printer de tect the la bel and gap length and set the sen sor lev -els. This com
X Command - Box Draw Description Use this com mand to draw a box shape.Syntax Xp1,p2,p3,p4,p5Pa ram e tersp1 = Hor i zon tal start po si tion (X)
Y Command - Serial Port Setup Description Use this com mand to es tab lish the se rial portcom mu ni ca tion pa ram e ters. Syntax Yp1,p2,p3,p4Param
ProgrammingSequences AffectGraphic ResultsGraphic el e ments can in ter act and the re sul tantimage can be affected by other commands.Structure comma
Z Command - Print Direction Description Use this com mand to se lect the print ori en ta -tion.Syntax Zp1Parameters p1 = Print ori en ta tion. T =
? Command - Download Variables Description This com mand sig nals the printer to “fill-in”vari able or coun ter “prompt” data field. The host sys te
^@ Command - Reset Printer Description This com mand is used to re set the printer.Syntax^@¿ :where ^is 94 dec i malThis com mand em u lates Power Of
^default Command - Set Printer to Factory Defaults Description: Use this com mand to re turn the printer to its de -fault con fig u ra tion. The ^
^ee Command - Error Report - Immediate Description: Use this com mand to get printer er ror and sta tus re port im me di ately. The ^ee com mand
; Command - Code Comment Line Description This com mand sig nals the printer to ig nore thefol low ing data. All data be tween the line ini ti at -i
3-128 980352-001 Rev.D
Appendix A - Character ReferencesThis sec tion has char ac ter ref er ences.Resident Fonts 1-5 Page Mode sup ports 5 dif fer ent font sizes, num -
Default Character MapCode Page - 437Fonts 1-4 are rep re sented by the shaded andun shaded cells and Font 5 only sup portsshaded cells.See the I com m
Dump ModeCharacter MapThe printer’s Dump Mode is used to trou ble -shoot pro gram ming. The printer will print alldata as sent in Dump Mode Char ac te
Printer ConfigurationThis sec tion cov ers the in ter pret your printer’scon fig u ra tion setup and set ting ba sic modes.Printer AutoSenseFeatu
A-4 980352-001 Rev.D
Appendix B - Cash Drawer Kicker OptionThis sec tion has hard ware and pro gram mingfor the Cash Drawer Kicker. Introduction The cash drawer kicker is
Cash Drawer CableWiringThe fig ure be low dis plays the pin as sign mentsfor the printer’s re tail cash drawer in ter face. Re -fer to the cash draw
<Esc>p Command - Generate Pulse CDKDescription Gen er ate a drawer kicker pulse.Syntax <Esc>pp1 p2 p3Parameters p1 = Se lect DrawerDrawe
<Esc>u Command - CDK StatusDescription Re port the cash drawer kicker’s sta tus.Syntax <Esc>uParameters NoneStatus00 hex. = Cash Drawer O
Explanation of the Status PrintoutDetermining PrinterFirmware VersionThe printer ver sion num bers are a code used todoc u ment prod uct func tion and
Programming ModeConfigurationFlash based print ers are, by de fault, con fig uredfor Page (EPL2) mode op er a tions. The op er a -tor must con vert th
Media Detection Me dia de tec tion in EPL2 print ers is a com bi na -tion of pro gram ming and printer me dia sens ing. The Q (Set Form Length) and O
Command Reference This sec tion con tains a com plete list ing of allcom mands in al pha bet i cal or der. 980352-001 Rev.D 3-1
FOREWORDThis man ual pro vides pro gram ming in for ma tion for print ers fea tur ing Ze bra’s EPL2 Pro -gramming and com mand lan guage, wh
3-2 980352-001 Rev.DCom mand De scrip tion Mem ory ‡ PageA ASCII Text 3-4AUTOFR Au to matic Form Print ing 3-9B Bar Code 3-11B RSS-14 Bar Code 3-1
980352-001 Rev.D 3-3Com mand De scrip tion Mem ory ‡ PageO Op tions Se lect Stored 3-84OEPL1 Set Line Mode Writes 3-86P Print 3-87PA Print Au to m
A Command - ASCII Text Description Prints an ASCII text string.Syntax Ap1,p2,p3,p4,p5,p6,p7,“DATA”Parameters p1 = Hor i zon tal start po si tion (X)
A Command - ASCII TextThe backslash (\) character designates the fol-lowing character is a literal and will encode intothe data field. Refer to the fo
A Com mand - ASCII TextVariable Data andCounter FunctionsThe “Data” field can be re placed by or com -bined with the fol low ing com mands:Vnn= Prints
A Com mand - ASCII TEXTSimple Expressionsin Data FieldsAn ad vanced func tion of the A com mand al -lows ad di tion and sub trac tion to be per forme
A Com mand - Sim ple Ex pres sions in Data FieldsExample:¿FK"1"¿FK"1"¿FS"1"¿V00,10,N,"En ter cur rent mile age&qu
AUTOFR Command - Au to matic Form Print ing Description This spe cial form pro cess al lows you to de tachthe printer from the com puter and print
AUTOFR - Au to matic Form Print ing Fea tureAUTOFR treats any in com ing data as a vari able in -tended for print ing. This means if you send theprint
B Command - Bar Code Description Use this com mand to print stan dard bar codes.Syntax Bp1,p2,p3,p4,p5,p6,p7,p8,“DATA”Parameters p1 = Hor i zon tal
Table of ContentsIntroduction...1-1Command Conventions ...1-2Basic Command Syntax ...1-3Command Editor...
B Com mand - Bar Code3-12 980352-001 Rev.DDe scrip tion P4 ValueP5ValueCode 39 std. or extended 3 1-10Code 39 with check digit 3C 1-10Code 93 9 1-10Co
B Com mand - Bar CodeExample:¿N¿B10,10,0,3,3,7,200,B,"998152-001"¿P1¿Will Produce:Bar Codes withVariables & CountersThe data field can b
B Com mand - Bar CodeData with the RTCTime & DateFunctionsThe “Data” field can be re placed by or com -bined with the fol low ing vari ables:TT =
B Com mand - Bar CodeCode 128 Bar CodeFunction Characters(continued)A sin gle FCN4 tog gles be tween stan dard andex tended ASCII mode for only a sin
B Command - RSS-14 Bar Code Specific Options Description Use this com mand to print RSS-14 bar codefam ily bar codes for nu meric data. The printersu
B Com mand - RSS-14 Bar Code Spe cific Op tionsp7 = Bar code height in dots. See the ta bleabove for the Min i mum Height Mul ti -plier. The printer w
B Com mand - RSS-14 Bar Code Spe cific Op tionsExample #1N¿B100,100,0,RL,4,4,40,B,"1234567890"¿B100,300,0,R14,4,4,40,B,"1234567890"
B Com mand - RSS-14 Bar Code Spe cific Op tionsExample #2N¿B100,100,0,RL,4,4,40,B,"1234567890"¿B400,300,0,RT,4,4,40,B,"1234567890"
b Command - 2D Bar Code - Data Matrix Specific Options Description Use this com mand to print Data Ma trix two di -men sional bar code sym bols. The
b Com mand - 2D Bar Code - Data Ma trix Spe cific Options“DATA” = ASCII data or Bi nary data bytesAny com bi na tion of data strings, time fields(TT),
GM Command - Store Graphics ...3-60GW Command - Direct Graphic Write ...3-62I Command - Character Set Selection ...
b Com mand - 2D Bar Code - Data Ma trix Spe cific Op tions3-22 980352-001 Rev.DRowsCol umnsNu mericCa pac ity1Al pha-numericCa pac ity2Com presseddata
b Com mand - 2D Bar Code - Data Ma trix Spe cific Op tionsAutomatic DataMatrix Bar CodeGenerationThe printer au to mat i cally tests and changes theDa
b Com mand - 2D Bar Code - Data Ma trix Spe cific Op tions Example:N¿b30,20,D,h8,"Zebra Technologies corporation is the leadingworldwide manufact
b Command - 2D Bar Code - MaxiCode Specific Options Description Use this com mand to gen er ate MaxiCode barcode sym bols with a sin gle com mand. T
b Com mand - 2D Bar Code - MaxiCode Spe cific Op tionsp5= x,yAs so ci ated MaxiCode sym bol num ber ingwhere:x = Sym bol Num ber of y = To tal Num
b Com mand - 2D Bar Code - MaxiCode Spe cific Op tionsExample:N¿b20,20,M,"300,840,93065,1692,This is MaxiCode, but not MaxiCodefor mat ted data&
Using AIM Specified MaxiCode DataFormattingThe EPL printer can use and au to mat i cally de -code the AIM ITS (In ter na tional Tech ni cal Stan -dard
b Command - 2D Bar Code - PDF417 Specific Options Description Use this com mand to print PDF 417 and MacroPDF bar code sym bols. The printer will au
b Com mand - 2D Bar Code - PDF417 Spe cific Op tionsThe fol low ing pa ram e ters may be omit ted and de -fault val ues will au to mat i cally be in s
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions Auto-En cod ing (c0) data com pac tion methodis set by de fault, and pro vides the best com pac
US Command - Enable Error Reporting ...3-112U% Command - Host Promts/Motor Temperature ...3-114U$ Command - Host Prompts/Battery Status ..
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions p9 (f) = Bar code or i gin point Val ues: 0 or 1, De fault is 1f1- Cen ter of bar code as de fin
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions “DATA” = ASCII data or Bi nary data bytes Rep re sents a fixed data field.The back slash (
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions PDF417Symbol GeometryCol umns Max i mum Rows Codewords5 90 906 90 1807 90 2708 90 3609 90 45010
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions Automatic PDF 417Bar Code GenerationThe printer au to mat i cally tests and changes thePDF 417 ba
b Com mand - 2D Bar Code - PDF417 Spe cific Op tions Example:N¿b80,100,P,700,600,x2,y7,l100,r100,f0,s5," \ ¿Four score and seven years ago our f
C Command - Counter Description The coun ter (C) com mand de fines one of 10 au -to matic coun ters used in con sec u tive num ber -ing ap pli
C Com mand - Coun terThe C com mand is used in forms that re quire se -quen tial num ber ing. When initializing coun ters, they must be de fined in or
C Command - Cut Immediate Description: This com mand al lows the printer to ini ti ate an im me di ate me dia cut with out a form print op er -a tion
D Command - Density Description Use this com mand to se lect the print den sity. Syntax Dp1Parameters p1 = Den sity set ting. Ac cept able val ue
dump Command - Enable Dump Mode Description This com mand al lows the ad vanced pro gram -mer to force a user di ag nos tic “data dump”mode. Sending
vi 980352-001 Rev.D
eR Command - User Defined Error/Status Character Description This com mand al lows the ad vanced pro gram -mer to spec ify the printer’s er ror/sta
EI Command - Print Soft Font Information Description This com mand will cause the printer to print alist of all soft fonts that are stored in mem ory
EK Command - Delete Soft Font Description This com mand is used to de lete soft fonts frommem ory.Soft fonts can be down loaded to and de leted fromt
ES Command - Store Soft Font Description This com mand is used to down load and storesoft fonts in mem ory.Soft fonts can be down loaded to and de le
ES Com mand - Store Soft Font a1: (1st) Down load Char ac ter (map po si tion)Range: 00 to FF hex.b1: (1st) Spacing To Next Print Char ac terDown
ES Com mand - Store Soft Font For fonts with the ro ta tion pa ram e ter setfor “both” (p2 = 02 hex.):Re peat the in di vid ual font char ac ter
ES Com mand - Store Soft Font Soft FontsProgramming CodeExampleThe typ i cal soft font down load com mandstrings to the printer. The fol low ing ex am
ES Com mand - Store Soft Font Font Bitmap DataFormatThe black and white bitmap that rep re sents thefont must be con verted into ASCII hex a dec i mal
f Command - Cut Position Description Use this com mand on an in di vid ual printer topro vide pre ci sion cut place ment to:• Com pen sate for sm
FE Command - End Form Store Description This com mand is used to end a form store se -quence.Syntax FEExampleFS"FORMNAME"¿...FE¿The form s
IntroductionThis sec tion con tains in for ma tion about the ba -sic fea tures, com mand syn tax and ter mi nol ogyof the EPL2 Pro gramming Lan g
FI Command - Print Form Information Description This com mand will cause the printer to print alist of all forms stored in mem ory.Syntax FIExampleFI
FK Command - Delete Form Description This com mand is used to de lete forms frommem ory.Syntax FK [ “FORMNAME” | “*” ] Parameters “FORMNAME” = By en
FR Command - Retrieve Form Description Use this com mand to re trieve a form that waspre vi ously stored in mem ory.Syntax FR"FORMNAME"Para
FS Command - Store Form Description This com mand be gins a form store se quence. Syntax FS"FORMNAME"Parameters “FORMNAME” =This is the for
FS Com mand - Store FormExample¿FK"TESTFORM"¿ :de lete form “TESTFORM”FS"TESTFORM"¿ :be gins the form store se quence of :the form
GG Command - Print Graphics Description Use this com mand to print a PCX (for mat)graphic that has been pre vi ously stored inprinter mem ory.Syntax
GI Command - Print Graphics Information Description This com mand will cause the printer to print alist of all graph ics stored in mem ory.Syntax GIE
GK Command - Delete Graphics Description Use this com mand to de lete graph ics frommem ory.Syntax GK {“NAME”|"*"}Parameters “NAME” = By en
GM Command - Store Graphics Description Use this com mand to store PCX graph ics files inmem ory.SyntaxGM"NAME"p1¿“DATA”Parameters “NAME” =
GM Com mand - Store GraphicsExampleGK"LOGO1"¿ :de letes graphic “LOGO1” - Re quiredGK"LOGO1"¿ :sec ond de lete graphic - Re quired
CommandConventionsThe man ual uses the fol low ing ty po graphiccon ven tions to de scribe com mands.Ex am ple De scrip tionACom mands (Case Sen
GW Command - Direct Graphic Write Description Use this com mand to load bi nary graphic datadi rectly into the Im age Buffer mem ory for im -me di a
I Command - Character Set Selection Description Use this com mand to se lect the ap pro pri atechar ac ter set for print ing and dis play (KDU).Synta
I Com mand - Char ac ter Set Se lec tionp3 = KDU Coun try Code (8 bit data only)KDU Coun try Code (8 bit only)032 Bel gium 049 Ger many 027 S. Af rica
JB Command - Disable Top Of Form Backup Description This com mand dis ables the Top Of FormBackup fea ture when print ing mul ti ple la bels.At power
JC Command - Disable Top Of Form Backup- All Cases Description This com mand dis ables the Top Of FormBackup fea ture for all op er a tions. Use this
JF Command - Enable Top Of Form Backup Description This com mand en ables the Top Of FormBackup fea ture and pres ents the last la bel of abatch pri
LE Command - Line Draw Exclusive OR Description Use this com mand to draw lines with an “Ex clu -sive OR” func tion. Any area, line, im age or fieldt
LO Command - Line Draw Black Description Use this com mand to draw black lines, over writ -ing pre vi ous in for ma tion.Syntax LOp1,p2,p3,p4Parame
LS Command - Line Draw Diagonal Description Use this com mand to draw di ag o nal black lines,over writ ing pre vi ous in for ma tion.Syntax LSp1,p
LW Command - Line Draw White Description Use this com mand to draw white lines, ef fec -tively eras ing pre vi ous in for ma tion.Syntax LWp1,p2,p
Basic CommandSyntaxEach com mand con sists of one or two ASCII(case sen si tive) al pha char ac ters to iden tify thespe cific com mand de sired
M Command - Memory Allocation Description Use this com mand to set the size of form mem -ory. The re minder of the form stor age mem orywill be share
N Command - Clear Image Buffer Description This com mand clears the im age buffer prior tobuild ing a new la bel im age.Syntax NConsiderations ❏ Do n
o Command - Cancel Software Options Description This com mand al lows the user to can cel mostprinter cus tom iz ation pa ram e ters set by o se
oB Command - Cancel Auto Bar Code Optimization Description: This com mand al lows the ad vanced pro gram -mer to dis able bar code op ti mi za tion f
oE Command - Line Mode Font Substitution Description: This com mand is a Page Mode (EPL2) com -mand that al lows the printer to set al ter nateLine M
oH Command - Macro PDF Offset Description Use this com mand to place ad di tion sec ond ary,as so ci ated Macro PDF sym bols for the con tin u -a ti
oH Com mand - Macro PDF Off setExample:N¿q784¿Q1215,24¿R0,0¿oH0,500¿¿N¿b80,100,P,700,600,x2,y7,l100,r100,f0,s5,"\Four score and seven years ago o
oM Command - Disable Initial Esc Sequence Feed Description This com mand dis ables the au to matic la bel cal -i bra tion rou tine ex e cuted by the
oR Command - Character Substitution (Euro)Description This command allows the advanced program-mer to substitute the Euro currency characterfor any AS
oR Com mand - Char ac ter Sub sti tu tion (Euro)The oR com mand is a global printer com mand.❏ It can not be is sued in side of a form. ❏ It mus
Comments to this Manuals