herosdevices.core.templates.serial

Templates for devices connect via a serial interface.

Module Contents

class herosdevices.core.templates.serial.SerialDeviceTemplate(address: str, baudrate: int, line_termination: bytes = b'\n', keep_alive: bool = True, delays: dict | None = None, **kwargs)[source]

Template (base class) for devices which are controlled or read out through a serial interface.

The interface must be accessible via pyserial. This can be via UART, Serial via IP, etc.

Inheriting your device driver from this class allows to use herosdevices.core.DeviceCommandQuantity to define the serial commands within your device driver class.

address
connection