Description-
Queues a byte for transmission. Causes a byte to be transmitted. This function will wait for up to the amount of time set by SetTimeout() before returning failure if a byte could not be outputted.
Syntax-
stat = PutByte(port,ch);
On Entry-
int port;
Port previously opened with OpenComPort().
char ch;
Character to transmit.
On Exit-
int stat;
0 If data queued successfully for transmission.
else
-1 If port was not initialized or output buffer is full.
See Also-
PutPacket()
PutString()
Example-
#include <comm.h> int port=0; char byte="A"; if (PutByte(port,byte) == -1) { printf("Transmit buffer full\n"); }