First pass of Anime update for new matrix display

Co-authored with @I-Al-Istannen

Part of #189
This commit is contained in:
Luke D. Jones
2022-07-09 15:01:07 +12:00
parent a22808aff3
commit ff76c356c5
21 changed files with 734 additions and 1627 deletions

View File

@@ -13,6 +13,9 @@ pub enum AnimeError {
/// The input was incorrect size, expected size is `IncorrectSize(width, height)`
IncorrectSize(u32, u32),
Dbus(String),
Udev(String, std::io::Error),
NoDevice,
UnsupportedDevice,
}
impl fmt::Display for AnimeError {
@@ -30,6 +33,9 @@ impl fmt::Display for AnimeError {
width, height
),
AnimeError::Dbus(detail) => write!(f, "{}", detail),
AnimeError::Udev(deets, error) => write!(f, "udev {}: {}", deets, error),
AnimeError::NoDevice => write!(f, "No AniMe Matrix device found"),
AnimeError::UnsupportedDevice => write!(f, "Unsupported AniMe Matrix device found"),
}
}
}