Hi,
I have a problem getting the eInk display "4687" to work (Rasppi Model B Plus 1.2)
While follow the instructions from:
https://learn.adafruit.com/2-13-in-e-ink-bonnet/usage
I always get the following error message:
(.venv) pi@pi2b:~/e-ink-bonnet_2_13 $ python3 example_1.py
Traceback (most recent call last):
File "/home/pi/e-ink-bonnet_2_13/example_1.py", line 4, in <module>
from adafruit_epd.epd import Adafruit_EPD
File "/home/pi/e-ink-bonnet_2_13/.venv/lib/python3.9/site-packages/adafruit_epd/epd.py", line 32, in <module>
class Adafruit_EPD: # pylint: disable=too-many-instance-attributes, too-many-public-methods, too-many-arguments
File "/home/pi/e-ink-bonnet_2_13/.venv/lib/python3.9/site-packages/adafruit_epd/epd.py", line 250, in Adafruit_EPD
def set_black_buffer(self, index: Union[0, 1], inverted: bool) -> None:
File "/usr/lib/python3.9/typing.py", line 268, in inner
return func(*args, **kwds)
File "/usr/lib/python3.9/typing.py", line 345, in __getitem__
return self._getitem(self, parameters)
File "/usr/lib/python3.9/typing.py", line 456, in Union
parameters = tuple(_type_check(p, msg) for p in parameters)
File "/usr/lib/python3.9/typing.py", line 456, in <genexpr>
parameters = tuple(_type_check(p, msg) for p in parameters)
File "/usr/lib/python3.9/typing.py", line 157, in _type_check
raise TypeError(f"{msg} Got {arg!r:.100}.")
TypeError: Union[arg, ...]: each arg must be a type. Got 0.
(.venv) pi@pi2b:~/e-ink-bonnet_2_13 $ head -4 example_1.py
import digitalio
import busio
import board
from adafruit_epd.epd import Adafruit_EPD
I searched for this error but didn't found anything ...
Also tried that on a fresh installation of a Raspberry Pi OS32 lite, but the same problem.
adafruit-circuitpython-epd python3.9 TypeError
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- mikeysklar
- Posts: 14194
- Joined: Mon Aug 01, 2016 8:10 pm
Re: adafruit-circuitpython-epd python3.9 TypeError
Thank you for providing the stack trace.
What version of the circuitpython EPD library are you running? The library has been updated 3x in the last two weeks. The current release is 2.11.3. The previous release 2.11.2 had been messing with the types and might have created an issue.
Use this to check your current library version:
It would be a good idea to try version 2.11.0 to see if it still works.
What version of the circuitpython EPD library are you running? The library has been updated 3x in the last two weeks. The current release is 2.11.3. The previous release 2.11.2 had been messing with the types and might have created an issue.
Use this to check your current library version:
Code: Select all
pip show adafruit-circuitpython-epd
Code: Select all
pip install adafruit-circuitpython-epd=2.11.0
- eAhxBf
- Posts: 3
- Joined: Fri Jun 02, 2023 4:36 am
Re: adafruit-circuitpython-epd python3.9 TypeError
Thank you.
Yes, it's version 2.11.3. :
(.venv) pi@pi2b:~/e-ink-bonnet_2_13 $ pip3 show adafruit-circuitpython-epd
Name: adafruit-circuitpython-epd
Version: 2.11.3
Summary: CircuitPython library for EPD e-ink displays.
Home-page: None
Author: None
Author-email: Adafruit Industries <[email protected]>
License: MIT
Location: /home/pi/e-ink-bonnet_2_13/.venv/lib/python3.9/site-packages
Requires: adafruit-circuitpython-framebuf, Adafruit-Blinka, adafruit-circuitpython-busdevice
Required-by:
and version 2.11.0 seems to work.
Yes, it's version 2.11.3. :
(.venv) pi@pi2b:~/e-ink-bonnet_2_13 $ pip3 show adafruit-circuitpython-epd
Name: adafruit-circuitpython-epd
Version: 2.11.3
Summary: CircuitPython library for EPD e-ink displays.
Home-page: None
Author: None
Author-email: Adafruit Industries <[email protected]>
License: MIT
Location: /home/pi/e-ink-bonnet_2_13/.venv/lib/python3.9/site-packages
Requires: adafruit-circuitpython-framebuf, Adafruit-Blinka, adafruit-circuitpython-busdevice
Required-by:
and version 2.11.0 seems to work.
- mikeysklar
- Posts: 14194
- Joined: Mon Aug 01, 2016 8:10 pm
Re: adafruit-circuitpython-epd python3.9 TypeError
Great. Thank you for confirming that 2.11.0 works.
The current release 2.11.3 does not work and 2.11.0 does so there are two in between releases.
Would you mind trying 2.11.1 and then 2.11.2 so we can see which release introduced the TypeError? I'd like to open an issue with the repo and maybe provide a path if we can narrow it down.
The current release 2.11.3 does not work and 2.11.0 does so there are two in between releases.
Would you mind trying 2.11.1 and then 2.11.2 so we can see which release introduced the TypeError? I'd like to open an issue with the repo and maybe provide a path if we can narrow it down.
Code: Select all
pip install adafruit-circuitpython-epd=2.11.1
Code: Select all
pip install adafruit-circuitpython-epd=2.11.2
- eAhxBf
- Posts: 3
- Joined: Fri Jun 02, 2023 4:36 am
Re: adafruit-circuitpython-epd python3.9 TypeError
Yes, I can do ...
2.11.1 is working.
With version 2.11.2 I get the error message.
2.11.1 is working.
With version 2.11.2 I get the error message.
- mikeysklar
- Posts: 14194
- Joined: Mon Aug 01, 2016 8:10 pm
Re: adafruit-circuitpython-epd python3.9 TypeError
I opened an issue with the library. Please, let me know if anything is missing.
- mikeysklar
- Posts: 14194
- Joined: Mon Aug 01, 2016 8:10 pm
Re: adafruit-circuitpython-epd python3.9 TypeError
That did not take long. Adafruit_CircuitPython_EPD v2.11.4 was released today with a type fix and the issue I had opened yesterday is now marked closed. So far so good. Can you confirm that it works with your 2.13” display?
I tried on my Pi4 rubber Bullseye 32-bit Desktop and had no issues with the import line.
I tried on my Pi4 rubber Bullseye 32-bit Desktop and had no issues with the import line.
Code: Select all
Successfully installed adafruit-circuitpython-epd-2.11.4 adafruit-circuitpython-framebuf-1.6.3
pi@kipi:~ $ python
Python 3.9.2 (default, Mar 12 2021, 04:06:34)
[GCC 10.2.1 20210110] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from adafruit_epd.epd import Adafruit_EPD
>>>
Please be positive and constructive with your questions and comments.