The text of a manual · part 39 of 52
TE 2000 VT/ANSI Terminal Emulation Programmer's Guide: Chapter 6: Programming, pages 333 to 340
Pages 333 to 340 of 456, from TE 2000 VT/ANSI Terminal Emulation Programmer's Guide
The original document is the PDF (3.1 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.
For the Intermec 2425
Page 333
Chapter 6, Programming
Cursor Keys The following table lists codes generated by the terminals’ cursor keys.
Key
Cursor Key Mode Reset (Normal)
Cursor Key Mode Set (Application)
Down arrow CSI B
SS3 B
Left arrow
CSI D
SS3 D
Right arrow
CSI C
SS3 C
Up arrow
CSI A
SS3 A
Sending Host Cursor Keys In keyboard unshifted and shifted modes, the cursor control key sends a host cursor key to the host computer. The cursor control key emulates the arrow keys of a VT/ANSI Terminal in either their normal arrow key mode or Application mode, depending on the state set by the programmer. To Send
Press Terminal Keys
Host cursor down key
[B]
Host cursor left key
[A ]
Host cursor right key
["]
Host cursor up key
[Y]
Host cursor down key
[SFT]+[B]
Host cursor left key
[SFT]+[A]
Host cursor right key
[SFT]+["]
Host cursor up key
[SFT]+[Y]
Auxiliary Keypad Auxiliary keypad keys enter numeric data. The application software in use can also assign functions to these keys; refer to your VT/ANSI application software manual for their uses. The following table shows codes generated by the auxiliary keys in keypad Application mode. VT/ANSI Key
Keypad Mode
VT/ANSI Key
Keypad Mode
0
SS3 p
9
SS3 y
1
SS3 q
- (hyphen)
SS3 m
2
SS3 r
, (comma)
SS3 l
3
SS3 s
. (period)
SS3 n
4
SS3 t
Enter
SS3 M
5
SS3 u
PF1
SS3 P
6
SS3 v
PF2
SS3 Q
7
SS3 w
PF3
SS3 R
8
SS3 x
PF4
SS3 S
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
309
Page 334
Chapter 6, Programming
Top-Row Function Keys The following table lists function keys and the codes generated.
310
Key
VT220/320/340 Mode
VT100 Mode
F5 (Break)
No code
No code
F6
CSI 1 7 ~
No code
F7
CSI 1 8 ~
No code
F8
CSI 1 9 ~
No code
F9
CSI 2 0 ~
No code
F10
CSI 2 1 ~
No code
F11
CSI 2 3 ~
Esc
F12
CSI 2 4 ~
BS
F13
CSI 2 5 ~
LF
F14
CSI 2 6 ~
No code
F15
CSI 2 8 ~
No code
F16
CSI 2 9 ~
No code
F17
CSI 3 1 ~
No code
F18
CSI 3 2 ~
No code
F19
CSI 3 3 ~
No code
F20
CSI 3 4 ~
No code
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
Page 335
Chapter 6, Programming
Local Edit Mode If your application software program supports local editing, the terminal can be programmed to operate in Local Edit mode. Local Edit mode is a feature of the VT340 Terminal. Use the mode to send characters to page memory instead of to the host. The terminal sends a block of edited text to the host after you press a terminating key. Terminating keys in Local Edit mode are: S [Enter] S [F1] through [F20]
Edit Mode and Interactive Mode The edit mode control function (DECEDM) selects edit mode or interactive mode. The function determines when the terminal sends data to the host. The following Local Edit Modes table describes the modes. Mode
Sequence*
Action
Set
CSI ? 1 0 h
Selects edit mode. (Turns on the annunciator in the display.) The terminal stores all typed characters in page memory for local editing. After the data is edited, it can be sent in a block to the host.
Reset
CSI ? 1 0 l
Selects interactive mode. (Turns off the annunciator in the display.) The terminal immediately sends typed characters to the host.
*
The last character in the reset sequence is lowercase L (6C hexadecimal).
Local Editing Setup To use the terminal in Local Edit mode, the local editing features must be set up for the application software as described in the following table. Feature
Setting
Description
Edit mode
Edit
Edited text is stored in memory until you press a terminating key, which sends the text to the host.
Edit key execution mode
Not supported.
Transmit execution mode
Immediate
Local editing application keys
Suffix transmit When you press [F1] through [F20], the terminal sends that function to the host after sending a block of data.
Line transmit mode
Disabled
The terminal sends a full page of data to the host after you press a terminating key.
Transfer termination mode
Enabled
After you press a terminating key, the terminal sends the scrolling region, which is the area inside the scrolling margins.
VT131 transfer mode Space compression
The terminal sends data to the host immediately after you press a terminating key.
Not supported. Disabled
Terminal sends a space character for each unused character position
End of line characters
On the terminal, no characters indicate the EOL in a data block.
End of block characters
On the terminal, no characters indicate the end of a data block.
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
311
Page 336
Chapter 6, Programming
Selecting Characters to Send Three control functions allow you to define which characters the terminal can send to the host. The following table shows how the control functions select which characters the terminal sends. Selecting Character Fields for Transmission Fields Selected
GATM
SATM
MATM
All fields
Set
Set
Unavailable
Unprotected fields only
Reset
Set
Unavailable
Selected fields only
Set
Reset
Set
Selected field with cursor only
Set
Reset
Reset
Unprotected and selected fields
Reset
Reset
Set
Selected field with cursor only
Reset
Reset
Reset
Guarded Area Transfer Mode (GATM) The GATM control function selects whether the terminal sends all characters or only unprotected characters to the host. When GATM is unprotected (reset), the terminal sends a record separator (RS, 1E hexadecimal) to the host in place of a protected field. The followint table lists GATMs. Mode
Sequence*
Action
Set (All)
CSI 1 h
Selects all characters. During block transmission, the terminal can send all protected and unprotected characters to the host.
Reset (Unprotected)
CSI 1 l
Selects unprotected characters. During a block transmission, the terminal can send only unprotected characters to the host.
*
The last character of the reset sequence is lowercase L (6C hexadecimal).
Selected Area Transfer Mode (SATM) The SATM control function determines whether the terminal can send all characters or only selected characters to the host. Selected characters are characters defined as eligible to send to the host. The following table lists SATMs. Mode
Sequence*
Action
Set (All)
CSI 1 7 h
Selects all characters. The terminal can send selected and unselected characters on the current page to the host.
Reset (Unprotected)
CSI 1 7 l
Selects only selected characters. The terminal can only send selected characters on the current page to the host.
*
312
The last character of the reset sequence is lowercase L (6C hexadecimal).
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
Page 337
Chapter 6, Programming
Multiple Area Transfer Mode (MATM) The MATM control function determines what selected character areas the terminal can send to the host. MATM work only when SATM is reset. The following table describes MATMs. Mode
Sequence*
Action
Set (All)
CSI 1 5 h
The terminal can send all selected areas on the page to the host.
Reset (Unprotected)
CSI 1 5 l
Selects one area. The terminal can send only the selected area with the cursor. If the cursor is not in a selected field, cursor moves to the next selected field.
*
The last character of the reset sequence is lowercase L (6C hexadecimal).
Defining Selected Areas Start selected area (SSA) and end selected area (ESA) control functions select which characters on the current page the terminal can send to the host. SSA and ESA are 8-bit C-1 control characters that can also be coded as 7-bit escape sequences. The following conditions apply to SSA and ESA: S They work only when SATM is reset. S If the terminal receives ESA before SSA, it ignores ESA. S If SSA is not followed by ESA on the same page, the SSA has no effect on that page. Selected areas must always end with ESA. S Selected areas cannot be changed by the ED, EL, or ECH control functions. The following table describes SSA and ESA. Name (Mnemonic)
8-Bit
7-Bit Equivalent
Action
SSA
SSA (86 hex) ESC F (1B, 46 hex)
Marks the cursor position as the first of a string of character positions the terminal can send to the host.
ESA
ESA (87 hex) ESC G (1B, 47 hex)
Defines the cursor position as the last of a string of character fields the terminal can send to the host.
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
313
Page 338
Chapter 6, Programming
Local Edit Mode Keys Keys with special functions in Local Edit mode are described in this table. Keys
Function
Find
Advances cursor to the top margin, Column 1.
Tab
Advances cursor to the next tab stop. If in protected area, it advances to the next selectable field. If tab stop is selected, it advances to the next selectable field.
Insert here
Default mode is “insert.” The key toggles between insert and overstrike. If in insert mode, all following characters in the field are shifted right one position. If the field is full the last character is deleted.
Remove
If in protected area, terminal beeps and the cursor advances to the first position of the next selectable field. If no selectable field is found, it advances to the bottom margin (the default is Row 24, Column 80). If in unprotected field, the field is cleared and the cursor is positioned to the beginning of the selectable field.
Prev screen
Ignores this key.
Next screen
Ignores this key.
Select
Ignores this key.
Backspace
Moves cursor one position to the left until it reaches the left margin.
Delete
Deletes the previous selectable character.
A-Z, 0-9, Auxiliary keypad
If one of these keys is pressed while in a protected area, the terminal beeps, advances the cursor to the next selectable field, and enters the characters. If no other selectable field is found, the cursor advances to the bottom margin.
Back Tab
Cursor moves back to the first occurrence of the following: • Previous tab stop. • Beginning of the current unprotected field. • Beginning of the previous unprotected field. • Beginning of scrolling region. (Also called top margin.)
Cursor
[Y]
Cursor moves up one line until it reaches the top margin. The terminal beeps when the cursor reaches the top margin.
[B]
Cursor moves down one line until it reaches the bottom margin. The terminal beeps when the cursor reaches the bottom margin.
["]
Cursor moves right one character position until it reaches the right margin. The terminal beeps when the cursor reaches the right margin.
[A]
Cursor moves left one character position until it reaches the left margin. The terminal beeps when the cursor reaches the left margin.
Scanning in Local Edit Mode When scanning is enabled, data from the scanner is placed into the field where the cursor is located. If the cursor is not in an input field, the data from the scanner is placed into the next input field. If the data from the scanner fills the first input field, the remaining characters are placed into the next input field. When the bar code does not fill the input field, the cursor stays where it ended. If autotab scanning is enabled, the cursor is placed at the beginning of the next input field. If the next input field is not found, extra data will be lost.
314
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
Page 339
Chapter 6, Programming
Set Transmit Termination Character (DECTTC) The terminal supports the set transmit termination character (DECTTC) control function. Use the control function to select a character to indicate the end of a block transmission. You do not need to use an end-of-block character. The terminal sends the end-of-block character to the host at the end of each block transmission. The control sequence is: CSI Ps ⎢
Ps is the end-of-block character in the following chart. Ps
End-of-Block Character
Action
0 (default)
No character (DECTTC disabled)
1
FF (0C hexadecimal)
Form feed
2
ETX (03 hexadecimal)
End of text
3
EOT (04 hexadecimal)
End of transmission
4
CR (0D hexadecimal)
Carriage return
5
DC3 (13 hexadecimal)
XOFF
Use an extended form of DECTTC to select a string of characters to indicate the end of a block. The extended form uses decimal codes to represent characters. You can use the extended form to send a control function at the end of a block transmission, instead of a single character. You can send a control sequence of up to six characters (Pn1 through Pn6) at the end of a block. The control sequence is: CSI ? Pn1 ; 0 Pn6 ⎢
Pn1 through Pn6 are decimal codes for characters you can define as endof-block. For example, the decimal code for ESC is 27 (1B hexadecimal). A code outside the range of 0 to 254 is ignored. The “C0 and GL Codes” table on page 271 and “C1 and GR Codes” table on page 273 contain decimal codes for characters. For example, to send the default code of the [PF1] key on the terminal’s numeric keypad at the end of a block transmission, use the following procedure. 1 The [PF1] key sends this default code: ESC O P
2 Translate each character in the sequence to decimal code. ASCII characters: Decimal codes:
ESC O P 27 79 80
3 Insert the decimal codes into the extended DECTTC sequence: CSI ? 27 ; 79 ; 80 ⎢
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide
315
Page 340
Chapter 6, Programming
Telxon Private Use Telxon has defined its set of private use 2 escape sequences. For more information about these sequences, see the AIRVU ANSI, AE User’s Guide (Telxon Part Number: 24627-000) from Telxon Corporation. Each escape sequence is introduced by either: S PU2 in 8-bit mode (0x 92) or S ESC,R in 7-bit mode The two bytes that follow the introducer are interpreted as an ASCII decimal value that describes the specific type of escape operation. Intermec supports the following escape sequence for Telxon private use only: (PU2 0x92 is ESC 7 (1B 37 in 7 bit mode), ST bit mode))
0x9c is ESC \ (1B and 5C) in 7
Note: PU2 0 0 0 0 ST through PU2 0 0 0 5 ST are for 700 Series, CK30, and CK31 Terminals only. PU2 0 0 0 0 ST Sets screen size to 26x16 instead of 21x16 (Intermec’s closest match) PU2 0 0 0 1 ST Sets screen size to 16x16 PU2 0 0 0 2 ST Sets screen size to 26x8 instead of 21x8 (Intermec’s closest match) PU2 0 0 0 3 ST Sets screen size to 16x8 PU2 0 0 0 4 ST (16x4 screen size) Ignored, not supported by Intermec PU2 0 0 0 5 ST (21x4 screen size) Ignored, not supported by Intermec PU2 0 5 0 0 ST Disables scanner PU2 0 5 0 2 ST Enables scanner without Auto Enter PU2 0 5 0 3 ST Enables scanner with Auto Enter * ESC R 1 3 ST
Data entry allowed from scanner only
ESC R 1 4 ST
Data entry allowed from keyboard and scanner only*
* Default mode
316
TE 2000™ VT/ANSI Terminal Emulation Programmer’s Guide