- Function
Read a character from serial port.
- Header
- Declaration
unsigned char __fastcall__ ser_get (char* b);
- Description
Get a character from the serial port. If no characters are available, the function will return SER_ERR_NO_DATA, so this is not a fatal error.
- Limits
- The function is only available as fastcall function, so it may only be used in presence of a prototype.
- Availability
cc65
- See also
Other serial functions.
- Example
Wait for a character to be available from a serial port.
char ch; while (ser_get(&ch) == SER_ERR_NO_DATA) ;