rfc732.txt

来自「RFC 的详细文档!」· 文本 代码 · 共 1,770 行 · 第 1/4 页

TXT
1,770
字号

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



Network Working Group                                           John Day
Request for Comments: 732                                               
NIC: 41762                                             12 September 1977

Obsoletes: 731


                   Telnet Data Entry Terminal Option

1.  Command Name and Code:

  DET             20

2.  Command Meanings

  IAC WILL DET

    The sender of this command REQUESTS or AGREES to send and receive
    subcommands to control the Data Entry Terminal.

  IAC WONT DET

    The sender of this command REFUSES to send and receive subcommands
    to control the Data Entry Terminal.

  IAC DO DET

    The sender of this command REQUESTS or AGREES to send and receive
    subcommands to control the Data Entry Terminal.

  IAC DONT DET

    The sender of this command REFUSES to send and receive subcommands
    to control the Data Entry Terminal.

  The DET option uses five classes of subcommands 1) to establish the
  requirements and capabilities of the application and the terminal, 2)
  to format the screen, and to control the 3) edit, 4) erasure, and 5)
  transmission functions. The subcommands that perform these functions
  are described below.

  The Network Virtual Data Entry Terminal (NVDET)

    The NVDET consists of a keyboard and a rectangular display. The
    keyboard is capable of generating all of the characters of the ASCII
    character set. In addition, the keyboard may possess a number of
    function keys which when pressed cause a FN subcommand to be sent.





John Day                                                        [page 1]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    (Although most DET's will support one or more peripheral devices
    such as a paper tape reader or a printer, this option does not
    consider their support. Support of peripheral devices should be
    treated by a is a separate option).

    The screen of the data entry terminal is a rectangle M characters by
    N lines. The values of M and N are set by negotiating the Output
    Line Width and Output Page Size options, respectively. The next
    writing position (x,y) on the screen (where x is the character
    position and y is the position of the line on the screen) is
    indicated by a special display character called the cursor. The
    cursor may be moved to any position on the screen without disturbing
    any characters already on the screen. Cursor addressing in existing
    terminals utilizes several topologies and addressing methods. In
    order to make the burden of implementaton as easy as possible this
    protocol supports two topologies (the finite plane and the helical
    torus) and three addressing methods ((x,y); x and y, and relative
    increments). Since the finite plane with absolute addressing is the
    least ambiguous and the easiest to translate to and from the others,
    it is the default scheme used by the NVDET. The torodial form with
    either relative or absolute addressing is provided for convience.

    Also the NVDET provides a mechanism for defining on the screen
    fields with special attributes. For example, characters entered into
    these fields may be displayed with brighter intensity, highlighted
    by reverse video or blinking, or protected from modification by the
    user. This latter feature is one of the most heavily used for
    applications where the DET displays a form to be filled out by the
    user.

    The definition of the NVDET uses Telnet option subnegotiations to
    accomplish all of its functions. Since none of the ASCII characters
    sent in the data stream have been used to define these functions,
    the DET option can be used in a "raw" or even "rare" mode. In
    circumstances where the application program knows what kind of
    terminal is on the other end, it can send the ASCII characters
    required to control functions not supported by the option or an
    implementation. In general keeping all NVDET functions out of the
    data stream provides better flexibility.

  Facility Functions  (for detailed semantics see Section 5.)

    IAC SB DET <DET facility subcommand><facility map> IAC SE

    where <DET facility subcommand> is one 8-bit byte indicating  the
    class of the facilities to be described, and <facility map> is a
    field of one or two  8-bit  bytes containing  flags  describing  the





