I'm setting up my RaspberryPi 3 (Model B V1.2) to test the DotStarPiPainter.py code and I got this error:
Loading 'case.jpg'...
1300x2000 pixels
Resizing... now 1300x144 pixels
Traceback (most recent call last):
File "DotStarPiPainter.py", line 223, in <module>
scandir() # USB drive might already be inserted
File "DotStarPiPainter.py", line 142, in scandir
lightpaint = loadImage(imgNum) # Load first image
File "DotStarPiPainter.py", line 168, in loadImage
pixels = img.tostring()
File "/usr/lib/python2.7/dist-packages/PIL/Image.py", line 697, in tostring
"Please call tobytes() instead.")
NotImplementedError: tostring() has been removed. Please call tobytes() instead.
Changing the function img.tostring() to img.tobytes() will break the code?
Should I change the version of python (2.7) that I'm using?
I changed the function, ran the code again and got this:
I'm setting up my RaspberryPi 3 (Model B V1.2) to test the DotStarPiPainter.py code and I got this error:
Changing the function
img.tostring()
toimg.tobytes()
will break the code? Should I change the version of python (2.7) that I'm using?I changed the function, ran the code again and got this:
Apparently, it worked fine, but I'm not sure how this will affect the output to the LEDs...