Decodes an EDID, such as the one NanoKVMGo.Video.edid/1 returns: who made
the display it describes, its name and the modes it lists.
{:ok, edid} = NanoKVMGo.Video.edid()
{:ok, %{name: "NanoKVM-Go", modes: [%{width: 3840, height: 2160} | _]}} =
NanoKVMGo.EDID.decode(edid)The modes are the detailed timings of the base block and of CTA-861 extension blocks, the preferred mode first.
Summary
Functions
Decodes an EDID of one to four blocks with valid checksums.
Whether edid is an EDID: one to four blocks of 128 bytes, the first
with the EDID header, each with a valid checksum. NanoKVMGo.Video.set_edid/2
takes such an EDID.
Types
@type mode() :: %{ width: pos_integer(), height: pos_integer(), refresh: float(), pixel_clock_khz: pos_integer(), interlaced: boolean() }
A detailed timing.
@type t() :: %{ manufacturer: String.t(), product: non_neg_integer(), serial: non_neg_integer(), week: non_neg_integer(), year: pos_integer(), version: String.t(), name: String.t() | nil, modes: [mode()], extensions: non_neg_integer() }
Functions
Decodes an EDID of one to four blocks with valid checksums.
Whether edid is an EDID: one to four blocks of 128 bytes, the first
with the EDID header, each with a valid checksum. NanoKVMGo.Video.set_edid/2
takes such an EDID.