ILI9486 touchscreen image upside down, how to rotate it?

24 views
Skip to first unread message

Mike - W4HOO

unread,
Aug 13, 2026, 5:22:47 PM (5 days ago) Aug 13
to DigiPi
Hi Craig, all,  I just added the ILI9486 3.5" touchscreen 480x320 display to my Digipi running on a Pi5. The image looks great, but it is upside down. I remember a post where you said to edit these two files:

Screen rotation is fully accomplished by editing two files,
direwatch.py  (packet/aprs modes)
digibanner.py   (other modes)

Most of the other screens, e.g. ST7789 already have a "rotation=XX" in their section of those two files, but the ILI9486 doesn't have rotation= in it's section. 

How to I rotate the output to that screen so that is right side up?

Also, can anyone recommend resource to learn about how to enable that screen when I'm not running DigiPi?  I also use this machine to run SVXLink node on Debian Trixie.

Thanks in advance for any help!
Regards,
Mike

Mike - W4HOO

unread,
Aug 16, 2026, 3:51:13 PM (2 days ago) Aug 16
to DigiPi
SOLUTION FOUND: To rotate the DigiPi information screens on the Waveshare 3.5" ILI9486 display by 180 degrees (so it is right-side up in my application), update the origin parameter in your disp = ili9486.ILI9486(...) initialization block in each of the two files:  direwatch.py and digibanner.py

First, make the file system writeable with:
sudo remount.

Then use sudo nano filename (either of those below) to edit:

direwatch.py  (packet/aprs modes)
digibanner.py   (other modes)

default is: origin=ili9486.Origin.LOWER_RIGHT,
update to: origin=ili9486.Origin.UPPER_LEFT,

UPPER_LEFT flips it horizontally or vertically opposite to what I needed, you can also test these other origin settings supported by the library:
  • ili9486.Origin.UPPER_LEFT (180° rotation relative to LOWER_RIGHT)

  • ili9486.Origin.UPPER_RIGHT

  • ili9486.Origin.LOWER_LEFT

Save the changes in nano by pressing Ctrl + O, hitting Enter, and exit with Ctrl + X.

Just to be safe I used the SAVE CONFIGURATION button in the DigiPi, then restarted the DigiPi and voila!  The DigiPi info screen now displays right side up.

73 all, Mike

Reply all
Reply to author
Forward
0 new messages