This the multi-page printable view of this section.Click here to print.

Return to the regular view of this page.

CHROUT

Output a character

Table of Contents

Function AddressVectorDescription
CHROUT FFD20326Output a character

This routine outputs a character to an already opened channel. Use the OPEN and CHKOUT routines to set up the output channel before calling this routine. If this call is omitted, data is sent to the default output device (number 3, the screen).

The data byte to be output is loaded into the accumulator, and this routine is called. The data is then sent to the specified output device. The channel is left open after the call.

Care must be taken when using this routine to send data to a specific serial device since data will be sent to all open output channels on the bus.

Unless this is desired, all open output channels on the serial bus other than the intended destination channel must be closed by a call to the CLRCHN routine.

Example:
LDX#4Logical file 4
JSRCHKOUTOpen channel 4 for output
LDA#'A'
JSRCHROUTSend character
JMPCLRCHNClear all I/O channels so future output goes to screen