RS232IB.HLP     A BUFFERED CHIP LEVEL RS-232 driver for 8250 chip



bufsize is the number of bytes to allocate for the receive buffer.

baud ( n -- )
        Set baud rate equal to n

com-out ( c -- )
        Output character c to the com port in use.

com-in ( -- c )
        Get one character directly from the com port in use.
        Time out after about a second if there is no received character.
        There should be no reason to use this word.  Use COM-GET to get
        characters from the buffer.

com-stat ( -- s )
        Get the status byte of the port in use

com-cnt  ( -- count )
        The low-level function to see how many bytes are in the buffer.

com-get ( -- char )
        The low-level function to get one received character from the buffer.
        Returns zero if the buffer is empty.

clr-buf ( -- )
        Clear out the buffer and fill it with zeros.
        Helps .buf show what's going on.

.buf ( -- )
        Display the buffer contents, can be useful
        when debugging the communications.


Add together three of the following to select the bit protocol

nopar   oddpar  evenpar       \ parity control
1stop   2stop                 \ stop bit control
7bit    8bit                  \ length control

For example, the default setting is.....
        nopar 2stop 8bit + + value parity&bits
i.e.  no parity, 8 bit data, 2 stop bits

com2: ( -- ) Initialise drivers to use com port 2

com1: ( -- ) Initialise drivers to use com port 1


