How to enable 4k/60hz on RPi4

  • I have RPi4 and RPi5. Everything is OK, but I can't set neither one to 2160p/60Hz.

    My TV accepts 4k @ 60Hz @ 4:4:4. I have no problem to sent 2160p/60Hz videos from my computer, but not from RPi because I can't set it to 60Hz.

    I found information in this forum that I should go to config.txt and add "hdmi_enable_4kp60=1", but I have no idea where to find config.txt I went to folder Configfiles, but can't find config.txt

    Can anyone help me? Thanks upfront.

  • I put it at the last line in config.txt. I tried :

    # hdmi_enable_4kp60=1, #hdmi_enable_4kp60=1 and hdmi_enable_4kp60=1

    Nothing. No 60Hz available. What I am doing wrong?

    Why 60 Hz is not available in the LibreELEC software? I installed 11.0.6

  • The following works for my Pi4 via ssh.
    --
    mount -o remount,rw /flash
    echo "hdmi_enable_4kp60=1" >> /flash/config.txt
    mount -o remount,ro /flash
    reboot
    --
    after the reboot i can choose 60hz via GUI as resolution in LibreElec.
    If you cant choose that, then "MatteN" might be right that your may be not using a HDMI-Cable that supports this resulution.

  • I put it at the last line in config.txt. I tried :

    # hdmi_enable_4kp60=1, #hdmi_enable_4kp60=1 and hdmi_enable_4kp60=1

    Nothing. No 60Hz available. What I am doing wrong?

    Why 60 Hz is not available in the LibreELEC software? I installed 11.0.6

    # before a statement = ignore what follows for the rest of the line. (It's how to put comments in the file, or quickly disable something during testing without deleting it)

    4k60 requires a higher quality cable as the video is carried at a higher speed and thus requires cables capable of carrying the higher bandwidth signal (Don't spend silly money - just buy one that is Premium Certified). 4K30 and below can be carried on older low-bandwidth cables.


    Also - if you have an Argon One case - that can cause all sorts of problem with 4K60 as the HDMI extenders aren't HDMI 2.0 friendly in many cases.

  • Did you enable "Ultra HD Deep Colour" in your TV's HDMI port settings? If not then the PC will likely use 4:2:0 to output 4kp60 and RPi4 will be limited to 4kp30 as it doesn't support 4:2:0.

    Please post the output of "edid-decode /sys/class/drm/card1-HDMI-A-1/edid" and "kmsprint -m"

    so long,

    Hias

  • # before a statement = ignore what follows for the rest of the line. (It's how to put comments in the file, or quickly disable something during testing without deleting it)

    I figured it out so I inserted just hdmi_enable_4kp60=1, without #

    4k60 requires a higher quality cable as the video is carried at a higher speed and thus requires cables capable of carrying the higher bandwidth signal (Don't spend silly money - just buy one that is Premium Certified). 4K30 and below can be carried on older low-bandwidth cables.

    Cable shouldn't prevent from setting 60Hz. (Later on I could have problems with picture when using low quality cable, I know). I tried four cables, different settings but finally I gave up. I will use computer for 60fps videos and RPis for other, lower fps videos and movies.

    Hopefully next version of LibreELEC will have 2160p/60Hz as standard (at least for RPi5) and tweaking Config.txt will not be required.

    Thanks for your help, guys.

  • Cable shouldn't prevent from setting 60Hz. (Later on I could have problems with picture when using low quality cable, I know). I tried four cables, different settings but finally I gave up. I will use computer for 60fps videos and RPis for other, lower fps videos and movies.

    Hopefully next version of LibreELEC will have 2160p/60Hz as standard (at least for RPi5) and tweaking Config.txt will not be required.

    Thanks for your help, guys.

    I have both Pi4 and Pi 5 running 4k 60hz.

  • Cable shouldn't prevent from setting 60Hz.

    That's not correct. If you increase HDMI data rate by using 60Hz, a bad cable can interrupt transmission. I suggest to check the standard of your HDMI cable. For 4K it has to have HDMI 2.0 or 2.1 standard.

  • Da Flex sorry, but Zygmunt is correct here. With an underspecced cable you'll get signal drop outs (down to no signal at all) but you should see 4kp60 listed in settings.

    Missing modes is usually caused by software/EDID issues, i.e. the AVR or TV isn't advertising the correct modes or the RPi4 hasn't been configured to 4kp60 in config.txt and thus won't use the mode, even if the TV/AVR advertises that capability.

    so long,

    Hias

  • Thanks HiassofT! We need a log to figure it out now...

    Please provide a full debug log.

    How to post a log (wiki)

    1. Enable debugging in Settings>System Settings>Logging
    2. Restart Kodi
    3. Replicate the problem
    4. Generate a log URL (do not post/upload logs to the forum)

    use "Settings > LibreELEC > System > Paste system logs" or run "pastekodi" over SSH, then post the URL link
  • Hopefully next version of LibreELEC will have 2160p/60Hz as standard (at least for RPi5) and tweaking Config.txt will not be required.

    RPi5 doesn't need any additional config.txt amendments, it already has full bandwidth HDMI on both ports.

  • Da Flex sorry, but Zygmunt is correct here. With an underspecced cable you'll get signal drop outs (down to no signal at all) but you should see 4kp60 listed in settings.

    Missing modes is usually caused by software/EDID issues, i.e. the AVR or TV isn't advertising the correct modes or the RPi4 hasn't been configured to 4kp60 in config.txt and thus won't use the mode, even if the TV/AVR advertises that capability.

    so long,

    Hias


    Yes - and if the TV (or TV input used) only supports 4K60 using 4:2:0 (*) then that will also limit the connections to 2160p30 and below - as the Pi 4B doesn't support 4:2:0 output (and neither does the Pi 5?) because of the requirement for chroma subsampling in two directions (not just one)

    (*) Some TVs - like my two previous Sonys - only support 'Enhanced HDMI' (i.e. 18Gbps modes like 4:2:2 12-bit 4K60) that is needed for 4K60 output from a Pi 4B on two of their HDMI ports (HDMI 2 and 3 on ours), with the other HDMI ports only accepting 4:2:0 at 2160p60 (HDMI 1 and 4). The Pi 4B was limited to 2160p30 on those two limited HDMI ports ISTR (as it was for ports HDMI 2 and 3 if the TV didn't have Enhanced HDMI enabled in settings) as you had to use a <18Gbs mode. Similarly our previous Denon AVR also had to have 'HDMI Enhanced' enabled in its settings to allow 4K60 4:2:2 (and 12-bit) to be accepted - and the front panel HDMI input didn't support it.

    If the TV or TV input is flagging 4:2:0-only via EDID for 4k60 (aka 2160p60) modes then that won't be offered as a resolution by LibreElec as it will know that the Pi4B doesn't support 4:2:0?

    Edited once, last by noggin (March 6, 2024 at 9:09 AM).

  • Hello everybody
    I couldn't leave this problem unsolved, so I returned to this thread to check for new info.
    Hiassoft, you inspired me to further investigation writing: "Did you enable "Ultra HD Deep Colour" in your TV's HDMI port settings? If not then the PC will likely use 4:2:0 to output 4kp60 and RPi4 will be limited to 4kp30 as it doesn't support 4:2:0."
    I couldn’t find "Ultra HD Deep Colour" in my Hisense 43A65H settings, but I checked display info on my PC (Intel N5105) and found that output is 2160p/60 YCbCr420. I couldn't find any info about color depth output from N5105.

    I connected PC to LG 32UL500-W, which has a maximum refresh rate of 60Hz on HDMI input. (HDMI 2.0). The max I could get was 2160p/60 YCbCr420.
    Where is a limit? In PC or LG monitor?
    Than I connected PC to Denon X7200WA (connected to old 6040UB projector) and got 2160p/60 YCbCr420. I didn't expect any better result because 6040UB doesn't accept signals over 2160p/60 YCbCr420.

    Now it is time for RPi4 and RPi5
    RPi4.
    I added "hdmi_enable_4kp60=1" to config.txt just after hdmi_ignore_cec_init=1
    After connecting to Hisense 43A65H, RPi4 didn't let me go over 30Hz.
    So there are questions:
    Does Hisense 43A65H really accept 2160/60 4:4:4 and 4:2:2? It does not. (Or there is EDID problem).

    Connected to LG 32UL500-W. RPi4 let me set 60Hz. It means that "hdmi_enable_4kp60=1" works, Hisense 43A65H has a problem with RPi and my PC can not send 2160/60 4:2:2 only 4:2:0.
    After connecting to Denon with projector OFF and only LG monitor connected, I could set RPi4 to 60Hz as well. It means that LG 32UL500-W accepts 4:2:2.

    Now RPi5
    After connecting to Hisense 43A65H, RPi5 didn't let me go over 30Hz exactly like RPi4.
    When connected to LG 32UL500-W, RPi5 let me go to 60Hz without a problem.
    I connected RPi5 to Denon/LG monitor. No picture at all. I replaced RPi5 by RPi4 - and there is a picture. I connected RPi5 - no picture. Weird. Why RPi4 works but RPi5 doesn't?

    In next step I was testing RPi4 and RPi5 connected directly to LG monitor. I could play my 2160p/60 fps videos H.265 smoothly, but 2160p/60 fps H.264 videos are choppy on both players.

    Last test - 1080p movies. Both players play 1080p H264 without a problem.
    RPi4 has a problem with 1080p VC-1, but RPi5 plays them smoothly.

    Thank you all of you for your help.

  • No idea on the 4K60 output issue, but:

    In next step I was testing RPi4 and RPi5 connected directly to LG monitor. I could play my 2160p/60 fps videos H.265 smoothly, but 2160p/60 fps H.264 videos are choppy on both players.

    RPi4 hardware decodes H264 and does not support media over 1080p resolution. RPi5 software decodes H264 and will play media over 1080p but H264 is less efficient than e.g. HEVC for the same resolution and H264/60fps/2160p media probbably exceeds the CPU limits of software decoding. Best solution: reencode that media to HEVC and it'll play nicely. Alternative solution: use a recent Intel Core i7 or better device which has the CPU grunt to cope with the non-standard format.

    Last test - 1080p movies. Both players play 1080p H264 without a problem.
    RPi4 has a problem with 1080p VC-1, but RPi5 plays them smoothly.

    That's expected. RPi4 and RPi5 software decode VC1, but only RPi5 has the CPU grunt needed for the task.