Debian Buster: HDMI Output Shifted Down

I just installed the official Debian image for the Radxa Zero onto the emmc. It boots and runs perfectly except for one annoying thing: The hdmi output seems shifted down a few pixels and there is a pale grey bar across the top of the screen (about 5 to 10 pixels) that I can’t seem to use. It’s like the screen boundaries start at the bottom of that bar, and the bottom of the screen seems clipped at the bottom. This happens no matter what monitor I have it plugged into.

Are there any suggestions on how to adjust the screen alignment? The screen I’d like to use this with has no adjustment buttons, so that’s not an option.

Thanks

Hi @mjasner, in my experience, you should be able to use the xrandr command to fine tune your display placement.

This site has a good overview of this command’s power and the references provide some more details:
https://clay-atlas.com/us/blog/2021/09/03/linux-en-xrandr-screen-resolution/

Hope this helps!

Thanks, I’ve been playing with xrandr all night. I got some results, but it just makes things odder…

I have 4 screens I tested with:

1 24 inch HDMI computer monitor
2 different Samsung TVs (both 21 inches)
2 7 inch HDMI displays (compatible with Raspberry pi)

The 24 inch monitor detects at 1920x1080 and works fine, no graphical issues of any kind.

Both Samsung TVs detect at 1366x768 and have the issue where, aside from being slightly shifted down, there is a Blue/Grey bar across the top 10 rows of pixels of the screen. If I use xrandr to move the screen up so the bottom of the desktop is properly visible then everything is fine except for the bar across the top of the screen that obscures the top 10 or so rows of pixels.

Both 7 inch displays detect at 1024x600 (which is correct for them) and the video is the same as the Samsung TVs (slightly offset and with the bar across the top. xrandr fixes the offset but the bar remains.)

If I change the resolution with the 7 inch displays to 1280x768 or 1920x1080 then the bar is not visible but at those resolutions on a 7 inch screen it’s not usable.

It’s almost as if the Radxa Zero only seems to behave correctly at either 720p or 1080p resolutions, nothing else. Any thoughts on that? Am I just being crazy?

I tried Debian, Ubuntu, and Armbian, all had the same result. The color of the bar changes with the color of the desktop, it seems, so it’s possibly some kind of corruption in the display buffer?

Ideally I’d like to use this with one of the 7 inch displays. I suppose if I had to I could probably tolerate the bar, or even possibly tolerate 1280x720 with a little bit of eye strain, but I’d really like to get it working correctly on this screen because I have a specific use in mind for it.

Thanks for any advice/input!

Hi @mjasner,

I’m thinking aloud here to see if it helps. Grain of salt recommended.

24" screen works as expected: likely indicates the issue isn’t hardware/buffer based otherwise we should expect it on all screens.

For the Samsungs, I would double-check the actual resolutions and make sure that matches what’s set. Again xrandr can help ensure you have the expected options in your Display Settings. We have an older LG and it uses the aforementioned 1366x768 ratio, which had to be added as an option to my X11 settings / window manager.

For the little screens, do they use a 60 Hz refresh rate? If not, that could explain why the bar matches the desktop color. Likely worth trying a similar aspect ratio either up or down to troubleshoot further:
https://en.wikipedia.org/wiki/List_of_common_resolutions

If you haven’t already, you may wish to reboot or shutdown and start up when connecting a new screen to your R0 to ensure the display negotiation is proceeding as it should.

Here’s to your weekend!

Thanks for the input. I suspect the 24 inch screen worked normally because it was detected as 1920x1080 and 1080p and 720p resolutions work fine on every screen I’ve tried. It’s when I try other resolutions that things don’t work 100%. And when I set the 7 inch screen to either 1280x720 or 1920x1080 then things are fine. I can try setting it to a different resolution on the 24 inch screen and see if the bar appears there.

The 7 inch screen’s preferred resolution is 1024x600 at 60Hz. The manual for the screen has the following settings it suggests adding to the config.txt file for Raspberry Pi:

hdmi_force_hotplug=1
max_usb_current=1
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
hdmi_cvt 1024 600 60 6 0 0 0
hdmi_drive=1

I’m not sure how to apply those settings to Ubuntu or Debian on the Radxa Zero though. I tried following the directions on https://wiki.radxa.com/Zero/hardware/display but that didn’t make any difference. After following those instructions I get the following output from xrandr:

rock@radxa-zero:~$ xrandr
Screen 0: minimum 320 x 200, current 1024 x 600, maximum 3840 x 2160
HDMI-1 connected primary 1024x600+0+0 (normal left inverted right x axis y axis) 255mm x 255mm
   1024x600_60.00  59.85*+
   1024x600      60.04 +
   1920x1080     60.00
   1600x900      60.00
   1360x768      59.95
   1280x720      60.00

I don’t know why it detects the default 1024x600 as 60.04 hertz and the new one (which I ran through the cvt command as 1024 600 60) as 59.85. I now suspect the frequency is the issue. The other three resolutions, which all show 60.00 as the refresh rate, work fine. I have to figure out a way to get that 59.85 to be 60. Do you know how to do that?

I think I might have made significant progress! Instead of using the cvt tool in the image I tried an online calculator and, after enabling the overscan adjustment of the calculator tool I ended up with the following Modeline:

Modeline "1024x600_60.00" 52.55 1024 1064 1176 1360 600 601 604 644 -HSync +Vsync

The only issue now is that the very top row of pixels seems to flicker/flash but you have to be looking direclty at the very top of the visible screen to see it. It’s a great improvement and if this is the best I can get it I’m fine with it, as long as that flickering row of pixels isn’t going to cause any long term wear and tear and/or damage to the screen!

Any thoughts on that? Otherwise I can start going ahead with the rest of my project! Yay!

Hi @mjasner, I’m glad you found the settings needed to get this working. I wonder if the top flicker/flash is backlight bleeding or a row of pixels that isn’t being used?

You could try moving things up by 1-2 rows to see if that eliminates the flicker/flash?

Either way, wishing you well on your project!

like this? https://youtu.be/wDgf-4yaZNQ