John Day                                                        [page 2]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    facilities required or desired by the sender.  The bits of the
    facility maps are numbered from the right starting at zero.  Thus,
    if bit 2 is set the field will have a decimal  value  of  4.   The
    values of the field are as follows:

    facility cmd:  EDIT FACILITIES                    subcommand code: 1

      facility map:                              bit numbers

        Toroidal Cursor Addressing                  6
        Incremental Cursor Addressing               5
        Read Cursor Address                         4
        Line Insert/Delete                          3
        Char Insert/Delete                          2
        Back Tab                                    1
        Positive Addressing only                    0

    where:

    If the Toroidal Cursor Addressing bit is set, the sender requests or
    provides that the SKIP TO LINE and SKIP TO CHAR subcommands be
    supported.

    If the Incremental Cursor Addressing bit is set, the sender requests
    or provides that the UP, DOWN, LEFT, and RIGHT subcommands be
    supported.

    If the Read Cursor bit is set, the sender requests or provides the
    READ CURSOR subcommand.

    If the Line Insert/Delete bit is set, the sender requests or
    provides that the LINE INSERT and LINE DELETE subcommands be
    supported.

    If the Char Insert/Delete bit is set, the sender requests or
    provides that the CHAR INSERT and CHAR DELETE subcommands be
    supported.

    If the Back Tab bit is set, the sender requests or provides that the
    BACK TAB subcommand be supported.

    If the Positive Addressing bit is set, then the sender is informing
    the receiver that it can only move the cursor in the positive
    direction. (Note: Terminals that have this property also have a Home
    function to get back to the beginning.)







John Day                                                        [page 3]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    facility cmd:  ERASE FACILITIES                  subcommand code:  2

      facility map:                                bit numbers

        Erase Field                                     4
        Erase Line                                      3
        Erase Rest of Screen                            2
        Erase Rest of Line                              1
        Erase Rest of Field                             0

    where:

    If a bit of the facility map for this facility command is set, the
    sender requests or provides the facility indicated by the bit. For a
    more complete description of each of these functions see the Erase
    Functions section below.

    facility cmd:  TRANSMIT FACILITIES               subcommand code:  3

      facility map:                      bit numbers

        Data Transmit                         5
        Transmit Line                         4
        Transmit Field                        3
        Transmit Rest of Screen               2
        Transmit Rest of Line                 1
        Transmit Rest of Field                0

    where:

    If a bit of the facility map for this facility command is set, the
    sender requests or provides the facility indicated by the bit. For a
    more complete description of each of these functions see the
    Transmit Functions section below.

    facility cmd:  FORMAT FACILITIES                 subcommand code:  4

      facility map:                               bit numbers

        FN                                 byte 0      7
        Modified                                       6
        Light Pen                                      5
        Repeat                                         4
        Blinking                                       3
        Reverse Video                                  2
        Right Justification                            1
        Overstrike                                     0





John Day                                                        [page 4]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



        Protection On/Off                  byte 1      6
        Protection                                     5
        Alphabetic-only Protection                     4
        Numeric-only Protection                        3
        Intensity                                      0-2

    where:

    If the FN bit is set, the sender requests or provides the FN
    subcommand.

    If the Modified bit is set, the sender requests or provides the
    ability to indicate fields that are modified and supports the
    TRANSMIT MODIFIED subcommand.

    If the Light Pen bit is set, the sender requests or provides the
    support of a light pen, including the Pen Selectable attribute of
    the DATA FORMAT subcommand.

    If the Repeat bit is set the sender requests or provides the REPEAT
    subcommand.

    If the Blinking bit is set, the sender requests or provides the
    ability to highlight a string of characters by causing them to
    blink.

    If the Reverse Video bit is set, the sender requests or provides the
    ability to highlight a string of characters by "reversing the video
    image," i.e., if the characters are normally displayed as black
    characters on a white background, this is reversed to be white
    characters on a black background, or vice versa.

    If the Right Justification bit is set, the sender requests or
    provides the ability to cause entries of data to be right justified
    in the field.

    If the Overstrike bit is set, the sender requests or provides the
    ability to superimpose one character over another on the screen much
    like a hard copy terminal would do if the print mechanism struck the
    same position on the paper with different characters.

    If the Protection On/Off bit is set, the sender requests or provides
    the ability to turn on and off field protection.

    If the Protection bit is set, the sender requests or provides the
    ability to protect certain strings of






