diff --git a/src/device/etherdream.rs b/src/device/etherdream.rs index bd1a898..9a22922 100644 --- a/src/device/etherdream.rs +++ b/src/device/etherdream.rs @@ -169,18 +169,19 @@ impl Device for EtherdreamDevice { line: Vec, _speed: u32, ) -> LJResult<()> { - let chunk_size = 111; + let chunk_size = 512; let points_iter = line.into_iter(); for chunk in points_iter.as_slice().chunks(chunk_size) { debug!("New chunk length: {:?}", chunk.len()); + let capacity = self.points_capacity(); + debug!("capacity : {:?}", capacity); loop { - let capacity = self.points_capacity(); - debug!("capacity : {:?}", capacity); if chunk.len() > capacity as usize { debug!("Sleep"); // Sleep for 1/100th of a sec - sleep(Duration::new(0, 10_000_000)); - self.ping(); + sleep(Duration::new(0, 100_000_000)); + break; + // self.ping(); } else { break; }