framesmith 0.1.0

A Rust library for controlling Samsung Frame TVs over the local network
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum DisplayRotation {
    Landscape,
    Portrait,
    Unknown,
}

impl DisplayRotation {
    pub fn from_value(value: u16) -> Self {
        match value {
            0 => Self::Landscape,
            90 | 270 => Self::Portrait,
            _ => Self::Unknown,
        }
    }
}