Psion Homepage Logo.

Comms Link Manual, Chapter 6

Psion bar.

6

THE COMMS MENU

This chapter describes what Comms Link can do from the COMMS menu. The menu contains the following items:
TRANSMIT Transmit a file or procedure
RECEIVE Receive a file or procedure
SETUP Set up communications parameters
TERM Enter terminal mode
AUTO Run the automatic setup facility
CAPTURE Enter capture buffer menu
BOOT Load and run a program stored on the PC

SETUP

Comms Link contains a set of communications parameters (the SETUP parameters) which is used by the software. The SETUP command is used to review and edit these SETUP parameters.

In this section, the SETUP editor and the meaning and usage of the parameters themselves are described.

At any time, the Comms Link software uses the current SETUP parameters. The current SETUP parameters will be initialised to the default parameter values at the following times:

  • when Comms Link is first inserted;
  • when the RESET command in the SETUP menu is used (see below);
  • when the Organiser is reset using the RESET command in the top-level menu;
  • when the Organiser is powered off (e.g. when the battery is removed for longer than 90 seconds).
  • Other than the above, and excluding direct action to change the SETUP parameters, the current parameters remain unchanged and it is not necessary to use SETUP each time you remove and insert the Comms Link cable.

    The SETUP command effectively makes a copy of the current parameters which you can view and modify. When you exit the SETUP command, the current parameters are replaced by the edited copy (although you can choose to abandon the edit in which case the current parameters are unaffected). Within the SETUP command you can create and maintain saved SETUP parameter files which you can use to replace the current parameters at will.

    USING SETUP

    When the SETUP option is selected from the COMMS menu, the screen shows:
    BAUD >      9600
    PARITY      NONE

    The top line shows the Baud rate, and the bottom line the parity setting. These are just two out of 15 parameters which may be altered.

    The selected parameter (BAUD initially) is indicated by the right arrow symbol after the parameter name. To select one of the other parameters, use the UP and DOWN cursor keys to scroll through the list.

    Pressing ON/CLEAR sets the selected parameter to its default value.

    When the selected parameter may only take its value from a list of allowable values, you change the value by pressing the LEFT and RIGHT cursor keys. The SETUP parameters may be changed in this way are BAUD, PARITY, BITS, STOP, HAND, PROTOCOL and ECHO.

    When the selected parameter can take a more open-ended set of values, the value is entered directly. (You can assume a parameter is of this type when nothing happens when you press the LEFT or RIGHT cursor keys.) Pressing EXE clears the old parameter value at the right of the display and enters the normal Organiser line editor. After typing the new parameter value, pressing EXE inserts the new value which, if accepted, is then displayed. If the new parameter value is invalid, the data is cleared and you remain within the line editor. Pressing ON/CLEAR when there is no input data abandons the parameter edit and the old value is restored. (Remember that pressing ON/CLEAR a further time would restore the parameter to its default value.)

    The SETUP parameters which are specified in this way are WIDTH, TIMEOUT, REOL, REOF, RTRN, TEOL, TEOF and TTRN.

    In practice, parameters of this type take as their value either a number or a short list of numbers, separated by commas. A number is interpreted as a decimal number unless it is prefixed by a dollar ($) when it is taken to be hexadecimal (base 16). For example, the ASCII carriage return code may be entered as 13 or as $D.

    When the parameter consists of an ASCII code or a list of ASCII codes, the character corresponding to that code is displayed instead of the code; for example, entering 42 displays an asterisk (since the ASCII code for "*" is 42). Non-printable control characters (with ASCII codes 0 to 31 and 127) are shown with their ASCII names in angle brackets. For example, when the ASCII code sequence 13,10 is entered, <CR><LF> is displayed. Characters with codes greater than 127 will have the hexadecimal value displayed in angle brackets, so 128 will be shown as <$80>. An appendix to this manual gives the names of the ASCII control codes. See appendix A in the Organiser 2 Operating Manual for the printable character set.

    The SETUP parameters, their names and allowable values are as follows:
    PARAMETER NAME OPTIONS
    Data transfer rate BAUD 50, 75, 110, 150, 300, 600, 1200, 2400, 4800, (9600)
    Parity PARITY (NONE), ODD, EVEN, MARK, SPACE
    No. of data bits BITS 7, (8)
    No. of stop bits STOP (1), 2
    Handshaking HAND NONE, (XON), RTS, XON+RTS, DTR, XON+DTR, RTS+DTR, ALL
    File transfer protocol PROTOCOL (NONE), XMODEM, PSION
    Echo ECHO LOCAL, (HOST)
    Forced line length WIDTH (NONE), 1 to 250
    Output timeout TIMEOUT (NONE), 1 to 255
    Receive EOL REOL NONE, 1 or 2 characters
    Receive EOF REOF NONE, 1 or 2 characters
    Receive translate RTRN (NONE), 1 or 2 characters
    Transmit EOL TEOL NONE, 1 or 2 characters
    Transmit EOF TEOF NONE, 1 or 2 characters
    Transmit translate TTRN (NONE), 1 or 2 characters

    Where possible, the default value is shown in brackets. For the remaining parameters, the default values are:
    PARAMETER DISPLAYED AS INPUT AS
    REOL and TEOL <CR><LF> 13,10
    REOF and TEOF <SUB> 26

    BAUD

    The BAUD parameter specifies the data transfer rate for both transmitted and received data.

    It is not possible to set a different rate for transferred data and received data on the Organiser. If you wish to communicate with a split speed host (e.g. the V23 75/1200 standard) you have to use a modem which buffers the data and presents a single speed interface at the RS232 interface.

    The Baud rate specifies the data transfer rate in bits per second. In most cases, dividing by 10 gives the transfer rate in bytes per second.

    BAUD is used by every aspect of the Comms Link software and is the most important parameter to get right. The Baud rate on the organiser must agree with the Baud rate which has been set on the communicating device.

    PARITY, BITS And STOP

    The Organiser transmits and receives data in groups (known as frames) of 10 or 11 bits. One character, or byte, of data is included in each frame.

    The first bit of a frame is the start bit and is always present.

    The next 7 or 8 bits (specified by the BITS parameter) contain the actual data which makes up the byte. When there are only 7 data bits in the frame, the missing most significant bit (there are 8 bits in a byte) is effectively set to zero.

    After the data bits there is an optional parity bit. If the PARITY parameter is NONE, there is no parity bit. Otherwise the parity bit is present and the rule for its value (0 or 1) is specified by the PARITY parameter, as follows:
    MARK always 1
    SPACE always 0
    ODD or EVEN depends on the data bits

    With ODD and EVEN parity, the parity bit is set depending on whether there is an odd or even number of 1's in the 7 or 8 data bits. This provides a primitive form of error checking.

    Finally, there will be one or two stop bits (specified by the STOP parameter).

    Because the hardware used by the Organiser can only transfer and receive 10 or 11 bit frames, combinations which would lead to a frame of other than 10 or 11 bits are not allowed. The software does this by overriding the STOP parameter value under the following circumstances:

  • When BITS is set to 7 and PARITY set to NONE (7 data bits with no parity), the Organiser will add 2 stop bits regardless of the STOP setting.
  • When BITS is set to 8 and PARITY is not NONE (8 data bits with a parity bit), the Organiser will add 1 stop bit regardless of the STOP setting.
  • Some manufacturers include the parity bit in their definition of the data bits. This means that they would call seven data bits and a parity bit eight data bits. Check the definition of data bits used by your target device in its documentation.

    As with the BAUD parameter, the important aspect about PARITY, BITS and STOP is that they agree with the corresponding settings on the communicating device. If the PARITY, BITS and STOP settings do not agree, then the communicating device will almost certainly incorrectly receive data sent to it, and the Organiser will incorrectly interpret received data.

    In terminal emulation, characters which are received with an error are set to ASCII 255 which is displayed as a solid block. In other cases (e.g. file transfer or an OPL procedure), a DEVICE READ ERROR is reported. If the parameter values do not match those of the correspondents but are not too dissimilar, you may receive some characters (sometimes as much as half the characters) without error.

    Although there are many PARITY settings on the Organiser, MARK and SPACE parity are rarely used.

    Setting 2 stop bits is normally associated with slow Baud rates (300 or lower) and mechanical devices. Having 2 stop bits rather than 1 will never cause an error - it will just slow down the byte transfer rate. The converse, however, is not true.

    The setting of PARITY, BITS and STOP are ignored in communications involving the PSION protocol, where 8 data bits, no panty and 1 stop bit are used. Other than this case, the PARITY, BITS and STOP parameters are used by all aspects of the Comms Link software, including XMODEM file transfer.

    HAND

    The HAND parameter controls the handshaking methods to be used by the Organiser.

    Devices can rarely cope with an uninterrupted stream of data, especially at the higher Baud rates, and handshaking (also called "flow control" or "buffer control") is a means by which the receiving device can pause and restart the transmitting device.

    For example, mechanical printers cannot print at the higher Baud rates and, as their internal buffer fills, they need to pause the Organiser. As another example, the Organiser applies vertical and horizontal scroll delays during terminal emulation (to give you a chance of seeing the received data) and, as a result of these delays, the Organiser will need to pause the host if it continuously transmits more than a hundred or so bytes of data.

    The Organiser supports three different kinds of handshaking, XON/XOFF, RTS/CTS and DTR each of which may be enabled or disabled. When HAND is NONE, no handshaking takes place. When HAND is ALL, all three handshaking modes are enabled. Otherwise one or two are enabled, as suggested by the value.

    XON/XOFF

    XON/XOFF handshaking is based on using two control characters to pause and restart data transfer. The receiver sends an XOFF to pause the transmitter when its input buffer is getting too full and sends an XON when its buffer is sufficiently empty. The control characters used by XON/XOFF handshaking have the ASCII names DC1 and DC3 (the "DC" stands for "Device Control") and so "DC1/DC3 handshaking" means the same thing.

    When XON/XOFF handshaking is enabled, the Organiser will pause and restart transmission in response to received XON and XOFF characters and the Organiser will also transmit XOFFs and XONs to manage the capacity of its own receive buffer.

    XON/XOFF handshaking is typically used in terminal emulation and is also supported by some printers.

    RTS/CTS

    RTS/CTS handshaking is named after the RS232 control lines (Request to Send, Clear to Send) on which it is based. On the Organiser, the detailed operation of these lines is quite complicated - see the appendix on the Comms Link interface if you need to know exactly how these lines operate.

    RTS/CTS handshaking is usually required when the Organiser is connected to a modem.

    DTR

    DTR handshaking is named after the RS232 control line (Data Terminal Ready) on which it is based. The DTR line is output low by the communicating device (usually a printer) when its receive buffer is too full, and output high again as the buffer empties.

    XON/XOFF and RTS/CTS handshaking are used to control the flow of data in either direction. DTR handshaking, however, is only used to control the flow of data from the Organiser to the communicating device.

    See the appendix on the Comms Link interface for more information on the use of the DTR/DSR lines on the Organiser.

    If your target device does not support any of the above types of handshaking, set the handshake parameter to NONE. However, in this case, you may have difficulty receiving any but the shortest files or procedures. At low Baud rates it may work provided that no access is made to a datapack (i.e., files are received to A:). You will still be able to transmit data to the other device provided that it can save the data as fast as the Organiser is transmitting. Using a slow Baud rate will clearly help.

    Communications involving the PSION protocol will override (i.e. disable) XON/XOFF handshaking. Except for this case, the handshaking specified by XON/XOFF. RTS/CTS and DTR parameters is used by all aspects of the Comms Link software, including XMODEM file transfer.

    PROTOCOL

    The PROTOCOL parameter specifies the file transfer protocol used by the COMMS menu items TRANSMIT and RECEIVE and by the TRANSMIT command in the CAPTURE menu. It has no affect on any OPL communications procedures.

    When PROTOCOL is set to NONE, the RECEIVE command just captures received data without any error checking. The TRANSFER command just sends file data down the RS232 connection, again without any error checking. The communicating device normally has to be persuaded independently to perform the corresponding capture or transmission of data. In the case of a host, this could be achieved using terminal emulation (the TERM command, described later) on the Organiser.

    When PROTOCOL is set to XMODEM, TRANSMIT and RECEIVE assume that the communicating device is running an XMODEM program. In this case, file transfers are error checked, but the corresponding transfers (TRANSMIT at one end and RECEIVE at the other) must be independently and manually initiated.

    When PROTOCOL is PSION, TRANSMIT and RECEIVE work on the assumption that the communicating device is a PC running the Comms Link communications server program (CL). File transfers are error checked and, once the CL program is running, the transfer is controlled entirely from the Organiser.

    ECHO

    The ECHO parameter only affects terminal emulation (TERM and CAPTURE in the COMMS menu).

    In terminal emulation, characters corresponding to the keys being pressed are transmitted to the host and characters which are received are displayed on the Organiser screen (and optionally saved in the capture buffer).

    When ECHO is LOCAL. transmitted characters are also displayed (and recorded in the capture buffer if capture is enabled.

    Usually, the host will echo characters as they are typed and ECHO should be set to HOST. If the host does not echo its input, ECHO should be set to LOCAL so that you can see what you type.

    If ECHO is set to LOCAL and the host is also echoing its input. you will see each character displayed twice. Set ECHO to HOST to remedy this.

    An example of a "host" which does not echo its input is a printer. If you are using terminal emulation to test a printer, you may find it helpful to set ECHO to LOCAL.

    TIMEOUT

    The TIMEOUT parameter may be used to set a time out for the LIST command under the top-level PROG menu, the OPL LPRINT command, and the output stage of the Comms Link TRIGS procedure.

    The TIMEOUT parameter is only meaningful when handshaking is in use where the communicating device can pause the output from the Organiser. When TIMEOUT is set to NONE, the output operation (LIST, LPRINT or TRIG$) can be paused indefinitely. An indefinite pause can be avoided by setting the TIMEOUT parameter to a time out value of between 1 and 255 seconds. It the communicating device (e.g. printer) pauses the Organiser for more than the timeout period. the operation will abort with a DEVICE WRITE ERR (error number 192).

    In practice. the TIMEOUT parameter is usually used to detect a device being left "off line" and to recover gracefully after the timeout period rather than "hang" forever.

    WIDTH

    The WIDTH parameter is used to break up long lines.

    In terminal emulation (TERM and CAPTURE in the COMMS menu). the WIDTH parameter is used to force an end of line (as if the REOL sequence had been received) when the received line length is greater than the number of characters specified.

    Apart from terminal emulation. the width command affects certain RS232 output operations in that a TEOL (Transmit End Of Line) sequence is inserted into the output stream when the length of the line being transmitted exceeds the WIDTH specified. If WIDTH is NONE. no TEOL insertion takes place. When receiving data. WIDTH equal to NONE is equivalent to a width of 250 characters. The output operations which use WIDTH are the OPL command LPRINT. the Comms Link device procedure TRIG$, and the LIST command under the PROG menu. The file transfer commands do not use the WIDTH parameter.

    This feature is useful when sending data to a printer which does not insert its own new line when the print position exceeds the right margin.

    REOL And TEOL

    REOL and TEOL stand for Receive End Of Line and Transmit End Of Line. They both define the ASCII sequence of characters which define an end of line. The REOL sequence is used by the Organiser to recognise an end of line on input. The TEOL sequence is transmitted by the Organiser to signal an end of line to the communicating device.

    Both the REOL and TEOL sequence may be set to no characters (NONE), one character, or two characters. TEOL and REOL would normally be set to a combination of <CR> (ASCII 13) and <LF> (ASCII 10).

    Except for communications involving the PSION protocol, where the end of line sequence is always <CR><LF>, the TEOL and REOL parameters are used by all aspects of Comms Link.

    In terminal emulation, pressing the EXE key transmits the TEOL sequence. When the REOL sequence is received, the display continues on a new line (and the screen scrolls).

    In the tile transfer commands TRANSMIT and RECEIVE, when PROTOCOL is either NONE or XMODEM. TEOL is sent at the end of transmitted data records and procedure lines and REOL is used to recognise received data records and procedure lines.

    TEOL is transmitted by LPRINT (except where the command ends with a semicolon). TRIG$ and LIST (under the PROG menu). REOL is used by TRIG$ and LINPUT$.

    If you are using the Organiser as a terminal to a host it is more likely that TEOL should be <CR> with REOL left at the default of <CR><LF>. If you are using the Organiser to transfer files to another microcomputer or to send data to a printer, you will probably find that the default settings are correct.

    If you have a data file which contains the carriage return character (ASCII 13) within a record you may be surprised to see the record broken into two lines when transferred to a communicating device. This is because an end of line is implemented internally as a <CR> character, so any <CR> is translated to the TEOL sequence. This also means that carriage returns are removed if TEOL is set to NONE.

    REOF And TEOF

    REOF and TEOF stand for Receive End Of File and Transmit End Of File. They both define the ASCII sequence of characters which define an end of file when using file transfer when the PROTOCOL parameter is set to NONE or XMODEM (not PSION).

    The REOF sequence is used by the Organiser to recognise an end of file when receiving a file using the RECEIVE command. The TEOF sequence is sent by the Organiser to signal an end of file to the communicating device when transmitting a file using the TRANSMIT command.

    As for REOL and TEOL, the REOF and TEOF sequence may be set to no characters (NONE), one character, or two characters.

    An end of file is implemented internally as a <SUB> character, so any <SUB> is translated to the TEOF sequence. This also means that any <SUB> character will be removed if TEOF is set to NONE.

    RTRN And TTRN

    RTRN and TTRN stand for Receive Translate and Transmit Translate.

    RTRN and TTRN provide the means to translate any character to another character or to remove a character on input and output respectively. When RTRN or TTRN is set to NONE (the default). no translation occurs. When set to only one character, that character is removed. When set to two characters, the first character is translated to the second character.

    On output, the transmit translate does not operate on <CR> and <SUB> characters - these are always transmitted as the current TEOL and TEOF sequences respectively. However, TTRN processing is performed before TEOL and TEOF processing so that if the specified TTRN translates a character to <CR> or <SUB>. this new character will then be translated a second time, either to the TEOL or TEOF sequence.

    On input, REOL and REOF sequences are checked for before RTRN processing is done. In the cases of LINPUT$ and TRlG$, REOL and REOF sequences are treated as part of the received data and are passed through for RTRN processing. See the following chapter for descriptions of LINPUT$ and TRIG$.

    An example of the usage of RTRN is to convert <BELL> (ASCII 7) into, say, an asterisk (ASCII 42). (The <BELL> control code normally sounds a bell on a terminal.)

    Another example, which applies to both RTRN and TTRN, is to translate to and from the <TAB> (ASCII 9) character, used as a field delimiter in Organiser data files. For example, if RTRN is set to translate the "/" character (ASCII 47) to <TAB> (ASCII 9), the received line (using the RECEIVE option to receive a data file):

    Psion Limited/Psion House/Harcourt Street/LONDON/W1H 1DT<CR><LF>

    will produce a record with 5 separate fields on the Organiser.

    For communications involving the PSION protocol, the RTRN and TTRN parameters are only used in file transfers to and from data files on the Organiser (RTRN and TTRN are ignored in transfers involving procedure files and binary files). Except for this case, RTRN and TTRN are used by all aspects of Comms Link.

    LEAVING SETUP

    Pressing the MODE key exits the SETUP parameter editor into the SETUP menu:
    EXIT Exit SETUP keeping any changes
    ABANDON Exit SETUP discarding any changes
    EDIT Return to the parameter list to continue editing
    SAVE Save the current SETUP
    LOAD Load a previously saved SETUP
    DIR Read the directory of saved SETUPs
    ERASE Erase a previously saved SETUP
    RESET Reset to the default SETUP settings

    Selecting EXIT or ABANDON exits the SETUP command; selecting EDIT returns to the parameter editor. The remaining commands return to the SETUP menu on completion.

    If you use your Organiser to connect to more than a single device, it is useful to be able to recall a previously defined SETUP. The SAVE, LOAD, DIR and ERASE commands are used to maintain a set of custom SETUP files.

    When you select the SAVE option from the SETUP menu, the screen will show:
    SAVE A:         

    Press the MODE key to change the device, if you wish, and then enter the name you wish to save the current setup under. The edited SETUP parameter values are saved, even if you have not yet made them the current parameter values by selecting EXIT.

    The procedure for entering the filename for LOAD and ERASE is the same. Like the SAVE command, the LOAD command does not replace the current parameter values, only the edited parameters.

    To view a directory of SETUP files, select the DIR option from the SETUP menu. Press the MODE to change the current device, if necessary. Press the EXE key repeatedly to view the names of SETUP files which are stored on the specified device. After the last SETUP file, the END OF PACK message will be displayed. Press the ON/CLEAR key to return to the SETUP menu.

    The RESET command sets all the SETUP parameters to their default values. However, only the edited parameters are affected and EXIT must be used to replace the current parameters.

    FILE TRANSFER

    The TRANSMIT and RECEIVE commands are used to transfer data files and procedures to and from the Organiser.

    The type of file transfer which is used and the behaviour of the RECEIVE and TRANSMIT commands depend upon the setting of the PROTOCOL parameter (as set by the SETUP command). The PROTOCOL parameter can take the values NONE, XMODEM or PSION.

    The PSION protocol provides the best file transfer service but relies on the communicating device being an IBM PC/XT/AT or compatible running the PC communications program CL (supplied with Comms Link).

    The XMODEM protocol provides a better file transfer service than NONE but assumes that the communicating device is running an XMODEM program (not supplied with Comms Link).

    Using PROTOCOL set to NONE provides the most primitive file transfer (no error checking) but makes the least demands upon the communicating device. With PROTOCOL set to NONE, the TRANSMIT command may be used to send data files and procedure files to a printer.

    For all three protocols, the only file transfer available using the RECEIVE and TRANSMIT commands is between simple text files on the communicating device and either data files or procedure files on the Organiser.

    Binary files (e.g. DIARY files) can be transferred using the PSION protocol but you have to write an OPL program (see the following chapter).

    When you select either RECEIVE or TRANSMIT, the screen will show:

    This is a small menu, from which a selection can be made in the usual way. Select FILE to receive or transmit a data file (see the Organiser 2 Operating Manual for a description of data files) and PROCEDURE to receive or transmit a procedure file.

    Data Files

    Data files consist of a number of records where each record may be split into fields. Records contain up to 254 characters and fields are delimited by the <TAB> character (ASCII 9). Each data file record corresponds to a line within the text file on the communicating device.

    When receiving data files with PROTOCOL set to NONE or XMODEM, if the incoming file contains lines longer than 254 characters, they are split into records of that length with the remainder of the line being written to successive records. Normally, a new record begins whenever the REOL sequence is detected.

    Incoming <TAB> characters will divide the records into separate fields. Alternatively, the <TAB> characters may be generated by the RTRN option as described above under SETUP.

    On the Organiser. a data file record may not be empty. Any received blank lines are saved as a record containing a single space character.

    Procedure Files

    When procedure files are transmitted using the TRANSMIT command, only the source is transmitted. When procedure files are received using the RECEIVE command, a file is created which contains the source only (no object). You have to translate the procedure (using the TRAN option in the procedure editor under the PROG menu) before you can run a received procedure.

    The first line of an Organiser procedure consists of a procedure name followed by a colon and optionally followed by the procedure parameters. When procedures are created under the top-level PROG command, the procedure file name will match the name on the first line. When you receive a procedure, however, the file name may not match the name on the first line. It is the procedure file name which is significant when you invoke a procedure in an OPL program, not the name which appears on the first line. (When you edit a procedure on the Organiser the name of the fist line is changed, if necessary, to agree with the procedure file name.) When receiving a procedure, you should be mindful of the significance of the file name when choosing it.

    When receiving a procedure, if the first line does not contain a colon, a first line is inserted consisting of a question mark followed by a colon. If the received data contains one or more ASCII control characters (i.e. with ASCII codes which are less than 32) and except for REOL and REOF characters, the RECEIVE command will fail with a BAD PROCEDURE message.

    When receiving a procedure with the PROTOCOL set to either NONE or XMODEM, the whole procedure is held in a buffer in memory before being saved to the file. In this case, there must be sufficient free memory to hold the entire procedure. If the procedure is being received to A: (the internal memory of the Organiser), there must be sufficient room for two copies of the procedure.

    RECEIVE

    When using RECEIVE and after selecting PROCEDURE, the screen will show the prompt:
    RECV A:         

    Press the MODE key to change the device shown, if necessary. You may now type in the name of the file which is to take the received data. The file name must, as usual, be no longer than eight characters. If you have previously specified a file name in file transfer, that name will be given as a default.

    If you specify a file name which already exists, the display will show:
    A:FNAME EXISTS  
    DELETE Y/N

    where FNAME is the procedure file name which was specified. If you press N you are returned to the previous screen and may now type in a different file name or press ON/CLEAR to abort the transfer. Press Y and the old procedure will be deleted and replaced by the incoming file.

    When using RECEIVE and after selecting FILE, the screen will show the prompt:
    RECV A:MAIN     

    The default file name will be MAIN unless you have previously specified a file name in file transfer, in which case that name will be given instead. You can either accept the default or press ON/CLEAR to clear the input and type another name in.

    If you select the FILE option and you specify a file name which already exists and which contains data, the display will show:
    ERASE APPEND    

    This is another small menu. If ERASE is selected, the incoming file will replace the old data file of that name and its original contents will be lost. If the file being erased contains a large number of records, this may take some time. If the APPEND option is selected, the data in the incoming file will be appended to the original file.

    The subsequent behaviour of the RECEIVE command depends on the setting of the PROTOCOL parameter.

    Receiving files with the PSION protocol

    If the PROTOCOL parameter is set to PSION, the display will prompt for the PC file name:
    RECV A:FNAME    
    FROM:FNAME

    where you are offered the default of the same name for the PC. Either accept the default or enter a different PC file name (and path name, if required). If you do not include a path name, the current directory (when you ran Comms Link) will be used on the PC. Since path names use the backslash character (\) (which cannot be entered from the Organiser keyboard), any "/"in the name is converted to a "\", by the PC software. Also, as the default name may contain a percent character (%), which is not allowed in PC file names, the PC software converts any percent characters in the file name to an underscore character (_). If the file does not exist on the PC, a FILE NOT FOUND error is displayed and you are given another opportunity to enter the "FROM:" file name.

    While data is being received, the screen will show:
    receiving...    

    If the file transfer is unsuccessful, it will display one of the following error messages:

    If possible, look at the PC display for further details of any failure.

    Receiving files with no protocol

    When PROTOCOL is set to NONE, the received data is displayed on the screen as it downloads. At the higher Baud rates, this will not be readable but it will indicate that data transfer is taking place. The RECEIVE command terminates when the REOF sequence is received. Pressing ON/CLEAR aborts the transfer, saving all the information so receive This is useful if the communicating device has sent all its data and cannot send an REOF sequence.

    Receiving files with the XMODEM protocol

    When PROTOCOL is set to XMODEM, the screen will initially show:
    connecting      

    Provided that the XMODEM program on the communicating device has been set up to transmit a file, the screen will change to:
    Received nn     

    where nn indicates the number of blocks received successfully. If all goes well, the block count will steadily increase until a RECEIVE OK message is displayed. At this point, press any key to continue.

    The following messages may also be shown:

    The RECEIVE command terminates when the file is received successfully or if a fatal error occurs.

    TRANSMIT

    When using TRANSMIT and after selecting PROCEDURE, the screen will show the prompt:
    SEND A:         

    Press the MODE key to change the device, if necessary, and enter the name of the file which is to be transmitted. If you have previously specified a file name in file transfer, that name will be given as a default.

    As with RECEIVE, selecting TRANSMIT then FILE offers as a default the file name you have most recently specified in file transfer. If it is your first file transfer operation the default file name MAIN is offered:
    RECV A:MAIN     

    Press EXE to accept the default or press ON/CLEAR to clear the input and enter another name.

    If the file is not found, a FILE NOT FOUND message will be displayed.

    Transmitting files with the PSION protocol

    If the PROTOCOL parameter is set to PSION, the display will prompt for the PC file name:
    SEND A:FNAME    
    TO:FNAME

    where you are offered the default of the same name for the PC. Either accept the default or enter a PC file name (and path name, if required). If you do not include a path name, the current directory (when you ran Comms Link) will be used on the PC. Since path names use the backslash character (\) (which cannot be entered from the Organiser keyboard), any "/" in the name is converted to a "\" by the PC software. Also, as the default name may contain a percent character (%), which is not allowed in PC file names, the PC software converts any percent characters in the file name to an underscore character (_).

    If the file already exists, the display will show:
    FNAME EXISTS    
    DELETE Y/N

    If you press N you are returned to the previous screen and may now type in a different file name or press ON/CLEAR to escape. Press Y and the existing file will be replaced.

    While data is being transmitted the screen will show:
    Sending...      

    If the file transfer is unsuccessful, it will display one of the following error messages:

    If possible, look at the PC display for further details of any failure.

    Transmitting files with no protocol

    When PROTOCOL is set to NONE, transmitted data is displayed on the screen as it is transmitted. At the higher Baud rates, this will not be readable but it will indicate that data transfer is taking place.

    When all the file data has been sent the TEOF sequence is transmitted and the command terminates. Pressing ON/CLEAR aborts the transfer.

    Transmitting files with the XMODEM protocol

    When PROTOCOL is set to XMODEM, the screen will initially show:
    connecting      

    Provided that the XMODEM program on the communicating device has been set up to receive a file, the screen will change to:
    Sending nn      

    where nn indicates the number of the block currently being sent. If all goes well, the block count will steadily increase until a SEND OK message is displayed. At this point, press any key to continue.

    The following messages may also be shown:

    TERMINAL EMULATION

    Selecting the TERM option in the COMMS menu enters terminal emulation, where key presses transmit the corresponding character and received characters are displayed as they arrive - emulating the basic features of a terminal. If the SETUP parameter ECHO is set to LOCAL, characters are also displayed as they are transmitted.

    As data is echoed, the lower display line scrolls horizontally if the line length exceeds 16 characters. When an end of line sequence (as set by the REOL parameter) is received or if the line width (as set by the WIDTH parameter) is exceeded, the display scrolls vertically showing the first 16 characters of the line in the upper display line. Either a horizontal or a vertical scroll delay is applied to give you a chance of viewing the data received. You can disable horizontal scrolling by setting the WIDTH parameter to 16. Comms Link terminal emulation does not process any escape codes.

    Normally, you use terminal emulation to access a multi-user RS232-based minicomputer or mainframe (for example, to use an Electronic Mail service), often via a modem and a dialled connection. Terminal emulation can also be used when connected to a printer to confirm that the SETUP parameters are correct and that the printer is able to receive data from the Organiser.

    Selecting the TERM option in the CAPTURE menu (described below) has the same effect as selecting TERM in the COMMS menu except that displayed characters are recorded in the capture buffer (in the internal memory of the Organiser) and that the scroll delays are switched off. The CAPTURE command is described in the next section.

    In terminal emulation, the SHIFT, CAP and NUM keys produce the usual full range of upper an lower case letters, numbers, operators and punctuation. However, the cursor keys behave differently within terminal emulation.

    The LEFT and RIGHT cursor keys operate like shift keys.

    The LEFT cursor key acts like the CONTROL key on a PC enabling you to send the control characters such as <SUB>, or CONTROL-Z (ASCII 26) for end of file, <DC3>, or CONTROL-S (ASCII 19) for pause, <DC 1>, or CONTROL-O (ASCII 17) for continue and so on.

    The RIGHT cursor key acts a "special" shift key which allows you to send characters which cannot otherwise be sent with normal keyboard behaviour. The additional characters which are made available by the LEFT and RIGHT cursor keys are shown in the table below.
    LEFT with: ASCII CHAR RIGHT with: ASCII CHAR
    A 01 ^A A 1B ^[
    B 02 ^B B 1C ^\
    C 03 ^C C 1D ^]
    D 04 ^D D 1E ^^
    E 05 ^E E 1F ^_
    F 06 ^F F 21 !
    G 07 bell G 23 #
    H 08 backspace H 26 &
    I 09 tab I 27 '
    J 0A line feed J 3F ?
    K 0B ^K K 40 @
    L 0C form feed L 5B [
    M 0D carr. return M 5C \
    N 0E ^N N 5D ]
    O 0F ^O O 5E ^
    P 10 ^P P 5F _
    Q 11 XON Q 60 `
    R 12 ^R R 7B {
    S 13 XOFF S 7C |
    T 14 ^T T 7D }
    U 15 ^U U 7E ~
    V 16 ^V V 7F del left
    W 17 ^W W 3F ?
    X 18 ^X X 3F ?
    Y 19 ^Y Y 3F ?
    Z 1A ^Z Z 3F ?

    Note that on the Organiser, the ASCII \ character is displayed as a Yen sign and the ASCII ~ character is displayed as a right arrow sign.

    The DOWN cursor keys pauses the display and the UP cursor starts the display again. You will not lose any data provided you are using handshaking.

    To exit terminal emulation and return to the COMMS menu, press ON/CLEAR. You will not lose any data when you exit and re-enter terminal emulation, provided you are using handshaking.

    Except for <NUL> (ASCII 0) and <TAB> (ASCII 9), received characters below ASCII 32 are displayed as ^A for ASCII 1, ^B for ASCII 2, ^C for ASCII 3 and so on. All received <NUL>s are discarded. A received REOL will scroll the display, and is then discarded. A received REOF will also be discarded. Received <TAB> characters (which are used to delimit fields in data records) are displayed using a special <TAB> graphic, shown in figure 6.1.
             
             
             
             
             
             
             
             

    Figure 6.1 The <TAB> Graphic

    File Transfer During Terminal Emulation

    You can still use TRANSMIT and RECEIVE with PROTOCOL set to NONE to upload data to a host and capture data from it.

    For example, to send a file to a host, such as an electronic mail file, enter terminal emulation and type to the host in the normal way. At the point where the software on the host is expecting you to type in the data, press ON/CLEAR to return to the COMMS menu and then use TRANSMIT to send the data. You can either re-enter terminal emulation to type the sequence which indicates to the host that the data is complete or set the TEOF parameter to the correct sequence (you may find that the default is correct).

    To receive data from a host, type a command which would display the data you want to receive followed by the REOF sequence. Before pressing EXE to enter this command on the host, hold down the RIGHT key and press S to send an XOFF character to the host, pausing the output until you are ready to receive it. Now press EXE to complete the command for the host to send the file. Press ON/CLEAR to get the COMMS menu and then use RECEIVE to capture the data. When the RECEIVE command starts, it sends an XON and the host starts transmission.

    If the data you are receiving does not end with your REOF sequence, press ON/CLEAR to save the data when the transmission has finished.

    An alternative way of capturing data is to enter terminal emulation via the CAPTURE command, as described in the next section.

    CAPTURE

    Selecting the CAPTURE command presents a menu of commands which are associated with the capture buffer. The CAPTURE menu contains the following items:
    TERM enters terminal emulation with capture enabled
    EDIT enters the capture buffer editor
    CLEAR clears the capture buffer
    SAVE saves capture buffer data to data file or procedure
    TRANSMIT transmits the data in the capture buffer

    SAVE, TRANSMIT and CLEAR will only operate when the capture buffer contains data. A BUFFER IS EMPTY message will be displayed if this is not the case.

    Selecting TERM (just press EXE) enters terminal emulation such that displayed data is recorded in the capture buffer. Pressing ON/CLEAR returns to the CAPTURE menu.

    Using TERM under CAPTURE can rapidly consume your free memory and you should not be too casual about leaving large amounts of data in the capture buffer as you may find that various operations on the Organiser will fail with an OUT OF MEMORY message.

    If the Organiser runs out of memory while data is being captured, terminal emulation is aborted and an OUT OF MEMORY message is displayed. Press SPACE to exit to the CAPTURE menu. You may take the opportunity to release memory (for example, by deleting some or all of the data in the capture buffer) before returning to terminal emulation. Provided that handshaking is in use, you will not miss any received data.

    Selecting EDIT enters the capture buffer editor from which you can view and modify the contents of the capture buffer. EDIT behaves almost identically to the procedure editor under the top-level menu PROG command. The cursor scan through captured lines; the LEFT and RIGHT arrow keys move the cursor within a line; ON/CLEAR deletes a line; EXE splits a line at the cursor position; DEL and SHIFT DEL delete left and right respectively and key presses corresponding to printable characters insert at the cursor position.

    The differences are that received <TAB> characters are displayed with a special <TAB> graphic and that the MODE key returns to the CAPTURE menu.

    The EDIT command can also be used to prepare data "off line" for subsequent transfer to a host (but remember that Comms Link must be plugged into the Organiser while you use any facilities under the COMMS menu).

    The CLEAR command requests confirmation before it erases the entire contents of the capture buffer.

    The SAVE option behaves similarly to the COMMS menu RECEIVE command (when PROTOCOL is set to NONE) and presents the PROCEDURE or FILE menu followed by a request for the file name to save to.

    The TRANSMIT command under the CAPTURE menu behaves in the same way as TRANSMIT under the COMMS menu (including the way it depends on the PROTOCOL parameter) except that it transmits the contents of the capture buffer without prompting for FILE or PROCEDURE or for a file name on the Organiser. The data in the capture buffer is subject to TTRN processing as it is transmitted (even when the PROTOCOL parameter is PSION)

    AUTO

    The AUTO command is an aid to determining the SETUP parameters BAUD, PARITY, BITS and STOP (with the exception of MARK and SPACE parity) which agree with the setting on the communicating device (especially a printer).

    The command cycles through all combinations of BAUD, PARITY, BITS and STOP transmitting a line of text for each combination. The text contains a message which identifies the four parameters so that if the device receives the text without corruption. you can read the correct values of the parameters to use in SETUP.

    While the program is running. the display continuously shows the combination of the parameters which is currently being transmitted. Press ON/CLEAR to abort AUTO when you are satisfied that you know the correct values. If you leave AUTO running it will return to the COMMS menu when it has tried every combination. Either way. the settings that were in force before AUTO was selected will be restored.

    The AUTO command does not aid the setting of the handshaking parameter, HAND.

    BOOT

    The BOOT command only works when the Organiser is connected to an IBM PC/XT/AT or compatible running the supplied communications program CL. It is used to run communications (written in the Organiser processor's machine code) on the Organiser, which are saved as files on the PC.

    Comms Link is not supplied with any applications of this type, but the BOOT command provides a "hook" for applications (particularly communications applications) to be provided on floppy disk alone.

    When you enter the BOOT command. Comms Link prompts for the name of the application to run. The subsequent behaviour of the command depends upon the application.

    If you accidentally enter the BOOT command press ON/CLEAR to abort the prompt for the application name and return to the COMMS menu. If you enter a name when you are not connected a PC running CL or if the application does not exist on the PC you will get an error message after a few seconds wait. You can then press SPACE to return to the COMMS menu.

    Organiser bar.

    These pages should be viewed using Netscape 4.03 or Microsoft Internet Explorer 3.02 at 800x600 pixels.
    Left arrow Comms Manual Chp. 4-5 ~ Homepage ~ Comms Manual Chp. 7 Right arrow