Class and Functions


Class

To use this extension board, use the ExpansionSerial class of the PHPoC Expansion library.

Member Functions

Available member functions of the ExpansionSerial class are as follows:

Member Function Description
int getPID(void) get the product's ID
char *getName(void) get the product's name
ExpansionSerial(int sid) create an instance of the serial port
void begin(void) set the serial communication parameters
int available(void) get the received data size
int peek(void) peek one byte of received data
int read(void) read one byte from the receive buffer
int availableForWrite(void) get the remaining size of receive buffer
void flush(void) flush send buffer
int write(int wbuf, int wlen) send data