INP

Command

INP [n filename]

Explaination

Inputs a file via the serial port.

Examples

INP can be used to load files in either Intel Hex format, with checksums etc., or as 8-bit data but without any error checking. The second method of loading is, however, faster than using Intel Hex.

Loading Intel Hex files

Files to be loaded must be in Intel Hex format, see Hex Data Format. If they are command files, overlay files or data files etc., this is achieved with a standard utility reproduced in Demo Program 4 "UNLOAD".

Typing INP readies HUNTER to receive data, which is put into RAM page 0. the data is not written directly to into a file. When completed the number of 56 byte blocks loaded is displayed. It may be copied to a file using the SAVE command, or if it is a program, executed with the EXECUTE command.

Loading 8-bit format

Data is loaded directly into a specified file in blocks of 256 bytes. The format of the command is:

INP n filename

For example a 14k overlay file:

>INP 56 OVERLAY1.OVR

The communications must have parity set to 8-bit and SERIG (Serial ignore character) set to off.

The number of blocks must be specified because there is no end of file character. If too many blocks are expected, the screen will display 'waiting', and reception may be terminated with 'ESC'.

Remarks

When HUNTER is loading data the following messages will appear on the screen:

>WAITING
>LOADING
>WAITING
>LOADING
.
.
.
.

HUNTER responds to each pause in transmission with a 'WAITING' message to indicate that data is not being received.

On completion of Hex loading the number of 256 byte blocks now in memory is displayed.

The number of blocks, n, can be overspecified, for instance:

INP 100 filename

will load most files. Only the number of blocks actually required will be used following termination by 'ESC'.

The number of blocks is calculated by:

1 block = 256 bytes

1K bytes = 4 blocks

Because INP clears the receive comms buffer to remove spurious data when it is invoked, it is important to ensure that the HUNTER is ready to receive before the transmitting device begins to SEND.