Constructors
class machine.UART(id, baudrate=115200, bits=8, parity=None, stop=1, *, flow=0, timeout=0, timeout_char=0)
- id: XBee Cellular supports a single UART, using the id 1.
- baudrate: Clock rate for serial data.
- bits: Bits per character, a value from 5 to 8.
- parity: An additional parity bit added to each byte, either None, 0 (even) or 1 (odd).
- stop: Number of stop bits after the optional parity bit, either 1 or 2.
- flow: Hardware flow control; either 0 for none, UART.RTS for RTS-only, UART.CTS for CTS-only or UART.RTS|UART.CTS for both.
- timeout: Number of milliseconds to wait for reading the first character.
- timeout_char: Number of milliseconds to wait between characters when reading.
You can pass parameters before the flow keyword without their names, for example: UART(1, 115200, 8, None, 1).
Note Unlike other MicroPython platforms, the XBee Cellular Modem uses a circular buffer to store serial data, and the timeout and timeout_char settings do not apply to writes.