#[non_exhaustive]pub enum CedWarning {
#[non_exhaustive] ChecksumMismatch {
expected: u8,
found: u8,
},
#[non_exhaustive] UnusedLaneReported {
count: CedCount,
},
}Expand description
A non-fatal anomaly in a CED read, returned with the decoded counters in
CedReading.
A warning does not withhold the counts: what to do about it, such as reading again or not trusting the counts, is the caller’s decision.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
#[non_exhaustive]ChecksumMismatch
The bytes the checksum covers do not sum to zero (mod 256). Most likely the read was torn: the sink updated a counter between two of its bytes. A sink whose checksum does not conform shows the same. A valid checksum is not proof of a consistent read either: an 8-bit sum misses a tear that leaves it unchanged.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
#[non_exhaustive]UnusedLaneReported
With HdmiLanes::Three, lane 3’s validity bit (0x58 bit 7) is set: the sink
reports a count for a lane not in use. CedCounters::lane3 stays None, as the
checksum does not cover it; the count is here.
Trait Implementations§
Source§impl Clone for CedWarning
impl Clone for CedWarning
Source§fn clone(&self) -> CedWarning
fn clone(&self) -> CedWarning
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CedWarning
Source§impl Debug for CedWarning
impl Debug for CedWarning
impl Eq for CedWarning
Source§impl PartialEq for CedWarning
impl PartialEq for CedWarning
impl StructuralPartialEq for CedWarning
Auto Trait Implementations§
impl Forget for CedWarning
impl Freeze for CedWarning
impl Move for CedWarning
impl RefUnwindSafe for CedWarning
impl Send for CedWarning
impl Sync for CedWarning
impl Unpin for CedWarning
impl UnsafeUnpin for CedWarning
impl UnwindSafe for CedWarning
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more