SER.readbyte()

This command receives a byte from the serial port TXD/RXD.

It has no input parameter.

The return value is a Python integer which is the byte value received and stored in buffer at the moment of command execution or is -1 if no data is received. The return value can also be zero.

 

Example:

 

b = SER.readbyte()

 

receives a byte from serial port USIF0 handling, assigning the return value to b.