Ri0n

EDID Save

Dec 30th, 2025
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.18 KB | Help | 0 0
  1. TITLE: Save (dump) your CRT/TV EDID to a file in Batocera (with edid-decode)
  2.  
  3. Goal:
  4. Read the EDID from the GPU connector and save it to a file you can download.
  5. Then decode it with edid-decode to confirm it is correct.
  6.  
  7. This method uses /sys/class/drm which is the most reliable on modern Batocera/Linux.
  8.  
  9. --------------------------------------------------------------------
  10. STEP 0 - Open a terminal (SSH/PuTTY or local terminal)
  11. --------------------------------------------------------------------
  12. If using SSH:
  13. - Host: batocera (or your IP)
  14. - User: root
  15. - Password: linux (default)
  16.  
  17. You should see a prompt like:
  18. [root@BATOCERA ~]#
  19.  
  20. --------------------------------------------------------------------
  21. STEP 1 - List DRM connectors
  22. --------------------------------------------------------------------
  23. Run:
  24. ls /sys/class/drm/
  25.  
  26. You will see entries like:
  27. card0-DVI-D-1
  28. card0-HDMI-A-1
  29. card0-DP-1
  30. card0-eDP-1
  31. etc.
  32.  
  33. Note:
  34. The output name you need is usually the one you are using in Batocera’s video menu.
  35.  
  36. --------------------------------------------------------------------
  37. STEP 2 - Check which connector is connected
  38. --------------------------------------------------------------------
  39. Run:
  40. for c in /sys/class/drm/card*-*; do
  41. if [ -f "$c/status" ]; then
  42. echo "$(basename "$c"): $(cat "$c/status")"
  43. fi
  44. done
  45.  
  46. Look for the one that says:
  47. connected
  48.  
  49. Example:
  50. card0-DVI-D-1: connected
  51.  
  52. That is the connector you will use in STEP 4.
  53.  
  54. --------------------------------------------------------------------
  55. STEP 3 - Create a folder in SHARE (easy to find in WinSCP/SMB)
  56. --------------------------------------------------------------------
  57. Run:
  58. mkdir -p /userdata/system/edid
  59.  
  60. This folder is persistent and easy to download from.
  61.  
  62. --------------------------------------------------------------------
  63. STEP 4 - Dump EDID to a file (IMPORTANT: change connector name)
  64. --------------------------------------------------------------------
  65. Replace card0-DVI-D-1 with your connected connector from STEP 2.
  66.  
  67. Run:
  68. cat /sys/class/drm/card0-DVI-D-1/edid > /userdata/system/edid/hdcrt.edid
  69.  
  70. Important notes:
  71. - This command prints nothing on success. That is normal.
  72. - The file will be created in /userdata/system/edid/
  73.  
  74. --------------------------------------------------------------------
  75. STEP 5 - Sanity check the file size
  76. --------------------------------------------------------------------
  77. Run:
  78. ls -l /userdata/system/edid/hdcrt.edid
  79.  
  80. Typical sizes:
  81. - 128 bytes (base EDID only)
  82. - 256 bytes (EDID + 1 extension)
  83.  
  84. If size is 0 bytes:
  85. - The display might not be providing EDID
  86. - Or the adapter/converter might block EDID
  87. - Or you dumped from the wrong connector
  88.  
  89. --------------------------------------------------------------------
  90. STEP 6 - Decode the EDID (Batocera includes edid-decode)
  91. --------------------------------------------------------------------
  92. Run:
  93. edid-decode /userdata/system/edid/hdcrt.edid
  94.  
  95. You should see:
  96. - Vendor / manufacturer
  97. - Display name (sometimes)
  98. - Supported resolutions and refresh rates
  99. - Detailed timings (if present)
  100.  
  101. If edid-decode prints sensible info, the EDID dump is correct.
  102.  
  103. --------------------------------------------------------------------
  104. STEP 7 - Download the EDID file
  105. --------------------------------------------------------------------
  106. WinSCP:
  107. - Browse to: /userdata/system/edid/
  108. - Download: hdcrt.edid
  109.  
  110. Windows network share:
  111. - \\batocera\share\system\edid\
  112. - Copy: hdcrt.edid
  113.  
  114. --------------------------------------------------------------------
  115. Common mistakes / gotchas
  116. --------------------------------------------------------------------
  117. 1) "Nothing happened" after the cat command
  118. - That is normal. It writes to a file silently.
  119.  
  120. 2) "I cannot find hdcrt.edid"
  121. - If you used: > hdcrt.edid (without a path)
  122. then it saved to your current folder (often /root).
  123. - Use the full path used in STEP 4 to avoid that.
  124.  
  125. 3) STEP 2 failed
  126. - Make sure you pasted the entire loop including 'done'.
  127.  
  128. Done.
  129. You now have:
  130. - /userdata/system/edid/hdcrt.edid
  131. and you can verify it with:
  132. - edid-decode /userdata/system/edid/hdcrt.edid
  133. --------------------------------------------------------------------
  134.  
Advertisement
Add Comment
Please, Sign In to add comment