vt100.rst
author Oleksandr Gavenko <gavenkoa@gmail.com>
Wed, 27 Jun 2012 22:52:40 +0300
changeset 1310 fe0efcd33788
parent 1032 4decc3e00bb6
child 1334 9bf0d5a1f0cf
permissions -rw-r--r--
Debian wiki.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1032
4decc3e00bb6 Fix coding and contents.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 953
diff changeset
     1
.. -*- coding: utf-8 -*-
953
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     2
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     3
==========================================================
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
 This document describes how to control a VT100 terminal.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     5
==========================================================
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     6
.. contents::
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     7
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     8
ANSI escape sequence is a sequence of ASCII characters, the first two of which
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     9
are the ASCII "Escape" character 27 (1Bh) and the left-bracket character " [ "
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    10
(5Bh). The character or characters following the escape and left-bracket
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    11
characters specify an alphanumeric code that controls a keyboard or display
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    12
function.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    13
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    14
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    15
|Esc[2;1yEsc[20h |Confidence power up testSet new line   |DECTSTLMN    |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    16
|                |mode                                   |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    17
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    18
|Esc[2;2yEsc[?1h |Confidence loopback testSet cursor key |DECTSTDECCKM |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    19
|                |to application                         |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    20
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    21
|Esc[2;9ynone    |Repeat power up testSet ANSI (versus   |DECTSTDECANM |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    22
|                |VT52)                                  |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    23
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    24
|Esc[2;10yEsc[?3h|Repeat loopback testSet number of      |DECTSTDECCOLM|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    25
|                |columns to 132                         |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    26
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    27
|Esc[0qEsc[?4h   |Turn off all four ledsSet smooth       |DECLL0DECSCLM|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    28
|                |scrolling                              |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    29
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    30
|Esc[1qEsc[?5h   |Turn on LED #1Set reverse video on     |DECLL1DECSCNM|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    31
|                |screen                                 |             |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    32
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    33
|Esc[2qEsc[?6h   |Turn on LED #2Set origin to relative   |DECLL2DECOM  |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    34
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    35
|Esc[3qEsc[?7h   |Turn on LED #3Set auto-wrap mode       |DECLL3DECAWM |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    36
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    37
|Esc[4qEsc[?8h   |Turn on LED #4Set auto-repeat mode     |DECLL4DECARM |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    38
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    39
|Esc[?9h         |Set interlacing mode                   |DECINLM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    40
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    41
|Esc[20l         |Set line feed mode                     |LMN          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    42
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    43
|Esc[?1l         |Set cursor key to cursor               |DECCKM       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    44
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    45
|Esc[?2l         |Set VT52 (versus ANSI)                 |DECANM       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    46
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    47
|Esc[?3l         |Set number of columns to 80            |DECCOLM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    48
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    49
|Esc[?4l         |Set jump scrolling                     |DECSCLM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    50
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    51
|Esc[?5l         |Set normal video on screen             |DECSCNM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    52
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    53
|Esc[?6l         |Set origin to absolute                 |DECOM        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    54
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    55
|Esc[?7l         |Reset auto-wrap mode                   |DECAWM       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    56
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    57
|Esc[?8l         |Reset auto-repeat mode                 |DECARM       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    58
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    59
|Esc[?9l         |Reset interlacing mode                 |DECINLM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    60
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    61
|Esc=            |Set alternate keypad mode              |DECKPAM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    62
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    63
|Esc>            |Set numeric keypad mode                |DECKPNM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    64
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    65
|Esc(A           |Set United Kingdom G0 character set    |setukg0      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    66
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    67
|Esc)A           |Set United Kingdom G1 character set    |setukg1      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    68
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    69
|Esc(B           |Set United States G0 character set     |setusg0      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    70
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    71
|Esc)B           |Set United States G1 character set     |setusg1      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    72
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    73
|Esc(0           |Set G0 special chars. & line set       |setspecg0    |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    74
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    75
|Esc)0           |Set G1 special chars. & line set       |setspecg1    |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    76
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    77
|Esc(1           |Set G0 alternate character ROM         |setaltg0     |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    78
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    79
|Esc)1           |Set G1 alternate character ROM         |setaltg1     |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    80
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    81
|Esc(2           |Set G0 alt char ROM and spec. graphics |setaltspecg0 |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    82
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    83
|Esc)2           |Set G1 alt char ROM and spec. graphics |setaltspecg1 |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    84
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    85
|EscN            |Set single shift 2                     |SS2          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    86
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    87
|EscO            |Set single shift 3                     |SS3          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    88
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    89
|Esc[m           |Turn off character attributes          |SGR0         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    90
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    91
|Esc[0m          |Turn off character attributes          |SGR0         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    92
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    93
|Esc[1m          |Turn bold mode on                      |SGR1         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    94
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    95
|Esc[2m          |Turn low intensity mode on             |SGR2         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    96
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    97
|Esc[4m          |Turn underline mode on                 |SGR4         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    98
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    99
|Esc[5m          |Turn blinking mode on                  |SGR5         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   100
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   101
|Esc[7m          |Turn reverse video on                  |SGR7         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   102
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   103
|Esc[8m          |Turn invisible text mode on            |SGR8         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   104
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   105
|Esc[Line;Liner  |Set top and bottom lines of a window   |DECSTBM      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   106
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   107
|Esc[ValueA      |Move cursor up n lines                 |CUU          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   108
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   109
|Esc[ValueB      |Move cursor down n lines               |CUD          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   110
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   111
|Esc[ValueC      |Move cursor right n lines              |CUF          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   112
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   113
|Esc[ValueD      |Move cursor left n lines               |CUB          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   114
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   115
|Esc[H           |Move cursor to upper left corner       |cursorhome   |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   116
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   117
|Esc[;H          |Move cursor to upper left corner       |cursorhome   |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   118
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   119
|Esc[Line;ColumnH|Move cursor to screen location v,h     |CUP          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   120
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   121
|Esc[f           |Move cursor to upper left corner       |hvhome       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   122
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   123
|Esc[;f          |Move cursor to upper left corner       |hvhome       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   124
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   125
|Esc[Line;Columnf|Move cursor to screen location v,h     |CUP          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   126
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   127
|EscD            |Move/scroll window up one line         |IND          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   128
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   129
|EscM            |Move/scroll window down one line       |RI           |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   130
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   131
|EscE            |Move to next line                      |NEL          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   132
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   133
|Esc7            |Save cursor position and attributes    |DECSC        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   134
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   135
|Esc8            |Restore cursor position and attributes |DECSC        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   136
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   137
|EscH            |Set a tab at the current column        |HTS          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   138
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   139
|Esc[g           |Clear a tab at the current column      |TBC          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   140
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   141
|Esc[0g          |Clear a tab at the current column      |TBC          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   142
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   143
|Esc[3g          |Clear all tabs                         |TBC          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   144
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   145
|Esc#3           |Double-height letters, top half        |DECDHL       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   146
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   147
|Esc#4           |Double-height letters, bottom half     |DECDHL       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   148
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   149
|Esc#5           |Single width, single height letters    |DECSWL       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   150
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   151
|Esc#6           |Double width, single height letters    |DECDWL       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   152
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   153
|Esc[K           |Clear line from cursor right           |EL0          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   154
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   155
|Esc[0K          |Clear line from cursor right           |EL0          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   156
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   157
|Esc[1K          |Clear line from cursor left            |EL1          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   158
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   159
|Esc[2K          |Clear entire line                      |EL2          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   160
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   161
|Esc[J           |Clear screen from cursor down          |ED0          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   162
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   163
|Esc[0J          |Clear screen from cursor down          |ED0          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   164
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   165
|Esc[1J          |Clear screen from cursor up            |ED1          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   166
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   167
|Esc[2J          |Clear entire screen                    |ED2          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   168
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   169
|Esc5n           |Device status report                   |DSR          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   170
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   171
|Esc0n           |Response: terminal is OK               |DSR          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   172
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   173
|EscLine;ColumnR |Response: cursor is at v,h             |CPR          |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   174
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   175
|Esc[c           |Identify what terminal type            |DA           |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   176
+----------------+---------------------------------------+-------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   177
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   178
Codes for use in VT52 compatibility mode
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   179
========================================
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   180
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   181
|Esc<         |Enter/exit ANSI mode (VT52) setansi        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   182
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   183
|Esc=         |Enter alternate keypad mode altkeypad      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   184
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   185
|Esc>         |Exit alternate keypad mode numkeypad       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   186
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   187
|EscF         |Use special graphics character set setgr   |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   188
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   189
|EscG         |Use normal US/UK character set resetgr     |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   190
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   191
|EscA         |Move cursor up one line cursorup           |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   192
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   193
|EscB         |Move cursor down one line cursordn         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   194
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   195
|EscC         |Move cursor right one char cursorrt        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   196
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   197
|EscD         |Move cursor left one char cursorlf         |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   198
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   199
|EscH         |Move cursor to upper left corner cursorhome|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   200
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   201
|EscLineColumn|Move cursor to v,h location cursorpos(v,h) |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   202
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   203
|EscI         |Generate a reverse line-feed revindex      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   204
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   205
|EscK         |Erase to end of current line cleareol      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   206
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   207
|EscJ         |Erase to end of screen cleareos            |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   208
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   209
|EscZ         |Identify what the terminal is ident        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   210
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   211
|Esc/Z        |Correct response to ident identresp        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   212
+-------------+-------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   213
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   214
VT100 Special Key Codes
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   215
=======================
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   216
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   217
These are sent from the terminal back to the computer when the particular key is pressed. Note that the numeric keypad keys send different codes in numeric mode than in alternate mode. See escape codes above to change keypad mode.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   218
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   219
Function Keys:
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   220
==============
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   221
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   222
+-----+---+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   223
|EscOP|PF1|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   224
+-----+---+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   225
|EscOQ|PF2|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   226
+-----+---+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   227
|EscOR|PF3|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   228
+-----+---+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   229
|EscOS|PF4|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   230
+-----+---+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   231
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   232
Arrow Keys:
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   233
===========
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   234
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   235
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   236
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   237
|     |Reset|Set  |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   238
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   239
|up   |EscA |EscOA|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   240
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   241
|down |EscB |EscOB|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   242
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   243
|right|EscC |EscOC|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   244
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   245
|left |EscD |EscOD|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   246
+-----+-----+-----+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   247
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   248
Numeric Keypad Keys:
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   249
====================
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   250
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   251
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   252
|EscOp|0        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   253
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   254
|EscOq|1        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   255
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   256
|EscOr|2        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   257
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   258
|EscOs|3        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   259
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   260
|EscOt|4        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   261
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   262
|EscOu|5        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   263
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   264
|EscOv|6        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   265
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   266
|EscOw|7        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   267
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   268
|EscOx|8        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   269
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   270
|EscOy|9        |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   271
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   272
|EscOm|-(minus) |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   273
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   274
|EscOl|,(comma) |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   275
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   276
|EscOn|.(period)|
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   277
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   278
|EscOM|^M       |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   279
+-----+---------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   280
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   281
Printing:
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   282
=========
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   283
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   284
+------+------------+--------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   285
|Esc[i |Print Screen|Print the current screen                    |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   286
+------+------------+--------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   287
|Esc[1i|Print Line  |Print the current line                      |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   288
+------+------------+--------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   289
|Esc[4i|Stop Print  |Disable log                                 |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   290
+------+------------+--------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   291
|Esc[5i|Start Print |Start log; all received text is echoed to a |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   292
|      |            |                  printer                   |
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   293
+------+------------+--------------------------------------------+
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   294