Display HAT Mini (PIM589)

This is a placeholder topic for “Display HAT Mini” comments.

A spacious 2.0" (320 x 240) IPS LCD display for Raspberry Pi, with four buttons, an RGB LED and plenty of room for your projects!

Read more

2 Likes

Can’t get this to work. Seems there is a conflict between bullseye and bookworm python libraries. python3-spidev can’t be installed.

2 Likes

Hi @David41202. Good to have you on the forums. :slight_smile:

Are you using a package manager like PIP or apt-get to install spidev?
If so, would you mind pasting the command and error below?

2 Likes

sudo apt install python3-spidev

Reading package lists… Done

Building dependency tree… Done

Reading state information… Done

Some packages could not be installed. This may mean that you have

requested an impossible situation or if you are using the unstable

distribution that some required packages have not yet been created

or been moved out of Incoming.

The following information may help to resolve the situation:

The following packages have unmet dependencies:

python3-spidev : Depends: python3 (< 3.8) but 3.9.2-3 is to be installed

E: Unable to correct problems, you have held broken packages.

2 Likes

what’s going on?

Ah that’s super weird. That would suggest to me that the Raspberry PI foundations index’s are unaware of spidev and Python 3.9 in the distro you’re using.
You totally nailed it when you were talking about Bullseye and Bookworm having a conflict. :fire:

I found this post online that explains the problem well.

python3-spidev is pulled from https://archive.raspberrypi.org/ Bullseye repository, while python3 is pulled from http://raspbian.raspberrypi.org/ Bookworm repository. This is causing a conflict between versions now. Unfortunately there is still no Bookworm repository available from https://archive.raspberrypi.org/

It gets more interesting.
Just last night at 4:35pm Bullseye was updated in the Raspberry PI Index.
This is wild, but it might be that running sudo apt update magics your problem away. Unlikely, but give it a go?

downgrading to python 3.7

Depends: python3 (< 3.8) implies that if the version of python on the system is 3.7 the installer would be chill. You could install it here :slight_smile: => Python Release Python 3.7.0 | Python.org

using pip

Python’s personal package manager, pip, doesn’t query the Raspberry Pi Archives, instead querying it’s own rainbow tables of packages. It’s frustrating that the apt-get indexing isn’t working as intended, but if you use Pypi on this occasion you might find Spidev comes down without a problem.
pip install spidev

1 Like

You are correct. Using pip install spidev worked.
Now I have a picture of a cat on the screen, but I need to make it do what I want it to, which is to display some information which is written for an adafruit display hat. It is also st7789 so I hope I can tweak the code to get it working.
Thanks,
David

2 Likes

:confetti_ball: :balloon: :100: :dizzy: :cat: :sparkling_heart: :clap: :fireworks: :tada:

3 Likes

Hi David,

Glad to hear Pix got you all sorted out!
Keen to see what you make with the screen :smiley:

We’ll get these amazing notes added to the product page
Liam

2 Likes

Well I did get it working as a display for a DigiPi APRS node/decoder, but it was too unstable. Seemed to be a physical problem with the display.

Where can I find more information about this display. Is there a source of instructions to use all its features?

In the end I ordered some Adafruit screens which are known to work without code change.

1 Like

Hi David,

This is a Pimoroni HAT, I’ve attached their provided docs below for you and a link to the repo which has some examples available:

Here’s a link to Pimoroni’s product page over in the UK:

Thanks for that. The instability was related to the buttons. The application was using the same GPIO pins that the board uses for buttons and RGB LED, for other purposes. It is working again, but it doesn’t use the standard ST7789 python instruction set, so had to change a few words in the python file. Looks pretty on the pizero2W though!

David

1 Like