Crates.io | liboptic_edid |
lib.rs | liboptic_edid |
version | 0.1.0 |
source | src |
created_at | 2024-11-10 08:14:24.117577 |
updated_at | 2024-11-10 08:14:24.117577 |
description | Parses EDIDs from raw bytes (in 100% Rust) |
homepage | |
repository | https://github.com/onkoe/liboptic |
max_upload_size | |
id | 1442726 |
size | 165,757 |
liboptic_edid
A library crate to parse EDID information.
Currently, this uses EDID v1.4 and does not account for any incompatbilities with earlier versions. However, after running against around 100k EDIDs, there are only about 5% failing to parse, and no panics.
The only significant type in the library is Edid
. Call Edid::new()
with your EDID in bytes to get it parsed!
use liboptic_edid::Edid;
// grab the edid file from disk
let data = std::fs::read("tests/assets/dell_s2417dg.raw.input")?;
// and load it into the parser
let parsed_edid = Edid::new(&data)?;
assert_eq!(parsed_edid.checksum, 0x51);
This crate is #![no_std]
but still depends on alloc
while pisserror
does. When I get around to fixing that, that requirement will be dropped. :)