[SOLVED] Inkyphat not working

Hey there,

I just received a brand new inky phat yesterday and been trying to get it to work without success.

The inky phat arrived with the default logo on it (a bit pink instead of white compared to the photos of the previous version), and I plugged it into a Raspberry Pi Zero W. No matter what example I run it just doesn’t do anything, it hangs. When I try to stop the script with Ctrl+C the traceback is always in the same state:

^CTraceback (most recent call last):
  File "cal.py", line 166, in <module>
    inkyphat.show()
  File "/usr/lib/python3/dist-packages/inkyphat/__init__.py", line 113, in show
    _panel.update()
  File "/usr/lib/python3/dist-packages/inkyphat/inky212x104.py", line 193, in update
    self._display_init()
  File "/usr/lib/python3/dist-packages/inkyphat/inky212x104.py", line 102, in _display_init
    self.reset()
  File "/usr/lib/python3/dist-packages/inkyphat/inky212x104.py", line 238, in reset
    self._busy_wait()
  File "/usr/lib/python3/dist-packages/inkyphat/inky212x104.py", line 228, in _busy_wait
    while(GPIO.input(self.busy_pin) == GPIO.LOW):
KeyboardInterrupt
Shutting down display, please wait...

Then it stays at Shutting down until I Ctrl+C again.

I tried rebooting, made sure the Raspbian version was up to date, waited for one hour, tried executing the python steps on the command line and it’s always the same.

Am I missing something? is there any checks I may perform to identify the problem?

Jon ran into this problem yesterday, but I’m not 100% sure why it happens yet.

Could you run: lsb_release -a for me,
and also run dpkg -s python-inkyphat and let me know what it says in the “Version:” line.

Thanks for the super fast reply!

Glad I can help debugging the problem. Here’s the output of both commands:

lsb_release -a:

pi@raspberrypi:~ $ lsb_release -a
No LSB modules are available.
Distributor ID:	Raspbian
Description:	Raspbian GNU/Linux 8.0 (jessie)
Release:	8.0
Codename:	jessie

dpkg -s python-inkyphat:

pi@raspberrypi:~ $ dpkg -s python-inkyphat
Package: python-inkyphat
Status: install ok installed
Priority: extra
Section: python
Installed-Size: 504
Maintainer: Phil Howard <phil@pimoroni.com>
Architecture: all
Source: inkyphat
Version: 0.0.2
Depends: python-numpy, python-pil, python-rpi.gpio, python-spidev, python:any (<< 2.8), python:any (>= 2.7.5-5~)
Suggests: python-requests
Description: python library for the Pimoroni Inky pHAT
 Ideal for name badges or displaying statutes and notifications.
 .
 This is the Python 2 version of the package.
Homepage: https://github.com/pimoroni/inky-phat

Exactly what I’d suspected. I’m currently trying to figure out exactly why but Jessie seems stuck on version 0.0.2 via apt.

Try: sudo pip install --upgrade inkyphat

The other thing to try is to carefully unclip the ribbon cable on the back of the Inky pHAT and re-seat it. Slide your fingernail, or a thin plastic spudger under the clip and flip it open, then remove and re-insert the ribbon cable, then push the clip back down.

Other than that, you might see this behaviour if you haven’t updated the software, which needs to be done, for this new board. You can do that by typing sudo pip install --upgrade inkyphat in the terminal.

Recompiled everything and it’s now working! Thank you so much for all the help!

Yay! Glad that you’re up and running! \o/