balena-labs-projects / balena-dash

Build a Raspberry Pi based desktop dashboard for stats, photos, videos and more!
https://balena.io/blog/make-a-web-frame-with-raspberry-pi-in-30-minutes/
MIT License
435 stars 137 forks source link

Cannot get balena dash fullscreen on 4K TV #146

Open janipewter opened 2 years ago

janipewter commented 2 years ago

Hi, I am trying to use balena dash on a Raspberry Pi 4 4GB to display a webpage. The Pi is connected to the TV (LG 55CX) via HDMI and no matter what I try I cannot get the kiosk to use the whole screen, it is always letterboxed. If I test on 1080p TV it works fine.

I have tested the webpage on other devices including another Pi 4 running standard Raspberry Pi OS and it works perfectly. Even on my laptop in Chrome development console switching between 1920x1080 and 3840x2160 I can see it working fine.

However balena will not go full screen. Even the splash logo is letterboxed. The TV says it is receiving 2160p30 signal from Pi which I expect and when I run tvservice -s it reports 3840x2160 30Hz" which I also expect.

No combination of setting WINDOW_SIZE or WINDOW_POSITION in device variables can fix this. It simply doesn't work.

I can't be the only person using a Balena Dash on a Pi 4 with a 4K TV???

Anyone have solution, would be appreciated. Thanks

janipewter commented 2 years ago
root@95171afdd7fd:/usr/src/app# tvservice -s
state 0xa [HDMI CEA (95) RGB lim 16:9], 3840x2160 @ 30.00Hz, progressive

But the kiosk window is letterboxed, looks like it might even be 4:3

I enabled show cursor and took it out of kiosk mode and I can't move beyond the sides of the browser window, so it looks like it's not outputting 3840 horizontal pixels at all, but the vertical still looks like 2160 pixels as the kiosk touches the top and bottom edges. The breakpoint is 3800 pixels and the kiosk is showing the sub-4K version so clearly balena is not getting the Pi's resolution correct

janipewter commented 2 years ago

20220213_221927

jordan-lumley commented 2 years ago

Also trying to solve this.. watching

Demitjev commented 2 years ago

I can tell that it works with the Generic x86 image on a standard pc with HDMI out. But I cannot for the love of god force it to work on Raspberry pi 4.

janipewter commented 2 years ago

I've given up on balena-dash now, it seems totally broken on Raspberry Pi.

I followed this instead: https://pimylifeup.com/raspberry-pi-kiosk/

oleye21 commented 2 years ago

This appears to work for me. Manually defining the custom CVT mode for the HDMI. Hardware: TCL 4-Series (3840x2160; 30fps) balena dashboard _ Fleets and 10 more pages - Work

[Define a custom CVT mode for the HDMI](): 3840 2160 30 0 0 0 0

mwl commented 2 years ago

I'm experiencing the exact same issue on a Samsung QM55R monitor. The tvservice sees a 4K monitor

$ tvservice -s
state 0xa [HDMI CEA (95) RGB lim 16:9], 3840x2160 @ 30.00Hz, progressive

which by my calculations is a 16:9 resolution, while X11 seems to prefer a 16:10 aspect ratio

$ cat /sys/class/graphics/fb0/modes
U:1920x1280p-0

Cable has been verified to be a HDMI 2.0 cable.

Defining a custom CVT mode at 3840 2160 30 0 0 0 0 makes no difference either.

mwl commented 2 years ago

Never mind. Upgraded balenaOS to version 2.94.4 which seem to have solved the issue completely.