sbp.client.drivers.pyserial_driver module

class sbp.client.drivers.pyserial_driver.PySerialDriver(port, baud=115200, rtscts=False)[source]

Bases: sbp.client.drivers.base_driver.BaseDriver

The PySerialDriver class reads SBP messages from a serial port using the pyserial driver. This is mostly redundant, is the Serial object’s read and write methods can be used directly.

port
: string
URI to port to read SBP messages from. Accepts the following types of URLs: - rfc2217://<host>:<port>[/<option>[/<option>]] - socket://<host>:<port>[/<option>[/<option>]] - loop://[<option>[/<option>]] and device names, such as /dev/ttyUSB0 (Linux) and COM3 (Windows). See http://pyserial.sourceforge.net/pyserial_api.html#urls for more details.
baud
: int
Baud rate of serial port (defaults to 115200)
read(size)[source]

Read wrapper.

size
: int
Number of bytes to read.
write(s)[source]

Write wrapper.

s
: bytes
Bytes to write