[Top] [Prev] [Next] [Contents] [Index]

Using Keyboard Escape Sequences

An escape sequence is a series of non-printing characters, beginning with an Escape character, that sends a command to a device. Escape sequences are used by some legacy applications for printing, communications, and display management. The command in an escape sequence results in specified actions by devices. Escape sequences are also called control codes or control sequences.

The tables in this section describe the escape sequences sent to the terminal emulator from the following NCD keyboards: N-101/N-102, VT220/N-108LK, and N-97/N-Kana.

Escape key sequences are sent by the following types of keys:

N-101/N-102 Keyboard Escape Sequences

The tables in this section list escape sequences for N-101/N-102 keyboards.

Table 12-9 N-101/N-102 Keypad Escape Sequences
Key
Application Mode Reset
Application Mode Set

8-bit
7-bit
0 0 SS3 p Esc O p
1 1 SS3 q Esc O q
2 2 SS3 r Esc O t
3 3 SS3 s Esc O s
4 4 SS3 t Esc O t
5 5 SS3 u Esc O u
6 6 SS3 v Esc O v
7 7 SS3 w Esc O w
8 8 SS3 x Esc O x
9 9 SS3 y Esc O y
Enter Return SS3 M Esc O M
- - SS3 m Esc O m
. . SS3 n Esc O n
+ + + +
/ / / /
* * * *

Table 12-10 N-101/N-102 Function Key Escape Sequences
Key

Escape Sequence

8-bit

7-bit