John Day                                                        [page 5]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    characters displayed on the screen from being altered by the user of
    the terminal. Setting this bit also implies that ERASE UNPROTECTED,
    DATA TRANSMIT, FIELD SEPARATOR, and TRANSMIT UNPROTECTED subcommands
    (see below) are supported.

    If the Alphabetic-only Protection bit is set, the sender requests or
    provides the ability to constrain the user of the terminal such that
    he may only enter alphabetic data into certain areas of the screen.

    If the Numeric-only Protection bit is set, the sender requests or
    provides the ability to constrain the user of the terminal such that
    he may only enter numerical data into certain areas of the screen.

    The three bits of the Intensity field will contain a positive binary
    integer indicating the number of levels of intensity that the sender
    requests or provides for displaying the data. The value of the 3 bit
    field should be interpreted in the following way:

      1        one visible intensity
      2        two intensities; normal and bright
      3        three intensities; off, normal, and bright
      >3        >3 intensities; off, and the remaining levels
      proportioned from dimmest to brightest intensity.

    For the all of the above commands, if the appropriate bit in
    <facility map> is not set, then the sender does not request or
    provide that facility.

  Editing Functions

    IAC SB DET MOVE CURSOR <x><y> IAC SE              subcommand code: 5

    where <x> is an 8-bit byte containing a positive binary integer
    representing the character position of the cursor, <y> is an 8-bit
    byte containing a positive binary integer representing the line
    position of the cursor.

    This subcommand moves the cursor to the absolute screen address
    (x,y) with the following boundary conditions:

      if x>M-1, set x=M-1 and send an ERROR subcommand

      if y>N-1, set y=N-1 and send an ERROR subcommand

    This describes a finite plane topology on the screen.







John Day                                                        [page 6]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    IAC SB DET SKIP TO LINE <y> IAC SE                subcommand code: 6

    where <y> is a positive 8-bit binary number.

    This subcommand moves the cursor to the absolute screen line y. x
    remains constant. For values of y>N-1

      y = y mod N.

    IAC SB DET SKIP TO CHAR <x> IAC SE                subcommand code: 7

    where <x> is a positive 8-bit binary number.

    This subcommand moves the cursor to the absolute character position
    x. y remains constant, unless x>M-1 in which case:

      x' = (x mod M)
      y' = (y+(x DIV N))
      where x' and y' are the new values of the cursor.

    These last two subcommands define a toroidal topology on the screen.

    IAC SB DET UP IAC SE                              subcommand code: 8

    IAC SB DET DOWN IAC SE                            subcommand code: 9

    IAC SB DET LEFT IAC SE                           subcommand code: 10

    IAC SB DET RIGHT IAC SE                          subcommand code: 11

    These subcommands are provided as a convenience for some terminals.
    The commands UP, DOWN, LEFT, and RIGHT are defined as

    UP:     (x,y)=(x, y-1 mod N)
    DOWN:   (x,y)=(x, y+1 mod N)
    LEFT:   (x,y)=(x-1, y); if x=0 then x-1 = 0

    RIGHT:  (x,y)=(x+1 mod M, y) and y = y+1 if x+1>M-1

    Note: DOWN, LEFT, and RIGHT cannot always be replaced by the ASCII
    codes for linefeed, backspace, and space respectively. The latter
    are format effectors while the former are cursor controls.

    IAC SB DET HOME IAC SE                           subcommand code: 12

    This subcommand positions the cursor to (0,0). This is equivalent to
    a MOVE CURSOR 0,0 or the sequence SKIP TO LINE 0, SKIP TO CHAR 0.





John Day                                                        [page 7]

NWG/RFC# 732                                  DAY 13-Sep-77 18:38  41762
Data Entry Terminal Option



    This subcommand is provided for convenience, since most terminals
    have it as a separate control.

    IAC SB DET LINE INSERT IAC SE                    subcommand code: 13

    This subcommand inserts a line of spaces between lines y (the
    current line, determined by the position of the cursor) and line
    y-1. Lines y through N-2 move down one line, i.e. line y becomes
    line y+1; y+1 becomes y+2, ...; N-2 becomes N-1. Line N-1 is lost
    off the bottom of the screen. The position of the cursor remains
    unchanged.

    IAC SB DET LINE DELETE IAC SE                    subcommand code: 14

    This subcommand deletes line y where y is the current line position
    of the cursor. Lines y+1 through N-1 move up one line, i.e. line y+1
    becomes line y; y+2 becomes y+1; ...; N-1 becomes N-2. The N-1st
    line position is set to all spaces. The cursor position remains
    unchanged.

    IAC SB DET CHAR INSERT IAC SE                    subcommand code: 15

    This subcommand inserts the next character in the data stream
    between the xth and x-1st characters, where x is the current

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?