read 9 bytes

nik nikbaer at gmail.com
Mon Jun 11 05:52:28 CEST 2007


Hi,

I need to read a 9 byte response from a device on the serial port.
>From reading the pySerial documentation it appears that I can only
read in characters at a time.

If I do: serialport.read(4)
I would get 8 bytes, and if I did
serialport.read(5)
I think the port will block until a time out, since there

Is there a trick to read 9 bytes off of a serial port?

Thanks,
Nik




More information about the Python-list mailing list