
                        Table of Contents

Chapter - 1.  Introduction       ..........................    4
Chapter - 2.  Starting using UniTerm     ..................    5
   Requirements        ....................................    5
   Getting started       ..................................    5
   Exiting UniTerm       ..................................    7
   Vector graphics mode      ..............................    7
   Zoom mode       ........................................    7
   GIN mode       .........................................    8
   Tektronix 4014 alpha mode     ..........................    8
   Using the special keys     .............................    8
Chapter - 3.  More about UniTerm     ......................   10
   RS232 Port Parameters      .............................   10
   Terminal Parameters       ..............................   10
   Graphics Terminal Parameters      ......................   11
   Setup Files       ......................................   12
   File Capture/Playback       ............................   12
   Editing Function Keys      .............................   12
   The Statusline       ...................................   12
   The Single-Line Editor      ............................   13
Chapter - 4.  File Transfer      ..........................   14
   General        .........................................   14
   ASCII file transfer      ...............................   14
      Using ASCII file transfer     .......................   14
      Setting the ASCII file transfer parameters   ........   14
   XModem/YModem        ...................................   15
      Using XModem       ..................................   15
      Using YModem batch      .............................   15
      Setting the XModem parameters     ...................   16
   Kermit        ..........................................   16
      UniTerm Kermit capabilities      ....................   16
      Simple file transfer      ...........................   17
      Binary file transfer      ...........................   17
      Server commands       ...............................   17
      Setting the Kermit parameters     ...................   18
Chapter - 5.  Implementation Notes      ...................   20
   General        .........................................   20
   VT102/VT100 Mode       .................................   21
      Smooth Scrolling       ..............................   21
      132 Column Mode      ................................   21
      Double Height/Width Characters      .................   21
      Extended character set in 8 bit mode  ...............   21
   VT200 Mode       .......................................   21
      VT200 function keys      ............................   21
      C0/C1 Modes       ...................................   22
      International character set      ....................   22
      Downloadable character set      .....................   22
      Downloadable function keys      .....................   22
      Regis        ........................................   22
   Tektronix Mode       ...................................   22
      General        ......................................   22
      Alpha Mode       ....................................   23
      Vector Mode       ...................................   23
      Zoom Mode       .....................................   23
   Problems        ........................................   23
Appendices.................................................   24
   Appendix - A Control Codes and Escape Sequences.........   24
   ANSI/VT2XX/VT102/VT100 Mode       ......................   24
      Set Mode       ......................................   24
      Reset Mode       ....................................   25
      Select Character Sets      ..........................   25
      Shift into Character Sets     .......................   25
      Character Attributes       ..........................   25
      Scrolling Region       ..............................   26
      Cursor Movement Commands      .......................   26
      Tab Stops       .....................................   26
      Line Attributes       ...............................   26
      Erasing        ......................................   26
         In Line       ....................................   26
         In Screen       ..................................   23
      Requests/Reports        .............................   27
      Reset        ........................................   27
      Tests        ........................................   27
      Keyboard LED's       ................................   27
      VT52 Mode       .....................................   28
      Editing Functions       .............................   28
      Print Commands       ................................   28
      Other Control Characters      .......................   29
      Nonstandard functions       .........................   29
   VT2XX functions       ..................................   30
      Character sets       ................................   30
      Terminal modes       ................................   30
      Selective erasing and attributes     ................   30
      Reports        ......................................   31
      Miscellaneous      ..................................   31
      Downloadable function keys      .....................   31
      Downloadable character sets      ....................   31
      Control codes       .................................   32
   4014 Mode       ........................................   32
      Alpha Mode       ....................................   32
         Cursor movement       ............................   32
         Character set sizes      .........................   33
         Mode changing       ..............................   33
      Other functions and extended escape codes   .........   33
      Vector mode       ...................................   33
      Point plot/special point plot mode    ...............   34
      Incremental point plot mode     .....................   34
   4105 Commands       ....................................   34
   Appendix - B ASCII control characters  .................   38
      Seven bit control characters     ....................   38
      Eight bit control characters     ....................   39
   Appendix - C Error numbers   ...........................   40
   Appendix - D Simple macro processor  ...................   41
   Appendix - E The KeyEdit Program  ......................   42
      Editing a UniTerm setup file   ......................   42
   Appendix - F Key assignments and generated codes........   43




                           Chapter - 1

                          Introduction


  UniTerm is  a  program  that emulates most of the functions  of 
DEC's  (Digital  Equipment Corporation) VT102/VT220 text terminal 
and   the  vector  mode  of  Tektronix's 4014  graphics terminal. 
Additionally   UniTerm   provides  the  XModem  and  Kermit  file 
transfer  protocols.  The  program  and  its documentation can be 
copied,  distributed  and  used free of cost, but may not be sold 
for  commercial  purposes. Please contact me, if you find bugs or 
have  suggestions  for  revised  versions  of  UniTerm,  but read
appendix A and the implementation notes first.  

  Some compromises  have  been made in the implementation of  the 
VT100  132  column mode and double width characters will not work 
on  a  color  monitor.  Enhancements which are planned for future 
releases:
          -Tektronix 4105 commands (already started!)
          -sideways scrolling for 132 columns
          -cursor in 132 column mode
          -backwards scrolling
          -make UniTerm work with the blitter-chip
          -speedup the redrawing of vectors
          -enhanced color version (colors for highlighted etc.)


          GEM is a trademark of Digital Research Co.  
          DEC,VT are trademarks of Digital Equipment Co.  
          Tektronix is a trademark of Tektronix Co.  
          Atari is a trademark of Atari Co.  


          The  Kermit  file  transfer  protocol  was developed by
          Frank   da   Cruz   and   Bill  Catchings  at  Columbia
          University. Many thanks!   

          This  program  was  developed  with ST Pascal Plus from
          CCD.  














                           Chapter - 2

                     Starting using UniTerm


Requirements         

   To use UniTerm you need: 
     a ATARI ST computer 
     a monochrome or color monitor 
     a RS232 standard cable 
     a computer/modem to connect to 
     a floppy disk with UniTerm.PRG and UniTerm.RSC on it 


Getting started        

   After connecting  your  ST to your host computer, double click
the  UniTerm  Icon.  After  the  program has been loaded you will
(hopefully)  see  the  UniTerm opening dialog. Now you can select
the  size  of the vector/filecapture buffer, if you select 0 or a
size to big for your free RAM no buffer will be allocated.  

   If you  are  using UniTerm for the first time a alert box will
appear,  press  <Return>  (in  this manual <xx> means the the key
with  xx  on  it)  and  ignore the warning message(UniTerm didn't
find  the  file  UNITERM.SET, which we will create later on), the
screen  will  clear  to  white  (on  a monochrome monitor) with a
status  line  on  line  25.   Press  <Help>  and the UniTerm help
screen and a menu bar with following contents will appear: 

     -------------------------------------------------
     | Desk  File   Transfer   Settings   Other      |
     -------------------------------------------------

     Desk  is  the  well  known  menu  where  you  can start desk
     accessories.  

     File allows you to select from: 
          Load Setup load a previously saved setup from disk, 
          Save Setup save the current settings of UniTerm to disk, 
          Delete File delete a file, 
          Set Path change the TOS current drive and path, 
          Show  Space  show  total  available  and  free  space on the 
          current  drive,
          Quit  Menu  leave this screen and return to terminal mode.  

     Transfer  selects the file transfer protocol you want to use:
          ASCII,  XModem, YModem or Kermit. A change here is reflected 
          in  a  different  dialog  box  appearing when you select the 
          File Transfer item in the Settings menu.   




     Settings allows you to select from: 
          RS232 sets the parameters of the serial port, 
          Terminal sets the value of some terminal (VT100/102) 
          parameters, 
          Graphics sets the values for the graphics terminal 
          module of UniTerm, 
          File Transfer allows you to set the parameters for the 
          current file transfer mode, 

     Other has only one item right now: 
          Edit Function Keys allows you to assign a string and/or 
          macro commands to a function key.  

   Select  the RS232 item in the Settings menu and a  new  dialog 
will appear. Selecting the different values for the parameters is 
quite straightforward,  just click on the buttons with the  right 
values (we  hope you know them,  otherwise you will just have  to 
experiment)  and  when you are finished select OK.  To  save  the 
setup,  select Save setup from the File menu,  a normal GEM  file 
selector  dialog will appear,  if you want to use this  setup  as 
default,  save  it with the name 'UNITERM.SET' and  UniTerm  will 
load it automatically on startup. To leave the help screen select 
Quit Menu or press the left mouse button once.  

   If you  have adjusted the parameters correctly, you should now 
