<< Previous | Next >>

cof_serXputs

void cof_serXputs( char * str ); /* where X is A-F */

Description

This single-user cofunction writes a null terminated string to port X. It yields to other tasks for as long as the input buffer may be locked or whenever the buffer may become full as characters are written. This function is non-reentrant.

The functions cof_serEputs() and cof_serFputs() may be used with the Rabbit 3000 or Rabbit 4000.

NOTE Alternatively you can use another form of this function that has been generalized for all serial ports. Instead of substituting for "X" in the function name, the prototype of the generalized function is: cof_serXputs(port, ...), where "port" is one of the macros SER_PORT_A through SER_PORT_F.

Parameters

str
Null terminated character string to write.

Library

RS232.LIB

Example

// writes a null terminated character string, repeatedly
main() {
const char s[] = "Hello Rabbit";
serAopen(19200);
loopinit();
while (1) {
loophead();
costate {
wfd cof_serAputs(s);
}
}
serAclose();
}


Dynamic C Functions << Previous | Next >> rabbit.com