From 631f140c48f047d1a2042ed80ea163a4cbb2c1c0 Mon Sep 17 00:00:00 2001 From: Mateusz Faderewski Date: Sun, 21 Jul 2024 12:19:03 +0200 Subject: [PATCH] [SC64][SW] Adjust buffer sizes in sc64deployer to tune for maximum transfer speed --- sw/deployer/src/sc64/ftdi.rs | 2 +- sw/deployer/src/sc64/mod.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sw/deployer/src/sc64/ftdi.rs b/sw/deployer/src/sc64/ftdi.rs index 38574de..782dfc1 100644 --- a/sw/deployer/src/sc64/ftdi.rs +++ b/sw/deployer/src/sc64/ftdi.rs @@ -486,7 +486,7 @@ impl FtdiDevice { wrapper.set_module_detach_mode(ModuleDetachMode::AutoDetachReattach); wrapper.set_interface(InterfaceIndex::A)?; - const CHUNK_SIZE: usize = 2 * 1024 * 1024; + const CHUNK_SIZE: usize = 1 * 1024 * 1024; wrapper.read_data_set_chunksize(CHUNK_SIZE)?; wrapper.write_data_set_chunksize(CHUNK_SIZE)?; diff --git a/sw/deployer/src/sc64/mod.rs b/sw/deployer/src/sc64/mod.rs index 9a8064c..181db2f 100644 --- a/sw/deployer/src/sc64/mod.rs +++ b/sw/deployer/src/sc64/mod.rs @@ -101,7 +101,7 @@ const ISV_BUFFER_LENGTH: usize = 64 * 1024; pub const MEMORY_LENGTH: usize = 0x0500_2980; -const MEMORY_CHUNK_LENGTH: usize = 1 * 1024 * 1024; +const MEMORY_CHUNK_LENGTH: usize = 8 * 1024 * 1024; impl SC64 { fn command_identifier_get(&mut self) -> Result<[u8; 4], Error> {