Skip to content

Tuning.py (AttributeError: 'array.array' object has no attribute 'tostring') #49

Description

@Retroman445

Running tuning.py gives me this error.

Traceback (most recent call last):
  File "tuning.py", line 197, in <module>
    main()
  File "tuning.py", line 181, in main
    print('{:24} {}'.format(name, dev.read(name)))
  File "tuning.py", line 109, in read
    response = struct.unpack(b'ii', response.tostring())
AttributeError: 'array.array' object has no attribute 'tostring'

Solved it by changing this line

response = struct.unpack(b'ii', response.tostring())

to this

response = struct.unpack(b'ii', response)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions