Python Serial Communication (pyserial)

Download python eBook

Syntax

  • ser.read(size=1)

  • ser.readline()

  • ser.write()

Parameters

parameterdetails
portDevice name e.g. /dev/ttyUSB0 on GNU/Linux or COM3 on Windows.
baudratebaudrate type: int default: 9600 standard values: 50, 75, 110, 134, 150, 200, 300, 600, 1200, 1800, 2400, 4800, 9600, 19200, 38400, 57600, 115200

Remarks

For more details check out pyserial documentation

Related Examples

Stats

68 Contributors: 5
Tuesday, December 20, 2016
Licensed under: CC-BY-SA

Not affiliated with Stack Overflow
Rip Tutorial: info@zzzprojects.com

Download eBook