F1 CSI 1 1 ~ Esc [ 1 1 ~
F2 CSI 1 2 ~ Esc [ 1 2 ~
F3 CSI 1 3 ~ Esc [ 1 3 ~
F4 CSI 1 4 ~ Esc [ 1 4 ~
F5 CSI 1 5 ~ Esc [ 1 5 ~
F6 CSI 1 7 ~ Esc [ 1 7 ~
F7 CSI 1 8 ~ Esc [ 1 8 ~
F8 CSI 1 9 ~ Esc [ 1 9 ~
F9 CSI 2 0 ~ Esc [ 2 0 ~
F10 CSI 2 1 ~ Esc [ 2 1 ~
F11 CSI 2 3 ~ Esc [ 2 3 ~
F12 CSI 2 4 ~ Esc [ 2 4 ~

Table 12-11 N-101/N-102 Editing Keypad Escape Sequences
Key

Escape Sequence

8-bit

7-bit

Insert CSI 2 ~ Esc [ 2 ~
Home CSI ^ A Esc [ ^ A
Page Up CSI 5 ~ Esc [ 5 ~
Delete CSI ^ ? Esc [ ^ ?
End CSI ^ B Esc [ ^ B
Page Down CSI 6 ~ Esc [ 6 ~

Table 12-12 N-101/N-102 Cursor Keypad Sequences
Arrow Key

Escape Sequence

8-bit

7-bit

Up CSI A Esc [ A
Down CSI B Esc [ B
Right CSI C Esc [ C
Left CSI D Esc [ D

N-108LK (VT220-Style) Keyboard Escape Sequences

The tables in this section list escape sequences for N-108LK and VT220 keyboards.

Table 12-13 N-108LK Keypad Escape Sequences
Key

Application Mode Reset

Application Mode Set

8-bit

7-bit

8-bit

7-bit

0 0 0 SS3 p Esc O p
1 1 1 SS3 q Esc O q
2 2 2 SS3 r Esc O r
3 3 3 SS3 s Esc O s
4 4 4 SS3 t Esc O t
5 5 5 SS3 u Esc O u
6 6 6 SS3 v Esc O v
7 7 7 SS3 w Esc O w
8 8 8 SS3 x Esc O x
9 9 9 SS3 y Esc O y
, , , SS3 l Esc O l
- _ _ SS3 m Esc O m
. . . SS3 n Esc O n
Enter Return Return SS3 M Esc O M
PF1 SS3 P Esc O P SS3 P Esc O P
PF2 SS3 Q Esc O Q SS3 Q Esc O Q
PF3 SS3 R Esc O R SS3 R Esc O R
PF4 SS3 S Esc O S SS3 S Esc O S

Table 12-14 N-108LK Function Key Escape Sequences
Key

VMS

ULTRIX

8-bit

7-bit

8-bit

7-bit

F1 hold screen hold screen hold screen hold screen
F2 print screen print screen print screen print screen
F3
F4
F5* Break Break Break Break
F6 CSI 1 7 ~ Esc [ 1 7 ~ CSI 1 7 ~ Esc [ 1 7 ~
F7 CSI 1 8 ~ Esc [ 1 8 ~ CSI 1 8 ~ Esc [ 1 8 ~
F8 CSI 1 9 ~ Esc [ 1 9 ~ CSI 1 9 ~ Esc [ 1 9 ~
F9 CSI 2 0 ~ Esc [ 2 0 ~ CSI 2 0 ~ Esc [ 2 0 ~
F10 CSI 2 1 ~ Esc [ 2 1 ~ CSI 2 1 ~ Esc [ 2 1 ~
F11 CSI 2 3 ~ Esc [ 2 3 ~ Esc _ Esc _
F12 CSI 2 4 ~ Esc [ 2 4 ~ Backspace Backspace
F13 CSI 2 5 ~ Esc [ 2 5 ~ Newline Newline
F14 CSI 2 6 ~ Esc [ 2 6 ~ CSI 2 6 ~ Esc [ 2 6 ~
Help CSI 2 8 ~ Esc [ 2 8 ~ CSI 2 8 ~ Esc [ 2 8 ~
Do CSI 2 9 ~ Esc [ 2 9 ~ CSI 2 9 ~ Esc [ 2 9 ~
F17 CSI 3 1 ~ Esc [ 3 1 ~ CSI 3 1 ~ Esc [ 3 1 ~
F18 CSI 3 2 ~ Esc [ 3 2 ~ CSI 3 2 ~ Esc [ 3 2 ~
F19 CSI 3 3 ~ Esc [ 3 3 ~ CSI 3 3 ~ Esc [ 3 3 ~
F20 CSI 3 4 ~ Esc [ 3 4 ~ CSI 3 4 ~ Esc [ 3 4 ~
*F5 is the break key in a serial terminal emulator only.

Table 12-15 N-108LK Cursor Keypad Sequences
Arrow Key

Cursor Key Mode Reset

Cursor Key Mode Set

8-bit

7-bit

8-bit

7-bit

Up CSI A Esc [ A SS3 A Esc O A
Down CSI B Esc [ B SS3 B Esc O B
Right CSI C Esc [ C SS3 C Esc O C
Left CSI D Esc [ D SS3 D Esc O D

Table 12-16 N-108LK Escape Sequences-Break, Shift, and Control
Key
Code Sent
Break* 250 millisecond Break
Shift-Break* 3.5 second Break & drop DTR
Control-@ NULL
Control-Space NULL
Control-Shift-Space NULL
* Break and Shift-Break apply to the serial terminal emulator only.

Table 12-17 N-108LK Editing Keypad Escape Sequences
Key

VMS

ULTRIX

8-bit

7-bit

8-bit

7-bit

Find CSI 1 ~ Esc [ 1 ~ CSI 1 ~ Esc [ 1 ~
Insert CSI 2 ~ Esc [ 2 ~ CSI 2 ~ Esc [ 2 ~
Remove CSI 3 ~ Esc [ 3 ~ CSI 3 ~ Esc [ 3 ~
Select CSI 4 ~ Esc [ 4 ~ CSI 4 ~ Esc [ 4 ~
Prior CSI 5 ~ Esc [ 5 ~ CSI 5 ~ Esc [ 5 ~
Next CSI 6 ~ Esc [ 6 ~ CSI 6 ~ Esc [ 6 ~

N-97/N-Kana Keyboard Escape Sequences

The tables in this section list escape sequences for N-97 and N-Kana keyboards.

Table 12-18 N-97/N-Kana Keypad Escape Sequences
Key

Application Mode Reset

Application Mode Set

8-bit

7-bit

8-bit

7-bit

0 0 0 SS3 p Esc O p
1 1 1 SS3 q Esc O q
2 2 2 SS3 r Esc O r
3 3 3 SS3 s Esc O s
4 4 4 SS3 t Esc O t
5 5 5 SS3 u Esc O u
6 6 6 SS3 v Esc O v
7 7 7 SS3 w Esc O w
8 8 8 SS3 x Esc O x
9 9 9 SS3 y Esc O y
, , , SS3 l Esc O l
- _ _ SS3 m Esc O m
. . . SS3 n Esc O n
Enter Return Return SS3 M Esc O M
PF1 SS3 P Esc O P SS3 P Esc O P
PF2 SS3 Q Esc O Q SS3 Q Esc O Q
PF3 SS3 R Esc O R SS3 R Esc O R
PF4 SS3 S Esc O S SS3 S Esc O S

Table 12-19 N-97/N-Kana Function Key Escape Sequences
Key

Escape Sequence

8-bit

7-bit

F1 CSI 1 1 ~ Esc [ 1 1 ~
F2 CSI 1 2 ~ Esc [ 1 2 ~
F3 CSI 1 3 ~ Esc [ 1 3 ~
F4 CSI 1 4 ~ Esc [ 1 4 ~
F5 CSI 1 5 ~ Esc [ 1 5 ~
F6 CSI 1 7 ~ Esc [ 1 7 ~
F7 CSI 1 8 ~ Esc [ 1 8 ~
F8 CSI 1 9 ~ Esc [ 1 9 ~
F9 CSI 2 0 ~ Esc [ 2 0 ~
F10 CSI 2 1 ~ Esc [ 2 1 ~
F11 CSI 2 3 ~ Esc [ 2 3 ~
F12 CSI 2 4 ~ Esc [ 2 4 ~



[Top] [Prev] [Next] [Contents] [Index]

Send comments, suggestions, or questions about this document to the NCD Technical Publications Department by Internet e-mail. Write to us at techpubs@ncd.com.
Copyright © 1997, NCD Inc. All rights reserved.