How to change display on Pi Top 4?

Hello, I would like to add another option onto the menu of the mini screen display. This option would would be a folder in which code files will be stored and deployed off of from there. I essentially want to be able to customize what I see on the miniscreen menu from bootup and add folders if I want.

I’ve looked over the sdk documentation and there doesn’t seem to be a clear way to do this thru that. Also was confused on how you would go about using the sdk to make permanent changes to the pitop. For example, I can get the screen to print hello world but thats only when i actually run the program thru the sdk. How would I make that a permanent change wherein it would just be the default state of the screen?

The only other way I see of doing this is downloading the pi top os source code and manipulate the display code from there and then redeploy the os, with the new changes. This brings up another issue though. How do I test the code before redeploying it to make sure it works and functions how I want it to? Any thoughts on this are appreciated. I am just gettinf started with with raspberry pi and have around 6 months of coding experience so I am sure im missing things here. Any thoughts are welcome, thanks.

Hi @WiseImbecile,

There is official support for saving code projects to, and running them from, the OLED Miniscreen, similar to what you have suggested. That is the purpose of the ‘Projects’ section of the menu and there is a guide for how to use it here, as well as some related guides in the same Further course.

The SDK documentation does need to be improved to point to this and give some suggestions for your second question about how to make broader changes to the Miniscreen menu.

If you want to do more than is possible using the Projects menu, you would probably be looking at disabling the system miniscreen menu (systemd service called pt-miniscreen.service) and replacing it with your own version (a fork of the official one would be a good place to start of course). This would be a python application which you should generally be able to test by running it as normal with the system menu still active. The only special thing about the system miniscreen menu is the use of the PT_MINISCREEN_SYSTEM environment variable, which I won’t get into here but you could search for in the code.

One last thing I’ll mention is that there is a library within the SDK for creating advanced UIs with the miniscreen which is used for the system menu itself. See the readme and a previous discussion on that.