Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ body:
id: version
attributes:
label: drmcru version or commit
placeholder: "0.1.3 or commit hash"
placeholder: "0.1.4 or commit hash"
validations:
required: true
- type: textarea
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "drmcru"
version = "0.1.3"
version = "0.1.4"
edition = "2024"
rust-version = "1.87"
description = "Linux DRM/KMS custom resolution and EDID override utility"
Expand Down
27 changes: 21 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ yay -S drmcru-bin
```

Download the portable x86-64 binary from the
[latest release](https://github.com/ssupt/drmcru/releases/tag/v0.1.3):
[latest release](https://github.com/ssupt/drmcru/releases/tag/v0.1.4):

```sh
curl -LO https://github.com/ssupt/drmcru/releases/download/v0.1.3/drmcru-0.1.3-x86_64-unknown-linux-musl
curl -LO https://github.com/ssupt/drmcru/releases/download/v0.1.3/SHA256SUMS
curl -LO https://github.com/ssupt/drmcru/releases/download/v0.1.4/drmcru-0.1.4-x86_64-unknown-linux-musl
curl -LO https://github.com/ssupt/drmcru/releases/download/v0.1.4/SHA256SUMS
sha256sum -c --ignore-missing SHA256SUMS
chmod +x drmcru-0.1.3-x86_64-unknown-linux-musl
./drmcru-0.1.3-x86_64-unknown-linux-musl doctor
./drmcru-0.1.3-x86_64-unknown-linux-musl
chmod +x drmcru-0.1.4-x86_64-unknown-linux-musl
./drmcru-0.1.4-x86_64-unknown-linux-musl doctor
./drmcru-0.1.4-x86_64-unknown-linux-musl
```

The TUI and manual Export work on Linux systems that expose connectors through
Expand Down Expand Up @@ -100,6 +100,21 @@ new EDID mode appear.
- Base-block detailed timing descriptors
- Base-block standard timings
- CTA-861 extension detailed timing descriptors
- EDID 1.4 range-limits-only VRR descriptors (minimum and maximum refresh)

Choose **VRR range** or press `Shift+R` to edit an existing advertised range.
For example, change `24–120 Hz` to `40–120 Hz` when the monitor cannot operate
reliably below 40 Hz. Export or Install/Update the override and reboot to apply.
The editor preserves horizontal limits and other descriptor data and supports
whole Hz from 1 to 510. It requires a continuous-frequency EDID with an existing
range-limits-only descriptor, as used by Linux DRM for DisplayPort VRR. HDMI
FreeSync/Forum and DisplayID VRR blocks are currently read-only; the editor
does not add VRR support to a monitor that does not advertise it.

Export and Install/Update clear stereo flags from all base and CTA detailed
resolutions and repair the affected checksums. This also works when clearing
stereo flags is the only pending change. Sync polarity, interlace, physical
dimensions, and unrelated descriptors and extension data are preserved.

DisplayID Type I detailed timings are decoded and can be copied into an
editable EDID DTD. DisplayID blocks themselves are currently read-only.
Expand Down
8 changes: 4 additions & 4 deletions packaging/aur/drmcru-bin/.SRCINFO
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pkgbase = drmcru-bin
pkgdesc = Linux DRM/KMS custom resolution and EDID override utility
pkgver = 0.1.3
pkgver = 0.1.4
pkgrel = 1
url = https://github.com/ssupt/drmcru
arch = x86_64
Expand All @@ -10,11 +10,11 @@ pkgbase = drmcru-bin
optdepends = mkinitcpio: initramfs integration for automatic Apply/Uninstall
optdepends = limine: supported bootloader for automatic Apply/Uninstall
optdepends = limine-mkinitcpio: Limine entry regeneration on Omarchy-style systems
provides = drmcru=0.1.3
provides = drmcru=0.1.4
conflicts = drmcru
options = !strip
options = !debug
source_x86_64 = drmcru-0.1.3::https://github.com/ssupt/drmcru/releases/download/v0.1.3/drmcru-0.1.3-x86_64-unknown-linux-musl
sha256sums_x86_64 = 8507a68e93ab9846e31a7d90644b4307e3bf7198737f999db337163cc44fa29b
source_x86_64 = drmcru-0.1.4::https://github.com/ssupt/drmcru/releases/download/v0.1.4/drmcru-0.1.4-x86_64-unknown-linux-musl
sha256sums_x86_64 = 601fe35c1bc57a5d27828e782183fd244b777709e9b2412a55c09a67607a953b

pkgname = drmcru-bin
4 changes: 2 additions & 2 deletions packaging/aur/drmcru-bin/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

pkgname=drmcru-bin
_pkgname=drmcru
pkgver=0.1.3
pkgver=0.1.4
pkgrel=1
pkgdesc="Linux DRM/KMS custom resolution and EDID override utility"
arch=('x86_64')
Expand All @@ -19,7 +19,7 @@ optdepends=(
)
options=('!strip' '!debug')
source_x86_64=("${_pkgname}-${pkgver}::${url}/releases/download/v${pkgver}/${_pkgname}-${pkgver}-x86_64-unknown-linux-musl")
sha256sums_x86_64=('8507a68e93ab9846e31a7d90644b4307e3bf7198737f999db337163cc44fa29b')
sha256sums_x86_64=('601fe35c1bc57a5d27828e782183fd244b777709e9b2412a55c09a67607a953b')

package() {
install -Dm755 "${srcdir}/${_pkgname}-${pkgver}" "${pkgdir}/usr/bin/${_pkgname}"
Expand Down
24 changes: 16 additions & 8 deletions src/demo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ fn sample_edid() -> Result<Vec<u8>> {
base[21] = 60;
base[22] = 34;
base[23] = 120;
base[24] = 0x0a;
base[24] = 0x0b;
base[35] = 1 << 5;
base[36] = 1 << 3;
base[38..54].fill(0x01);
Expand All @@ -78,17 +78,16 @@ fn sample_edid() -> Result<Vec<u8>> {
base[offset..offset + 2].copy_from_slice(&encoded);
}

for (slot, timing) in [
timing_1440p(144.0),
timing_1440p(120.0),
timing_1080p(120.0),
]
.iter()
.enumerate()
for (slot, timing) in [timing_1440p(144.0), timing_1440p(120.0)]
.iter()
.enumerate()
{
let offset = 54 + slot * DTD_LEN;
base[offset..offset + DTD_LEN].copy_from_slice(&encode_detailed_timing(timing)?);
}
base[90..108].copy_from_slice(&[
0, 0, 0, 0xfd, 0, 48, 144, 30, 220, 60, 1, 10, 0, 0, 0, 0, 0, 0,
]);
write_name_descriptor(&mut base[108..126], "Example Display");
base[126] = 1;
repair_checksum(base);
Expand All @@ -100,6 +99,8 @@ fn sample_edid() -> Result<Vec<u8>> {
cta[4] = (2 << 5) | 4;
cta[5..9].copy_from_slice(&[0x80 | 16, 4, 64, 97]);
cta[9..9 + DTD_LEN].copy_from_slice(&encode_detailed_timing(&timing_1080p(60.0))?);
cta[9 + DTD_LEN..9 + 2 * DTD_LEN]
.copy_from_slice(&encode_detailed_timing(&timing_1080p(120.0))?);
repair_checksum(cta);

Ok(raw)
Expand Down Expand Up @@ -188,6 +189,13 @@ mod tests {
assert!(monitor.hyprland.as_ref().unwrap().serial.is_none());
assert!(edid.checksum_valid);
assert!(edid.cta_blocks[0].checksum_valid);
assert_eq!(
crate::edid::vrr_range(&edid.raw).unwrap(),
crate::edid::VrrRange {
min_hz: 48,
max_hz: 144
}
);
assert_eq!(edid.monitor_name.as_deref(), Some("Example Displ"));
}
}
Loading