Pololu Robotics & Electronics
Menu
My account Comments or questions? About Pololu Contact Ordering information Distributors

Pololu Forum

Tic825 serial communication error

#1

I try to use example from “Tic Stepper Motor Controller User’s Guide”: [Example serial code in Python]
It finished with

File "slin.py", line 24, in exit_safe_start
    self.send_command(0x83)
  File "slin.py", line 20, in send_command
    self.port.write(header + list(data_bytes))
  File "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 475, in write
    n = os.write(self.fd, d)
TypeError: must be string or buffer, not list

HW: raspberry 3, OS: Jessie
Any idea what is wrong

#2

Hello.

We took a closer look at the write command for I/O objects in Python and realized that it its argument is not supposed to be a list. We fixed and updated code in the “Example serial code in Python” section of the Tic’s user’s guide.

- Amanda