All manuals and user guides at all-guides.com TABLE OF CONTENTS OKIPOS X400 Programming Guide Introduction .........................1 The Oki Data Programming Language ...............1 Selecting Protocol Control Codes ................2 Using Basic..........................2 Printing with the Parallel Port...................3 Printing with the RS232 Port...................4 The Print Area........................4 Rotated Fields..........................8...
Page 2
All manuals and user guides at all-guides.com Print Length, Expanded...................51 Line Feed ........................52 Media Size ........................54 Postnet ..........................55 Print Position .......................56 Print Quantity .......................58 Print Speed ........................59 Repeat Label .......................60 Replace Data (Partial Edit) .................61 Reverse Image ......................63 Rotate, Fixed Base Reference Point ..............65 Rotate, Moving Base Reference Point .............67 Sequential Numbering ...................69 Start/Stop Label .....................71...
OKIPOS X400 PROGRAMMING GUIDE INTRODUCTION This section presents the commands that are used with the OKIPOS X400 printer to produce labels with logos, bar codes, and alphanumeric data. The commands listed include all revisions of firmware. The following information is presented in this section:...
All manuals and user guides at all-guides.com This commands set the operational parameters of the printer, “set the print speed to 3.” <ESC>{Command} {Parameter} {Data} Some commands can contain both parameter and data elements, such as “print a code 39 symbol containing the data.”...
LPRINT E$;”A”; Sends an “<ESC>A” command code to the LPT1 parallel port LPRINT E$;”H400”;E$;”V100”;E$;”WL1OKI”; Sends the data “OKI” to be placed 400 dots horizontally and 100 dots vertically on the label and printed in the “WL” font. LPRINT E$;”Q1”; Instructs the printer to print one label.
Sends an “<ESC>A” command code to print port #1 opened by statement 20 above. PRINT #1,E$;”H400”;E$;”V100”;E$;”WL1OKI”; Sends the data “OKI” to be placed 400 dots horizontally and 100 dots vertically on the label and printed in the “WL” font. PRINT #1,E$;”Q1”;...
Page 7
All manuals and user guides at all-guides.com Normal Reference Point H1, V1 3” label length Your Label Label Feed 2:1” 2:0” Direction 7” Label Width from Edge Print Area 4.1” Print Area The base reference point is always on the right edge of the print head as you face the front (label exit) of the printer.
Page 8
Doing so will cause irreparable damage to the print head. This damage is not covered under the print head warranty. Base Reference Base Reference Point, H=0001 Point, H=0001 Label Label 4” 2” For example, the following illustrates a sample data stream and the resulting label assuming a four inch wide label: <ESC>A <ESC>H0050<ESC>V0100<ESC>L0303<ESC>MOKI <ESC>H0050<ESC>V0200<ESC>B103100*OKI* <ESC>H0070<ESC>V0310<ESC>L0101<ESC>UOKI <ESC>Q1<ESC>Z...
Page 9
Base Reference Point command to the second line of the data stream, the base reference point will be changed, causing the image to be shifted over toward the inside of the printer where it can be printed on the narrow label. <ESC>A <ESC>A3H0406V0001 <ESC>H0050<ESC>V0100<ESC>L0303<ESC>MOKI <ESC>H0050<ESC>V0200<ESC>B103100*OKI* <ESC>H0070<ESC>V0310<ESC>L0101<ESC>UOKI <ESC>Q1<ESC>Z 2” Label 4.1”...
All manuals and user guides at all-guides.com ROTATED FIELD The printers can rotate each print field in 90 increments using the Rotate command. There are two variations of this command. <ESC>% - The field rotates, but the base reference point for the field remains the same. <ESC>R - The field and the base reference point rotate.
(2) These values transmitted with these commands will remain in effect until a new command is received. PRINTER CONFIGURATION The OKIPOS X400 printers are different from other OKI models in that they do not use DIP switches for printer configuration. Instead, all printer configuration is done via software commands. The parameters that can be...
Page 12
All manuals and user guides at all-guides.com bottom of the label liner or tag. The eye-mark must not reflect more than 12% of the light. Since the same receiving sensor is used for all three types of sensing, it must be calibrated with the media that will be used. The ribbon must be installed while the calibration is being performed.
Page 13
All manuals and user guides at all-guides.com Explain the different commands and provide examples of their usage. To provide a detailed reference for programming. Each command begins on a separate page with its own heading. An uniform layout is used to help you find key information about each command.
All manuals and user guides at all-guides.com Bar Codes Command Structure 1:3 narrow/wide bar ratio: <ESC>Babbcccd 2:5 narrow/wide bar ratio: <ESC>BDabbcccd 1:2 narrow/wide bar ratio: <ESC>Dabbcccd Bar code Symbol Codabar Code 39 Interleaved 2 of 5 (I25) UPC-A/EAN-13 EAN-8 Industrial 2 of 5 Matrix 2 of 5 Code 93 UPC-E...
Page 15
All manuals and user guides at all-guides.com Input to Printer <ESC>A <ESC>H25<ESC>V25<ESC>B103100*CODE 39* <ESC>H155<ESC>V130<ESC>XS*CODE 39* <ESC>H25<ESC>V200<ESC>BD20210045676567 <ESC>H75<ESC>V310<ESC>XM45676567 <ESC>H25<ESC>V375<ESC>BD30215001234567890 <ESC>H25<ESC>V950<ESC>BA03100123455 <ESC>H95<ESC>V1060<ESC>XS12345 <ESC>H25<ESC>V1125<ESC>BC03100081234ABCD <ESC>H80<ESC>V1240<ESC>XS1234ABCD <ESC>H525<ESC>V25<ESC>B002100A12345B <ESC>H565<ESC>V135<ESC>XS123445 <ESC>H475<ESC>V200<ESC>BD303100123456789012 <ESC>H525<ESC>V375<ESC>BD4031001234567 <ESC>H525<ESC>V550<ESC>DE03100123456 <ESC>H500<ESC>V600<ESC>OB0 <ESC>H533<ESC>V655<ESC>OB123456 <ESC>H350<ESC>V725<ESC>D30315009827721123 <ESC>L0101<ESC>H320<ESC>V800<ESC>OB0 <ESC>H378<ESC>V878<ESC>OB98277 <ESC>H498<ESC>V878<ESC>OB21123 <ESC>H665<ESC>V760<ESC>BF0313021826 <ESC>H680<ESC>V730<ESC>OB21826 <ESC>H425<ESC>V1125<ESC>D30315000633895260 <ESC>L0101<ESC>H395<ESC>V1200<ESC>OB0 <ESC>H455<ESC>V1278<ESC>OB06338 <ESC>H572<ESC>V1278<ESC>OB95260 <ESC>H730<ESC>V1155<ESC>BF0314024 <ESC>H745<ESC>V1125<ESC>OB24 <ESC>H325<ESC>V950<ESC>BG03100>GAB>B789>C123456 <ESC>H435<ESC>V1055<ESC>XSAB789123456...
Page 16
All manuals and user guides at all-guides.com Printer Output...
Page 17
All manuals and user guides at all-guides.com UCC-128 Without Incrementing <ESC>A <ESC>H100<ESC>V200<ESC>BI04150101234567000000001 <ESC>Q2<ESC>Z With Incrementing <ESC>A <ESC>H100<ESC>V200<ESC>F001+001<ESC>BI04150101234567000000001 <ESC>Q2<ESC>Z...
Page 18
All manuals and user guides at all-guides.com Special Notes 1. UPC and EAN bar codes are not affected by the different types of narrow to wide ratios. Instead, the <ESC>D command adds descender bar to these codes where needed to meet UPC specification. The <ESC>BD command puts descender bars and human readable text below the symbol.
All manuals and user guides at all-guides.com Bar Codes, Expansion Command Structure <ESC>BWaabbb Expansion factor by which the width of all bars and spaces will be increased (01-12) bbb = Bar height by dot (004 - 999 dots) Example: <ESC>BW02100 Placement: Immediately follows the <ESC>BT command and precedes data to be encoded.
All manuals and user guides at all-guides.com Bar Codes, Variable Ratio Command Structure <ESC>BTabbccddee Bar Code Symbol Codabar Code 39 Interleaved 2 of 5 Industrial 2 of 5 Matrix 2 of 5 Narrow space in dots (01-99) Wide space in dots (01-99) Narrow bar in dots (01-99) Wide bar in dot (01-99) Example: <ESC>BT101030103...
Page 21
All manuals and user guides at all-guides.com Special Notes 1. This command must be immediately follow by the <ESC>BW Bar Code Exp -ansion command. You may use only one variable ratio bar code per label. If the data specified in this command is incorrect, the command is ignored and the ratio used will be based on the previous setting.
All manuals and user guides at all-guides.com Base Reference Point Command Structure <ESC>A3H-aaaaVbbbb This character is optional. When present, it specifies that the horizontal offset is the negative direction. If it is left out the offset direction is positive. aaaa = Horizontal Print Offset (-832 to 0832) bbbb = Vertical Print Offset (1 to 9999)
Page 23
For a more detailed example of the Base Reference Point command, see “Print Area” in this section. The OKIPOS X400 printers will not “wrap” (i.e. If any part of a character or image extends beyond the last print dot position. It will disappear and not be visible...
All manuals and user guides at all-guides.com Character, Custom-Designed Command Structure Store Command : <ESC>Tabcc Recall Command: <ESC>Kab90cc 16x16 matrix 24x24 matrix Specifies the character encoding method for the data stream hexadecimal characters Binary characters If B is specified than both 90 and cc codes are represented by one byte code separately.
Page 25
All manuals and user guides at all-guides.com <ESC>A <ESC>H150<ESC>V100<ESC>L0505<ESC>K1H903F <ESC>H350<ESC>V100<ESC>L1010<ESC>K1H903F <ESC>Q1<ESC>Z Printer Output Special Notes 1. When printing the custom character using the <ESC>K Recall command, the character is affected by the following commands: Character Expansion Character Pitch Line Feed Rotate, Fixed Base Reference Point Rotate, Moving Base Reference Point The characters are stored in volatile memory and must be reloaded if the printer...
All manuals and user guides at all-guides.com Character Expansion Command Structure <ESC>Laabb Multiple to expand horizontally (01~12) Multiple to expand vertically (01~12) Example: <ESC>L0304 Placement: Preceding the data to be expanded Default: L0101 Command Function To expand characters independently in both the horizontal and vertical directions.
Page 27
All manuals and user guides at all-guides.com Special Notes This command will expand the following fonts: Fonts U, S, M XU, XS, XM, OA & OB and fonts WB, WL, XB, and XL. This command will also affect the following commands: Character Pitch Characters, Custom-Designed The Character Expansion value is in effect for the current print job until a new...
All manuals and user guides at all-guides.com Character, Fixed Spacing Command Structure <ESC>PR Example: See above Placement: Preceding the data. Default: The default is Proportional Spacing for proportional fonts. Command Function To reset proportional spacing and place the printer to fixed spacing. Input to Printer <ESC>A <ESC>H100<ESC>V50<ESC>PS...
All manuals and user guides at all-guides.com Character Pitch Command Structure <ESC>Paa Number of dots between characters (00 ~ 99). Example: <ESC>P03 Placement: Preceding the text to be printed Default: <ESC>P02 Command Function To designate the amount of spacing (in dots) between characters. This com- mand provides a means of altering character spacing for label constraints or enhances readability.
Page 30
All manuals and user guides at all-guides.com Special Notes 1. This command is affected by the <ESC>L Character Expansion command. The Character Pitch is actually the product of the current horizontal expansion multiple and the designed pitch value. Example: <ESC>L0304 <ESC>P03 Pitch = (03) x (03) = 9 dots To avoid confusion, you may want to include the <ESC>L Character Expan-...
All manuals and user guides at all-guides.com Continuous Forms Printing Command Structure None The printer locates the end of adhesive label by sensing the backing between labels or through the use of an Eye-Mark (black rectangle on the reverse side of the backing).
All manuals and user guides at all-guides.com Character, Proportional Spacing Command Structure <ESC>PS Sets to proportional spacing. <ESC>PR Resets to fixed spacing. Example: See above Placement: Preceding the data to be proportionally spaced. Default: <ESC>PS Command Function To specify the printing of proportional or fixed spacing for proportionally spaced fonts.
All manuals and user guides at all-guides.com Clear Print Job(s) & Memory Command Structure <ESC>*a Specifies the internal memory section to be cleared. To clear the custom character memory. & To clear the form overlay memory. To clear all internal memory. Example: <ESC>*&...
All manuals and user guides at all-guides.com Copy Image Area Command Structure <ESC>WDHaaaaVbbbbXccccYdddd aaaa = Horizontal position of the top left corner of the area to be copied 0001 to 832. bbbb = Vertical position of the top left corner of the area to be copied 0001 to 1424.
Page 35
All manuals and user guides at all-guides.com Special Notes 1. Use the Print Position command (V and H) to locate the new area for the dup- licate image. Position of the new target area must not be inside the original image. If you use the Rotate command, V, H, X and Y axis will be reversed.
Enables cutter. Example: <ESC>CK1 Placement: Following the <ESC>Q Print Quality command. Default: Cutter is disabled Command Function To control the cutting of labels when using a OKI cutter unit with the printer. Input to Printer <ESC>A <ESC>H20<ESC>V20<ESC>WB1TEST LABEL <ESC>Q3 <ESC>CK1 <ESC>Z...
Special Notes 1. You must have the optional printer Peeler installed to use this function. Contact your OKI representative for more information. Sending a Peeler Enable command to a printer without a Peeler installed will halt the printer except you press the FEED button..
All manuals and user guides at all-guides.com Fonts U, S, M, OA, OB, XU, XS & XM Command Structure <ESC>XU Font XU <ESC>U Font U <ESC>XS Font XS <ESC>S Font S <ESC>XM Font XM <ESC>M Font M <ESC>OA Font OA <ESC>OB Font OB Example: See above...
Page 39
All manuals and user guides at all-guides.com Printer Output Special Notes 1. Characters may be enlarged through the use of Character Expansion command (see page 24). Character spacing may be altered through the use of the Character Pitch com- mand (see page 27). The default is 2 dots between characters. It is recom- mended to use a spacing of 5 dots for OCR-A and 1 dot for OCR-B.
All manuals and user guides at all-guides.com Fonts WB, WL, XB & XL Command Structure <ESC>WBa Font WB <ESC>XBa Font XB <ESC>WLa Font WL <ESC>XLa Font XL Provided for compatibility with CL Printers. Can be either a 0 or 1. Example: <ESC>WB1123456 Placement: Preceding the data to be printed.
Page 41
All manuals and user guides at all-guides.com Special Notes 1. Characters may be enlarged through the use of Character Expansion command (see page 24). Character spacing may be altered through the use of the Character Pitch com- mand (see page 27). A font must be defined for each field to be printed.
Command Function To specify printing of the unique vector font. The vector font allows large characters to be printed with smooth, round edges. Each character is made of a number of vectors (or outlines), and will require slightly more printer processing time. Input to Printer <ESC>A <ESC>H100<ESC>V100<ESC>$A,100,100,0<ESC>$=OKI <ESC>H100<ESC>V200<ESC>$=VECTOR FONT <ESC>$A,200,300,8<ESC>H100<ESC>V350<ESC>$=OKI <ESC>Q1<ESC>Z...
Page 43
All manuals and user guides at all-guides.com Printer Output Special Notes 1. The Pitch command can be used with Vector fonts. If the font size designation is out of the specified range, a default value of 50 is used. The font width and height values include asenders, desenders and other space. A font must be defined for each field to be printed.
All manuals and user guides at all-guides.com Form Feed Command Structure <ESC>A(space)<ESC>Z Example: See above Placement: Separate data stream sent to printer. Default: None Command Function To feed a blank tag or label, which is the equivalent of a “form feed”. Input to Printer <ESC>A(space) <ESC>Z...
All manuals and user guides at all-guides.com Form Overlay, Recall Command Structure <ESC>/ Example: See above Placement: Must be preceded by all other data and placed just before the Print Quality command (<ESC>Q). Default: None Command Function To recall the label image from the form overlay memory for printing. This command recalls a stored image from the overlay memory.
All manuals and user guides at all-guides.com Form Overlay, Store Command Structure <ESC>& Example: See above Placement: Must be preceded by all other data and placed just before the Stop command (<ESC>Z). Default: None Command Function To store a label image in the volatile form overlay memory. Only one label image may be stored in this memory area at a time.
All manuals and user guides at all-guides.com Graphics, Custom Command Structure <ESC>Gabbbccc(data) Specifies format of data stream to follow binary format. Hexadecimal format. bbb = Number of horizontal 8 x 8 blocks 001 to 104. ccc = Number of vertical 8 x 8 blocks 001 to 356.
Page 48
All manuals and user guides at all-guides.com <ESC>H300<ESC>V150<ESC>XSIN A SAFE PLACE <ESC>Q1<ESC>Z Printer Output Special Notes 1. Do not insert <CR> or <LF> codes (carriage return or line feed) as line deli- meters within the graphic data or the actual image will not be printed as specified.
All manuals and user guides at all-guides.com Graphics, PCX Command Structure <ESC>GPaaaaa,(data) aaaaa Number of bytes to be downloaded. Example: <ESC>GP32000,…data… See Appendix C for a detailed example. Placement: Anywhere within the job data stream. Default: None Command Function To allow the creation and printing of graphic images using a PCX file format. Input to Printer See Appendix C for a detailed example.
All manuals and user guides at all-guides.com Journal Print Command Structure <ESC>J Example: See above Placement: Immediately following <ESC>A. Default: None Command Function To print text in a line by line format on a label. By specifying this command, you automatically select Font S with a Character Expansion of 2x2. You also establish a base reference point of H2, V2.
All manuals and user guides at all-guides.com Lines and Boxes Command Structure Line: <ESC>FWaabcccc Width of horizontal line in dots (01 ~ 99). Line orientation Horizontal line. Vertical line. cccc = Length of line in dots. Box: <ESC>FWaabbVccccHdddd Width of horizontal side in dots (01 ~ 99). Width of vertical side in dots (01 ~ 99).
All manuals and user guides at all-guides.com Print Darkness Command Structure <ESC>#Ea Print darkness value a = 1,2,3,4 or 5 Example: <ESC>#E2 Placement: Must be placed immediately after <ESC>A and immediately before <ESC>Z in its own separate data stream. Default: Command Function To specify a new print darkness setting.
Page 53
All manuals and user guides at all-guides.com Print Length, Expanded Command Structure <ESC>AX Sets the print length to 14”(356 mm) <ESC>AR Resets the maximum print length to 7”(178 mm) <ESC>EX0 Sets the print length to 50”(1270 mm) Example: See above Placement: Must follow the Start Code command and be in its separate data stream.
Page 54
All manuals and user guides at all-guides.com Line Feed Command Structure <ESC>Eaaa aaa = Number of dots (001 ~ 999) between the bottom of the characters on one line to the top of the characters on the next line. Example: <ESC>E010 Placement: Preceding the text that will use the line feed function.
Page 55
All manuals and user guides at all-guides.com Following this command with a <CR> character will allow you to print with auto line feed. The print position will be determined from the value specified and the H value set in the printer. If you specify several H values after this command, the print position will be determined by the H value last specified.
Page 56
All manuals and user guides at all-guides.com Media Size Command Structure <ESC>A1aaaabbbb aaaa = Vertical Media Size in dots (0 to Vmax). bbbb = Horizontal Media Size in dots (0 to Hmax). Example: <ESC>A132000832 Placement: Separate data stream to the printer. Default: <ESC>A136000832 Command Function To set the size of the media.
Page 57
All manuals and user guides at all-guides.com Postnet Command Structure <ESC>BPn…n n…n = 5 digits (Postnet-32 format) 6 digits (Postnet-37 format) 9 digits (Postnet-52 format) 11 digits (Postnet-62 format, Delivery Point format). Example: <ESC>BP123456789 Placement: Immediately preceding the data stream to be encoded. Default: None Command Function To print Postnet bar codes.
Page 58
All manuals and user guides at all-guides.com Print Position Command Structure Horizontal Position <ESC>Haaaa Vertical Position <ESC>Vbbbb aaaa = Number of dots horizontally from the base reference point 1 to 832. bbbb = Number of dots vertically from the base reference point 1 to 8120.
Page 59
All manuals and user guides at all-guides.com Special Notes 1. The print position of a field is affected by both the Rotate (<ESC>R) and <ESC>A3 commands. If any part of an image is placed past maximum allowable dots across the label, that part of the image will be lost.
Page 60
<ESC>A <ESC>H100<ESC>V100<ESC>WB1OKI <ESC>Q3<ESC>Z Printer Output Three labels containing the data “OKI” will be printed. Special Notes 1. To cancel a print job, you must turn off the printer. When used with <ESC>F Sequential Numbering command (see page 69), the Print Quality value should be equal to the total number of labels to be printed.
Page 61
All manuals and user guides at all-guides.com Print Speed Command Structure <ESC>CSa Designates the speed selection. 1 ips (25 mm/s) 2 ips (50 mm/s) 3 ips (75 mm/s) 4 ips (100 mm/s) Example: <ESC>CS3 Placement: Must be placed immediately after <ESC>A and immediately before <ESC>Z in its own data stream.
Page 62
All manuals and user guides at all-guides.com Repeat Label Command Structure <ESC>C Example: See above Placement: Must be placed immediately after <ESC>A and immediately before <ESC>Z in its own data stream. Default: None Command Function To print duplicate of the last label printed. Input to Printer <ESC>A <ESC>C...
Page 63
All manuals and user guides at all-guides.com Replace Data (Partial Edit) Command Structure <ESC>0 Example: See above Placement: Must follow <ESC>A and precede all other print data. Default: None Command Function To replace a specified area of the previous label with new data. This command will cause the previous label to print along with any changes specified within the current data stream.
Page 64
All manuals and user guides at all-guides.com Special Notes 1. Specify the exact same parameters for the image to be replaced as were speci- fied in the original data stream, including rotation, expansion, pitch, etc.. This will ensure that the new data will exactly replace the old image. If the replace- ment data contains fewer characters than the old data, then the characters not replaced will still be printed.
Page 65
All manuals and user guides at all-guides.com Reverse Image Command Structure <ESC>(aaaa,bbbb aaaa = Horizontal length in dots of reverse image area 1 to 832. bbbb = Vertical height in dots of reverse image area 1 to 10150 Example: <ESC>(100,50 Placement: This command must be preceded by all other data and be placed just before <ESC>Q.
Page 66
All manuals and user guides at all-guides.com If the Rotate commands are used with this command, the V and H parameters are reversed. If the height and width to be reversed contain other than alphanumeric data, the area is not printed. If the values specified exceed the maximum ranges, the reverse image is not created.
Page 67
All manuals and user guides at all-guides.com Rotate, Fixed Base Reference Point Command Structure <ESC>%a Sets print to normal direction. Sets print to 90 CCW. Sets print to 180 CCW (upside down). Sets print to 270 CCW. Example: <ESC>%3 Placement: Preceding any printed data to be rotated. Default: <ESC>%0 Command Function To rotate the print direction in 90...
Page 68
All manuals and user guides at all-guides.com Special Notes 1. Do not combine this command and the <ESC>R rotate command in the same data stream. The specified values are valid until another Rotate (<ESC>%) command is received. Receipt of a Stop Print (<ESC>Z) command will reset the setting to the default value.
Page 69
All manuals and user guides at all-guides.com Rotate, Moving Base Reference Point Command Structure Normal Direction: <ESC>N Rotated Direction: <ESC>R Example: See above Placement: Preceding any printed data to be rotated. Default: <ESC>N Command Function The <ESC>R command rotates the printing data of all subsequent images in a print job by 90 counterclockwise each time it is used.
Page 70
All manuals and user guides at all-guides.com Special Notes 1. This command is provided for compatibility with other OKI printers. It is not recommended for new label designs and the <ESC>% rotate command should be used. Do not combine this command and the <ESC>% rotate command (see page 65) in the same data stream.
Page 71
All manuals and user guides at all-guides.com Sequential Numbering Command Structure <ESC>Faaaabcccc,dd,ee aaaa = Number of times to repeat the same data (0001 ~ 9999). Plus or minus symbol (+ for increments, – for decrements). cccc = Value of step for sequence (0001 ~ 9999). Number of digits for sequential numbering (01 ~ 99).
Page 72
All manuals and user guides at all-guides.com Printer Output Special Notes 1. The value specified for Print Quantity (see page 58) should be equal to the number of different sequential number desired multiplied by the number of repeats specified. Example: To print 2 sets each of the numbers 1001 ~ 1025 on separate labels, we need 50 total labels.
Page 73
Command Function For all print jobs, the Start command must precede the data, and the Stop com- mand must follow. The print job will not run properly if these are not in place. Input to Printer <ESC>A <ESC>H1<ESC>V100<ESC>WB1OKI <ESC>H130<ESC>V200<ESC>B103150*OKI* <ESC>H170<ESC>V360<ESC>L0202<ESC>S*OKI* <ESC>Q1<ESC>Z Printer Output There is no output for these commands they are not accompanied by other label printing commands.
Page 74
All manuals and user guides at all-guides.com Expanded Memory Option Commands These commands require the Expanded Memory Option. There are two types of Expanded Memory cards, 2MB and 4MB respectively.
Page 75
Printer Output There is no printer output as a result of this command. See <ESC>GR Recall Custom Graphics command. Special Notes 1. You must have the optional Expanded Memory to use this command. Call your Oki Data representative for details.
Page 76
All manuals and user guides at all-guides.com The maximum storage capacity is 999 graphics, up to the capacity of the memory expansion. Each graphic to be stored must be sent in its own data stream. Example of correct data stream: <ESC>A <ESC>GIHaaabbb001(DATA) <ESC>Z...
Page 77
All manuals and user guides at all-guides.com Expanded Memory Function Graphics, Custom Recall Command Structure <ESC>GRaaa aaa = Graphics storage number (1 ~ 999). Example: <ESC>GR111 Placement: The Recall command is sent in a secondary data stream to print the graphic, and follows any necessary position or size commands.
Page 78
There is no printer output as a result of this command. See <ESC>PY PCX Graphics Recall command. Special Notes 1. This command requires Expanded Memory option. Call your Oki Data representative for details. Graphics cannot be stored as part of a format.
Page 79
Input to Printer <ESC>A <ESC>CC1 <ESC>H1<ESC>V100<ESC>PY011 <ESC>%1<ESC>H176<ESC>V330<ESC>PY011 <ESC>%2<ESC>H585<ESC>V330<ESC>PY011 <ESC>%3<ESC>H760<ESC>V100<ESC>PY011 <ESC>Q1<ESC>Z Printer Output Special Notes 1. This command requires Expanded Memory option. See your Oki Data repre- sentative for details. See the <ESC>PI Store PCX Graphics command.
Page 80
Care should be exercised when using this command as it destroys any data previously written the specified section of memory. It will clear all data from the Expanded Memory and assign the new ID (“OKI” in the above example).
Page 81
Oki Data representative for more information. The OKIPOS X400 provides only one slot for the Expanded Memory option. For the OKIPOS X400 printer, CC1 stands for onboard 512K byte flash memory and CC2 for the Optional flash memory (2M/4M bytes).
Page 82
Input to Printer <ESC>A <ESC>CC2 <ESC>BJS <ESC>Z Printer Output MYCARD : 2097152 Bytes PCX GRAPHIC 1234 CUSTOM GRAPHIC (1) 5678 2090240 Bytes Free Special Note This command requires the Expanded Memory option. Call your local Oki Data representative for more information.
Page 83
All manuals and user guides at all-guides.com Two-Dimensional Symbols The following commands are used to create the two-dimensional symbologies supported by the printers.
Page 84
All manuals and user guides at all-guides.com Two-Dimensional Bar Codes Maxicode Command Structure <ESC>BVa,b,c,ddddddddd,eee,fff,gggg…<ESC> Position of Maxicode symbol within the set, when used in a structured append format 1~8. Total number of Maxicode symbols in the set, when used in a structured format 1~8.
Page 85
All manuals and user guides at all-guides.com Special Notes 1. Please refer to UPS Publication “Guide to Bar Coding with UPS Online - Version 5” for the UPS secondary message data format requirements and the latest format requirements. This command implements Maxicode AIM I.S.S. (UPS version 3.1) symbol. The following modes are supported.
Page 86
All manuals and user guides at all-guides.com Two-Dimensional Bar Codes PDF 417 Command Structure <ESC>BKaabbcddeeffffnn…n Minimum module dimension (03~09 dots). Will not print if values of 01, 02 or greater than 10 are specified. Minimum module pitch dimension (04 ~ 24 dots). Will not print if values of 01, 02, 03 or greater than 25 are specified.
Page 87
All manuals and user guides at all-guides.com Special Notes 1. When the code words per line and the number of rows per symbol (“dd” and “ee”) are set to all zeroes, the printer will calculate the optimum configuration. The product of the values entered for “dd” and “ee” are not equal to or less than the value of “ffff”...
Page 88
The following commands are used to set the operating parameters of the OKIPOS X400 printers. The settings currently active in the printer can be determined by printing a Test Label, either by using the <ESC>CT Print Test Label command or by pressing the FEED button while turning on the printer. (See the OKIPOS X400 User’s Guide).
Page 89
All manuals and user guides at all-guides.com Backfeed Enable Command Structure <ESC>CEa Disables Backfeed. Enables Backfeed. Example: <ESC>CE1 Placement: This command should be sent in a separate data stream. Default: Last setting. Command Function To select the top-of-label sensing method. Input to Printer <ESC>A <ESC>CE1...
Page 90
The sensor must be recalibrated whenever the sensor type is changed or in- correct label detection occurs. When calibrating the sensor for the OKIPOS X400 Thermal Transfer unit operating in the thermal transfer mode, the ribbon must be installed in the printer.
Page 91
All manuals and user guides at all-guides.com Custom Protocol Command Codes Download Command Structure <ESC>LD,a,b,c,d,e,f,g,h,i Replacement character for STX in ASCII or hex format Replacement character for ETX in ASCII or hex format Replacement character for ESC in ASCII or hex format Replacement character for ENQ in ASCII or hex format Replacement character for CAN in ASCII or hex format Replacement character for NULL in ASCII or hex format...
Page 92
All manuals and user guides at all-guides.com This command must be sent as an independent data stream immediately following the <ESC>A Start code and immediately preceding the <ESC>Z Stop code. No other commands can be included in the data stream. If more or less than nine commas are included in the command, the entire command sequence will be ignored.
Page 93
All manuals and user guides at all-guides.com Label Tear-Off Command Structure <ESC>CBabb + to move the print line down from the top edge of the label - to move the print line toward the top of the label. Distance moved in millimeters (00 to 25) Example: <ESC>CB+03 Placement: This command should be sent in a separate data stream.
Page 94
All manuals and user guides at all-guides.com Print Test Label Command Structure <ESC>CT Example: <ESC>CT Placement: This command should be sent in a separate data stream. Default: There is no default for this command. Command Function To print a test label. Input to Printer <ESC>A <ESC>CT...
Page 95
Special Notes 1. This command covers the complete range of heat settings. In general the Media Adjust Setting is ignored by the OKIPOS X400. The factory setting for these adjustments is set to provide the optimum results when using the Oki Data supplied media with the printer. It is recommended that any changes be made judiciously as they can have a significant impact on print quality and bar code readability.
Page 96
All manuals and user guides at all-guides.com Set RS232 Parameters Command Structure <ESC>CRaaaaa,b,c,d aaaaa = Baud rate (9600, 19200 or 38400) Parity (N for None, O for Odd, E for Even) Number of data bits (7 or 8) Number of stop bits (1 or 2) Example: <ESC>CR9600,N,8,1 Placement: Must be sent in a separate data stream.
Page 97
1 for Thermal Transfer Printing (with ribbon) Example: <ESC>CP0 Placement: Must precede all other commands in the data stream. Default: 1 for OKIPOS X400 model. Command Function To optimize the print head heat management algorithms. Input to Printer <ESC>A <ESC>CP0 <ESC>Z...
Page 98
All manuals and user guides at all-guides.com Set Sensor Type Command Structure <ESC>CIa Disables Sensor. Reflective (Eye-Mark) Sensing. Transmissive (Label Gap or Notch) Sensing. Example: <ESC>CI0 Placement: This command should be sent in a separate data stream. Default: <ESC>CI2 (Transmissive Sensing) Command Function To select the top-of-label sensing method.
Page 99
All manuals and user guides at all-guides.com APPENDIX A. COMMAND CODE QUICK REFERENCE INSTRUCTION DESCRIPTION PAGE Start code. Begins all print jobs. Page 71 A1aaaabbbb Media size. Specifies the label size. Used to automatically calculate Page 54 the offset for center justified labels. aaaa = Vertical length.
Page 100
All manuals and user guides at all-guides.com UCC 128 Number of dots (01-12) for narrow bar and narrow space ccc = Bar height in dots (001-600) UCC 128 only. Not used for other bar code types. No human readable text Human readable text at top Human readable text at bottom BDabbcccd...
Page 101
All manuals and user guides at all-guides.com BTabbccddee Bar codes. Variable ratio. Provides the ability to print a bar code Page 18 with a ratio other than those specified through the standard bar code commands (B, BD and D). Bar Code Symbol Codabar Code 39 Interleaved 2 of 5...
Page 102
All manuals and user guides at all-guides.com Calibration. Calibrates the media so that the print can recognize Page 88 the characteristics of the media used. CBabb Label Tear-Off. Page 91 + to move the print line down from the top edge of the label - to move the print line toward the top of the label.
Page 103
All manuals and user guides at all-guides.com 1 for Thermal Transfer Printing (with ribbon) CRaaaaa,b,c,d RS232 Setting. Sets the related parameters for the RS232 Page 94 communication. aaaaa = Baud rate (9600, 19200 or 38400) Parity (N for None, O for Odd, E for Even) Number of data bits (7 or 8) Number of stop bits (1 or 2) Print Speed Selection.
Page 104
All manuals and user guides at all-guides.com is 0. FWaaHbbbb Horizontal Line. Prints a horizontal line. Units of measurement are Page 49 dots. Width of horizontal line, 1 ~ 99. bbbb = Length of horizontal line, 1 ~ 1248. FWaabbVcccHdddd Box.
Page 105
All manuals and user guides at all-guides.com data = Hex or binary data to describe the graphic image GPaaaaa,(data) PCX Graphics. Prints a graphic with standard PCX format. Page 47 aaaaa = Number of bytes to be downloaded. GRaaa Expansion Memory Function. Recalls custom designed character Page 75 from expansion memory.
Page 106
All manuals and user guides at all-guides.com Font Type. Specifies the 13Wx20H dot matrix font (including Page 36 descenders). Normal Direction. Returns to the original base reference point and Page 67 returns printing to the normal orientation. Font Type. Specifies the OCR-A font with dot matrix. Page 36 OA Font Matrix: 15Wx22H.
Page 107
All manuals and user guides at all-guides.com Font Type. Specifies the 8Wx15H dot matrix font (including Page 36 descenders). Tabcc(data) Store Custom Designed Characters. To create and store custom Page 22 characters or images in the printer’s volatile memory. See Kab90cc to recall the character for printing.
Page 108
Sets print to 270 CCW. Print Darkness. a = 1~5. Page 50 $a,b,c,d Vector Font. Specifies printing of the unique OKI vector font. Page 40 Helvetica Bold (proportional spacing). Helvetica Bold (fixed spacing). Font width (24~999 dots) Font height (24~999 dots)
Page 109
All manuals and user guides at all-guides.com Font variation (0~9) as follows: Standard Standard open (outlined) Gray (mesh) pattern 1 Gray (mesh) pattern 2 Gray (mesh) pattern 3 Standard open, shadow 1 Standard open, shadow 2 Standard mirror image Italic Italic open, shadow $=(data) Data for Vector Font.
Page 110
All manuals and user guides at all-guides.com APPENDIX B. BAR CODE SPECIFICATION BAR CODE SYMBOLOGIES This section contains detailed information on the printing of bar codes on the OKIPOS X400 printers. Information on printing the following bar code symbologies is provided: Codabar Code 39...
Page 111
All manuals and user guides at all-guides.com Codabar Command Structure 1:3 ratio <ESC>B0bbcccd (data) d 2:5 ratio <ESC>BD0bbcccd (data) d 1:2 ratio <ESC>D0bbcccd (data) d Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) Required Start and Stop character (A,B,C, or D) (data) = Bar code data (alphanumeric) Character Set...
Page 112
All manuals and user guides at all-guides.com Code 39 Command Structure 1:3 ratio <ESC>B1bbccc* (data) * 2:5 ratio <ESC>BD1bbccc* (data) * 1:2 ratio <ESC>D1bbccc* (data) * Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) Required Start and Stop character (asterisk) (data) = Bar code data (alphanumeric)
Page 113
All manuals and user guides at all-guides.com Interleaved Two of Five Command Structure 1:3 ratio <ESC>B2bbccc (data) 2:5 ratio <ESC>BD2bbccc (data) 1:2 ratio <ESC>D2bbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric);...
Page 114
All manuals and user guides at all-guides.com UPC-A/EAN-13 Command Structure <ESC>B3bbccc (data) <ESC>D3bbccc (data) <ESC>BD3bbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric); must be exactly 13 digits. For UPC-A, the first digit must be a zero and the last 11 digits are the actual UPC-A data followed by a check digit.
Page 115
All manuals and user guides at all-guides.com 1. First add all the numbers in the ODD positions. i.e., 0+2+4+6+8+0 = 20 2. Multiple the result of step 1 by 3. i.e., 20 x 3 = 60 3. Add up all the numbers in the EVEN positions. i.e., 1+3+5+7+9 = 25 4.
Page 116
All manuals and user guides at all-guides.com EAN-8 Command Structure <ESC>B4bbccc (data) <ESC>D4bbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric); must be exactly 8 digits. Character Set 0-9 (numeric only) Density Table Value of “bb”...
Page 117
All manuals and user guides at all-guides.com Industrial Two of Five Command Structure 1:3 ratio <ESC>B5bbccc (data) 2:5 ratio <ESC>BD5bbccc (data) 1:2 ratio <ESC>D5bbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric);...
Page 118
All manuals and user guides at all-guides.com Matrix Two of Five Command Structure 1:3 ratio <ESC>B6bbccc (data) 2:5 ratio <ESC>BD6bbccc (data) 1:2 ratio <ESC>D6bbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric);...
Page 119
All manuals and user guides at all-guides.com Code 128 Command Structure <ESC>BGbbcccdd (data) Width of narrow element in dots (01~12). ccc = Bar height in dots (001~999) Start code to specify initial subset of bar code data. >G Subset A Start code. >H Subset B Start code.
Page 120
All manuals and user guides at all-guides.com Character Table The Code 128 table lists 105 data values for the three subsets: A, B and C. Each subset column displays either a single column of data or a double column of data. If the subset column displays a single column of data, this is the data to be entered to produce the result.
Page 121
All manuals and user guides at all-guides.com VALUE SUBSET A SUBSET B SUBSET C VALUE SUBSET A SUBSET B SUBSET C “ “ & & ‘ ‘ < < > >...
Page 122
All manuals and user guides at all-guides.com FNC3 FNC3 FNC2 FNC2 SHIFT SHIFT Subset C Subset C Subset B FNC4 Subset B FNC4 Subset A Subset A FNC1 FNC1 FNC1 Subset A Start Code Subset B Start Code Subset C Start Code...
Page 123
All manuals and user guides at all-guides.com Command Structure 1:3 ratio <ESC>BAbbccc (data) 2:5 ratio <ESC>BDAbbccc (data) 1:2 ratio <ESC>DAbbccc (data) Width of narrow element in dots (01~12). ccc = Bar height in dots (001~999) (data) = Bar code data (numeric); maximum of 15 digits. Required check digit.
Page 124
All manuals and user guides at all-guides.com Code 93 Command Structure 1:3 ratio <ESC>BCbbcccdd (data) Width of narrow element in dots (01~12). ccc = Bar height in dots (001~999) Length of data (number of digits, 00~99). (data) = Bar code data (alphanumeric); length must match value of parameter “dd”;...
Page 125
All manuals and user guides at all-guides.com UPC-E Command Structure <ESC>BEbbccc (data) <ESC>DEbbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric); must be exactly 6 digits. Character Set 0-9 (numeric only) Density Table Value of “bb”...
Page 126
All manuals and user guides at all-guides.com Bookland (UPC/EAN Supplement) Command Structure <ESC>BFbbccc (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) (data) = Bar code data (numeric); must be exactly 2 or 5 digits. Character Set 0-9 (numeric only) Density Table...
Page 127
All manuals and user guides at all-guides.com UCC-128 Command Structure <ESC>BIbbcccd (data) Width of narrow element in dots (01~12) ccc = Bar height in dots (001~999) Placement of human readable text. None Text at top of bar code Text at bottom of bar code (data) = 17 digits made up of the following: digit = Container type...
Page 128
All manuals and user guides at all-guides.com none of it will be printed. Care should be exercised when placing the bar code to allow for any automatically created human readable text. Example Without incrementing <ESC>A <ESC>H100<ESC>V200<ESC>BI04150101234567000000001 <ESC>Q2<ESC>Z With incrementing <ESC>A <ESC>H100<ESC>V200<ESC>F001+001 <ESC>BI04150101234567000000001 <ESC>Q2<ESC>Z...
Page 129
All manuals and user guides at all-guides.com Postnet Command Structure <ESC>BP (data) (data) = 5 digit ZIP 6 digits for Postnet 37 9 digits for ZIP+4 11 digits for Delivery Point Bar Code Character Set 1-9 (numeric only) Notes Frame bits and check digits added automatically by printer. Bar code width and height are fixed and cannot be changed.
Page 130
All manuals and user guides at all-guides.com APPENDIX C. CUSTOM CHARACTERS AND GRAPHICS CUSTOM-DESIGNED CHARACTER The following example is presented to help understand the use of the Custom-Designed Characters command. It demonstrates the design and printing of an “arrow” in a 16x16 matrix. Determine which matrix size to use.
Page 131
All manuals and user guides at all-guides.com Transfer the image into two bit map representations and then into hexadecimal or binary format. BIT MAP 0000 0001 0000 0000 01 00 0000 0011 1000 0000 03 80 0000 0111 1100 0000 07 C0 0000 1111 1110 0000 0F E0...
Page 132
All manuals and user guides at all-guides.com To store the custom designed character in memory using a binary data stream, the command would be: <ESC>A <ESC>K1B3F <ESC>Z Note: Spaces are shown between hexadecimal values in the above example for clarity only and are not included in the data string.
Page 133
All manuals and user guides at all-guides.com CUSTOM GRAPHICS EXAMPLE The following example is presented to help you understand the use of the Custom Graphics command. It demonstrates the design and printing of an “diskette” in a 48x48 matrix. Determine the matrix size for the graphic. It must be in 8 dot by 8 dot blocks. The example here has six blocks horizontally and six blocks vertically (48x48).
Page 135
All manuals and user guides at all-guides.com C00000000003 C00000000003 C00003C00003 C00007E00003 C0000FF00003 C0000FF00003 C0000FF00003 C0000FF00003 C00007E00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00003C00003 C00001800003 C00000000003 C00000000003 FFFFFFFFFFFF FFFFFFFFFFFF 000000000000 000000000000 000000000000 000000000000 000000000000 000000000000 <ESC>H300<ESC>V100<ESC>XSPLEASE PLACE YOUR DISK <ESC>H300<ESC>V150<ESC>XSIN A SAFE PLACE <ESC>Q1<ESC>Z Note: Spaces shown in the hexadecimal listing above are for emphasis only.
Page 137
All manuals and user guides at all-guides.com PRINT #1,E$;"Q1";E$;"Z" CLOSE #1 The printer output for both hexadecimal and binary format examples is:...
Need help?
Do you have a question about the OKIPOS X400 and is the answer not in the manual?
Questions and answers