7 Colour E-Ink Display For Raspberry Pi | Inky Impression 5.7" (7 Colour ePaper/eInk HAT)

Hi Sean,

Looks like I was barking up the wrong tree then.

The only other thing I can think of is file ownership, i.e. the user the script is running as, doesn’t have permissions to access hardware peripherals.

Would it work to try and run it via rc.local instead? Apparently that will run it as root, and it doesn’t get any better than that.
https://forums.raspberrypi.com//viewtopic.php?f=63&t=46125

2 Likes

In the terminal, I typed sudo mousepad /etc/rc.local to edit it
I added
/home/pi/inky/examples/7color/html.sh /home/pi/inky/examples/7color/hello-world.html
and it did something interesting. It created a new screenshot in the filesystem root folder /screenshot.png with the content that I want to display.
It didn’t put it on the e-ink display, but it did something, which was the lightbulb moment! That image.py it references didn’t know where that picture was and therefore couldn’t run.
I edited the last line of html.sh to
/home/pi/examples/7color/image.py /screenshot.png
and it works perfectly!!

Thank you so much James(!!!) for your help in getting this going, and I will share the final project once its finished.

2 Likes

Oh yes! (sory for the late reply) I saw this one a while back and it’s the PERFECT size for my art. Upscaling the art I make comes out to the exact same height of 480. I’m actually waiting on a photoframe made using that screen. I’m looking forward to displaying multiple art pieces! :smiley:

Hi Oretal,

That’s super great to hear! Glad to see we could help, and it’s nice to know it’s all working out a few months on.

Cheers,
Sophia

Hi - I really like the colors you achieved with your code. Is there a way I can use this for the inky frame? It uses the same screen, but with a picow, so it uses Thonny to communicate with the screen.

2 Likes

Hi Val,

Looks like the image example script doesn’t provide a saturation option (processing images is hard work, probably beyond a Pico), so I would up the saturation in paint.NET or GIMP before transferring it to the Pico.

2 Likes

When I run “python3 run-on-boot.py”, I get “Detected 7-Colour (UC8159)
Usage:
image.py --file image.png (–saturation 0.5)”
Has the image.py command changed?

Thanks,

Dave

1 Like

Hi David,

Welcome to the forum! When running python3 run-on-boot.py you will need to specify your file path. Have you done this? Which Pi and OS are you using as well?

Raspberry Pi 3 Model A Plus Rev 1.0, 512MB
Linux version 6.6.56-v8+ (dom@buildbot) (aarch64-linux-gnu-gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0

Yes, I specify file path and still get the error.

My bad, I had added extensions to all the numbered files.

Dave

1 Like

Hi David,

No worries, I find forums can serve as rubber duck debugging sometimes. Glad its working now, let us know if you run into any other issues.

1 Like

Insightful.

1 Like

I have set up a new RPi in a venv and followed the directions as per your instructions and also those on PyPi. I get this error when trying to update the display:
“Woah there, some pins we need are in use!
:warning: Chip Select: (line 8, GPIO8) currently claimed by spi0 CS0”
There is a thread on the pimoroni site addressing the issue, but with no clear solution. There is a suggestion you have to play with the config file, but this worked for one person, and not for another.
I feel that (if something extra has to be done) why the information is not provided by the Inky vendors; the onus is on them to provide clear details as to what has to be done to make their product work! What I’m trying to do is simple, i.e. display an image on the screen, and whilst I admit I am a relative beginner, I just don’t think it has to be so hard!!
Any thoughts?
David

Hey @David197028,

I have done some light research into this and it seems like the solution of adding the line dtoverlay=spi0-0cs to the bottom of the config.txt file (located at /boot/firmware/config.txt on bookworm) seems to fix this issue for most users.

The post I have found that don’t have success with the method seem to have at least moved on to a different error message after making this change so if you haven’t already, I would give this a shot and see if it helps out!

Let us know how that goes for you and we can help out with any other problems that pop up :slight_smile:

Hi Sam,
Thanks! Reinforcing my idea that the RPi is proving to be a bizarre hobby, that line was already the last in my config file on starting up the RPi again! I absolutely did not put it there!! But suffice to say that after giving my code one last go, I have now successfully refreshed the image on the inky display!
Cheers, David

2 Likes

Hey @David197028,

That’s great to hear! Sometimes a reboot is all you need to fix a weird issue like this.

Let us know if you run into any other troubles. Best of luck with your future projects! :slight_smile: