Improve GUI plot workflow and performance

This commit is contained in:
2026-06-10 11:54:57 +08:00
parent 9b826d79da
commit 18bdd2652a
12 changed files with 989 additions and 217 deletions

View File

@@ -6,8 +6,8 @@ use tokio::time::timeout;
use xserial_core::frame::{
Endian, Framer,
cobs::cobs_encode as raw_cobs_encode,
cobs::CobsFramer,
cobs::cobs_encode as raw_cobs_encode,
fixed::FixedLengthFramer,
length::{LengthConfig, LengthPrefixedFramer},
line::{LineConfig, LineFramer},
@@ -298,10 +298,7 @@ async fn tcp_mixed_text_and_plot_single_stream() {
conn.disconnect().await.unwrap();
let decoder = MixedTextPlotDecoder::new(MixedTextPlotConfig::default());
let results: Vec<DecodedData> = frames
.iter()
.filter_map(|f| decoder.decode(f))
.collect();
let results: Vec<DecodedData> = frames.iter().filter_map(|f| decoder.decode(f)).collect();
assert_eq!(results.len(), 3);
assert!(matches!(&results[0], DecodedData::Text(s) if s == "status ok"));