Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ layers(C) — OpenDesktop 3.0.0

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

layers(M)

libwindows(S)

mkdev(ADM)

relogin(ADM)

sh(C)

write(C)

wtinit(ADM)

xts(ADM)

xtt(ADM)

xt(HW)


 layers(C)                       19 June 1992                       layers(C)


 Name

    layers - layer multiplexer for windowing terminals

 Syntax

    layers [ -s ] [ -t ] [ -d ] [ -p ] [ -f file ] [ layersys-prgm ]

 Description

    The layers command manages asynchronous windows (see layers(M)) on a win-
    dowing terminal.  On invocation, layers finds an unused xt(HW) channel
    group and associates it with the terminal line on its standard output.
    It then waits for commands from the terminal.

    To use layers, you must have configured the xt driver.  This is done
    using the mkdev layers script.  For more information, see mkdev(ADM).

    Command-line options:

    -s             Reports protocol statistics on standard error at the end
                   of the session after you exit from layers. The statistics
                   may be printed during a session by invoking the program
                   xts(ADM).

    -t             Turns on xt(HW) driver packet tracing, and produces a
                   trace dump on standard error at the end of the session
                   after you exit from layers.  The trace dump may be printed
                   during a session by invoking the program xtt(ADM).

    -d             If a firmware patch has been downloaded, prints out the
                   sizes of the text, data, and bss portions of the firmware
                   patch on standard error.

    -p             If a firmware patch has been downloaded, prints the down-
                   loading protocol statistics and a trace on standard error.

    -f file        Starts layers with an initial configuration specified by
                   file.  Each line of the file represents a layer to be cre-
                   ated, and has the following format:

                      originx originy cornerx cornery commandlist

                   The coordinates specify the size and position of the layer
                   on the screen in the terminal's coordinate system. If all
                   four are 0, the user must define the layer interactively.
                   commandlist, a list of one or more commands, must be pro-
                   vided.  It is executed in the new layer using the user's
                   shell (by executing:  $SHELL -i -c "commandlist").  This
                   means that the last command should invoke a shell, such as
                   /bin/sh.  (If the last command is not a shell, then, when
                   the last command has completed, the layer will not be
                   functional.)

    layersys-prgm  A file containing a firmware patch that the layers command
                   downloads to the terminal before layers are created and
                   commandlist is executed.

    Each layer is in most ways functionally identical to a separate terminal.
    Characters typed on the keyboard are sent to the standard input of the
    UNIX system process attached to the current layer (called the host pro-
    cess), and characters written on the standard output by the host process
    appear in that layer.  When a layer is created, a separate shell is esta-
    blished and bound to the layer.  If the environment variable SHELL is
    set, the user will get that shell, otherwise, /bin/sh will be used.  In
    order to enable communications with other users via write(C), layers
    invokes the command relogin(ADM) when the first layer is created.  relog-
    in(ADM) will reassign that layer as the user's logged-in terminal.  An
    alternative layer can be designated by using relogin(ADM) directly.
    layers will restore the original assignment on termination.

    Layers are created, deleted, reshaped, and otherwise manipulated in a
    terminal-dependent manner.  For instance, the AT&T TELETYPE 5620 DMD ter-
    minal provides a mouse-activated pop-up menu of layer operations.  The
    method of ending a layers session is also defined by the terminal.

 Example


       layers -f startup

    where startup contains:

       8 8 700 200 date ; pwd ; exec $SHELL
       8 300 780 850 exec $SHELL


 Notes

    The xt(HW) driver supports an alternate data transmission scheme known as
    ENCODING MODE.  This mode makes layers operation possible even over data
    links which intercept control characters or do not transmit 8-bit charac-
    ters.  ENCODING MODE is selected either by setting a configuration option
    on your windowing terminal or by setting the environment variable DMDLOAD
    to the value hex before running layers:

       export DMDLOAD; DMDLOAD=hex

    If, after executing layers -f file, the terminal does not respond in one
    or more of the layers, often the last command in the command-list for
    that layer did not invoke a shell.

    When invoking layers with the -s, -t, -d, or -p options, it is best to
    redirect standard error to another file to save the statistics and trac-
    ing output (for example, layers -s 2>stats); otherwise all or some of the
    output may be lost.

 Files

    /dev/xt??[0-7]
    /usr/lib/layersys/lsys.8;7;3
    /usr/lib/layersys/lsys.8;?;?

 See also

    layers(M), libwindows(S), mkdev(ADM), relogin(ADM), sh(C), write(C),
    wtinit(ADM), xts(ADM), xtt(ADM), xt(HW)


Typewritten Software • bear@typewritten.org • Edmonds, WA 98026