be  able  to  communicate with your host computer. Some operating 
systems   (VMS)  try  to  identify  the  terminal  automatically, 
depending  on  your  setup  UniTerm will identify itself as a DEC 
VT200,   VT102,  VT100  or  as  an  VT100  emulating  a  VT52.  A 
VT102/VT200  has more 'advanced' editing functions (which results 
in  less  overhead  in  transmitting  inserts etc.) so leave this 
option  on  VT102/VT200  if  possible.  If  you have to enter the 
terminal  type  manually  try VT102 first (changing from VT102 to 
VT100  or  to VT200 only changes the report from UniTerm, not the 
actual commands UniTerm understands). 

Exiting UniTerm 
       
  To stop UniTerm press <Undo>, if there is nothing in the buffer 
you  will be returned straightaway to the Desktop,  otherwise  an 
alertbox will appear asking for confirmation.
  
Vector graphics mode       

   After receiving  the  control  code  'GS'  (this can be turned 
off)  or  the 4105 command 'ESC'%!0 (ASCII control characters are 
enclosed  in  apostrophes  to  distinguish  them  from  printable 
characters,  a  space  is  written  'SP')  from the host, UniTerm 
switches  to a separate graphics screen, if the host doesn't send 
'ESC''FF'  (the  ASCII  characters  Escape  and  Formfeed) before 
starting  a  new  picture,  you  will  have  to  clear the screen 
manually   with   <Alt><F1>.  The  incoming  characters  will  be 
interpreted   as  Tektronix  encoded  vectors  or  commands  (see 
appendix  A) until UniTerm receives one of the  following  codes:      

     'CAN' will return you to VT102 mode,
     'ESC''FF'  will  clear the screen and enter Tektronix alpha
     mode.  
     'ESC'%!1 will return to VT102 mode.  

