Site and Software
Developed with Notepad++
Video Terminal Emulator
Implementing VTX

This will contain information needed to either embedding VTX to your web page to allow users to access your system, or needed to utilize VTX from a developers standpoint.

PETSCII Codes Supported

Legend : Not to be implemented - Implemented - In the works - Testing - Not gotten to yet
CodeDescriptionVTX Key
STOP (03) Stop keyEnd
WHITE (05) Foreground color whiteCtrl 2
DCSS (08) Disable font switch
ECSS (09) Enable font switch
CR (0D) ReturnEnter
FONT0 (0E) Switch to CBM Business font
DOWN (11) Cursor downDown Arrow
RV1 (12) Reverse text onCtrl 9
HOME (13) Cursor home (to upper left corner)Home
DEL (14) Delete keyDelete
RED (1C) Foreground color redCtrl 3
RIGHT (1D) Cursor rightRight Arrow
GREEN (1E) Foreground color greenCtrl 6
BLUE (1F) Foreground color blueCtrl 7
ORANGE (81) Foreground color orangeAlt 1
F1 (85) F1 keyF1
F3 (86) F3 keyF3
F5 (87) F5 keyF5
F7 (88) F7 keyF7
F2 (89) F2 keyF2
F4 (8A) F4 keyF4
F6 (8B) F6 keyF6
F8 (8C) F8 keyF8
ENTER (8D) Shift ReturnShift Enter
FONT1 (8E) Switch to CBM Graphics font
BLACK (90) Foreground color blackCtrl 1
UP (91) Cursor upUp Arrow
RV0 (92) Reverse text offCtrl 0
CLR (93) Clear screenShift Home
INSERT (94) Insert keyInsert
BROWN (95) Foreground color brownAlt 2
LRED (96) Foreground color light redAlt 3
GRAY1 (97) Foreground color gray 1Alt 4
GRAY2 (98) Foreground color gray 2Alt 5
LGREEN (99) Foreground color light greenAlt 6
LBLUE (9A) Foreground color light blueAlt 7
GRAY3 (9B) Foreground color gray 3Alt 8
PURPLE (9C) Foreground color purpleCtrl 5
LEFT (9D) Cursor leftLeft Arrow
YELLOW (9E) Foreground color yellowCtrl 8
CYAN (9F) Foreground color cyanCtrl 4
ANSI Code Sequences Supported

Note: This chart is not yet completey filled out. It is a reference as to what VTX is aiming to emulate.

ESC = 27 (1b)
CSI = 27 91 (1B 5B) or (9D in 8 bit mode)
CO = ASCII control characters 0 - 31 (00 - 1F)
G0 = ASCII printable characters 32 - 127 (20 - 7F)
C1 = ASCII control characters 128 - 159 (80 - 9F)
G1 = ASCII printable characters 160 - 255 (A0 - FF)
SP = Space, character 32 (20)

