Kernel Update 5.4.51 breaks luma python library
Posted: Tue Sep 01, 2020 10:19 am
I have just tried to run a python program which uses the luma library to drive the dot matrix display.
I got an error similar to :
Turns out there is a problem with the spidev driver which was updated in 5.4.51 to fix a memory leak.
The advice was to revert the spidev driver back to a previous version with the following command :
I did this and now my python code is working again !
I got an error similar to :
Code: Select all
Traceback (most recent call last):
File "./matrix_demo.py", line 120, in <module>
demo(args.cascaded, args.block_orientation, args.rotate)
File "./matrix_demo.py", line 20, in demo
serial = spi(port=0, device=0, gpio=noop())
File "/usr/local/lib/python2.7/dist-packages/luma/core/interface/serial.py", line 281, in __init__
self._spi.cshigh = cs_high
SystemError: error return without exception set
The advice was to revert the spidev driver back to a previous version with the following command :
Code: Select all
pip3 install spidev==3.4 --force-reinstall