To  return manually from Tektronix to VT200/VT102/VT100/VT52 mode
press  <Alt><F6>  or  select  the  appropriate mode from the item
Terminal  in the menu Settings.  To view your picture again press
<Alt><F5>  (this  just  switches  the  physical  screen  (not the
mode!).   Be careful, selecting Tektronix 4010 mode manually will
also reset the vector buffer!  


Zoom mode        

   If you selected a vector buffer larger than zero  kilo  bytes, 
you  can  redraw a picture with  different  scaling  factors.  To 
select  this  mode  press <Alternate><F9>,  the  screen  will  be 
cleared,  the current contents of the buffer will be drawn on the 
screen and the normal arrow mouse cursor will appear.  

   To select  the region of the picture you want to magnify, move 
the  arrow to the upper left corner of the region, press the left 
mouse  button and drag the mouse to the lower right corner of the 
region  (a  'rubber box' should follow the arrow) and release the 
button.  The  resulting picture will be scaled so that the larger 
side  of box will fit on the screen (if the option True Aspect is 
selected).   You  can  repeat  this operation until a magnificat
ion factor of thirty is reached.   
  
   <Backspace>  will  restore  the  previous   scaling   factors,  
the  arrow    keys   will   move  the  screen  a  10th   of   the  
screen  width/height   in  their  direction  and   <Return>  will 
leave  zoom  mode   (all  other  keys only  redraw  the  screen). 
Remember that if your  picture  is  built  out a lot of  vectors, 
the redrawing may take some time!
 
GIN mode        

   The sequence  'ESC''SUB'  will enter GIN mode from any of  the 
Tektronix  modes,  it  will  not  work  from the VT102/VT100 mode 
since   'SUB'  cancels  any  ANSI  command.   A crosshair  cursor 
will appear  which  can  be  moved with the mouse.  Pressing  any 
key  on the  keyboard  will cause a GIN report to be sent to  the 
host and exits the GIN mode to Tektronix alpha mode.  

Tektronix 4014 alpha mode      

   This mode   is   only  included  for  compatibility  with  the
GIN-mode  and  is  not  very useful. It is the same as 4010 alpha
mode  with  one  margin.   This mode will probably be replaced in
future versions with a 4105 compatible alphamode.  

Using the special keys      

   Here is  a  list  of  the functions on the special keys (press
<Alternate> and the key listed here): 

     <F1> 
     Erases the graphics screen from any terminal mode.  

     <F2> 
     Toggles  the  foreground/background color (white on black or
     black on white).  

     <F3> 
     Toggles between blinking and static cursor.  

     <F4> 
     Prints the contents of the textbuffer.  

     <F5> 
     Switches  to  the  graphics  screen and sets the terminal to
     Tektronix 4010 mode.  

     <F6> 
     Switches the screen and the terminal to VT102/VT100 mode.  

     <F7> 
     Resets the terminal, reads the default values from disk.  

     <F8> 
     Toggle autoprint.  

     <F9> 
     Enter zoommode.  

     <F10> 
     Reset the Tektronix mode.  

     <B> 
     Send a short break (0.233 s) (doesn't drop DTR).  

     <L> 
     Send a long break (3.5 s) (drops DTR).  

     <A> 
     Send the answerback string 

     <W> 
     Switch to 132 column mode (really only 128*24).  

     <S> 
     Switch to 80 column mode.  

     <C> 
     Start/stop file capture.  

     <R> 
     Replay a captured file.  

     <T> 
     Start file transfer.  

     <Help> 
     Atari screen dump.  

     <P> 
     Screen dump to disk in DEGAS (tm) format.  

     <.> 
     Toggle 24/49 lines mode (only on monochrome monitor).  

     <Z> 
     Hold Screen (<Y> on the german keyboard).  

     <Insert> 
     Start the single-line editor.  

                           Chapter - 3

                       More about UniTerm

   Please  read  the chapter about the  different  file  transfer 
protocols, for more information on them.  

RS232 Port Parameters       

   To change  these  settings, press <Help> and select RS232 from
the Settings menu.  Following parameters can be changed: 

     Baud selects the rate for the serial port.  

     Flowcontrol  selects  the  flowcontrol mode, these functions
     are implemented by the BIOS.  

     Parity  selects the parity mode, these modes are implemented
     by the BIOS.  

     Data/Stop  allows  you to select the number of data and stop
     bits, implemented by the BIOS. 

     Mode allows you to put the terminal in one of following 
     modes: 
          Full: Data typed on the terminal is echoed by the host 
          computer.  
          Echo: UniTerm echos user input on the screen.  
          Local: User input is only sent to the screen.  


Terminal Parameters        

   To change  these  settings,  press  <Help> and select Terminal
from the Settings menu following parameters can be changed: 

     Answerback is the string which is sent as answerback 
     message.  

     Terminal  selects  the terminal mode and change the terminal
     identification.  4014 selects 4014 alpha mode! 

     Send/Receive masks out the 8th bit of sent or received bytes 
     for the terminal emulations, set to 8 bits if you want to 
     use the 8 bit VT2XX mode (this only effects ASCII file 
     transfer and not the other file transfer modes).  

     Attributes  allows  you  to  change  the  processing of text
     attributes: 
          Ignore: All attributes except inverse are ignored, the 
          terminal identifies itself as if it had the advanced 
          video option (AVO), this is the quickest output mode.  
          AVO: The terminal processes all DEC text attribute 
          codes, slowest mode.  
          NoAVO: The terminal only processes underline and 
          inverse attributes.  

     Scroll selects between slow and quick scroll.  

     Print terminator determines if a 'FF' is sent after each 
     print operation or not.  

     Printer determines if a printer is connected or not.  

     Newline Mode sets the VT100/102/200 newline mode.  

     Cursor selects blinking or non blinking cursor.  

     Tektronix  mode enables or disables automatic  switching  to 
     the Tektronix mode on receipt of a 'GS' character, useful on 
     noisy telephone lines.  

Graphics Terminal Parameters       

  Select Graphics from the Settings menu to change the parameters 
of the graphic terminal module: 

     GIN Termination Sequence sets the string sent after a GIN 
     report.  

     Status Termination Sequence sets the string sent after a 
     status report.  

     Aspect this option controls the scaling of pictures.  

     Ignore Deletes allows you to set processing of 'DEL' in the
     4010 module.  

Setup Files        

   All user  setable  parameters  are  stored  in the setup files
(including  the  function key strings etc.). Loading a setup file
from  a  different  version  of  UniTerm  may result in a version
conflict   error  message,  if  this  happens  UniTerm  uses  its
internal defaults.  

File Capture/Playback        

   The file capture routine uses a character  translation  table, 
which can be edited by selecting ASCII from the Transfer menu and 
then selecting File Transfer from the Settings menu.

   While  file  capture  is in  progress  all  screen  output  is 
translated too,  so you will get a direct impression of what  you 
are saving.

   The  Playback function allows you to simulate input  from  the 
serial  port,  pressing  <A> allows you to abort,  any other  key 
will cause UniTerm to wait for another keypress.  

Editing Function Keys       

  To edit the string assigned to a function key, press <Help> and 
select Edit Function Keys from the Other menu.  You can edit  the 
strings now, the cursor keys will move you to the string you want 
to edit,  <Esc> will clear the string, <Backspace> will delete to 
the left,  <Delete> the current character.  Control codes can  be 
entered  by  pressing  <Control> and  the  appropriate  key  (see 
appendix B).  

The Statusline        

  The 25th line on the screen is used as a statusline in text 
terminal mode, it should look like this: 

UniTerm  V1.7a    Full                    DBLCR 1234
  ^      ^        ^                       ^^^^^ ^^^^
  |      |        |                       ||||| ||||
  |      |        Communication           ||||| |||LED 4
  |      |        Mode (Full,Echo,Local)  ||||| ||LED 3
  |      Version                          ||||| |LED 2
  |      Identification                   ||||| LED 1
Program                                   ||||Replace or
Identification                            ||||Insert Mode
                                          |||File Capture on
                                          ||Keyboard Locked
                                          |Break
                                          DCD on



The Single-Line Editor       

   To make  working  on  systems  that  don't  have a single-line
editor  (short  sle)  easier,  a  simple  sle  is  implemented in
UniTerm.  The  last  20  lines  typed by the user are stored in a
circular  buffer.  Pressing  <Insert>  starts the sle, the status
line  will  clear and the current line will be displayed instead.
Following functions are provided: 
     Left  and  right  cursor keys: move the cursor one character
     left or right.  
     Up  and  down  cursor keys: display the next or last line in
     the buffer.  
     <Delete>: delete the character under the cursor.  
     <Backspace>:  delete  the  character  to  the  left  of  the
     cursor.  
     <Insert>: abort the sle.  
     <Return>: send the line and leave the sle.  
The  sle  is  always  in  insert mode. DON'T FORGET TO ERASE YOUR
PASSWORDS! 

                           Chapter - 4

                          File Transfer


General         

  To change the current file transfer mode use the Transfer menu. 
Changing the file transfer type here, changes the dialog box that 
is displayed when you select File Transfer from the Settings menu 
and  what  happens  when  you  type  <Alternate><T>  (start  file 
transfer).  

ASCII file transfer       

Using ASCII file transfer      

  There is nothing much to say about ASCII  file  transfer,  just 
press  <Alternate><T>  and  choose the file  you  want  to  send. 
Pressing  <Help> gets you to the Help screen,  so you can  change 
the  delay  between  characters to a different  value  during  an 
upload  (this  is  useful with VMS which normally has  a  lot  of 
trouble  with the first line sent).  The transfer can  be  inter
rupted at any time by pressing <A>. Normally some experimentation 
is  needed to find the shortest delay time for your  system.  You 
can use a character translation table to map incoming  characters 
to Atari characters.  

  To receive  files use the file capture function.  A translation 
table  is  used  in the same way as with sending files. When file 
capture  is  in effect  the characters are displayed as they will 
be saved. 
 
Setting the ASCII file transfer parameters    

   The following parameters can be set: 

     Start  of  file  transfer  a string that is sent before file
     transfer starts.  

     End  of  file  transfer  a  string  that  is  sent  when the
     transfer finishes.  

     Send  determines if the output translation table is used for
     sending files.  

     Receive  determines  if  the input translation table is used
     for capturing files.  

     Delay  after  every  character  sets  the time [ms]  UniTerm 
     waits  after  every character sent (this is implemented with 
     the 200Hz system clock=>resolution is 5 ms).  

     Method  if  Paced  by  Echo  is  selected, UniTerm waits for
     every  character  sent  to  be  echoed (except ASCII control
     codes), this doesn't time out!

     Send   EOL   as  selects    if   'CR''LF'   is    sent    as 
     'CR''LF','CR','LF'  or 'SP''CR'.   This  function will  send 
     single  'CR''s and 'LF''s  correctly!

     Translation  on  input and Translation on output enables you 
     to  edit  the  translation  tables,  enter the decimal ASCII 
     values  of  the  characters  or  nothing  if  you  want  the 
     character to be ignored.
  
XModem/YModem         


Using XModem        

   To receive   a   file   start   the  remote  XModem  and  type 
<Alternate><T>.   To   receive  a  file  select Receive from  the 
dialog  box  and enter the filename in the file selector form. If 
you  have  set  the  error  check mode to CRC UniTerm will try to 
initiate  a  file  transfer  with  CRC, if it gets no response in 
the  maximum  allowed  number of errors,  it will retry with  the 
normal  checksum.   To  send  a  file select Send and  enter  the 
name  of the file in the file selector.   

Using YModem batch       

   This implementation  of  YModem  is probably not quite conform
with  the   actual  YModem protocol as it was impossible to get a
proper  protocol  definition  for the current release of UniTerm. 
What  it does is:  send/receive a header packet with filename and 
size  before  starting  a XModem file transfer. The file date and 
time  is  set  to  0  and  the   attributes  to 000644 (octal) on 
sending  and  ignored  on receiving.  Filename collision handling 
and  wildcard expansion are done on receiving/sending a group  of 
files.  

Setting the XModem parameters      

   The following parameters can be set: 

     Timeout  after  sets  the  maximum  time  XModem waits for a
     character to be received from the serial port.  
     Maximum  number  of errors sets the maximum number of errors
     before the file transfer is aborted.  
     Accept  ASCII  NUL  allows you to use XModem for none binary
     file   transfers,  when  ASCII  'NUL'  is  used  as  padding
     character.  
     Packet  size  chooses  the packet size for XModem transfers,
     the 1kB size may be more efficient on noise free lines.  
     Error   check  type  sets  the  default  checksum  type,  if
     possible use the CRC check for the larger packet size.  


Kermit         


UniTerm Kermit capabilities       

   UniTerm Kermit capabilities at a glance: 
     Local operation:               Yes
     Remote operation:              No
     Transfers text files:          Yes
     Transfers binary files:        Yes
     Wildcard send:                 Yes
     ^X/^Y interuption:             Yes
     Filename collision avoidance:  Yes
     Can time out:                  Yes
     8th-bit prefixing:             Yes
     Repeat count prefixing:        No  
     Alternate block checks:        No
     Terminal emulation:            Yes (UniTerm)
     Communication settings:        Yes (UniTerm)
     Transmit BREAK:                Yes (UniTerm)
     IBM mainframe communications:  Yes (not tested)
     Transaction logging:           No
     Session logging:               No
     Act as server:                 No
     Talk to server:                Yes
     Advanced server functions:     No
     Advanced commands for servers: Yes
     Local file mangement:          Yes
     Handle file attributes:        No
     Command/init files:            No
     Command macros:                No
     Large packets:                 No  
     Windows:                       No

Please don't forget if you miss some feature,  that UniTerm is  a 
terminal emulator and not a 'real' Kermit.


Simple file transfer      

    Check that the host kermit and UniTerm have the  same  parity 
set.  To  receive a file type the correct command for the  remote 
Kermit and type <Alternate><T> on the ST keyboard, a large dialog 
box should appear.  Select Receive if you want to use a different 
name  than  the original filename use the file selector  form  to 
select a name (this will only effect the first file received in a 
mutiple file transfer). If you want to receive the files with the 
names supplied by the host,  just press <Return> (if you enter  a 
path in this situation,  the current TOS drive and path is set to 
the value you entered).  A new form will appear and will  display 
the current file being received, the total number of packets, the 
current  number  of errors and timeouts and  the  last  non-fatal 
error  that  occured.  The  transfer can  be  aborted  by  typing 
<Control><C>.

    To send a single file or a group of files,  setup the  remote 
host for receiving,  type <Alternate><T> and select Send. Enter 
the filename or wildcards (*,  ?) in the file selector dialog and 
press <Return>.  

Binary file transfer      

   Set both sides (host and local computer) to binary  mode   (on 
most mainframes with 'set file type binary' or 'set file binary', 
select the |Binary| button on UniTerm ),  if you have set  parity 
to  none  and have selected 8 data bits,  binary  files  will  be 
transferred without 8th bit prefixing in all other cases 8th  bit 
prefixing  will  be used.  One note,  since the  Kermit  'end  of 
record'  is the same as the TOS 'end of line' no  translation  of 
'CR''s or 'LF''s is done, this may lead to problems if you have a 
file on the ST which uses 'LF' as 'end of line' marker.  

Server commands       

 This is probably the simplest way to use Kermit,  connect to the 
remote host and start the remote Kermit in server mode.  A  large 
subset of the possible Kermit server commands is implemented (not 
implemented: Journal, Who, Variable):

     Put send a file to the host.
     Get receive a file from the host.
     Finish terminate the remote Kermit.
     Logout terminate the remote Kermit and logout.
     Dir  send  a  directory  to the local  Kermit  and  have  it 
     displayed on the screen (argument: file-spec).
     Remote send a command to the remote host (argument: command
     line).
     Type  send a file to the local Kermit and display it on  the 
     screen (argument: file).
     CWD  change  the  current working directory  of  the  remote 
     Kermit (arguments: directory, password).
     Usage show disk usage (argument: area).
     Program  start  a program on the host  computer  (arguments: 
     program-file, program-commands).
     Erase delete a file on the host computer (argument: file).
     Copy  copy a file on the host computer  (arguments:  source, 
     destination).
     Rename  rename  a  file on  the  host  computer  (arguments: 
     oldname, newname).
     Login  login on a remote Kermit in server  mode  (arguments: 
     user, password, account).
     Help get help from the remote host (argument: topic).
     Status get the current status of the server.

For more information consult the 'Kermit Protocol Manual'. 


Setting the Kermit parameters     

   The following parameters can be set:

     Timeout after
     sets the maximum time Kermit waits for a character to be received
     from the serial port.
     Maximum number of retrys
     the maximum number of retrys before the transmission is aborted.
     Number of padding characters
     the number of padding characters sent before each packet.
     Packet size
     the maimum packet size you want to use (maximum size without large
     packets is 94.
     Quote character
     the ASCII character used for control character quoting.
     8 bit quote character
     the ASCII character used for 8th bit quoting.
     Repeat prefix character
     the character used for repeat prefixing (not implemented!).
     Padding character
     the character used for padding.
     Start of packet
     the character that marks the start of a Kermit packet.
     IBM mode
     wait for a 'XOn' character before sending a packet (XOn/XOff 
     flow  control  naturally has to be turned off  for  this  to 
     work).
     Error check type
     right now only the standard Kermit single character checksum.

Normally  you shouldn't have to change any of  these  parameters, 
please consult the Kermit literature for more details.

                           Chapter - 5

                      Implementation Notes


General        

   Most of   UniTerm  is  written  in  CCD/OSS  Pascal  and  uses
standard GEM,GEMDos,Bios and XBios calls. The exceptions are: 

     Scrolling  up, this is done with a assembler routine instead
     of a raster operations.  

     Peeking  and poking in user and supervisor status is done in
     assembler.  

     Character  output  with  text  attributes  set, is done with
     TXTBLT (which doesn't help very much speedwise) 

In  future versions probably more will be done in assembler.  The
Bios  input  buffer  for  the  serial  port  is expanded to 10000
bytes.  If no attributes except reverse are set and the character
cell  height  is  16  or 8 pixels, screen output is done with the
Bios  call  BConout  (Bios  3), this is at least twice as fast as
using  GEMDos  and  three  and  half times faster than using GEM.
Typical  times  (may  change  from version to version, these were
taken with Beta version 0.7): 

     Polling of the serial port and keyboard (main loop):  0.65ms
                                            (Beta V1.2    0.48ms)
     (if there are characters in the input buffer, a maximum
     of 20 are processed before the keyboard is polled again)
     The following data was measured with simulated input
     to the VT102 command processing routine, the times
     are per operation:
        Carriage return                                     0.6ms
        Clear complete screen ('ESC'[2K):                 140  ms

        Clear complete line ('ESC'[2J):                    10.0ms
        Absolute cursor address combination
        ('ESC'[H'ESC'[10;10H):                              5.6ms
        Linefeed with scroll:                              30.0ms
        40'000 characters  8 per line                       4.4ms
                          80 per line                       1.0ms
                                             (Beta V1.2   0.88ms)
        4'000 characters bold (highlighted)
                          80 per line                       3.5ms

To  decode  one character without any output operation (moving of
cursor  etc.) takes less than 0.5 ms. Use of UniTerm at 9600 baud
is probably not unresonable, but it may need flowcontrol.  
  The carrier  detect  signal  and  the break bit on the Mfp  are 
polled  once  per main loop and if they are present a appropriate 
message is displayed.  

VT102/VT100 Mode        

Smooth Scrolling        

   Only works  upwards  (this  is  hopefully  the  only direction
anybody  really  needs  ),  this  will  be  fixed the day I get a
blitter.  


132 Column Mode       

   Only 128   columns   wide,  this  is  due  to  the  640  pixel
resolution  of the ST in horizontal direction. No cursor is shown
in this mode! 


Double Height/Width Characters       

   Restrictions: no double width in color.  


Extended character set in 8 bit mode   

   Using the  GR  character  set  will work, but is probably very
slow  due  to  the  fact that the font has to set/reset for every
character.  


VT200 Mode        



VT200 function keys       

   There is  no  default assignment of the VT200 function keys to
ST  keys,  except  for  the downloadable function key strings. If
you  need  the default VT200 keys (-> appendix F), build yourself
a setup file with the right settings.  

C0/C1 Modes        

   Not implemented,  that  means UniTerm always sends C0 codes (7
bit), received C1 codes will be interpreted correctlly.  

International character set       

   The international  character  set is the default GR set (->the
characters  that  are  between  ASCII 128 and 256). For technical
reasons  use  of the GR set is slow (the set is changed for every
character!).  

Downloadable character set       

   Not implemented  (very  resolution  dependent,  useless on the
ST).  


Downloadable function keys       

   The lock/unlock/erase  parameters  are ignored. The mapping of
the  keys  is  described in appendix F, maximum string length per
key  is 80 characters (DON'T FORGET THAT % IS A SPECIAL CHARACTER
FOR UNITERM!).  


Regis         

   Not implemented  (very  resolution  dependent,  useless on the
ST).  


Tektronix Mode        


General         

   The Tektronix  mode is still a bit in a mess. This will change
with  the  using  the  4105  command  set,  this implies that you
should  only  use  the  vector  mode of the 4010 emulation as all
other 4010 commands will probably be removed from the program.  

   Right now  scaling  is  done  with  respect  to  a  4010  with
1024*780   points,   this  probably  will  change  for  the  4105
(512*360)  emulation.  In  Tek  coordinates  the  screen measures
4096*3120 points (4105: 4096*3072 points).  

   For redrawing  and  zooming  purposes  the incoming characters
are  stored in a linear buffer. This is quite a memory saving way
to  store  them, but on the other hand this means they have to be
decoded every time the vectors are drawn.  


Alpha Mode        

   Restrictions: 1  margin, all (well nearly all) character sizes
are the same only the spacing is different.  


Vector Mode        


Zoom Mode        

   Restrictions: No zooming of graph text, slow.  


Problems         

   Sometimes the  serial port seems to blocked (this has happened
to  me  with other ST terminal emulators as well), the reason for
this  still  hasn't been discovered (probably due to a bug in the
ST Bios).  

    Don't use  the Set RS232 Port Parameters dialog in an  editor 
or  the  like, for some mysterious reason the serial port outputs 
a  delete  character  if  you  actually change something and exit 
with OK (probably due to a bug in the ST Bios).  

   Don't try   to   use   the   underscore   character   in   the
file-selector dialogs (this is a bug in GEM).  


                          Appendix - A
               Control Codes and Escape Sequences


   This appendix  list  control  codes  and escape sequences that 
complete  implementations  of VT102/VT2XX and Tektronix 4014/4105 
terminals  should  interpret  and  the  functions   they   should  
initiate. * marks  functions  that  are redundant or not possible 
on  an  Atari ST  computer,   *NI  marks  other  not  implemented 
functions (due to my  laziness?),   *RI  uncomplete  implementat
ion   of  a function,  please read the implementation  notes  for 
details.  

   Consult the  ASCII  table  for  numeric  values of the control
codes,   'Ps',   'Pn',   'Pc'  and  'Pl'  denote  decimal  values
('Esc'[10;10f postion cursor at text coordinates (10,10)).  

   The following  control  codes and commands, the syntax and the
command  interfaces  as a whole could possibly be patented or/and
copyrighted,  please  consider  this  list  as  'for  information
only'. Commercial use is strictly forbidden.  


ANSI/VT2XX/VT102/VT100 Mode       


Set Mode       


     'ESC'[2h                 Keyboard locked
     'ESC'[4h                 Insert mode
     'ESC'[12h                Local echo off
     'ESC'[20h                New line mode on
     'ESC'[?1h                Cursor key application mode
     'ESC'[?3h                *RI 132 column mode
     'ESC'[?4h                *RI Smooth scrolling
     'ESC'[?5h                Screen reverse
     'ESC'[?6h                Origin mode relative
     'ESC'[?7h                Auto wrap on
     'ESC'[?8h                * Auto repeat on
     'ESC'[?9h                * Interlace on
     'ESC'[?18h               Print form feed on
     'ESC'[?19h               Print extent full screen

Reset Mode       

     'ESC'[2l                 Keyboard unlocked
     'ESC'[4l                 Replace mode
     'ESC'[12l                Local echo on
     'ESC'[20l                New line mode off
     'ESC'[?1l                Cursor key cursor mode
     'ESC'[?2l                VT52 mode
     'ESC'[?3l                80 column mode
     'ESC'[?4l                Jump scrolling
     'ESC'[?5l                Screen normal
     'ESC'[?6l                Origin mode absolute
     'ESC'[?7l                Auto wrap off
     'ESC'[?8l                * Auto repeat off
     'ESC'[?9l                * Interlace off
     'ESC'[?18l               Print form feed on
     'ESC'[?19l               Print extent scrolling region


Select Character Sets      

       G0         G1

     'ESC'(A   'ESC')A          UK
     'ESC'(B   'ESC')B          USASCII
     'ESC'(0   'ESC')0          Special graphics (line drawing)
     'ESC'(1   'ESC')1          *NI Alt char ROM
     'ESC'(2   'ESC')2          *NI Alt char ROM


Shift into Character Sets     

     'SO'                     Locked shift G1
     'SI'                     Locked shift G0


Character Attributes       

     'ESC'[m                 No attributes
     'ESC'[0m                No attributes
     'ESC'[1m                Bold
     'ESC'[4m                Underline
     'ESC'[5m                Blink (Light)
     'ESC'[7m                Reverse

Scrolling Region       

     'ESC'['Pt';'Pb'r        Set scrolling region


Cursor Movement Commands      

     'ESC'['Pn'A             Cursor up
     'ESC'['Pn'B             Cursor down
     'ESC'['Pn'C             Cursor right
     'ESC'['Pn'D             Cursor left
     'ESC'['Pl';'Pc'H        Cursor position
     'ESC'['Pl';'Pc'f
     'ESC'D                  Index
     'ESC'M                  Reverse Index
     'ESC'E                  Next line
     'ESC'7                  Save cursor
     'ESC'8                  Restore cursor


Tab Stops       

     'ESC'H                  Horizontal tab set
     'ESC'[g                 Tab clear
     'ESC'[0g                Tab clear
     'ESC'[3g                Clear all tabs


Line Attributes       

     'ESC'#3                 Double-height top half
     'ESC'#4                 Double-height bottom half
     'ESC'#5                 Single-width single-height
     'ESC'#6                 *RI Double-width single-height


Erasing        


In Line       

     'ESC'[K                  Cursor to end of line
     'ESC'[0K
     'ESC'[1K                 Beginning of line to cursor
     'ESC'[2K                 Entire line

In Screen       

     'ESC'[J                  Cursor to end of screen
     'ESC'[0J
     'ESC'[1J                 Beginning of screen to cursor
     'ESC'[2J                 Entire screen


Requests/Reports        

     Requests from host         Reports to host

     'ESC'[5n   Status          'ESC'[0n         Terminal OK
                                'ESC'[3n         * Terminal not OK
     'ESC'[6n   Cursor position 'ESC'['Pl';'Pc'R Cursor position Pl,Pc
     'ESC'[c    What are you?   'ESC'[?1;'Ps'c   VT100, Ps options
     'ESC'[0c                   'ESC'[?6;'Ps'c   VT102, Ps options
     'ESC'Z                     'ESC'[?62;'Ps'c  VT200, Ps options
     'ESC'[?15n Printer status  'ESC'[?10n   Printer ready
                                'ESC'[?11n   Printer not ready
                                'ESC'[?13n   No printer
     'ESC'[0x   Terminal Parameter
                Request, send on
                exit of setup
     'ESC'[1x   send only on
                request


Reset        

     'ESC'c                   Reset to default values


Tests        

     'ESC'#8                  Fill screen with E's
     'ESC'[2;'Ps'y            * Invoke tests


Keyboard LED's       

     'ESC'[0q                 All off
     'ESC'['Ps'q              LED 'Ps' on

VT52 Mode       

     'ESC'<                   Enter ANSI Mode
     'ESC'=                   Enter alternate keypad mode
     'ESC'>                   Exit alternate keypad mode
     'ESC'F                   Select special graphics character set
     'ESC'G                   Select US/UK character set
     'ESC'A                   Cursor up
     'ESC'B                   Cursor down
     'ESC'C                   Cursor right
     'ESC'D                   Cursor left
     'ESC'H                   Cursor home
     'ESC'Y'Pl''Pc'           Direct cursor address
     'ESC'I                   Reverse line feed
     'ESC'K                   Erase to end of line
     'ESC'J                   Erase to end of screen
     'ESC'Z                   What are you?
     'ESC'/Z                  I am a VT52 (Response)
     'ESC'^                   Enter auto print mode
     'ESC'-                   Exit auto print mode
     'ESC'W                   Enter printer controller mode
     'ESC'X                   Exit printer controller mode
     'ESC']                   Print screen
     'ESC'V                   Print cursor line


Editing Functions       

     'ESC'['Pn'P              Delete character
     'ESC'['Pn'L              Insert Line
     'ESC'['Pn'M              Delete Line


Print Commands       

     'ESC'[?5i                Enter auto print
     'ESC'[?4i                Exit  auto print
     'ESC'[5i                 Enter printer controller
     'ESC'[4i                 Exit printer controller
     'ESC'[i                  Print screen
     'ESC'[0i
     'ESC'[?1i                Print cursor line

Other Control Characters      

     'NUL'                    Ignored
     'SOH'                    Ignored
     'ETX'                    Ignored
     'EOT'                    Ignored
     'ENQ'                    Transmit answerback message
     'BEL'                    Bell
     'BS'                     Backspace
     'HT'                     Horizontal tab
     'LF'                     Linefeed or 'CR''LF'
     'VT'                     'LF'
     'FF'                     'LF'
     'CR'                     Carriage Return
     'SO'                     Shift to G1 character set
     'SI'                     Shift to G0 character set
     'DC1'                    Ignored (Alternate XOn)
     'DC3'                    Ignored (Alternate XOff)
     'CAN'                    Cancel
     'SUB'                    Cancel
     'DEL'                    Ignored
     'US'                     Ignored
     'RS'                     Ignored
     'FS'                     Ignored
     'SYN'                    Ignored
     'EM'                     Ignored
     'ETB'                    Ignored
     'NAK'                    Ignored
     'DLE'                    Ignored
     'XON'                    In XOn/XOff flow control mode
     'XOFF'                   intercepted by ST bios, otherwise
                              ignored


Nonstandard functions       

     'ESC'[`                  Lock Keyboard
     'ESC'[b                  Unlock Keyboard
     'ESC'['Pn'I              Move Pn tabs right
     'GS'                     Enter 4014 Vector mode
     'ESC'%!0                 Enter Tektronix alpha mode (4105 command)
     'ESC'#!0                 Report terminal mode (4105 command)
     %!'SP''SP'1              Report: I am a ANSI terminal

VT2XX functions       



Character sets       

        G0       G1       G2       G3
     'ESC'(<  'ESC')<  'ESC'*<  'ESC'+< DEC International character set
     'ESC'(B  'ESC')B  'ESC'*B  'ESC'+B USASCII
     'ESC'(0  'ESC')0  'ESC'*0  'ESC'+0 Specal graphics

     'ESC'~                   Lock shift G1 -> GR
     'ESC'n                   Lock shift G2 -> GL
     'ESC'}                   Lock shift G2 -> GR
     'ESC'o                   Lock shift G3 -> GL
     'ESC'|                   Lock shift G3 -> GR
     'ESC'N                   Single shift G2 -> GL
     'ESC'O                   Single shift G3 -> GL


Terminal modes       

     'CSI'61"p                VT100 mode
     'CSI'62"p                VT200 mode, 8-bit
     'CSI'62;0"p                  "         "
     'CSI'62;1"p              VT200 mode, 7-bit
     'CSI'62;2"p              VT200 mode, 8-bit
     'ESC''SP'F               *NI Send only C0 codes
     'ESC''SP'G               *NI Send C1 codes


Selective erasing and attributes     

     'CSI'22m                 Bold off
     'CSI'24m                 Underline off
     'CSI'25m                 Blink off
     'CSI'27m                 Inverse off

     'CSI'0"q                 Erase protection off
     'CSI'1"q                 Non-erasable
     'CSI'2"q                 Erasable

     'CSI'?K                  Cursor to EOL
     'CSI'?0K
     'CSI'?1K                 SOL to Cursor
     'CSI'?2K                 Whole line

     'CSI'?J                  Cursor to EOP
     'CSI'?0J
     'CSI'?1J                 SOP to Cursor
     'CSI'?2J                 Whole screen


Reports        

     From host
     'CSI'>0c                 Secondary device attribute response
     From terminal
     'CSI'>1;17;0c            VT220, Software version 1.7

     From host
     'CSI'?25n                Are the function-keys locked?
     From terminal
     'CSI'?20n                Unlocked
     'CSI'?21n                *NI Locked


Misc        

     'ESC'['Pn'X              Erase Pn characters
     'ESC'['Pn'P              Delete Pn characters
     'ESC'['Pn'@              Insert Pn blanks
     'CSI'!p                  Soft reset
     'CSI'?38h                Tektronix mode
     'CSI'?38l                VT200 mode
     'CSI'?25h                *NI Cursor on
     'CSI'?25l                *NI Cursor off


Downloadable function keys      

     'DCS'Pc;Pl|Ky1/St1;..'ST' Pc  0 clear all keys (ignored)
                                   1 don't clear keys (ignored)
                               Pl  0 lock keys (ignored)
                                   1 don't lock keys (ignored)
                               Ky1 Key number (decimal)
                               St1 String (hex)


Downloadable character sets      

   Not implemented! Sorry.

Control codes       

     'IND'                    Index
     'NEL'                    Next line
     'SSA'                    Ignored
     'ESA'                    Ignored
     'HTS'                    Horizontal tab set
     'HTJ'                    Ignored
     'VTS'                    Ignored
     'PLD'                    Ignored
     'PLU'                    Ignored
     'RI'                     Reverse index
     'SS2'                    Single shift G2 -> GL
     'SS3'                    Single shift G3 -> GL
     'DCS'                    Device control string introducer
     'PU1'                    Ignored
     'PU2'                    Ignored
     'STS'                    Ignored
     'CCH'                    Ignored
     'MW'                     Ignored
     'SPA'                    Ignored
     'EPA'                    Ignored
     'CSI'                    Control sequence introducer
     'ST'                     String terminator
     'OSC'                    Ignored
     'PM'                     Ignored
     'APC'                    Ignored


4014 Mode       


Alpha Mode       


Cursor movement       

     'BS'                    Cursor left
     'HT'                    Cursor right
     'LF'                    Cursor down
     'VT'                    Cursor up
     'CR'                    Cursor to left margin

Character set sizes      

     'ESC'8                  Normal   35x76 (lines x columns)
     'ESC'9                  Small    38x81
     'ESC':                  Smaller  50x120
     'ESC';                  Smallest 58x133
     'ESC'6                  *NI Enter Italics ?
     'ESC'7                  *NI Exit Italics  ?

Mode changing       

     'GS'                    Vector mode
     'ESC''SUB'              GIN mode
     'FS'                    Point plot mode
     'ESC''FS'               *NI Special point plot mode
     'RS'                    *NI Increment mode
     'CAN'                   Return to text terminal (this hopefully has no
                             side effects)


Other functions and extended escape codes   

     'ESC''ETB'              Hardcopy
     'ESC''ENQ'              Transmit status
     'ESC''STX'              Enable block fill/erase
     'ESC''ETX'              Disable block fill/erase
     'ESC'\R                 Enable rectangle draw
     'ESC'\r                 Disable rectangle draw
     'ESC'x                  Enable selective erase
     'ESC'/0d                Dots on
     'ESC'/1d                Dots off
     'ESC'/2d                Dots complemented


Vector mode       

     'GS'                    Next vector is dark
     address                 Draw vector, next vector is visible
     'ESC'`                  Solid vector
     'ESC'a                  Dotted
     'ESC'b                  Dot-dashed
     'ESC'c                  Short-dashed
     'ESC'd                  Long-dashed
     'ESC'p                  Solid vector, XOR
     'ESC'q                  Dotted, XOR
     'ESC'r                  Dot-dashed, XOR
     'ESC's                  Short-dashed, XOR
     'ESC't                  Long-dashed, XOR
     'ESC''SUB'              GIN mode
     'US'                    Alpha mode, don't move
     'CR'                    Alpha mode
     'ESC''FF'               Alpha mode, clear screen

Point plot/special point plot mode    

     address                 Plot point
     intensity address       *NI Special plot point
     'CR'                    Alpha mode
     'ESC''FF'               Alpha mode


Incremental point plot mode     

     'SP'                    *NI Pen up
     P                       *NI Pen down
     D                       *NI North
     E                       *NI North east
     A                       *NI East
     I                       *NI South east
     H                       *NI South
     J                       *NI South west
     B                       *NI West
     F                       *NI North west
     'CAN'                   *NI Alpha mode
     'ESC''SUB'              *NI GIN mode


4105 Commands       

   In the  following list capital letters are part of the command
sequences  and  lower  case  identifiers denote Tektronix encoded
parameters.  

'ESC'IQ code                *NI Report terminal settings
'ESC'IJ normal
        shifted             *NI Change GIN cursor speed

'ESC'JC                     *NI Copy

'ESC'KC                     *NI Cancel
'ESC'KR mode                *NI Change carriage return/line feed mode
'ESC'KD number
        contents            *NI Define macro
'ESC'KO number
        contents            *NI Define nonvolatile macro
'ESC'KA mode                *NI Enable dialog area
'ESC'KW mode                *NI Enable key expansion
'ESC'KX number              *NI Expand macro
'ESC'KH mode                *NI Hardcopy
'ESC'KI mode                Ignore deletes mode
'ESC'KF mode                *NI Change line feed/carriage return mode
'ESC'KL mode                *NI Lock keyboard
'ESC'KQ                     *NI Report errors




'ESC'KV                     *NI Reset
'ESC'KU                     *NI Save nonvolatile parameters
'ESC'KE mode                *NI Change echo mode
'ESC'KZ char-delete
        line-delete
        literal             *NI Change edit characters
'ESC'KT threshold           *NI Change error threshold
'ESC'KY char                *NI Change key execute character
'ESC'KS mode                *NI Change transparent mode
'ESC'KB positions           *NI Change tab stops

'ESC'LL number              *NI Change number of lines in dialog area
'ESC'LP start-point
        fill-boundary       *NI Start panel boundary
'ESC'LZ                     *NI Clear dialog area
'ESC'LG position            *NI Draw to position
'ESC'LH position            *NI Draw marker at position
'ESC'LE                     *NI Finish panel
'ESC'LT text                *NI Graphic text
'ESC'LF position            *NI Move to position
'ESC'LB number              *NI Change number of lines for dialog buffer
'ESC'LI char-color
        char-backgr-color
        dialog-backgr-color *NI Change dialog area color
'ESC'LV mode                *NI Change dialog area visibility
'ESC'LM writing-mode        *NI Change dialog area writing mode

'ESC'MP number              *NI Choose fill pattern
'ESC'MG writing-mode        *NI Change graphics area writing mode
'ESC'MN direction           *NI Change graphtext direction
'ESC'MR mantissa
        power-of-two        *NI Change graphtext rotation
'ESC'MC width
        height
        spacing             *NI Change graphtext size
'ESC'ML color               *NI Change line color
'ESC'MV style               Change line style
'ESC'MM type                Change marker type
'ESC'MT text-color          *NI Change text color

'ESC'NM mode                *NI Prompt mode
'ESC'NR transmit
        receive             *NI Change baud rates
'ESC'NK time                *NI Change break time
'ESC'NU char                *NI Change echo suppression cancel character
'ESC'NE string              *NI Change EOF string
'ESC'NT string              *NI Change EOL string
'ESC'NC first-char
        second-char         *NI Change EOM characters
'ESC'NF mode                *NI Change flow control mode
'ESC'NP string              *NI Change prompt string
'ESC'NQ size                *NI Change input buffer size

'ESC'NB stopbits            *NI Change number of stop bits
'ESC'ND delay               *NI Change transmit delay

'ESC'QI values              *NI Map color to monochrome values for print
'ESC'QU density             *NI Choose color hardcopy
                            image density
'ESC'QD type                *NI Choose printer type
'ESC'QL pages
        page-origin
        ff-mode             *NI Change dialog hardcopy
                            attributes
'ESC'QE attributes          *Ni Change hardcopy monochrome
                            attributes
'ESC'QO orientation         *NI Change image orientation

'ESC'RU plane
        writing-mode
        bits-per-pixel      *NI Begin pixel operations
'ESC'RX dest.-plane
        d.-lower-left-corner
        first-source-corner
        second-s.-corner    *NI Copy pixels
'ESC'RP number
        color               *NI Write pixels
'ESC'RR lower-left-corner
        upper-right-corner
        fill-color          *NI Fill rectangle
'ESC'RL array               *NI ?
'ESC'RH position            *NI Move to pixel position
'ESC'RS lower-left-corner
        upper-right-
corner  *NI Change coordinates for pixel operations
'ESC'RW first-corner
        opposite-
corner     *NI Change window on 4096*4096 coordinates

'ESC'TD first-color
        second-color        *NI Change alpha cursor colors
'ESC'TF colors              *NI Change color indices for dialog area
'ESC'TG plane
        colors              *NI Change color indices for plane
'ESC'TC first-color
        second-color
        third-color         *NI Change GIN cursor color

'ESC'SX number
        position            *NI Change GIN cursor position

'ESC''SUB'                  Enter 4010 GIN mode
'ENQ'                       *NI Inquire 4105 status
'US'                        *NI Enter 4105 alpha mode
'ESC''CAN'                  Enter echo suppression mode
'FS'                        Enter marker mode
'GS'                        Enter vector mode

'ESC''FF'                   Clear screen, enter alpha mode
'ESC'#!0                    Report terminal mode
'ESC''ENQ'                  Report 4010 status
'ESC'%! mode                Change to a different terminal mode
'ESC' font                  Change fonts
'ESC' style                 Change 4014 line style
'ESC''ETB'                  4014 hardcopy

                          Appendix - B

                    ASCII control characters

Seven bit control characters     


|Dec|Oct|Hex|Keys        |Atari character|ASCII name                 |
|   |   |   |            |               |                           |
|  0|000| 00|<Control><@>|None           |NUL Null                   |
|  1|001| 01|<Control><A>|Up Arrow       |SOH Start of header        |
|  2|002| 02|<Control><B>|Down Arrow     |STX Start text             |
|  3|003| 03|<Control><C>|Right Arrow    |ETX End text               |
|  4|004| 04|<Control><D>|Left Arrow     |EOT End of transmission    |
|  5|005| 05|<Control><E>|Close Box      |ENQ Enquiry                |
|  6|006| 06|<Control><F>|Move Box       |ACK Acknowledge            |
|  7|007| 07|<Control><G>|Full Box       |BEL Bell                   |
|  8|010| 08|<Control><H>|Check          |BS  Backspace              |
|  9|011| 09|<Control><I>|Clock          |TAB Horizontal tab         |
| 10|012| 0A|<Control><J>|Bell           |LF  Linefeed               |
| 11|013| 0B|<Control><K>|Note           |VT  Vertical tab           |
| 12|014| 0C|<Control><L>|FF             |FF  Formfeed               |
| 13|015| 0D|<Control><M>|CR             |CR  Carrige return         |
| 14|016| 0E|<Control><N>|Left Atari sign|SO  Shift out              |
| 15|017| 0F|<Control><O>|Right Atari "  |SI  Shift in               |
| 16|020| 10|<Control><P>|Led 0          |DLE Data link escape       |
| 17|021| 11|<Control><Q>|Led 1          |DC1 X-on                   |
| 18|022| 12|<Control><R>|Led 2          |DC2                        |
| 19|023| 13|<Control><S>|Led 3          |DC3 X-off                  |
| 20|024| 14|<Control><T>|Led 4          |DC4                        |
| 21|025| 15|<Control><U>|Led 5          |NAK Negative acknowledge   |
| 22|026| 16|<Control><V>|Led 6          |SYN Synchronus idle        |
| 23|027| 17|<Control><W>|Led 7          |ETB End transmission blocks|
| 24|030| 18|<Control><X>|Led 8          |CAN Cancel                 |
| 25|031| 19|<Control><Y>|Led 9          |EM  End of medium          |
| 26|032| 1A|<Control><Z>|?              |SUB Substitute             |
| 27|033| 1B|<Control><[>|ES             |ESC Escape                 |
| 28|034| 1C|<Control><\>|?              |FS  File separator         |
| 29|035| 1D|<Control><]>|?              |GS  Group separator        |
| 30|036| 1E|<Control><^>|?              |RS  Record separator       |
| 31|037| 1F|<Control><_>|?              |US  Unit separator         |
| 32|040| 20|         < >|               |SP  Space                  |

Eight bit control characters     

|Dec|Oct|Hex|Keys <Meta>+| 7-bit aequiv. |ASCII name                 |
|   |   |   |            |               |                           |
|128|200| 80|<Control><@>| 'ESC'@        |Unused                     |
|129|201| 81|<Control><A>| 'ESC'A        |Unused                     |
|130|202| 82|<Control><B>| 'ESC'B        |Unused                     |
|131|203| 83|<Control><C>| 'ESC'C        |Unused                     |
|132|204| 84|<Control><D>| 'ESC'D        |IND Index                  |
|133|205| 85|<Control><E>| 'ESC'E        |NEL New line               |
|134|206| 86|<Control><F>| 'ESC'F        |SSA                        |
|135|207| 87|<Control><G>| 'ESC'G        |ESA                        |
|136|210| 88|<Control><H>| 'ESC'H        |HTS Horizontal tab set     |
|137|211| 89|<Control><I>| 'ESC'I        |HTJ                        |
|138|212| 8A|<Control><J>| 'ESC'J        |VTS                        |
|139|213| 8B|<Control><K>| 'ESC'K        |PLD                        |
|140|214| 8C|<Control><L>| 'ESC'L        |PLU                        |
|141|215| 8D|<Control><M>| 'ESC'M        |RI  Reverse index          |
|142|216| 8E|<Control><N>| 'ESC'N        |SS2 Single shift 2         |
|143|217| 8F|<Control><O>| 'ESC'O        |SS3 Single shift 3         |
|144|220| 90|<Control><P>| 'ESC'P        |DCS Device control string  |
|145|221| 91|<Control><Q>| 'ESC'Q        |PU1                        |
|146|222| 92|<Control><R>| 'ESC'R        |PU2                        |
|147|223| 93|<Control><S>| 'ESC'S        |STS                        |
|148|224| 94|<Control><T>| 'ESC'T        |CCH                        |
|149|225| 95|<Control><U>| 'ESC'U        |MW                         |
|150|226| 96|<Control><V>| 'ESC'V        |SPA                        |
|151|227| 97|<Control><W>| 'ESC'W        |EPA                        |
|152|230| 98|<Control><X>| 'ESC'X        |Unused                     |
|153|231| 99|<Control><Y>| 'ESC'Y        |Unused                     |
|154|232| 9A|<Control><Z>| 'ESC'Z        |Unused                     |
|155|233| 9B|<Control><[>| 'ESC'[        |CSI Command sequence intro |
|156|234| 9C|<Control><\>| 'ESC'\        |ST  String terminator      |
|157|235| 9D|<Control><]>| 'ESC']        |OSC                        |
|158|236| 9E|<Control><^>| 'ESC'^        |PM                         |
|159|237| 9F|<Control><_>| 'ESC'_        |APC                        |

Due  to  the way the german bios is written (and probably most of
the  none  US  versions)  not  all of these codes can be produced
with the keyboard.  

                          Appendix - C

                          Error numbers


     4  No special point plot
     10 Fatal Error, Please contact me 
     11 Fatal Error, Please contact me

                          Appendix - D

                     Simple macro processor


   These commands  can be in the strings assigned to the function
keys  or on a file, the default command initiator is '%', this is
reset  on  every  line!  The commands are in single quotes in the
following list.  
       '%C'chr     Change command initiator to chr
       '%E'string  Echo string (string = 'ABCD')
       '%D'        Drop DTR
       '%U'        Assert DTR
       '%W'int     Wait for int mSec (Integers have to be terminated
                   by a none numeric character, -->%N)
       '%N'        Do nothing, can be used as a terminator for int's
       '%G'string  Wait for string (this can be interupted by pressing
                   any key)
       '%S'int     Send ASCII character int
       '%B'int     Send Break for int mSec, without dropping DTR
       '%I'int     Send Break for int mSec, dropping DTR
       '%P'string  Change path for macros to string
       '%M'string  Execute the macro with name 'string' from disk, 
                   default path is the current directory -->%P
       '%L'string  Load the setup file with name 'string'.

       Example:

          call c100%S13%G'type:'v%W100t%W100%N1%W100%N0%W100%N0%S13

         Output    Send Wait for| Wait| Wait ||
        'call c100' CR  'type:' |100mS|100mS ||
                             Output Output   |Output
                               'v'    't'    |1
                                          Delimiter
Naturally  you can still enter control characters in function key
strings by pressing the right keys on the keyboard.  

                          Appendix - E

                       The KeyEdit Program



   If you  have  got  a  complete  release  of  UniTerm  (V1.4 or 
later),  you  should  have  a  copy  of KeyEdit.Prg (Please check 
that  it is for version 1.6f or higher!).  This  program  enables  
you   to  edit  the  keyboard  table stored in an  UniTerm  setup  
file,   additionally  you can create an executable keyboard table 
loader or just output the table itsself.  

Editing a UniTerm setup file     

   Start KeyEdit.Prg  and press <Return> when you see the opening 
dialog  box.   It  will take a few seconds to create the display. 
You  can  only  edit  a  existing  setup  file  with  predictable 
results,   so  select  Load UniTerm File and select the file  you 
want  to  edit.  Select  the  key  you want to change (select the 
approbiate  part  of  the table (normal, shifted or caps locked))
and  then  the character you want to assign to the key.  When you 
are finshed with editing, select Save UniTerm File.
  
  Don't try to  change the characters on the  keypad,  cursorkeys 
or  function-keys  in  the  UniTerm  setup file.  These keys  are 
hardwired  via  keycode  to  specific  strings  (like  on  a real 
VT100).  

                          Appendix - F

               Key assignments and generated codes


|   VT100 Key      |      Mode        |  UniTerm key   |  Sends   |
|                  |                  |                |          |
| Cursor Up        | ANSI normal      | Cursor Up      | 'ESC'[A  |
| Cursor Down      | ANSI normal      | Cursor Down    | 'ESC'[B  |
| Cursor Right     | ANSI normal      | Cursor Right   | 'ESC'[C  |
| Cursor Left      | ANSI normal      | Cursor Left    | 'ESC'[D  |
|                  |                  |                |          |
| Cursor Up        | ANSI application | Cursor Up      | 'ESC'OA  |
| Cursor Down      | ANSI application | Cursor Down    | 'ESC'OB  |
| Cursor Right     | ANSI application | Cursor Right   | 'ESC'OC  |
| Cursor Left      | ANSI application | Cursor Left    | 'ESC'OD  |
|                  |                  |                |          |
| Cursor Up        | VT52 normal      | Cursor Up      | 'ESC'A   |
| Cursor Down      | VT52 normal      | Cursor Down    | 'ESC'B   |
| Cursor Right     | VT52 normal      | Cursor Right   | 'ESC'C   |
| Cursor Left      | VT52 normal      | Cursor Left    | 'ESC'D   |
|                  |                  |                |          |
| Cursor Up        | VT52 application | Cursor Up      | 'ESC'A   |
| Cursor Down      | VT52 application | Cursor Down    | 'ESC'B   |
| Cursor Right     | VT52 application | Cursor Right   | 'ESC'C   |
| Cursor Left      | VT52 application | Cursor Left    | 'ESC'D   |
|                  |                  |                |          |
| PF1              | Numeric mode     | Keypad (       | 'ESC'OP  |
| PF2              | Numeric mode     | Keypad )       | 'ESC'OQ  |
| PF3              | Numeric mode     | Keypad /       | 'ESC'OR  |
| PF4              | Numeric mode     | Keypad *       | 'ESC'OS  |

|    VT100 Key     |      Mode        |   UniTerm key  |  Sends   |
|                  |                  |                |          |
| Keypad 7         | Numeric mode     | Keypad 7       | 7        |
| Keypad 8         | Numeric mode     | Keypad 8       | 8        |
| Keypad 9         | Numeric mode     | Keypad 9       | 9        |
| Keypad 4         | Numeric mode     | Keypad 4       | 4        |
| Keypad 5         | Numeric mode     | Keypad 5       | 5        |
| Keypad 6         | Numeric mode     | Keypad 6       | 6        |
| Keypad 1         | Numeric mode     | Keypad 1       | 1        |
| Keypad 2         | Numeric mode     | Keypad 2       | 2        |
| Keypad 3         | Numeric mode     | Keypad 3       | 3        |
| Keypad 0         | Numeric mode     | Keypad 0       | 0        |
| Keypad -         | Numeric mode     | Keypad -       | -        |
| Keypad ,         | Numeric mode     | Keypad +       | ,        |
| Keypad .         | Numeric mode     | Keypad .       | .        |
| Keypad Enter     | Numeric mode     | Keypad Enter   | 'CR' or  |
|                  |                  |                |          |
| PF1              | Application mode | Keypad (       | 'ESC'OP  |
| PF2              | Application mode | Keypad )       | 'ESC'OQ  |
| PF3              | Application mode | Keypad /       | 'ESC'OR  |
| PF4              | Application mode | Keypad *       | 'ESC'OS  |
| Keypad 7         | Application mode | Keypad 7       | 'ESC'Ow  |
| Keypad 8         | Application mode | Keypad 8       | 'ESC'Ox  |
| Keypad 9         | Application mode | Keypad 9       | 'ESC'Oy  |
| Keypad 4         | Application mode | Keypad 4       | 'ESC'Ot  |
| Keypad 5         | Application mode | Keypad 5       | 'ESC'Ou  |
| Keypad 6         | Application mode | Keypad 6       | 'ESC'Ov  |
| Keypad 1         | Application mode | Keypad 1       | 'ESC'Oq  |
| Keypad 2         | Application mode | Keypad 2       | 'ESC'Or  |
| Keypad 3         | Application mode | Keypad 3       | 'ESC'Os  |
| Keypad 0         | Application mode | Keypad 0       | 'ESC'Op  |
| Keypad -         | Application mode | Keypad -       | 'ESC'Om  |
| Keypad ,         | Application mode | Keypad +       | 'ESC'Ol  |
| Keypad .         | Application mode | Keypad .       | 'ESC'On  |
| Keypad Enter     | Application mode | Keypad Enter   | 'ESC'OM  |

|    VT100 Key     |      Mode        |   UniTerm key  |  Sends   |
|                  |                  |                |          |
| PF1              | VT52 Appl. mode  | Keypad (       | 'ESC'P   |
| PF2              | VT52 Appl. mode  | Keypad )       | 'ESC'Q   |
| PF3              | VT52 Appl. mode  | Keypad /       | 'ESC'R   |
| PF4              | VT52 Appl. mode  | Keypad *       | 'ESC'S   |
| Keypad 7         | VT52 Appl. mode  | Keypad 7       | 'ESC'?w  |
| Keypad 8         | VT52 Appl. mode  | Keypad 8       | 'ESC'?x  |
| Keypad 9         | VT52 Appl. mode  | Keypad 9       | 'ESC'?y  |
| Keypad 4         | VT52 Appl. mode  | Keypad 4       | 'ESC'?t  |
| Keypad 5         | VT52 Appl. mode  | Keypad 5       | 'ESC'?u  |
| Keypad 6         | VT52 Appl. mode  | Keypad 6       | 'ESC'?v  |
| Keypad 1         | VT52 Appl. mode  | Keypad 1       | 'ESC'?q  |
| Keypad 2         | VT52 Appl. mode  | Keypad 2       | 'ESC'?r  |
| Keypad 3         | VT52 Appl. mode  | Keypad 3       | 'ESC'?s  |
| Keypad 0         | VT52 Appl. mode  | Keypad 0       | 'ESC'?p  |
| Keypad -         | VT52 Appl. mode  | Keypad -       | 'ESC'?m  |
| Keypad ,         | VT52 Appl. mode  | Keypad +       | 'ESC'?l  |
| Keypad .         | VT52 Appl. mode  | Keypad .       | 'ESC'?n  |
| Keypad Enter     | VT52 Appl. mode  | Keypad Enter   | 'ESC'?M  |
|                  |                  |                |          |
| PF1              | VT52 Numeric mode| Keypad (       | 'ESC'P   |
| PF2              | VT52 Numeric mode| Keypad )       | 'ESC'Q   |
| PF3              | VT52 Numeric mode| Keypad /       | 'ESC'R   |
| PF4              | VT52 Numeric mode| Keypad *       | 'ESC'S   |

|     VT2XX Key      | Assigned to    |   Sends     |
|                    | for down-      | (default    |
|                    | lodable keys   | on a VT2XX) |
|                    |                |             |
| Find               |                | 'ESC'[1~    |
| Insert here        |                | 'ESC'[2~    |
| Remove             |                | 'ESC'[3~    |
| Select             |                | 'ESC'[4~    |
| Prev Screen        |                | 'ESC'[5~    |
| Next Screen        |                | 'ESC'[6~    |
|                    |                |             |
| F6           (F6)  | F1             | 'ESC'[17~   |
| F7           (F7)  | F2             | 'ESC'[18~   |
| F8           (F8)  | F3             | 'ESC'[19~   |
| F9           (F9)  | F4             | 'ESC'[20~   |
| F10          (F10) | F5             | 'ESC'[21~   |
| F11          (F11) | F6             | 'ESC'[23~   |
| F12          (F12) | F7             | 'ESC'[24~   |
| F13          (F13) | F8             | 'ESC'[25~   |
| F14          (F14) | F9             | 'ESC'[26~   |
| Help         (F15) | F10            | 'ESC'[28~   |
| Do           (F16) | Shift F1       | 'ESC'[29~   |
| F17          (F17) | Shift F2       | 'ESC'[31~   |
| F18          (F18) | Shift F3       | 'ESC'[32~   |
| F19          (F19) | Shift F4       | 'ESC'[33~   |
| F20          (F20) | Shift F5       | 'ESC'[34~   |
|                    |                |             |

           Enter marker mode
'GS'                        Enter vector mode

'ESC''FF'      