Legend : Not to be implemented - Implemented - In the works - Testing - Not gotten to yet
Table 1 - The List (a comparison reference)
C0 Control Codes - ASCII 0 - 31 (00 - 1F)
NUL(00) Null. Ignored____
SOH(01) Start of Header____
STX(02) Start of Text____
ETX(03) End of Text____
EOT(04) End of Transmission____
ENQ(05) Enquiry, causes terminal to send ANSWER-BACK ID____
ACK(06) Acknowledge, sent by terminal in response to ETX____
BEL(07) Bell, causes bell sound on terminal____
BS(08) Backspace____
HT(09) Horizontal Tabulation, move to next predetermined tab stop____
LF(0A) Linefeed, move to same col on next rowe____
VT(0B) Vertical Tabulation, move to next pedetermined row____
FF(0C) Formfeed, move to next form or page____
CR(0D) Carriage Return, move to first col of current row____
SO(0E) Shift Out, switch to G1 character set____
SI(0F) Shift In, switch to G0 character set____
DLE(10) Data Link Escape, interpret next control character specially____
DC1(11) Device Control 1 (XON), Terminal is allowed to resume transmitting____
DC2(12) Device Control 2____
DC3(13) Device Control 3 (XOFF), Terminal must pause and refrain from transmitting____
DC4(14) Device Control 4____
NAK(15) Negative Acknowledge, used sometimes with ETX and ACK____
SYN(16) Synchronous Idle, used to maintain timing in Sync communication.____
ETB(17) End of Transmission block____
CAN(18) Cancel, abort current escape sequence____
EM (19) End of Medium____
SUB(1A) Substitute____
ESC(1B) Escape, start an escape sequence (see below)____
FS (1C) File Separator____
GS (1D) Group Separator____
RS (1E) Record Separator____
US (1F) Unit Separator____
G0 Control Codes
DEL(7F) Delete, ignored by terminal____
C1 Control Codes, also induced with ESC @ (40) through _ (5F)
PAD or ESC @(80) Ignored____
HOP or ESC A(81) Ignored____
BPH or ESC B(82) Ignored____
NBH or ESC C(83) Ignored____
IND or ESC D(84) Index, moves down one row same col, regardless of NL____
NEL or ESC E(85) NEw Line, moves down one row to the first col (CR+LF)____
SSA or ESC F(86) Start of Selected Area____
ESA or ESC G(87) End of Selected Area____
HTS or ESC H(88) Horizontan Tabulation Set at current col____
HTJ or ESC I(89) Horizontal Tab Justify, moves string to next tab position____
VTS or ESC J(8A) Vertical Tabulation Set at current row____
PLD or ESC K(8B) Partial Line Down, subscript____
PLU or ESC L(8C) Partial Line Up, superscript____
RI or ESC M (8D) Reverse Index, go up one row with reverse scroll____
SS2 or ESC N(8E) Single Shift to G2____
SS3 or ESC O(8F) Single Shift to G3____
DCS or ESC P(90) Device Control String, terminated with ST____
PU1 or ESC Q(91) Private Use 1____
PU2 or ESC R(92) Private Use 2____
STS or ESC S(93) Set Transmit State____
CCH or ESC T(94) Cancel Character, ignore previous character____
MW or ESC U (95) Message Waiting, turns on indicator____
SPA or ESC V(96) Start of Protected Area____
EPA or ESC W(97) End of Protected Area____
SOS or ESC X(98) Ignored____
SGCI or ESC Y(99) Ignored____
SCI or ESC Z(9A) Ignored____
CSI or ESC [(9B) Control Sequence Introducer (see below)____
ST or ESC \(9C) String Terminator____
OSC or ESC ](9D) Operating System Command____
PM or ESC ^(9E) Privacy Message, terminated with ST____
APC or ESC _(9F) Application Program Command, terminated with ST____
ESC Sequences
ESC SP AOnly G0 will be used, Ignore SI, SO, and G1 (tty mode)____
ESC SP BG0 used, SI and SO effect G0____
ESC SP CG0 and G1 used in 8-bit mode. Ignore SI and SO____
ESC SP DG0 and G1 are used, SI and SO affect G0____
ESC ! SPSelect C0 control set____
ESC " SPSelect C1 control set____
ESC # 3Double wide / double high, top halfY___
ESC # 4Double wide / double high, bottom halfY___
ESC # 5Single height rowY___
ESC # 6Double wide rowY___
ESC # 8Alignment display, fill screen with E'sY___
ESC $ SPMultibyte CharactersN___
ESC % SPSpecial InterpretationN___
ESC ( ?SCS, Select Character Set as G0 (see table 2)____
ESC ) ?SCS, Select Character Set as G1 (see table 2)____
ESC * ?SCS, Select Character Set as G2 (see table 2)____
ESC + ?SCS, Select Character Set as G3 (see table 2)____
ESC , SPSCS, Select Character Set as G0 - this is slated to be removed____
ESC - SPSCS, Select Character Set as G1____
ESC . SPSCS, Select Character Set as G2____
ESC / SPSCS, Select Character Set as G3____
ESC 1DECHTS, horizontal tab set____
ESC 2DECCAHT, clear all horizontal tabs____
ESC 3DECVTS, vertical tab set____
ESC 4DECCAVT, clear all vertical tabs____
ESC 5DECXMT, request terminal to transmit as if ENTER were pressed____
ESC 7DECSC, Save cursor position and attributes____
ESC 8DECRC, Restore cursor position and attributes____
ESC <DECANSI, switch from VT52 to VT100 mode____
ESC =DECPAN, Keypad to app mode____
ESC >DECPNM, Keypad to numeric mode____
ESC @ to ESC _A C1 control code. See above____
ESC `DMI, Disable Manual Input____
ESC aINT, INTerrupt the terminal and do special action____
ESC bEMI, Enable Manual Input____
ESC cRIS, Reset to Initial State____
ESC nLS2, Shift G2 to GL____
ESC oLS3, Shift G3 to GL____
ESC |LS3R, Lock Shift G3 to GR____
ESC }LS2R, Lock Shift G2 to GR____
ESC ~LS1R, Lock Shift G1 to GR____
Control Sequences - these start with ESC [ (1B 5B) or CSI (9B) and take optional parameters separated by semicolons.
CSI n @ICH, Insert n Characters at current position. Defaults:n=1____
CSI n ACUU, Cursor Up, move up n rows, stop at top of screen. Defaults: n=1____
CSI n BCUD, Cursor Down, move down n rows, stop at bottom of screen. Defaults: n=1____
CSI n CCUF, Cursor Forward, move right n cols, stop at right side of screen. Defaults: n=1____
CSI n DCUB, Cursor Backward, move left n cols, stop at left side of screen. Defaults: n=1____
CSI n ECNL, Cursor Next Line, move cursor to start of n rows down. Defaults:n=1____
CSI n FCPL, Cursor Previous Line, move cursor to start of n rows up. Defaults:n=1____
CSI n GCHA, Cursor Horizontal position Absolute, move cursor to col n of current row. Defaults:n=1____
CSI r ; c HCUP, CUrsor Position, move cursor to r, c. Defaults:r=1,c=1____
CSI n ICHT, Cursor Horizontal Tabulation, move cursor forward n tab stops. Defaults:n=1____
CSI n JED, Erase in Display, cursor doesn't move. (0=position to end of screen,1=start of screen to position,2=entire screen) Preceed ? before n to leave attributes unchanged. Defaults:n=0____
CSI n KEL, Erase in Line, cursor doesn't move. (0=to EOR, 1=from SOR, 2=entire row) Preceed ? before n to leave attributes unchanged. Defaults: n=0____
CSI n LIL, Insert Lines, Scroll current row down n rows, replacing with blank rows. Scroll rows down.* Defaults: n=1____
CSI n MDL, Delete Lines, delete n rows at current row, scrolling blank rows in from bottom.* Defaults: n=1____
CSI n NEF, Erase in Field, like CSI n L, but between tab stops. Defaults: n=1____
CSI n OEA, Erase in Area, like CSI n J, but between protected areas. Defaults: n=1____
CSI n PDCH, Delete Character, delete n characters at position between tab stops. Defaults: n=0____
CSI n QSEM, Set Editing extent Mode (affects to ICH and DCH). (0=affects rest of screen,1=affects current row only,2=affect between tab stops,3=affects between protected fields) Defaults: n=0____
CSI r ; c RCPR, Cursor Position Report, send current row, col from terminal to server.____
CSI n SSU, Scroll Up, scroll display up n rows. Blank rows at bottom.* Defaults: n=1____
CSI n TSD, Scroll Down, scroll display down n rows. Blank rows at top.* Defaults: n=1____
CSI n UNP, Next Page. Defaults: n=1____
CSI n VPP, Previous Page. Defaults: n=1____
CSI n WCTC, Cursor Tabulation Control. (0=set horizontal tab for current row at current pos,1=set vertical tab stop for current row on current page,2=clear horiz tab stop at current pos of current page,3=clear vert tab stop at current row of current page,4=clear all horiz tab stops on current row only,5=clear all horiz tabs stops,6=clear all vert tab stops) Defaults: n=0____
CSI n XECH, Erase Character. Erase next n characters. Defaults: n=1____
CSI n YCVT, Cursor Vertical Tab. Move cursor to next n vert tab stop. Defaults: n=1____
CSI n ZCBT, Cursor Back Tab. Move cursor backwards n tab stops. Defaults: n=1____
CSI n `HPA, Horizontal Position Absolute. move to col n Defaults: n=1____
CSI n aHPR, Horizontal Position Relative, move n cols right on current row Default: n=1____
CSI n bREP, REPeat previous displayable character n times. Defaults: n=1____
CSI n cDA, Device Attributes. (0=request,>0=secondary request,?1;2=VT100 w/AVO response,?1:0=VT101 w/no options response,?6=VT102 response,?60;1;2;6;8;9;15=VT220 response____
CSI n dVPA, Vertical Position Absolute. Move to row n. Defaults: n=1____
CSI n eVRP, Vertical Position Relative. Move n rows down. Default n=1____
CSI r ; c fHVP, Horizontal and Vertical Position. Same as CUP. Defaults: r=1,c=1____
CSI n gTBC TaBulation Clear. (0=clear horiz tab stop at current pos,1=clear vert tab stop at current row,2=clear all horiz tab stops on current row,3=clear all horiz tab stops) Defaults: n=0____
CSI n hSM, Set Mode. (See Table 3 for values)____
CSI n iMC, Media Copy. ignored____
CSI n lRM, Reset Mode. (See Table 3 for values)____
CSI n ; ... mSGR, Set Graphics Rendition. (see Table 4) Defaults: n=0____
CSI n nDSR, Device Status Report. (0=ready/okay,1=busy/retry,2=busy/will respond,3=malfunction/retry,4=malfunction,will respond,5=request status,6=request cursor position,?15=request printer status,?25=request user keys locked)____
CSI n oDAQ, Define Qualified Area starting at current position. (0=accept all input, transmit on request,1=protected and guarded, accept no input, do not transmit,2=accept any printing character in this field,3=numeric only field,4=alphabetic only,5=right justified area,6=zero fill a numeric field,7=set horiz tab stop this is start of the fiend,8=protected and unguarded, eccept no input, do transmit,9=space fill in area) Defaults: n=0____
CSI n pDECSTR, Soft Terminal Reset. (!=soft reset)____
CSI n qDECLL, Load LEDs. (0=all off,1=L1,2=l2,etc) Defaults: n=1____
CSI t ; b rDECSTBM, Set Top and Bottom Margins. Set scroll region. Defaults: t=1;b=25____
CSI l ; r sDECSTRM, Set left and Right Margins. Set scroll region. Defaults: l=1;r=max___Y
CSI sSave cursor position._Y__
CSI n tDECSLPP, Set physical Lines Per Page____
CSI n ; .... uDECSHTS, Set horiz tab stops. Set multiple horiz tab stops___Y
CSI uRestore cursor position_Y__
CSI n ; ... vDECSVTS, Set vert tab stops. Set multiple vert tab stops____
CSI n wDECSHORP, Set Horiz Pitch on printer____
CSI n xDECREQTPARM, REQuest Terminal PARaMeters____
CSI n yDECTST, Test. (2;1=powerup test on VT100)____
CSI n zDECVERP, Set VERt Pitch on printer____
CSI n |DECTTC, Transmit Termination Charater (0=no extra characters, 1=terminate with FF)____
CSI n ; ... }DECPRO, Define PROtected Feild on VT132. (0=no protection, n=with attribute protected, 254=no attributes are protected)____
CSI n ~DECKEYS, Set by special function keys. (1=FIND, 2=INSERT, 3=REMOVE, 4=SELECT, 5=PREV, 6=NEXT, 17-34=F6-F20, 23=ESC, 24=BS, 25=LF, 28=HELP, 29=DO)____
CSI n SP @SL, Scroll Left. Move text left n cols *____
CSI n SP ASR, Scroll Right. Move text right n cols *____
CSI h ; w SP BGSM, Graphic Size Modification. Make graphics h% high, w% wide____
CSI n SP CGSS, Graphic Size Selection. Make characters n decipoints high____
CSI n ; m SP DFNT, FoNT selection. (As used by CSI 10-19 m) Set font n to be registered to font # m____
CSI n SP ETSS, Thin Space Specification. Define a thin space to n decipoints wide.____
CSI n SP FJFY, JustiFY. (0=no justification, 1=fill bringing words up from next line if needed, 2=interword spacing, 3=letter spacing, 4=use hyphenation, 5=flush left margin, 6=center following text between margins, 7=flush right margin, 8=italian form)____
CSI h ; v SP GSPI, SPacing Increment (in decipoints). Set horiz h and vert v.____
CSI n SP HQUAD, Do quadding on current row. n=(0=flush left, 1=fill with leader, 2=center, 4=flush right)____
* Scroll Region in effect.

