SerialDeviceConfig constructor

const SerialDeviceConfig({
  1. required String portName,
  2. int baudRate = 9600,
  3. int dataBits = 8,
  4. int parity = 0,
  5. int stopBits = 1,
  6. bool dtrEnable = true,
  7. bool rtsEnable = true,
  8. int flowControl = SerialPortFlowControl.none,
  9. Duration readTimeout = const Duration(milliseconds: 500),
  10. Duration writeTimeout = const Duration(milliseconds: 500),
  11. ProtocolMode protocolMode = ProtocolMode.framed,
})

Implementation

const SerialDeviceConfig({
  required this.portName,
  this.baudRate = 9600,
  this.dataBits = 8,
  this.parity = 0,
  this.stopBits = 1,
  this.dtrEnable = true,
  this.rtsEnable = true,
  this.flowControl = SerialPortFlowControl.none,
  this.readTimeout = const Duration(milliseconds: 500),
  this.writeTimeout = const Duration(milliseconds: 500),
  this.protocolMode = ProtocolMode.framed,
});