1-50 Command Descriptions Rev. A
GS w n
[Name] Set bar code width
[Format] ASCII GS w n
Hex 1D 77 n
Decimal 29 119 n
[Range] 2 ≤ n ≤6
GS w n sets the horizontal size of a bar code. n specifies the bar code width as shown below. The
multilevel bar codes are UPC-A, UPC-E, JAN13, JAN8, CODE93, and CODE128. The binary level bar
codes are CODE39, ITF, and CODABAR. The default setting is n=3.
n
Module Width (mm) for
Multilevel Bar Code
Binary Level Bar Code
Thin Element Width (mm) Thick Element Width (mm)
2 0.282 0.282 0.706
3 0.423 0.423 1.129
4 0.564 0.564 1.411
5 0.706 0.706 1.834
6 0.847 0.847 2.258
Program Example Print Sample
PRINT #1, CHR$(&H1D);"w";CHR$(3);← Set width size to 3
PRINT #1, CHR$(&H1D);"k";CHR$(2);← Print bar code
PRINT #1, "496595707379";CHR$(0);
PRINT #1, CHR$(&HA);
PRINT #1, CHR$(&H1D);"w";CHR$(4);← Set width size to 4
PRINT #1, CHR$(&H1D);"k";CHR$(2);← Print bar code
PRINT #1, "496595707379";CHR$(0);
PRINT #1, CHR$(&HA);
PRINT #1, CHR$(&H1D);"w";CHR$(5);← Set width size to 5
PRINT #1, CHR$(&H1D);"k";CHR$(2);← Print bar code
PRINT #1, "496595707379";CHR$(0);
PRINT #1, CHR$(&HA);
← Width size 3
← Width size 4
← Width size 5
Comments to this Manuals