Table 2 - Character sets
SettingNRC Character set (94 characters)
%5DEC Supplemental
%6NRCS Portuguese
0DEC Special Graphics
1DEC Alt ROM set
2DEC Alt Graphics ROM set
4NRCS Dutch
5NRCS Finnish
6NRCS Norwegian/Danish
7NRCS Swedish
9NRCS French Canadian
<DEC Supplimental Graphics Set
=NRCS Swiss
>DEC Technical
CNRCS Finnish
ENRCS Norwegian/Danish
HNRCS Swedish
KNRCS German
LNRCS Portuguese
QNRCS French Canadian
RNRCS French
YNRCS Italian
ZNRCS Spanish
`NRCS Norwegian/Danish
SettingCharacter set (96 characters)
ALatin-1 character set (ISO 8859-1)
BLatin-2 character set (ISO 8859-2)
CLatin-3 character set (ISO 8859-3)
DLatin-4 character set (ISO 8859-4)
ESupplementary Graphic Set
FLatin-7 Latin/Greek set (ISO 8859-7)
KTechnical character set
MLatin-5 character set (ISO 8859-9
~0Code Page 437 Upper Half **
~1Code Page 850 Upper Half **
~@VTX Blocks set **
~ACBM Business set lower **
~BCBM Business set upper **
~CCBM Graphics set lower **
~DCBM Graphics set upper **
~EAtari lower **
~FAtari upper **
~GTRS-80 lower **
~HTRS-80 Model I upper **
~ITRS-80 Model III upper **
** VTX Extension

Table 3 - Mode settings (VTX/VT100/220)
0Error, ignoredError, ignoredError, ignored
1GATM, Guarded Area Transmit ModeSend allSend only unprotected characters
2KAM, Keyboard Action ModeDisable keyboard inputEnable keyboard input
3CRM, Control Representation ModeShow all control charactersHide control characters
4IRM, Insertion/Replacement ModeSet insert modeReplacement mode
5SRTM, Status Report Transfer ModeReport after DCSReport on CSR
6ERM, ERasure ModeErase protected and unprotected areasErase only unprotected fields
7VEM, Vertical Editing ModeIL/DL affect previous rowsIL/DL affect rows after current
10HEM, Horiz Editing modeICH/DCH/IRM go backwardsICH/IRM move characters forward, DCH pulls
11PUM, Positioning Unit Mode.Use decipointsUse character position
12SRM, Send Recieve ModeLocal echo offLocal echo on
13FEAM, Format Effector Action ModeFE's are storedHPA/VPA/SGR/etc are acted upon when recieved
14FETM, Format Effector Transfer ModeSend only if storedFormat Effectors are sent to printer
15MATM, Multiple Area Transfer ModeSend all areaSend only current page if SATM is reset
16TTM, Transmit Termination ModeSend scrolling regionTransmit partial page, up to cursor pos
17SATM, Send Area Transmit ModeSend entire bufferTransmit areas bounded by SSA/ESA/DAQ
18TSM, Tabulation Stop ModeRows are independentSetting tab stops affect all lines
19EBM, Editing Boundry ModeAll of memory is affectedInsert does not overflow to next page
20LNM, Linefeed Newline ModeLF interpreted as CR LFLinefeed doesn't change horiz pos
?1DECCKM, Cursor Keys ModeSend ESC O A for cursor upCursor keys send ANSI cursor position commands
?2DECANM, ANSI ModeUse ESC < to switch VT52 to ANSIUse VT52 emulation instead of ANSI
?3DECCOLM, Column Mode132 cols per row80 cols per row
?4DECSCLM, Scroll ModeSmooth scrolling (approx 6 rows/sec)Jump Scrolling
?5DECSCNM, SCreen ModeReverse video (black on white)Normal screen
?6DECOM, Origin ModeRow 1 is relative to scroll regionRows are independent of scrolling region
?7DECAWM, Autowrap ModeStart new row after col 80Cursor remains at end of row after col 80
?8DECARM, Auto Repeat ModeKeys will autorepeatAutorepeat off
?9DECINLM, INterLace ModeInterlaced for taking photosDisplay does not interlace
?10DECEDM, EDit ModeVT132 is in EDIT modeVT132 transmits all keypresses
?11DECLTM, Line Transmit ModeIgnore TTM, send lineSend page or partial page depending on TTM
?13DECSCFDM, Space Compression/Field Delimiting ModeTrim trailing spaces on transmitDon't suppress trainling spaces on transmit
?14DECTEM, Transmit Execution ModeTransmit on ENTERENTER sends ESC S (STS) a request to send
?16DECEKEM, Edit Key Execution ModeEDIT key is localEDIT Key transmits either $[10h or $[10l
?18DECPFF, Print FormFeed ModeSend FF after printscreenDon't send formfeed after printing screen
?19DECPEXT, Print Extent ModePrint entire screenPrint only scroll region
?25DECTCEM, Text Cursor Enable ModeCursor enabledCursor disabled
?40smm/rmm, Meta ModeSet meta modeReset meta mode
?42DECNRCM - NRC ModeEnable NRC fontsDisable NRC fonts
?43DECGEPM Graphics Expanded Print ModeSetReset
?44DECGPCM Graphics Print Color ModeSetReset
?45DECGPCS Graphics Print Color SyntaxSetReset
?46DECGPBM Graphics Print Background ModeSetReset
?47DECGRPM Graphics Rotated Print ModeSetReset

Table 4 - SGR attribute settings
0Clear all attributes
1Bold on
2Dim on (monochrome display only)
3Italics on
4Underline on
5Slow blink on
6Fast blink on
7Reverse video (foreground and background color only swapped, remaining attributes apply to text)
8Concealed on (text not displayed)
9Strikethrough on
10Select primary font
11-19Select alternate font
21Bold off
22Dim off (monochrome display only)
23Italics off
24Underline off
25Slow blink off
26Fast blink off
27Normal video
28Concealed off
29Strikethrough off
30Black foreground
31Red foreground
32Green foreground
33Yellow foreground
34Blue foreground
35Magenta foreground
36Cyan foreground
37White foreground
38;2;r;g;bSet r g b foreground color (values are 0-255)
38;5;nSet foreground color to entry in special palette**
39Default foreground color
40Black background
41Red background
42Green background
43Yellow background
44Blue background
45Magenta background
46Cyan background
47White background
48;2;r;g;bSet r g b background color (values are 0-255)
48;5;nSet background color to entry in special palette**
49Default background color
90Bold Black foreground
91Bold Red foreground
92Bold Green foreground
93Bold Yellow foreground
94Bold Blue foreground
95Bold Magenta foreground
96Bold Cyan foreground
97Bold White foreground
100Bold Black background
101Bold Red background
102Bold Green background
103Bold Yellow background
104Bold Blue background
105Bold Magenta background
106Bold Cyan background
107Bold White background
* Palette used: 00-07=standard colors (as in ESC [ 30 - 37 m), 08-0F=high intensity colors (as in ESC [ 90 - 97 m), 10-E7=6 x 6 x 6 = 216 colors: 16 + 36 x r + 6 x g + b (0 = r, g, b = 5), E8-FF=grayscale from black to white in 24 steps
Character Sets