Rock64Pro 4K video

I just got a Rock64Pro and installed DietPi on it. Boots up just fine, but the video is standard HD (1920x1080). I went into Control Centre and 4K resolution isn’t even listed in the Resolution drop down. Anyone have any suggestions on how I can get/enable 4K resolution?

The monitor is 4K, and Rock64 running DietPi operates in 4K mode. I’m using the Rock64Pro version of DietPi.



Here’s an update. I was able to find an article online which provided me with the following commands to switch to 4K mode:

xrandr --newmode “3840x2160” 338.75 3840 4080 4488 5136 2160 2163 2168 2200 -hsync +vsync
xrandr --addmode HDMI-1 “3840x2160”
xrandr --output HDMI-1 --mode “3840x2160”

When executed in Terminal, the system will switch to 4K resolution. And under Armbian Ubuntu, if I add those lines to ~/.profile, Ubuntu boots to 4K resolution. When I tried adding those lines to ~/.profile under DietPi (with MATE as the UI), it doesn’t work.

I’m guessing that with DietPi/MATE, I need to add those lines to a different file. Does anyone know which file I need to edit?

How do you login to MATE? Via auto login or LightDM login mask? If so with which user?

I am not 100% sure if xrandr needs to run within the X session or can be done beforehand, so in case it needs to be added either/and/or to both, /root/.profile and /home//.profile.