'bytearray' object has no attribute 'encode'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-msp430-tools |
Fix Released
|
High
|
zsquareplusc |
Bug Description
I'm attempting to program an MSP430F1611 via 'msp430-bsl' and I'm receiving the following error:
$ msp430-bsl --invert-reset --invert-test --swap-reset-test --speed=38400 -r -e -P -p /dev/tty.
An error occurred:
'bytearray' object has no attribute 'encode'
Cleaning up after error...
$
Using 'msp430-bsl.py' from the 'historical' branch of mspgcc project works fine:
$ python msp430-bsl.py --swap-reset-test --invert-reset --invert-test --speed=38400 -c /dev/tty.
MSP430 Bootstrap Loader Version: 2.0
Mass Erase...
Transmit default password ...
Invoking BSL...
Transmit default password ...
Current bootstrap loader version: 1.61 (Device ID: f16c)
Changing baudrate to 38400 ...
Program ...
110 bytes programmed.
Reset device ...
$
I'm running the latest python-msp430-tools (commit 466), but I saw the same behavior on 444.
Any idea what I'm doing wrong or what could cause that error?
Related branches
Changed in python-msp430-tools: | |
assignee: | nobody → zsquareplusc (zsquareplusc) |
Changed in python-msp430-tools: | |
status: | Fix Committed → Fix Released |
Yes that was a bug introduced by internal changes to use "bytes" instead of strings to be compatible with python 3.x (2to3).
FYI: you get more detailed error messages with the "--debug" switch.