4 ANSI Control Functions Summary

4.1 Introduction

This chapter provides a general description of ANSI escape and control sequences, defining control characters, control functions, escape sequences, and device control strings. This chapter provides information on working with 7- and 8-bit environments and the conventions used in each, and it describes the Show control characters Set-Up feature. In addition, this chapter provides summary tables of the ANSI control functions.

4.2 Control Characters

The purpose of a control character is to control an action such as line spacing, paging, or data flow. The terminal does not display control characters unless you select Show control characters from the Display Set-Up menu. There are two groups of control characters.

C0 7-bit control characters, in columns 0 and 1 of the 8-bit code table
C1 8-bit control characters, in columns 8 and 9 of the 8-bit code table

Table 4–1 lists the C0 control characters the VT510 recognizes. Table 4–2 lists the C1 control characters the VT510 recognizes. You can also code C1 control characters as 7-bit escape sequences. Table 4–3 lists the equivalent 7-bit sequences for 8-bit control characters. All three tables give column/row locations to help you find the characters in the character sets.

Table 4–1 C0 (7-Bit) Control Characters Recognized
Name Mnemonic
Column/Row
Function
Null NUL
0/0
NUL has no function (ignored by the terminal).
Enquiry ENQ
0/5
Sends the answerback message.
(Communications Set-Up)
Bell BEL
0/7
Sounds the bell tone if the bell is enabled in Keyboard Set-Up.
Backspace BS
0/8
Moves the cursor one character position to the left. If the cursor is at the left margin, no action occurs.
Horizontal tab HT
0/9
Moves the cursor to the next tab stop. If there are no more tab stops, the cursor moves to the right margin. HT does not cause text to auto wrap.
Line feed LF
0/10
Causes a line feed or a new line operation, depending on the setting of line feed/new line mode.
Vertical tab VT
0/11
Treated as LF.
Form feed FF
0/12
Treated as LF.
Carriage return CR
0/13
Moves the cursor to the left margin on the current line.
Shift out (locking shift 1) SO (LS1)
0/14
Maps the G1 character set into GL. You designate G1 by using a select character set (SCS) sequence.
Shift in (locking shift 0) SI (LS0)
0/15
Maps the G0 character set into GL. You designate G0 by using a select character set (SCS) sequence.
Device control 1 (XON) DC1
1/1
Also known as XON. If XON/XOFF flow control is enabled in Communications Set-Up, DC1 clears DC3 (XOFF). This action causes the VT510 to continue sending characters.
Device control 3 (XOFF) DC3
1/3
Also known as XOFF. If XON/XOFF flow control is enabled in Communications Set-Up, DC3 causes the VT510 to stop sending characters. The terminal cannot resume sending characters until it receives a DC1 control character.
Cancel CAN
1/8
Immediately cancels an escape sequence, control sequence, or device control string in progress. In this case, the VT510 does not display any error character.
Substitute SUB
1/10
Immediately cancels an escape sequence, control sequence, or device control string in progress, and displays a reverse question mark as an error character.
Escape ESC
1/11
Introduces an escape sequence. ESC also cancels any escape sequence, control sequence, or device control string in progress.
Delete DEL
7/15
Ignored when received, unless a 96- character set is mapped into GL. DEL is not used as a fill character. Digital does not recommend using DEL as a fill character. Use NUL instead.
Table 4–2 C1 (8-Bit) Control Characters Recognized
Name Mnemonic
Column/Row
Function
*The VT510 ignores all following characters until it receives a SUB, ST, or any other C1 control character.
Index IND
8/4
Moves the cursor down one line in the same column. If the cursor is at the bottom margin, the page scrolls up.
Next line NEL
8/5
Moves the cursor to the first position on the next line. If the cursor is at the bottom margin, the page scrolls up.
Horizontal tab set HTS
8/8
Sets a horizontal tab stop at the column where the cursor is.
Reverse index RI
8/13
Moves the cursor up one line in the same column. If the cursor is at the top margin, the page scrolls down.
Single shift 2 SS2
8/14
Temporarily maps the G2 character set into GL, for the next graphic character. You designate the G2 set by using a select character set (SCS) sequence.
Single shift 3 SS3
8/15
Temporarily maps the G3 character set into GL, for the next graphic character. You designate the G3 set by using a select character set (SCS) sequence.
Device control string DCS
9/0
Introduces a device control string that uses 8-bit characters. A DCS control string is used for loading function keys or a soft character set.
Start of string SOS
9/8
Ignored.
VT identification DECID
9/10
Makes the terminal send its device attributes response to the host (same as an ANSI device attributes (DA) sequence). Programs should use the ANSI DA sequence instead. If the printer is in controller mode, the terminal sends the sequence to the printer.
Control sequence introducer CSI
9/11
Introduces a control sequence that uses 8-bit characters.
String terminator ST
9/12
Ends a device control string. You use ST in combination with DCS.
Operating system command OSC
9/13
Introduces an operating system command.*
Privacy message PM
9/14
Introduces a privacy message string.*
Application program command APC
9/15
Introduces an application program command.*
Table 4–3 8-Bit Control Characters and Their 7-Bit Equivalents
Name 8-Bit Character 7-Bit Sequence
Index IND
8/4
ESC
1/11
D
4/4
Next line NEL
8/5
ESC
1/11
E
4/5
Horizontal tab set HTS
8/8
ESC
1/11
H
4/8
Reverse index RI
8/13
ESC
1/11
M
4/13
Single shift 2 SS2
8/14
ESC
1/11
N
4/14
Single shift 3 SS3
8/15
ESC
1/11
O
4/15
Device control string DCS
9/0
ESC
1/11
P
5/0
Start of string SOS
9/8
ESC
1/11
X
5/8
VT identification DECID
9/10
ESC
1/11
Z
5/10
Control sequence introducer CSI
9/11
ESC
1/11
[
5/11
String terminator ST
9/12
ESC
1/11
\
5/12
Operating system command OSC
9/13
ESC
1/11
]
5/13
Privacy message PM
9/14
ESC
1/11
^
5/14
Application program APC
9/15
ESC
1/11
_
5/15

4.3 Control Functions

You use control functions to make the terminal perform special actions in your applications. Examples:

Move the cursor.
Delete a line of text.
Select bold or underlined text.
Change character sets.
Make the terminal emulate a VT52 or VT100 terminal.

There are single-character and multiple-character control functions.

The single-character functions are the C0 and C1 control characters. You can use C0 characters in a 7-bit or 8-bit environment. C1 characters provide a few more functions than C0 characters, but you can only use C1 characters directly in an 8-bit environment.

Multiple-character functions provide many more functions than the C0 and C1 characters. Multiple-character functions can use control characters and graphic characters. There are three basic types of multiple-character functions.

Escape sequences
Control sequences
Device control strings

Many sequences are based on ANSI and ISO standards and are used throughout the industry. Others are private sequences, created by some manufacturers, for specific families of products. ANSI sequences and private sequences follow ANSI and ISO standards for control functions.

In this manual, control functions created for the VT have the prefix DEC in their mnemonic name. For example, column mode has the mnemonic DECCOLM. All other control functions are standardized.

The following sections describe the format for escape sequences, control sequences, and device control strings.

Programming Tip
When you use control functions, remember that the binary codes define a function—not the graphic characters. This manual uses graphic characters from a Multinational character set to show control functions. If you use another character set, the graphic characters for control functions may change, but the code is always the same.

4.3.1 Sequence Format

This manual shows escape and control sequences in their 8-bit format. You can also use equivalent 7-bit sequences (Table 4–3).

The 8-bit format uses the C0 and C1 control characters and ASCII characters from the Multinational character set. The sequences also show each character's column/row position in the character set table, below the character. The column /row code eliminates confusion over similar-looking characters such as 0 (3/0) and O (4/15).

Note

Spaces appear between characters in a sequence for clarity. These spaces are not part of the sequence. If a space is part of the sequence, the SP (2/0) character appears.

4.3.2 Escape Sequences

An escape sequence uses two or more bytes to define a specific control function. Escape sequences do not include variable parameters, but may include intermediate characters. Here is the format for an escape sequence.

ESC
1/11
I
2/0 to 2/15
F
3/0 to 7/14
Escape
character
Intermediate
characters
(zero or more
characters)
Final
character
(one character)

ESC introduces escape sequences. After receiving the ESC control character, the terminal interprets the next received characters as part of the sequence.

I represents zero or more intermediate characters that can follow the ESC character. Intermediate characters come from the 2/0 through 2/15 range of the code table.

F is the final character. This character indicates the end of the sequence. The final character comes from the 3/0 through 7/14 range of the code table. The intermediate and final characters together define a single control function.

For example, the following escape sequence changes the current line of text to double-width, single-height characters:

ESC
1/11
#
2/3
6
3/6

4.3.3 Control Sequences

A control sequence uses two or more bytes to define a specific control function. Control sequences usually include variable parameters. Here is the format for a control sequence.

CSI
9/11
P...P
3/0 to 3/15
I...I
2/0 to 2/15
F
4/0 to 7/14
Control
sequence
introducer
Parameter
(zero or more
characters)
Intermediate
(zero or more
characters)
Final
(one character)

