Pyserial question

Diez B. Roggisch nospam-deets at web.de
Mon Jan 5 10:09:56 EST 2004


Hi,

> I am using Pyserial to work with a RS232 device.  My question is, how do I
> write hex to the device or cannot write hex to it pyserial?

Look into the module struct - it will allow you to convert arbitrary data to
strings representing this data as binary string. Then you simply write that
to the serial connection. Reading is the same. I used that sucessfully for
a Vernier LabPro.

Regards,

Diez



More information about the Python-list mailing list