Wire live serial data into matrix renderer

This commit is contained in:
lennlouisgeek
2026-05-20 01:23:02 +08:00
parent a7b617419d
commit d2c9fad556
18 changed files with 874 additions and 63 deletions

7
src/serial_core/codec.rs Normal file
View File

@@ -0,0 +1,7 @@
use crate::serial_core::error::CodecError;
use std::time::Instant;
pub trait Codec<F> {
fn decode(&mut self, input: &[u8], session_started_at: Instant) -> Result<Vec<F>, CodecError>;
fn encode(&self, frame: &F) -> Result<Vec<u8>, CodecError>;
}