# Supported ESC/POS Commands

This is not a copy of the ESC/POS specification. For what a command means, Epson's own manuals are the
authority. What this page answers is the question they cannot: **what happens to that command here.**

Every row is generated from the command descriptors the parser registers, so the table cannot claim
support that does not exist, and a command added to the parser appears here on the next deploy.

## How to read it

- **Renders** - the command affects the document you see: text styling, position, barcodes, images,
  cuts, drawer pulses.
- **Answers on the socket** - the printer writes bytes back to your client, and what it answers
  reflects the fault flags you have set on the printer.
- **Ignored** - the command is recognised and consumed so the byte stream stays in sync, but the
  emulator has nothing to do with it. The reason is in the same cell. An ignored command is not an
  error and does not mark the document.

A command **absent from this table** is a different matter: the parser does not know it, the bytes are
reported as unrecognised, and the document is marked with an error. If you hit one that a real printer
accepts, that is worth an email to
[support@virtual-printer.online](mailto:support@virtual-printer.online) - see
[Document marked with an error](/docs/troubleshooting/document-has-errors).

## The matrix

| Command | What it does | Bytes | In the emulator |
| --- | --- | --- | --- |
| BEL | buzzer/beeper | 07 | Supported |
| CAN | cancel print data in page mode | 18 | Ignored in standard mode (page mode is not supported) |
| Carriage Return (CR) | legacy compatibility command, ignored by printer | 0D | Supported |
| DC1 | device select (legacy software flow control) | 11 | Ignored: the virtual printer is always selected |
| DC2 | cancel condensed printing | 12 | Supported. Rendered as Font A. |
| DC3 | device deselect (legacy software flow control) | 13 | Ignored: the virtual printer is always selected |
| DC4 | cancel the double-width mode selected by SO | 14 | Supported |
| DLE DC4 fn ... | real-time requests (drawer pulse, power-off, buzzer, buffer clear) | 10 14 fn | Supported. The drawer pulse drives the emulated cash drawer; the remaining real-time hardware actions are not modeled and are ignored. |
| DLE ENQ n | real-time recovery from a recoverable error | 10 05 n | Ignored: the virtual printer has no recoverable error state to clear |
| DLE EOT n | real-time printer status | 10 04 n | Supported |
| ESC | n - enable/disable underline mode | 1B 2D n (00=off, 01=on) | Supported |
| ESC ! | select print mode | 1B 21 n | Supported |
| ESC $ nL nH | set absolute print position | 1B 24 nL nH (position = nL + nH * 256 dots from the beginning of the line) | Supported |
| ESC % n | select or cancel the user-defined character set | 1B 25 n | Ignored: user-defined glyphs are not rendered |
| ESC & y c1 c2 [x1 d1...dk] ... | define user-defined characters | 1B 26 y c1 c2 | Supported. (per character: one width byte x followed by y * x data bytes). The payload is parsed only to keep the byte stream in sync; the glyphs are not rendered. |
| ESC * m nL nH d1...dk | select bit image mode | 1B 2A m nL nH | Supported. (m: 0/1 = 8-dot single/double density, 32/33 = 24-dot). |
| ESC 0 | select 1/8-inch line spacing (legacy preset) | 1B 30 | Supported |
| ESC 1 | select 7/72-inch line spacing (legacy preset) | 1B 31 | Supported |
| ESC 2 | set default line spacing (approx. 30 dots) | 1B 32 | Supported |
| ESC 3 n | set line spacing | 1B 33 0xNN | Supported |
| ESC 4 | enable italic mode | 1B 34 | Supported |
| ESC 5 | disable italic mode | 1B 35 | Supported |
| ESC = n | select peripheral device | 1B 3D n | Ignored: there is only one (virtual) device on the line |
| ESC @ | reset printer | 1B 40 | Supported |
| ESC a | select justification | 1B 61 n (00=left, 01=center, 02=right) | Supported |
| ESC c 0/1/3/4/5 n | paper type, paper sensor and panel button configuration | 1B 63 30/31/33/34/35 n | Ignored: the virtual printer has one paper station, and |
| ESC d n | print and feed n lines | 1B 64 n | Supported |
| ESC D n1 ... nk NUL | set horizontal tab positions | 1B 44 n1 | Supported. nk 00. |
| ESC E n | enable/disable emphasized (bold) mode | 1B 45 n (00=off, 01=on) | Supported |
| ESC F | cancel emphasized (bold) mode | 1B 46 | Supported |
| ESC g | select 15 cpi pitch | 1B 67 | Supported. Rendered as Font B. |
| ESC G n | enable/disable double-strike mode | 1B 47 n (00=off, 01=on) | Supported |
| ESC i | Partial cut (one point left uncut) | 1B 69 | Supported |
| ESC J n | print and feed paper by n dots | 1B 4A n | Supported |
| ESC m | Partial cut (three points left uncut) | 1B 6D | Supported |
| ESC M n | select character font | 1B 4D n (00=Font A, 01=Font B) | Supported |
| ESC P | select 10 cpi pica pitch (the dot-matrix default) | 1B 50 | Supported. Rendered as Font A. |
| ESC p m t1 t2 | cash drawer pulse | 1B 70 0xMM 0xT1 0xT2 | Supported. m selects the drawer kick-out connector pin - 0 and 48 mean pin 2, 1 and 49 mean pin 5 - and is normalized to the 0/1 drawer index the emulated drawers are addressed by. The ON interval is t1 x 2 ms and the OFF interval is t2 x 2 ms; a printer that is given t2 < t1 stretches the OFF interval to match the ON interval. |
| ESC r n | select print color on two-color paper | 1B 72 n (0/48 black, 1/49 red) | Supported |
| ESC R n | select international character set | 1B 52 n (0=USA, 1=France, 2=Germany, ...) | Supported |
| ESC SP n | set right-side character spacing | 1B 20 n | Supported |
| ESC t | select character code table | 1B 74 n | Supported |
| ESC u n | transmit peripheral device (drawer) status | 1B 75 n | Supported. Legacy counterpart of GS r 2. |
| ESC v | transmit paper sensor status | 1B 76 | Supported. Legacy counterpart of GS r 1. |
| ESC V n | turn 90-degree clockwise character rotation on/off | 1B 56 n (0/48 off; 1/49 and 2/50 on) | Supported. Distinct from GS V (1D 56), which cuts paper. |
| ESC \ nL nH | set relative print position | 1B 5C nL nH (offset = signed 16-bit nL + nH * 256 dots from the current position) | Supported |
| ESC { n | enable/disable upside-down mode | 1B 7B n | Supported |
| FS & | select Chinese (GB2312) character set | 1C 26 | Supported |
| FS . | cancel Kanji character mode | 1C 2E | Ignored: single-byte code pages are always active |
| FS p n m | print NV logo n with scale mode m | 1C 70 n m | Supported |
| FS q n [xL xH yL yH d1...dk] x n | define NV bit images | 1C 71 n | Supported. (per image: width = (xL + xH*256) * 8 dots, height = (yL + yH*256) * 8 dots, k = x * y * 8 bytes of column-format data). Replaces all previously stored NV logos. |
| GS ! n | select character size | 1D 21 n | Supported |
| GS ( A pL pH fn m | execute a test print | 1D 28 41 pL pH | Ignored: the virtual printer has no self-test page |
| GS ( J pL pH fn m | absent from the public ESC/POS reference | 1D 28 4A pL pH | Ignored: only its length is known, and it has no visible effect on |
| GS ( k | 2D symbology configuration and workflow (model, module size, EC level, | 1D 28 6B pL pH cn fn [data] (cn: 0x30 PDF417, 0x31 QR, 0x35 Aztec, 0x36 DataMatrix) | Supported |
| GS ( K pL pH fn m | select print control method(s) | 1D 28 4B pL pH | Supported. Function 49 selects the print density and is honoured, because it decides how dark the paper actually comes out. The remaining functions - print control mode (48), print speed (50) and the number of thermal head energizing parts (97) - describe how the head is driven and leave no trace in a rendered document, so they stay ignored. |
| GS ( L pL pH ... | graphics data store/print workflow | 1D 28 4C pL pH | Supported |
| GS ( M pL pH fn m | customize printer control values | 1D 28 4D pL pH | Ignored: the virtual printer keeps no persistent setting areas |
| GS ( N pL pH fn m | two-color print configuration | 1D 28 4E pL pH fn m (fn=48 selects the character color: m=48 black, m=49 red) | Supported |
| GS ( P pL pH fn ... | page mode control | 1D 28 50 pL pH | Ignored: page mode is not supported |
| GS ( Q pL pH fn ... | draw a line (fn = 48) or a rectangle (fn = 49) into the | 1D 28 51 pL pH | Ignored: the command is only valid while page mode is selected |
| GS ( V pL pH fn m [n] | paper cut functions | 1D 28 56 pL pH | Supported. Function 48 cuts, function 49 feeds n motion units and then cuts; both map onto the same cut element GS V produces. Other functions (cut reservation) only arrange for a cut to happen later, so they are consumed but not turned into a cut here. |
| GS * x y d1...dk | define download bit image | 1D 2A x y | Supported. (width = x * 8 dots, height = y * 8 dots, k = x * y * 8 bytes). |
| GS / m | print download bit image | 1D 2F m (0/48 normal, 1/49 double width, 2/50 double height, 3/51 quadruple) | Supported |
| GS 8 L p1 p2 p3 p4 ... | long graphics data store workflow | 1D 38 4C p1 p2 p3 p4 | Supported |
| GS a n | enable/disable Automatic Status Back | 1D 61 n (bit mask of the enabled status types; 0 disables ASB) | Supported |
| GS B n | enable/disable reverse (white-on-black) mode | 1D 42 n (00=off, 01=on) | Supported |
| GS b n | turn smoothing mode on/off | 1D 62 n | Ignored: the virtual printer does not model glyph smoothing |
| GS h n | set the height of the next barcode in dots | 1D 68 n | Supported |
| GS H n | choose where the human-readable digits are printed, relative to the barcode | 1D 48 n | Supported |
| GS I n | transmit printer ID | 1D 49 n (1-3 single byte model/type/version, 65-69 information strings) | Supported |
| GS k | print a barcode of type m from the data that follows | 1D 6B m d1...dk 00, or 1D 6B m n d1...dn | Supported |
| GS L nL nH | set left margin | 1D 4C nL nH (margin = nL + nH * 256 dots) | Supported |
| GS r n | transmit status | 1D 72 n (1/49 paper sensor, 2/50 drawer kick-out connector) | Supported |
| GS v 0 m xL xH yL yH [data] | raster bit image print | 1D 76 30 m xL xH yL yH | Supported |
| GS V m [n] | paper cut with mode | 1D 56 0xMM [0xNN] | Supported |
| GS w n | set the module width (the width of the narrowest bar) of the next barcode | 1D 77 n | Supported |
| GS W nL nH | set print area width | 1D 57 nL nH (width = nL + nH * 256 dots) | Supported |
| HT | move to next horizontal tab stop | 09 | Supported |
| Line Feed | print buffer and feed one line | 0A | Supported |
| SI | select condensed printing | 0F | Supported. Rendered as Font B. |
| SO | select double-width printing for one line | 0E | Supported. Canceled by LF or DC4. |


## Related

- [Printer protocols](/docs/protocols) - ESC/POS, EPL, TSPL and where ZPL stands
- [Garbled characters](/docs/troubleshooting/garbled-characters) - code pages, the usual cause of wrong glyphs
- [How it works](/docs/concepts/how-it-works) - what the parser produces from these commands