CSI is the control sequence introducer. You can also use the equivalent 7-bit sequence, ESC (1/11) [ (5/11), as a substitute for CSI. After receiving CSI, the terminal interprets the next received characters as part of the sequence.

P...P are parameter characters received after CSI. These characters are in the 3/0 to 3/15 range in the code table. Parameter characters modify the action or interpretation of the sequence. You can use up to 16 parameters per sequence. You must use the ; (3/11) character to separate parameters.

All parameters are unsigned, positive decimal integers, with the most significant digit sent first. Any parameter greater than 9999 (decimal) is set to 9999 (decimal). If you do not specify a value, a 0 value is assumed. A 0 value or omitted parameter indicates a default value for the sequence. For most sequences, the default value is 1.

Note

All parameters must be positive decimal integers. Do not use a decimal point in a parameter—the terminal will ignore the command.

If the first character in a parameter string is the ? (3/15) character, it indicates that VT parameters follow. The terminal interprets VT parameters according to ANSI X3.64 and ISO 6429.

The VT510 processes two types of parameters, numeric and selective.

4.3.3.1 Numeric Parameters

A numeric parameter indicates a number value such as a margin location. In this manual, numeric parameters appear as actual values or as Pn, Pn1, Pn2, and so on.

The following is an example of a control sequence with numeric parameters:

CSI
9/11
5
3/5
;
3/11
2
3/2
0
3/0
r
7/2
Control
sequence
introducer
First
numeric
parameter
Delimiter Second
numeric
parameter
Final
character

This sequence sets the top and bottom margins of the current page. The top margin is at line 5, the bottom is at line 20. The ; (3/11) separates the two parameters.

4.3.3.2 Selective Parameters

A selective parameter selects an action associated with the specific parameter. In this manual, selective parameters usually appear as Ps, Ps1, Ps2, and so on.

The following is an example of a control sequence using selective parameters:

CSI
9/11
1
3/1
;
3/11
4
3/4
m
6/13
Control
sequence
introducer
First
selective
parameter
Delimiter Second
selective
parameter
Final
character

This control sequence turns on the bold and underline attribute at the cursor position. The parameters are 1 (indicating the bold attribute) and 4 (indicating the underline attribute). The ; (3/11) delimiter separates the two parameters.

I...I are zero or more intermediate characters received after CSI. These characters are in the 2/0 to 2/15 range.

F is the final character from the 4/0 to 7/14 range. The final character indicates the end of the sequence. The intermediate and final characters together define a control function. If there are no intermediate characters, the final character defines the function.

4.3.4 Device Control Strings

Device control strings (DCS), like control sequences, use two or more bytes to define specific control functions. However, a DCS also includes a data string. Here is the format for a device control string.

DCS
9/0
P...P
3/0
to
3/15
I...I
2/0
to
2/15
F
4/0
to
7/14
Data string
************
ST
9/12
Device
control
string
introducer
Zero or
more
para-
meters
Zero or
more
inter-
mediates
Final String String
terminator

DCS is the device control string introducer. DCS is the C1 control character at position 9/0. You can also use the equivalent 7-bit sequence, ESC (1/11) P (5/0). After receiving DCS, the terminal processes the next received characters as part of the string function.

P...P are parameter characters received after DCS. The use of parameter characters in a device control string is a Digital extension to the ANSI syntax. According to ANSI standards, any elements included after DCS are part of the data string.

Parameter characters are in the 3/0 to 3/15 range. They modify the action or interpretation of the device control string. You can use up to 16 parameters per string. Each parameter is separated with a ; (3/11) character. These characters follow the same rules as in a control sequence. See the "Section 4.3.3" section in this chapter.

I...I are zero or more intermediate characters received after CSI. These characters are in the 2/0 to 2/15 range.

F is the final character in the 4/0 to 7/14 range. The final character indicates the end of the string. The intermediate and final characters define the string. If there are no intermediates, the final character defines the string.

Data string follows the final character and usually includes several definition strings. Each definition string can be several characters in length. Individual strings are separated by the ; (3/11) delimiter.

ST is the string terminator. ST (9/12) indicates the end of a string. You can also use the equivalent 7-bit sequence, ESC (1/11) \ (5/12).

The following is an example of a device control string:

DCS
9/0
0
3/0
!
2/1
u
7/5
%
2/5
5
3/5
ST
9/12
Device
control
string
introducer
Para-
meter
Inter-
mediate
Final Data
string
String
terminator

This device control string assigns a Supplemental Graphic set as the user-preferred supplemental set.

4.3.5 Using Control Characters in Sequences

You can use control characters—ESC, CAN, and SUB—to interrupt or recover from errors in escape sequences, control sequences, and device control strings.

The VT510 does not lose data when errors occur in escape or control sequences and device control strings. The terminal ignores unrecognized sequences and strings, unless they end a current escape sequence.

4.3.6 7-Bit Code Extension Technique

You can represent all C1 control characters as 7-bit escape sequences. You can use the C1 characters indirectly, by representing them as 2-character escape sequences. ANSI calls this technique a 7-bit code extension. The 7-bit code extension provides a way of using C1 characters in applications written for a 7-bit environment. Here are some examples.

8-Bit
C1 Character
7-Bit Code Extension
Escape Sequence
CSI
9/11
ESC
1/11
[
5/11
SS3
8/15
ESC
1/11
O
4/15
IND
8/4
ESC
1/11
D
4/4
DCS
9/0
ESC
1/11
P
5/0

In general, you can use the 7-bit code extension technique in two ways.

4.4 Working with 7-Bit and 8-Bit Environments

There are three requirements for using one of the terminal's 8-bit character sets.

The following sections describe conventions that apply in VT level 4.

4.4.1 Conventions for Codes Received by the Terminal

The terminal expects to receive character codes in a form compatible with 8-bit coding. Your application can use the C0 and C1 control characters, as well as the 7-bit C1 code extensions, if necessary. The terminal always interprets these codes correctly.

When your program sends GL or GR codes, the terminal interprets the character codes according to the graphic character sets in use. When you turn on or reset the terminal, you automatically select the ASCII character set in GL and the current user-preferred character set in GR. You select the user-preferred set in the Terminal type, VT default character set Set-Up menu. This mapping assumes the current terminal mode is VT level 4.

4.4.2 Conventions for Codes Sent by the Terminal

The terminal can send data to an application in two ways.

Most function keys on the keyboard send multiple-character control functions. Many of these functions start with CSI (9/11) or SS3 (8/15), which are C1 characters. If your application cannot handle 8-bit characters, you can make the terminal automatically convert all C1 characters to their equivalent 7-bit code extensions before sending them to the application. To convert C1 characters, you use the DECSCL commands.)

By default, the terminal is set to automatically convert all C1 characters sent to the application to 7-bit code extensions. However, to ensure the correct mode of operation, always use the appropriate DECSCL commands.

Note

In VT level 4, the terminal can send GR graphic characters to an application, even if the application cannot handle 8-bit codes. However, in a 7-bit environment, the terminal sends C1 controls as 7-bit escape sequences and does not send 8-bit graphic characters.

New programs should accept both 7-bit and 8-bit forms of the C1 control characters.

4.5 Show Control Characters

The VT510 lets you display control characters as graphic characters, when you want to debug your applications. With this mode enabled, the terminal does not perform all control functions.

To enable this mode, use the Display Set-Up menu and enable the checkbox for Show control characters; or you can use the control representation mode (CRM) control sequence. (You cannot select this mode with an escape sequence.)

In VT level 4 mode
The terminal temporarily loads a special graphic character set into C0, GL, C1, and GR. Figures 4–1 and 4–2 shows this special set, called the display controls font. The terminal uses this font to display control characters on the screen.

In VT level 1 or VT52 mode
The terminal temporarily loads the left half of the display controls font into C0 and GL. The terminal uses this half of the font to display all C0 and GL characters. (C1 and GR are meaningless in VT52 or VT100 emulations.)

When displaying 36 or more lines on the screen
When you display 36 or more lines on the screen (DECSNLS), the terminal uses a smaller font to display control characters. The smaller font represents each control character as a two-character symbol instead of a three-character symbol. Figures 4–1 and 4–2 show what the control characters look like when displaying 24 or 25 lines on the screen. Table 4–4 shows the abbreviations for the control characters in the smaller font.

Table 4–4 Control Character Displayed on Screen
Control Character
in Large Font
Control Character
in Small Font
Name
NUL NL Null
SOH SH Start of heading
STX SX Start of text
ETX EX End of text
EOT ET End of transmission
ENQ EN Enquire
ACK AK Acknowledge
BEL BL Bell
BS BS Backspace
HT HT Horizontal tab
LF LF Line feed
VT VT Vertical tab
FF FF Form feed
CR CR Carriage return
SO SO Shift out
SI SI Shift in
DLE DE Data link escape
DC1 D1 Device control 1 (XON)
DC2 D2 Device control 2
DC3 D3 Device control 3 (XOFF)
DC4 D4 Device control 4
NAK NK Negative acknowledge
SYN SY Synchronous idle
ETB EB End of transmission block
CAN CA Cancel
EM EM End of medium
SUB SB Substitute
ESC EC Escape
FS FS Field separator
GS GS Group separator
RS RS Record separator
US US Unit separator
IND IN Index
NEL NE Next line
SSA SA Start selected area
ESA EA End selected area
HTS HS Horizontal tab set
HTJ HJ Horizontal tab with justify
VTS VS Vertical tab set
PLD PD Partial line down
PLU PU Partial line up
RI RI Reverse index
SS2 S2 Single shift 2
SS3 S3 Single shift 3
DCS DC Device control string
PU1 P1 Private use 1
PU2 P2 Private use 2
STS SS Set transmit state
CCH CC Cancel character
MW MW Message waiting
SPA SP Start protected area
EPA EP End protected area
CSI CS Control sequence introducer
ST ST String terminator
OSC OS Operating system command
PM PM Private message
APC AP Application program command
NS NS No-break space

Exceptions
Some control functions still work in this mode.

Figure 4–1 Show Control Characters Font (Left Half)
Figure 4–2 Show Control Characters Font (Right Half)

4.6 ANSI Control Function Tables

The tables in this section summarize the ANSI Control Functions for ANSI-compatible VT mode and PCTerm mode. Default conditions are in boldface type. Chapter 5 describes all the ANSI control functions in alphabetical order by mnemonic.

Table 4–5 lists the text processing control functions; Table 4–6, the reports control functions; Table 4–7, the terminal management control functions; Table 4–8, the keyboard processing control functions; and Table 4–9, the communications control functions. In these tables, the word "same" signifies the same control sequences as in the VT510 column.

Table 4–5 Text Processing Control Functions
Active Position and Cursor Control Function Mnemonic
VT510 VT420 VT100

1 The page size can be 24, 25, 36, 42, 48, 52, and 72 lines with 80 or 132 columns.

2 The ANSI mode supports Bold, Blink, Underline, and Reverse graphic renditions.

3 See SGR—Select Graphic Rendition in Chapter 5.

4 DECSCA does not affect visual character attributes set by the select graphic rendition (SGR) function.

Auto Resize Mode n/a n/a DECARSM
Set (enable): CSI ? 98 h
Reset (disable): CSI ? 98 l
Backspace BS same same BS
Carriage Return CR same same CR
Cursor Backward CSI Pc D same same CUB
Cursor Backward Tabulation CSI Pn Z n/a n/a CBT
Cursor Down CSI Pl B same same CUD
Cursor Forward CSI Pc C same same CUF
Cursor Horizontal Absolute CSI Pn G n/a n/a CHA
Cursor Horizontal Forward Tab CSI Pn I n/a n/a CHT
Cursor Information Report DCS 1$u D.....D ST same n/a DECCIR
Cursor Next Line CSI Pn E n/a n/a CNL
Cursor Previous Line CSI Pn F n/a n/a CPL
Cursor Position CSI Pl ; Pc H same same CUP
Cursor Position Report CSI 6 n same same CPR
(Also see DECCIR, DECXCPR, and DSR.)
Response: CSI Pl; Pc R
Pl No. of lines
Pc No. of columns
Cursor Up CSI Pl A same same CUU
Extended Cursor Position Report CSI ? 6 n same n/a DECXCPR
Response: CSI Pl; Pc; Pp R
Pl Line
Pc Column
Pp Page
Form Feed FF same same FF
Horizontal Tab HT same same HT
Horizontal/Vertical Position CSI Pl ; Pc f same same HVP
Pl No. of lines to move to
Pc No. of columns to move to
Horizontal Position Absolute CSI Pn ` same same HPA
Horizontal Position Relative CSI Pn a same same HPR
Line Feed LF same same LF
Line Feed/New Line Mode same same LNM
Set (NL): CSI 20 h
Reset (LF): CSI 20 l
Next Line ESC E same same NEL
No clear screen on column change n/a n/a DECNCSM
Do not clear: CSI ? 95 h
Clear screen: CSI ? 95 l
Restore Cursor ESC 8 same same DECRC
Restore Saved Cursor (SCO) CSI u n/a n/a SCORC
Right-to-Left Copy n/a n/a DECRLCM
Set: CSI ? 96 h
Reset: CSI ? 96 l
Right-to-Left Mode n/a n/a DECRLM
Set: CSI ? 34 h
Reset: CSI ? 34 l
Save Cursor ESC 7 same same DECSC
Save Cursor Position (SCO) CSI s n/a n/a SCOSC
Set Cursor Style CSI Ps SP q n/a n/a DECSCUSR
Ps
none, 0, 1 Blinking block
2 Steady block
3 Blinking underline
4 Steady underline
Select Set-Up Language CSI Ps p n/a n/a DECSSL
Ps
none, 0, 1 English
2 French
3 German
4 Spanish
5 Italian
Show Control Character Mode same same CRM
Set (show): CSI 3 h
Reset (interpret): CSI 3 l
Text Cursor Enable Mode same n/a DECTCEM
Set (visible): CSI ? 25 h
Reset (invisible): CSI ? 25 l
Vertical Line Position Absolute CSI Pn d n/a n/a VPA
Vertical Line Position Relative CSI Pn e n/a n/a VPA
Vertical Tab VT same same VT
Vertical Autowrap same n/a DECAWM
Set (enable): CSI ? 7 h
Reset (disable): CSI ? 7 l
Horizontal Tabs—Set/Clear Control Function Mnemonic
VT510 VT420 VT100
Set Horizontal Tab ESC H same same HTS
Set Tab at every 8 columns CSI ? 5 W n/a n/a DECST8C
Clear Tabs CSI Ps g same same TBC
Ps Clear . . .
none, 0 tab at cursor
3 all tabs
Margins and Scrolling Control Function Mnemonic
VT510 VT420 VT100
Back Index ESC 6 same n/a DECBI
Forward Index ESC 9 same n/a DECFI
Index ESC D same same IND
Origin Mode same same DECOM
Set (in margins): CSI ? 6 h
Reset (upper-left): CSI ? 6 l
Reverse Index ESC M same same RI
Scrolling Mode same same DECSCLM
Set (smooth): CSI ? 4 h
Reset (jump): CSI ? 4 l
Set Left and Right Margin CSI Pl ; Pr s same same DECSLRM
Pl Left column margin
(default = 1)
Pr Right column margin (default = 80 or 132, depending on page width)
Set Scroll Speed CSI Ps SP p n/a n/a DECSSCLS
Ps
none, 0, 1, 2, 3 Smooth 2
4, 5, 6, 7, 8 Smooth 4
9 Jump
Set Top and Bottom Margin CSI Pt ; Pb r same same DECSTBM
Pt Top margin (default = 1)
Pb Bottom margin (default = lines per screen)
Page Arrangement and Size1 Control Function Mnemonic
VT510 VT420 VT100
Column Mode same same DECCOLM
Set (132 columns): CSI ? 3 h
Reset (80 columns): CSI ? 3 l
Set Columns per Page CSI Ps $ | same n/a DECSCPP
Ps Set each page to . . .
0 or 80 80 columns
132 132 columns
Set Lines Per Page CSI Pn t same same DECSLPP
Vertical Split Screen same n/a DECVSSM
Set (enable): CSI 69 h
Reset (disable): CSI 69 l
Page Movement Control Function Mnemonic
VT510 VT420 VT100
Next Page CSI Pn U same same NP
Pn Number of pages to move (0 or 1 = 1 page)
Preceding Page CSI Pn V same same PP
Pn Number of pages to move (0 or 1 = 1 page)
Page Position Absolute CSI Pn SP P same same PPA
Page Position Backward CSI Pn SP R same same PPB
Page Position Relative CSI Pn SP Q same same PPR
WINDOW MANAGEMENT
Coupling Mode
Page Cursor Coupling same n/a DECPCCM
Set: CSI ? 64 h
Reset: CSI ? 64 l
Vertical Cursor Coupling same n/a DECVCCM
Set: CSI ? 61 h
Reset: CSI ? 61 l
Display Extent Control Function Mnemonic
VT510 VT420 VT100
Request Displayed Extent CSI " v same n/a DECRQDE
Report Displayed Extent CSI Ph ; Pw ; Pml ; Pmt ; Pmp " w
same n/a DECRPDE
Select number of lines per screen CSI Pn * | same same DECSNLS
Pan Direction
Pan Down CSI Pl S same same SD
Pan Up CSI Pl T same same SU
Audible and Visual Attributes
Bell BEL same same BEL
Double Height Line Top ESC # 3 same same DECDHLT
Double Height Line Bottom ESC # 4 same same DECDHLB
Single Width Line ESC # 5 same same DECSWL
Double Width Line ESC # 6 same same DECDWL
Screen Mode – Light/Dark same same DECSCNM
Set (light background): CSI ? 5 h
Reset (dark background): CSI ? 5 l
Select Graphic Rendition2 CSI Ps ; Ps m same same SGR
Ps Attribute
0 All attributes off
1 Bold
4 Underline
5 Blinking
7 Negative image
8 Invisible image
10 ASCII char set (SCO only)3
11 Map 00-7F (SCO only)
12 Map 80-FF (SCO only)
22 Bold off
24 Underline off
25 Blinking off
27 Negative image off
28 Invisible image off
GRAPHIC CHARACTER SETS
Assign User-Preference Supp Set DCS Ps ! u Dscs ST same n/a DECAUPSS
Ps
0 94-Character Set
1 96-Character Set
Dscs Default 94-Character Set Dscs Default 96-Character Set
% 5 DEC Supplemental A ISO Latin-1 Supplemental
" ? DEC Greek B ISO Latin-2 Supplemental
" 4 DEC Hebrew F ISO Greek Supplemental
% 0 DEC Turkish H ISO Hebrew Supplemental
& 4 DEC Cyrillic L ISO Latin-Cyrillic
< User-preferred supplemental M ISO Latin-5 Supplemental
< User-preferred supplemental
Display PC Characters (SCO) ESC xx n/a n/a
Select Character Set ESC I Dscs same n/a SCS
I 94-Character G-set I 96-Character G-set
( G0 - G1
) G1 . G2
* G2 / G3
+ G3
Dscs Default 94-Character Set Dscs Default 96-Character Set
& 4 Cyrillic (DEC) A ISO Latin-1 Supplemental
A British/U.K. NRCS B ISO Latin-2 Supplemental
5 or C Finnish NRCS F ISO Greek Supplemental
R French NRCS H ISO Hebrew Supplemental
9 or Q French Canadian NRCS M ISO Latin-5 Supplemental
K German NRCS L ISO Latin-Cyrillic
" ? Greek (DEC) < User-preferred Supplemental
" > Greek NRCS
" 4 Hebrew (DEC)
% = Hebrew NRCS
Y Italian NRCS
`, E, or 6 Norwegian/Danish NRCS
% 6 Portuguese NRCS
& 5 Russian NRCS
% 3 SCS NRCS
Z Spanish NRCS
7 or H Swedish NRCS
= Swiss NRCS
% 0 Turkish (DEC)
% 2 Turkish NRCS
0 DEC Special Graphic
% 5 DEC Supplemental
> DEC Technical Character Set
< User-preferred Supplemental
Supplemental Character Set Control Function Mnemonic
VT510 VT420 VT100
National Replacement Character Set Mode same n/a DECNRCM
Set (National):
(7-bit characters)
CSI ? 42 h
Reset (Multinational):
(8-bit characters)
CSI ? 42 l
Request User-Preference Supplemental Set CSI & u same n/a DECRQUPSS
Response: DEC Ps ! u Dscs ST See DECAUPSS
Parameters:
Send Control Character to Host
7-bit controls ESC SP F n/a n/a S7C1T
8-bit controls ESC SP G n/a n/a S8C1T
Single Shift 2 ESC N same same SS2
Single Shift 3 ESC O same same SS3
EDITING AND TEXT PROCESSING Control Function Mnemonic
VT510 VT420 VT100
Delete Character CSI Pn P same same DCH
Pn Number of characters to delete (default = 1).
Delete Column CSI Pn ' ~ same n/a DECDC
Pn Number of columns to delete (default = 1).
Delete Line CSI Pn M same same DL
Pn Number of lines to delete (default = 1).
Erase Character CSI Pn X same n/a ECH
Pn Number of characters to erase (Pn = 0 or 1 (default) = 1 character).
Erase in Display CSI Ps J same same ED
Ps Erase from . . .
0 Cursor to end of display
1 Top of display through cursor
2 Top to bottom of display
Erase in Line CSI Ps K same same EL
Ps Erase from . . .
0 Cursor to end of line
1 Start of line through cursor
2 Start to end of line
Insert Character CSI Pn @ same n/a ICH
Insert Column CSI Pn ' } same n/a DECIC
Pn Number of columns to insert (default = 1).
Insert Line CSI Pn L same same IL
Pn Number of lines to insert (default = 1).
Insert/Replacement Mode same same IRM
Set (insert): CSI 4 h
Reset (replace): CSI 4 l
Select Character Attribute4 CSI Ps " q same n/a DECSCA
Ps Meaning
0 DECSED and DECSEL can erase characters.
1 DECSED and DECSEL cannot erase characters.
2 Same as 0.
Selective Erase in Display CSI ? Ps J same n/a DECSED
Ps Erase from . . .
0 Cursor to end of display
1 Top of display through cursor
2 Top to bottom of display
Selective Erase in Line CSI ? Ps K same n/a DECSEL
Ps Erase from . . .
0 Cursor to end of line
1 Start of line through cursor
2 Start to end of line
Rectangle Area Processing Control Function Mnemonic
VT510 VT420 VT100
Change Attribute in Rectangle CSI Pt;Pl;Pb;Pr; Ps1;...Psn $ r
same n/a DECCARA
Ps Attribute
0 Off
1 Bold Pt Top line
4 Underline Pl Left column
5 Blink Pb Bottom line
7 Negative image Pr Right column
22 No bold
24 No underline
25 No blink
27 Positive image
Copy Rectangular Area CSI Pts;Pls;Pbs;Prs;Pps;Ptd;Pld;Ppd $ v
same n/a DECCRA
Source Destination
Pts Top line border Ptd Top line border
Pls Left column border Pld Left column border
Pbs Bottom line border Ppd Page number
Prs Right column border
Pps Page number
Erase Rectangular Area CSI Pt;Pl;Pb;Pr $ z same n/a DECERA
Fill Rectangular Area CSI Pch; Pt;Pl;Pb;Pr $ x
same n/a DECFRA
Pch Character
Reverse Attribute in Rectangle CSI Pt;Pl;Pb;Pr Ps1;...Psn $ t
same n/a DECRARA
Ps Reverse Attributes
0 All
1 Bold
4 Underline
5 Blink
7 Negative image
Select Attribute and Change Extent Mode CSI Ps * x same n/a DECSACE
Selective Erase Rectangular Area CSI Pt;Pl;Pb;Pr $ { same n/a DECSERA
Memory Checksum Report or DSR-Memory Checksum CSI ? 63; Pid n same n/a DECCKSR or DSR-Mem
Response: DCS Pid ! ~ D...D ST
Request Checksum of Rect Area CSI Pid;Pp;Pt;Pl;Pb;Pr * y
same n/a DECRQCRA
Response: DCS Pid ! ~ D...D ST
Table 4–6 Reports Control Functions
Macro Control Function Mnemonic
VT510 VT420 VT100

1A DECRQM sequence can only ask about one mode at a time. When the terminal is set to VT52 mode, DECRQM provides no report.

2The * means this mode is always Reset in the terminal and cannot be changed.

Define Macro DCS Pid;Pdt;Pen ! z D...D ST
same n/a DECDMAC
DSR - Macro Space CSI ? 62 n same n/a DSR-MSR
Invoke Macro CSI Pid * z same n/a DECINVM
Macro Space Report CSI Pn * { same n/a DECMSR, DSR-MSR
Pn = number of bytes
16
Reports
DSR - Data Integrity Report CSI ? 75 n same n/a DSR-Data
Response: CSI ? Ps n
Ps Meaning
70 Ready, no power loss or comm errors.
71 Malfunction, comm error.
73 No reported data loss since last power up.
Presentation State Report (See DECRQPSR.) n/a n/a DECPSR
Report Mode (DECRPM) (See Report Mode (ANSI) below.) same n/a DECRPM
Request Mode (ANSI) CSI Pa $ p same n/a DECRQM1
Request Mode (DEC) CSI ? Pd $ p same n/a DECRQM
Request Presentation State Report CSI Ps $ w same n/a DECRQPSR
Ps Report Requested
0 Error, restore ignored.
1 Cursor information report (DECCIR)
2 Tab stop report (DECTABSR)
Report Selection or Setting (See DECRQSS.) same n/a DECRPSS
Request Selection or Setting same n/a DECRQSS
Request (DECRQSS): DCS $ q D...D ST
Report (DECRPSS): DCS Ps $ r D...D ST
Setting Control Sequence Final Characters Mnemonic
Select Active Status Display $ g DECSASD
Select Attribute Change Extent * x DECSACE
Set Character Attribute " q DECSCA
Set Conformance Level " p DECSCL
Set Columns Per Page $ | DECSCPP
Set Lines Per Page t DECSLPP
Set Number of Lines per Screen * | DECSNLS
Set Status Line Type $ ~ DECSSDT
Set Left and Right Margins s DECSLRM
Set Top and Bottom Margins r DECSTBM
Set Graphic Rendition m SGR
Select Set-Up Language p DECSSL
Select Printer Type $ s DECSPRTT
Select Refresh Rate " t DECSRFR
Select Digital Printed Data Type ) p DECSDPT
Select ProPrinter Character Set * p DECSPPCS
Select Communication Speed * r DECSCS
Select Communication Port * u DECSCP
Set Scroll Speed SP p DECSSCLS
Set Cursor Style SP q DECSCUSR
Set Key Click Volume SP r DECSKCV
Set Warning Bell Volume SP t DECSWBV
Set Margin Bell Volume SP u DECSMBV
Set Lock Key Style SP v DECSLCK
Select Flow Control Type * s DECSFC
Select Disconnect Delay Time $ q DECSDDT
Set Transmit Rate Limit " u DECSTRL
Set Port Parameter + w DECSPP
Reports (Cont.) Control Function Mnemonic
VT510 VT420 VT100
Request Terminal State Report same n/a DECRQTSR
Request: CSI 1 $ u
Reply to Host: DCS 1 $ s D...D ST
Effects
DDD1 DECRLM, DECHEBM, and DECHCEM are set. DDD1
DDD2 DECRLM is reset. ASCII is designated in G1. DDD2
DDD3 ASCII is designated in G0. DDD3
Restore Presentation State DCS Ps $ t D...D ST same n/a DECRSPS
Ps Data String Format
0 Error, restore ignored.
1 Selects the format of the cursor information report (DECCIR).
2 Selects the format of the tab stop report (DECTABSR).
D...D Data string of tab stops or cursor position.
Restore Terminal State DCS Ps $ p D...D ST same n/a DECRSTS
Ps Data String Format
0 Error, restore ignored.
1 Selects the format of the terminal state report (DECTSR).
D...D Data string of restored information.
Report Mode (ANSI) CSI Pa; Ps $ y same n/a
Report Mode (DEC) CSI ? Pd; Ps $ y same n/a
Reset Mode CSI P1.....Pn l same same RM
Set Mode CSI P1.....Pn h same same SM
Mode Description ANSI Mode DEC Mode
Pa Mnemonic2 Pd Mnemonic Mode
Guarded area transfer 1 GATM * ?1 DECCKM Cursor keys
Keyboard action 2 KAM ?2 DECANM ANSI/VT52
Control representation 3 CRM ?3 DECCOLM Column
Insert/replace 4 IRM ?4 DECSCLM Scrolling
Status reporting transfer 5 SRTM * ?5 DECSCNM Screen
?6 DECOM Origin
Vertical editing 7 VEM * ?7 DECAWM Autowrap
Horiz editing 10 HEM * ?8 DECARM Autorepeat
Positioning unit 11 PUM *
Send/receive 12 SRM
Format effector action 13 FEAM *
Format effector transfer 14 FETM *
Multiple area transfer 15 MATM *
Transfer termination 16 TTM *
Selected area transfer 17 SATM *
Tabulation stop 18 TSM * ?18 DECPFF Print form
Editing boundary 19 EBM * ?19 DECPEX Print extent
Linefeed/New line 20 LNM
Text cursor enable ?25 DECTCEM
Right-to-left ?34 DECRLM
Hebrew keyboard map ?35 DECHEBM
Hebrew encoding ?36 DECHEM
NRCS characters ?42 DECNRCM
Greek/N.A. ?57 DECNAKB
Horiz cursor coupling ?60 DECHCCM *
Vertical cursor coupling ?61 DECVCCM
Page cursor coupling ?64 DECPCCM
Numeric keypad ?66 DECNKM
Backarrow key ?67 DECBKM
Keyboard usage ?68 DECKBUM
Vertical split screen ?69 DECVSSM
Transmit rate limiting ?73 DECXRLMM
No clear screen ?95 DECNCSM
Right-to-left copy ?96 DECRLCM
CRT save ?97 DECCRTSM
Auto resize ?98 DECARSM
Modem control ?99 DECMCM
Auto answerback ?100 DECAAM
Conceal answerback ?101 DECCANSM
Null ?102 DECNULM
Half-duplex ?103 DECHDPXM
Enable secondary keyboard language ?104 DECESKM
Overscan ?106 DECOSCNM
Set/Reset Parameters ANSI Mode DEC Mode
Ps
Not recognized 0 same
Set 1 same
Reset 2 same
Set permanently 3 same
Reset permanently 4 same
Reports (Cont.) Control Function Mnemonic
VT510 VT420 VT100
Set Mode/Reset Mode (See also DECRQM.) SM/RM
Send/Receive Mode (Local Echo) same same SRM
Set (Local echo off): CSI 12 h
Reset (Local echo on): CSI 12 l
Tabulation Stop Report DCS 2 $ u D...D ST same n/a DECTABSR
D...D Column numbers of tab stops.
Terminal State Report (See DECRQTSR.) same n/a DECTSR
Table 4–7 Terminal Management Control Functions
Purpose Control Function Mnemonic
VT510 VT420 VT100

1DECID may not be supported; use primary device attributes (DA1) instead.

2 "ESC # 8" invokes the Screen Alignment test. DECTST causes a disconnect; therefore, it should not be used in conjunction with a modem.

3Overscan and 72 Hz refresh rate cannot co-exist when the terminal is set to 42 or 53 lines per screen. Refer to DECSNLS—Set Lines Per Screen for details.

4DECTID has no effect when the terminal is in VT52 mode.

CRT Save Mode n/a n/a DECCRTSM
Set (enable CRT saver): CSI ? 97 h
Reset (disable CRT saver): CSI ? 97 l
Device Attributes CSI c or CSI 0 c same same DA1
Response: CSI ? Psc ; PS1 ; ... Psn c
(See Primary Device Attributes (DA1).)
Secondary Device Attributes CSI > c or CSI > 0 c same same DA2
VT Response: CSI > 61; Pv ; 0 c
PC Response: CSI > 61; Pv ; 1 c
(See Secondary Device Attributes (DA2).)
Tertiary Device Attributes CSI = c or CSI = 0 c same same DA3
Device Status Report – ANSI: CSI Ps n same same DSR
Device Status Report – DEC: CSI ? Ps n same same DSR
Enter/Exit PCTerm Mode or Select ASCII characters or scancodes CSI ? Ps1; Ps2 r same n/a DECPCTERM
Ps1 VT Emulation Mode SCO Console Mode
none, 0 VT Mode ASCII characters
1 PCTerm Mode Scancodes
Ps2 Character Set Ps2 Character Set
210 PC Greek none, 0 No Change
220 PC Spanish 1 PC Multilingual
437 PC International 2 PC International
850 PC Multilingual 3 PC Danish/Norwegian
852 PC Slavic (Latin 2) 4 PC Spanish
857 PC Turkish 5 PC Portuguese
860 PC Portuguese 6 DEC Supplemental
862 PC Hebrew 7 ISO Latin 1
863 PC French-Canadian
865 PC Danish
866 PC Cyrillic
Identify Device ESC Z n/a same DECID1
Invoke Confidence Test2 CSI 4 ; Ps ; ... ; Ps y same n/a DECTST
Ps Test
0 "All Tests" (1, 2, 3, 6)
1 Power-Up Self Test
2 RS-232 Port Data Loopback
3 Printer Port Loopback
4 Speed Select and Indicator
5 Reserved - No action
6 Modem Loopback Test
7 EIA-423 Port Loopback
8 Parallel Port Loopback
9 Repeat other tests
Overscan Mode n/a n/a DECOSCNM
Set (enable overscan):3 CSI ? 106 h
Reset (disable overscan): CSI ? 106 l
Primary Device Attributes CSI c or CSI 0 c same same DA1
Model Response to DA1
North American CSI ? 64;1;2;7;8;9;15;18;21;44;45;46 c
World-Wide CSI ? 64;1;2;7;8;9;12;15;18;21;23;24;42;44;45;46 c
Ext Description Ext Description
1 132 columns 18 Windowing capability
2 Printer port extension 21 Horizontal scrolling
4 Sixel extension 23 Greek extension
6 Selective erase 24 Turkish extension
7 DRCS 42 ISO Latin 2 character set
8 UDK 44 PCTerm
9 NRCS 45 Soft key map
12 SCS extension 46 ASCII emulation
15 Technical character set
Report Terminal Unit ID DCS ! | D...D ST same n/a DECRPTUI
Reset to Initial state ESC c same same RIS
Secondary Device Attributes CSI > c or CSI > 0 c same n/a DA2
Keyboard Response
VT keyboard CSI > 61; Pv; 0 c
PC keyboard CSI > 61; Pv; 1 c
Pv Firmware version
Secure Reset ESC [ Pr + p same n/a DECSR
Secure Reset Confirmation ESC [ Pr * q same same DECSRC
Select Conformance (Operating) Level CSI 6 Ps1 ; Ps2 ; " p same same DECSCL
Ps1 Level Selected Ps2 Data Bits
none,0,1 1 - VT100 none, 0, 2 8-bit controls
2,3,4 4 - VT510 1 7-bit controls
Select Refresh Rate3 CSI Ps " t n/a n/a DECSRFR
Ps Cursor Style
1 50 Hz
2 60 Hz
none, 0 or 3 ≥ 70 Hz
Select Terminal ID4 CSI Ps , q same same DECTID
Ps ID Type Response to DECTID Terminal Type
0 VT100 ESC [ ? 1; 2 c VT100
1 VT101 ESC [ ? 1; 0 c VT101
2 VT102 ESC [ ? 6 c VT102
5 VT220 CSI ? 62; 1; 2; 7; 8 c VT220 North American
CSI ? 62; 1; 2; 7; 8; 9 c VT220 International
7 VT320 CSI ? 63; 1; 2; 7; 8 c VT320 North American
CSI ? 63; 1; 2; 7; 8; 9 c VT320 International
9 VT420 CSI ? 64; 1; 2; 7; 8; 9; 15; 18; 21 c VT420 North American
CSI ? 64; 1; 2; 7; 8; 9; 15; 18; 21 c VT420 International
10 VT510 Refer to DA1 for response.
Soft Terminal Reset CSI ! p same n/a DECSTR
Terminal Mode Emulation CSI Ps SP ~ n/a n/a DECTME
Ps Terminal Mode
none, 0 or 1 VT510 (VT Level 4)
2 VT100
3 VT52
4 VT420 PCTerm
5 WYSE 60/160
6 WYSE 60/160 PCTerm
7 WYSE 50+
8 WYSE 150/120
9 TVI 950
10 TVI 925
11 TVI 910+
12 ADDS A2
13 SCO Console
Exit ANSI (VT52) Mode ESC < same same DECANM
Status Display Extension Functions Control Function Mnemonic
VT510 VT420 VT100
Select Active Status Display CSI Ps $ } same n/a DECSASD
Ps Send data to . . .
0 Main display only
1 Status line only
Select Status Display (Line) Type CSI Ps $ ~ n/a n/a DECSSDT
Ps Status Line Selected
0 No status line
1 Indicator status line
2 Host-writable status line
Desktop Features Control Functions Control Function Mnemonic
VT510 VT420 VT100
Load Time of Day CSI Ps1; Ps2 , p n/a n/a DECLTOD
Ps1 Hour (decimal number between 00 and 23)
Ps2 Minutes (decimal number between 00 and 59)
Table 4–8 Keyboard Processing Control Functions
Purpose Control Function Mnemonic
VT510 VT420 VT100

1DECHEM is opposite in action to DECNRCM; that is, setting DECHEM has the same result as resetting DECNRCM.

2The VT510 reports this sequence upon receiving DECRQPKFM from the host. See reference for limitations.

3See DECPFK for direction definitions.

Autorepeat Mode same same DECARM
Set (repeat): CSI ? 8 h
Reset (disabled): CSI ? 8 l
Backarrow Key Mode same same DECBKM
Set (backspace): CSI ? 67 h
Reset (delete): CSI ? 67 l
Copy Key Default DCS " z D...D ST n/a n/a DECCKD
D...D Key-s/Key-d;Key-s/Key-d...;
Key-s Source key
Key-d Destination key
Cursor Keys Mode same same DECCKM
Set (application): CSI ? 1 h
Reset (cursor): CSI ? 1 l
Define Function Key (SCO) ESC Q Fn string n/a n/a SCODFK
Device Status Report (keyboard status) DSR
Request Keyboard Report: CSI ? 26 n same same
Reply to Keyboard Request: CSI ? 27 ; Pn; Pst; Ptyp n
same same
Pn Keyboard Language (VT/PC) Pn Keyboard Language (VT or PC)
0 Unknown 15 Spanish
1 North American 16 Portuguese
2 British 19 Hebrew
3 Belgian (Flemish) 22 Greek
4 French Canadian 28 Canadian English
5 Danish 29 Turkish Q/Turkish
6 Finnish 30 Turkish F/Turkish
7 German/German 31 Hungarian
8 Dutch 33 Slovak
9 Italian 34 Czech
10 Swiss French 35 Polish
11 Swiss German 36 Romanian
12 Swedish 38 SCS
13 Norwegian 39 Russian
14 French 40 Latin American
Pst Keyboard Status Ptyp Keyboard Type
0 Keyboard Ready 4 LK450
3 No Keyboard 5 PCXAL
8 Keyboard Busy
Down-line Load DCS Pfn; Pcn; Pe; Pcmw; Pss; Pu; Pcmh;
Pcss
{ <Dscs> <sixel-font-patterns> ST
same n/a DECDLD
Extended Keyboard Report APC : ppp mm ST same n/a DECEKBD
Enable Local Functions CSI Pf1;Pc1;...Pfn;Pcn + q n/a DECELF
Enable Secondary Keyboard Language Mode same n/a DECESKM
Set (secondary): CSI ? 104 h
Reset (primary): CSI ? 104 l
Function Key CSI Ps1; Ps2 ~ same n/a DECFNK
Ps1 Function key
Ps2 Modifier
Hebrew Encoding Mode1 same n/a DECHEM
Set (8-bit char): CSI ? 36 h
Reset (7-bit char): CSI ? 36 l
Hebrew Keyboard Map Mode same n/a DECHEBM
Set (Hebrew keyboard): CSI ? 35 h
Reset (North American): CSI ? 35 l
Keyboard Action Mode same same KAM
Set (lock): CSI 2 h
Reset (unlock): CSI 2 l
Keypad Application Mode ESC = same same DECKPAM
Keyboard Language Selection CSI Ps1; Ps2 SP } same n/a DECKBD
Ps1 Keyboard Type
1,0 VT keyboard layout
2 Enhanced PC keyboard layout
Ps2 Keyboard Language (VT/PC) Ps2 Keyboard Language (VT or PC)
none, 0, 1 North American 16 Portuguese
2 British 19 Hebrew
3 Belgian 22 Greek
4 French Canadian 28 Canadian English
5 Danish 29 Turkish Q/Turkish
6 Finnish 30 Turkish F/Turkish
7 German 31 Hungarian
8 Dutch 33 Slovak
9 Italian 34 Czech
10 Swiss French 35 Polish
11 Swiss German 36 Romanian
12 Swedish 38 SCS
13 Norwegian 39 Russian
14 French 40 Latin American
15 Spanish
Keypad Numeric Mode ESC > same same DECKPNM
Key Position Mode same n/a DECKPM
Set (key position): CSI ? 81 h
Reset (char codes): CSI ? 81 l
Keyboard Usage Mode same n/a DECKBUM
Set (data processing): CSI ? 68 h
Reset (typewriter): CSI ? 68 l
Local Function Key Control CSI Pk1; Pf1; Pk2; Pf2... * g
same n/a DECLFKC
Pk Function VT Keyboard Enhanced PC Keyboard
1 Hold F1 Scroll Lock
2 Print F2 Print Screen
3 Set-Up F3 Cap Lock/Print Screen
Locking Shift LS
LS0 Map G0 into GL SI same same
LS1 Map G1 into GL SO same same
LS1R Map G1 into GR ESC ~ same n/a
LS2 Map G2 into GL ESC n same n/a
LS2R Map G2 into GR ESC } same n/a
LS3 Map G3 into GL ESC o same n/a
LS3R Map G3 into GR ESC | same n/a
North American/Greek Selection same n/a DECNAKB
Set (North American): CSI ? 57 h
Reset (Greek keyboard): CSI ? 57 l
Numeric Keypad Mode same n/a DECNKM
Set (application): CSI ? 66 h
Reset (numeric): CSI ? 66 l
Program Alphanumeric Key DCS " y D...D ST n/a n/a DECPAK
Program Function Key DCS " x D...D ST n/a n/a DECPFK
Program Key Action CSI Ps + z n/a n/a DECPKA
Ps1 Program Key Action
none, 0 None
1 Lock Keys and Modifiers
2 Restore Factory Defaults
3 Recall Key Definitions
Program Key Free Memory Report2 CSI Ps1; Ps2 + y n/a n/a DECPKFMR
Ps1 Total memory (bytes)
Ps2 Free memory
Program Key Free Memory Inquiry CSI + x n/a n/a DECRQPKFM
Response: DECPKFMR
Request Key Type CSI Ps , u n/a n/a DECRQKT
Report Key Type CSI Ps1; Ps2 , v n/a n/a DECRPKT
Report Function Key Definition DCS " } D...D ST n/a n/a DECRPFK
Report Modifiers/Key State DCS " ~ D...D ST n/a n/a DECRPAK
Set Key Click Volume CSI Ps SP r same n/a DECSKCV
Ps Volume
1 Off
2, 3, 4 Low
none, 0, 5, 6, 7, 8 High
Set Lock Key Style CSI Ps SP v n/a n/a DECSLCK
Ps Lock Style
none, 0, 1 Caps Lock
2 Shift Lock
3 Reverse Lock
Num Lock Mode same same DECNUMLK
Set: CSI ? 108 h
Reset: CSI ? 108 l
Caps Lock Mode same same DECCAPSLK
Set: CSI ? 109 h
Reset: CSI ? 109 l
Keyboard LEDs Host Indicator Mode same same DECKLHIM
Set: CSI ? 110 h
Reset: CSI ? 110 l
Load LEDs CSI Ps q n/a n/a DECLL
Ps Volume
0 Clear all LEDs
1 Light Num Lock
2 Light Caps Lock
3 Light Scroll Lock
21 Extinguish Num Lock
22 Extinguish Caps Lock
23 Extinguish Scroll Lock
Set Margin Bell Volume CSI Ps SP u same n/a DECSMBV
Ps Volume
none, 0, 1 Off
2, 3, 4 Low
5, 6, 7, 8 High
Select Modifier Key Reporting (See reference.) CSI Pm1;Pf1...Pmn;Pfn + r
same n/a DECSMKR
Set Warning Bell Volume CSI Ps SP t n/a n/a DECSWBV
Ps Volume
1 Off
2, 3, 4 Low
none, 0, 5, 6, 7, 8 High
User-Defined Keys Control Function Mnemonic
VT510 VT420 VT100
User Defined Keys DCS Ps1; Ps2; Ps3 | D...D ST
same n/a DECUDK
Ps1 Clear . . .
none, 0 All UDKs before loading new values
1 Old UDKs only when redefined; load new UDK values.
Ps2 Lock . . .
none, 0 UDKs against future redefinition
1 Don't lock the UDKs against future redefinition.
Ps3 Define . . .
none, 0 Shifted function key
1 Unshifted function key
2 Shifted function key
3 Alt unshifted function key
4 Alt shifted function key
D...D Key1/St1/Dir;Key2/St2/Dir;.......Keyn/Stn/Dir;
Stn Sequence user-defined key (UDK)
Keyn VT Keyboard PC Keyboard
11 F1 F1
12 F2 F2
13 F3 F3
14 F4 F4
15 F5 F5
17 F6 F6
18 F7 F7
19 F8 F8
20 F9 F9
21 F10 F10
23 F11 F11
24 F12 F12
25 F13
26 F14
28 F15
29 F16
31 F17
32 F18
33 F19
34 F20
Dir Direction3
0, none Normal
1 Local
2 Remote
DSR - User-Defined Key Request same n/a DSR-UDK
Request UDK lock: CSI ? 25 n
Reply to UDK locked status: CSI ? 20 n
Reply to UDK unlocked status: CSI ? 21 n
Table 4–9 Communications Control Functions
Printer Port Function Control Function Mnemonic
VT510 VT420 VT100

1This sequence takes effect only when a ProPrinter or Digital printer with ProPrinter emulation mode is attached.

2The answerback data string may consist of from 0 to 30, 7- or 8-bit characters, which are hex pairs in the 3/0 through 3/9 (0 through 9) range, 4/1 through 4/6 (A through F) range, and 6/1 through 6/6 (A through F) range. Pressing Ctrl/Break or receiving an ENQ code causes the VT510 to transmit the answerback message.

† Not available for the printer port. If specified in the sequence to configure the printer port, the Ps3 value is ignored.

DSR - Printer Port Report same same DSR-Print
Request: CSI ? 15 n
Response: CSI ? Ps n
Ps Printer . . .
10 Ready
11 Not ready
13 Off line
18 Busy
19 On another session.
Media Copy - Send Screen Data through Host Port CSI 2 i n/a n/a MC
Media Copy - Start/Stop Printer-to-Host Session MC
ANSI: CSI Pa i same same
DEC: CSI ? Pd i same CSI ?8i
ANSI Mode DEC Mode
Pa Function Pd Function
0, none Print page 1 Print cursor line
4 Reset printer controller mode 4 Reset autoprint mode
5 Set printer controller mode 5 Set autoprint mode
6 Start printer to host session 8 Stop printer to host session
7 Stop printer to host session 9 Start printer to host session
10 Print composed main display
11 Print all pages
18 Assign printer to active host session
19 Accept printer commands from sessions
Print Extent Mode same same DECPEX
Set (entire page): CSI ? 19 h
Reset (scroll region): CSI ? 19 l
Print Form Feed Mode same same DECPFF
Set (FF): CSI ? 18 h
Reset (no FF): CSI ? 18 l
Select Digital Printed Data Type1 CSI Ps ) p n/a n/a DECSDPT
Ps Printed Data Type
none, 0, 1 Print National Only
2 National and Line Drawing
3 Print Multinational
4 Print All Characters
Select Printer Type CSI Ps $ s n/a n/a DECSPRTT
Ps Printer Type
none, 0, 1 DEC ANSI
2 IBM ProPrinter
3 DEC + IBM
Select ProPrinter Character Set CSI Pn * p n/a n/a DECSPPCS
Pn Printer
210 PC Greek
220 PC Spanish
437 PC International
850 PC Multilingual
852 PC Slavic (Latin 2)
857 PC Turkish
860 PC Portuguese
862 PC Hebrew
863 PC French-Canadian
865 PC Danish
866 PC Cyrillic
Start/stop printer; see Media Copy.
DEC Printers with ProPrinter Emulation Control Function Mnemonic
VT510 VT420 VT100
Enter/Return from IBM ProPrinter Emulation Mode n/a n/a DECIPEM
Enter: CSI ? 58 h
Return: CSI ? 58 l
Terminal Synchronization
Auto Answerback Mode same same DECAAM
Set: CSI ? 100 h
Reset: CSI ? 100 l
Conceal Answerback Message Mode n/a n/a DECCANSM
Set: CSI ? 101 h
Reset: CSI ? 101 l
Communication Port CSI Ps1; Ps2 * u n/a n/a DECSCP
Ps1 Printer Port
1 Parallel port
2 Comm1
3 Comm2
Ps2 Session 1
1 Comm1
2 Comm2
Communication Speed CSI Ps1; Ps2 * r n/a n/a DECSCS
Ps1 Comm Line Ps2 Communication Speed
none, 0, 1 Host Transmit none, 0 Use default speed.
2 Host Receive 1 300
3 Printer 2 600
4 Modem Hi 3 1200
5 Modem Lo 4 2400
5 4800
6 9600
7 19200
8 38400
9 57600
10 76800
11 115200
Communication Line Default Communication Speed
Host Transmit 9600
Host Receive Receive=transmit
Printer 4800
Modem Hi Ignore
Modem Lo Ignore
Device Control 1 (XON) DC1 same same
Device Control 3 (XOFF) DC3 same same
Disconnect Delay Time CSI Ps $ q same same DECSDDT
Ps Delay Time
1 None
2 60 ms
none, 0, 3 2 s
Flow Control CSI Ps1; Ps2; Ps3; Ps4 * s
n/a n/a DECSFC
Ps1 Port Type Ps3 Flow Control Type
none, 0, 1 Comm Port none, 0 or 1 XON/XOFF or XPC (for receive only)
2 Printer Port 2 DTR
3 Both
4 None
Ps2 Transmit or Receive Ps4 Flow Control Threshold
1, 0 or none Transmit none, 0 or 1 Low (64)
2 Receive 2 High (768)
3 Transmit and Receive
Half-Duplex Mode n/a n/a DECHDPXM
Set: CSI ? 103 h
Reset: CSI ? 103 l
Load Answerback Message2 DCS Ps v D...D ST n/a n/a DECLANS
Load Banner Message DCS Ps r D...D ST n/a n/a DECLBAN
Modem Control Mode n/a n/a DECMCM
Set: CSI ? 99 h
Reset: CSI ? 99 l
Null Mode n/a n/a DECNULM
Set (ignore NUL): CSI ? 102 h
Reset (accept NUL): CSI ? 102 l
Set Port Parameters CSI Ps1; Ps2; Ps3; Ps4 + w
n/a n/a DECSPP
Ps1 Port Ps3 Parity
none, 0 or 1 Comm Port none, 0 or 1 No parity
2 Printer Port 2 Even
3 Odd
Ps2 Data 4† Even
1, 0 or none 8 bits 5† Odd, unchecked
2 7 bits 6 Mark
7 Space
Ps4 Stop Bit
none, 0 or 1 1 bit
2 2 bits
Set Transmit Rate Limit CSI Ps1; Ps2 " u n/a n/a DECSTRL
Ps1 Key Type
none, 0 or 1 All keys
2 Graphic key
3 Function key
Ps2 Characters Per Second
none, 0, 1 150 cps
2 50 cps
3 30 cps
Transmit Rate Limiting Mode same n/a DECXRLM
Set (limited): CSI ? 73 h
Reset (unlimited): CSI ? 73 l