From 609f3b8eeda0f70ae50344c5c5570f10d4e06eed Mon Sep 17 00:00:00 2001 From: Dom Rodriguez Date: Sat, 17 Feb 2024 23:06:26 +0000 Subject: [PATCH] Move old `bestool` code to `src/oldbestool` This is part of the refactor. Signed-off-by: Dom Rodriguez --- {bestool => src/oldbestool}/.gitignore | 0 {bestool => src/oldbestool}/Cargo.lock | 0 {bestool => src/oldbestool}/Cargo.toml | 2 +- {bestool => src/oldbestool}/src/beslink/bootloader.rs | 0 {bestool => src/oldbestool}/src/beslink/errors.rs | 0 .../oldbestool}/src/beslink/helper_sync_and_load_programmer.rs | 0 {bestool => src/oldbestool}/src/beslink/memory_info.rs | 1 + {bestool => src/oldbestool}/src/beslink/message.rs | 0 {bestool => src/oldbestool}/src/beslink/mod.rs | 0 {bestool => src/oldbestool}/src/beslink/read_flash.rs | 0 {bestool => src/oldbestool}/src/beslink/reboot.rs | 0 {bestool => src/oldbestool}/src/beslink/sync.rs | 0 {bestool => src/oldbestool}/src/beslink/test_port.rs | 0 {bestool => src/oldbestool}/src/beslink/write_flash.rs | 0 {bestool => src/oldbestool}/src/cmds/list_ports.rs | 0 {bestool => src/oldbestool}/src/cmds/mod.rs | 0 {bestool => src/oldbestool}/src/cmds/read_image.rs | 0 {bestool => src/oldbestool}/src/cmds/serial_monitor.rs | 0 {bestool => src/oldbestool}/src/cmds/write_image.rs | 0 .../oldbestool}/src/cmds/write_image_then_monitor.rs | 0 {bestool => src/oldbestool}/src/main.rs | 0 {bestool => src/oldbestool}/src/serial_monitor/mod.rs | 0 {bestool => src/oldbestool}/src/serial_monitor/monitor.rs | 0 {bestool => src/oldbestool}/supply-chain/audits.toml | 0 {bestool => src/oldbestool}/supply-chain/config.toml | 0 {bestool => src/oldbestool}/supply-chain/imports.lock | 0 26 files changed, 2 insertions(+), 1 deletion(-) rename {bestool => src/oldbestool}/.gitignore (100%) rename {bestool => src/oldbestool}/Cargo.lock (100%) rename {bestool => src/oldbestool}/Cargo.toml (94%) rename {bestool => src/oldbestool}/src/beslink/bootloader.rs (100%) rename {bestool => src/oldbestool}/src/beslink/errors.rs (100%) rename {bestool => src/oldbestool}/src/beslink/helper_sync_and_load_programmer.rs (100%) rename {bestool => src/oldbestool}/src/beslink/memory_info.rs (99%) rename {bestool => src/oldbestool}/src/beslink/message.rs (100%) rename {bestool => src/oldbestool}/src/beslink/mod.rs (100%) rename {bestool => src/oldbestool}/src/beslink/read_flash.rs (100%) rename {bestool => src/oldbestool}/src/beslink/reboot.rs (100%) rename {bestool => src/oldbestool}/src/beslink/sync.rs (100%) rename {bestool => src/oldbestool}/src/beslink/test_port.rs (100%) rename {bestool => src/oldbestool}/src/beslink/write_flash.rs (100%) rename {bestool => src/oldbestool}/src/cmds/list_ports.rs (100%) rename {bestool => src/oldbestool}/src/cmds/mod.rs (100%) rename {bestool => src/oldbestool}/src/cmds/read_image.rs (100%) rename {bestool => src/oldbestool}/src/cmds/serial_monitor.rs (100%) rename {bestool => src/oldbestool}/src/cmds/write_image.rs (100%) rename {bestool => src/oldbestool}/src/cmds/write_image_then_monitor.rs (100%) rename {bestool => src/oldbestool}/src/main.rs (100%) rename {bestool => src/oldbestool}/src/serial_monitor/mod.rs (100%) rename {bestool => src/oldbestool}/src/serial_monitor/monitor.rs (100%) rename {bestool => src/oldbestool}/supply-chain/audits.toml (100%) rename {bestool => src/oldbestool}/supply-chain/config.toml (100%) rename {bestool => src/oldbestool}/supply-chain/imports.lock (100%) diff --git a/bestool/.gitignore b/src/oldbestool/.gitignore similarity index 100% rename from bestool/.gitignore rename to src/oldbestool/.gitignore diff --git a/bestool/Cargo.lock b/src/oldbestool/Cargo.lock similarity index 100% rename from bestool/Cargo.lock rename to src/oldbestool/Cargo.lock diff --git a/bestool/Cargo.toml b/src/oldbestool/Cargo.toml similarity index 94% rename from bestool/Cargo.toml rename to src/oldbestool/Cargo.toml index d5db8a2..00240f8 100644 --- a/bestool/Cargo.toml +++ b/src/oldbestool/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "bestool" +name = "oldbestool" version = "0.1.1" edition = "2021" diff --git a/bestool/src/beslink/bootloader.rs b/src/oldbestool/src/beslink/bootloader.rs similarity index 100% rename from bestool/src/beslink/bootloader.rs rename to src/oldbestool/src/beslink/bootloader.rs diff --git a/bestool/src/beslink/errors.rs b/src/oldbestool/src/beslink/errors.rs similarity index 100% rename from bestool/src/beslink/errors.rs rename to src/oldbestool/src/beslink/errors.rs diff --git a/bestool/src/beslink/helper_sync_and_load_programmer.rs b/src/oldbestool/src/beslink/helper_sync_and_load_programmer.rs similarity index 100% rename from bestool/src/beslink/helper_sync_and_load_programmer.rs rename to src/oldbestool/src/beslink/helper_sync_and_load_programmer.rs diff --git a/bestool/src/beslink/memory_info.rs b/src/oldbestool/src/beslink/memory_info.rs similarity index 99% rename from bestool/src/beslink/memory_info.rs rename to src/oldbestool/src/beslink/memory_info.rs index 8d7851b..1b940b1 100644 --- a/bestool/src/beslink/memory_info.rs +++ b/src/oldbestool/src/beslink/memory_info.rs @@ -14,6 +14,7 @@ pub fn query_memory_info(serial_port: &mut Box) -> Result<(), BE payload: vec![0x03, 0x01, 0x12], checksum: 0xC6, }; + send_message(serial_port, get_flash_id_cmd)?; let flash_id = sync(serial_port, MessageTypes::FlashCommand)?; send_message(serial_port, get_flash_unique_id_cmd)?; diff --git a/bestool/src/beslink/message.rs b/src/oldbestool/src/beslink/message.rs similarity index 100% rename from bestool/src/beslink/message.rs rename to src/oldbestool/src/beslink/message.rs diff --git a/bestool/src/beslink/mod.rs b/src/oldbestool/src/beslink/mod.rs similarity index 100% rename from bestool/src/beslink/mod.rs rename to src/oldbestool/src/beslink/mod.rs diff --git a/bestool/src/beslink/read_flash.rs b/src/oldbestool/src/beslink/read_flash.rs similarity index 100% rename from bestool/src/beslink/read_flash.rs rename to src/oldbestool/src/beslink/read_flash.rs diff --git a/bestool/src/beslink/reboot.rs b/src/oldbestool/src/beslink/reboot.rs similarity index 100% rename from bestool/src/beslink/reboot.rs rename to src/oldbestool/src/beslink/reboot.rs diff --git a/bestool/src/beslink/sync.rs b/src/oldbestool/src/beslink/sync.rs similarity index 100% rename from bestool/src/beslink/sync.rs rename to src/oldbestool/src/beslink/sync.rs diff --git a/bestool/src/beslink/test_port.rs b/src/oldbestool/src/beslink/test_port.rs similarity index 100% rename from bestool/src/beslink/test_port.rs rename to src/oldbestool/src/beslink/test_port.rs diff --git a/bestool/src/beslink/write_flash.rs b/src/oldbestool/src/beslink/write_flash.rs similarity index 100% rename from bestool/src/beslink/write_flash.rs rename to src/oldbestool/src/beslink/write_flash.rs diff --git a/bestool/src/cmds/list_ports.rs b/src/oldbestool/src/cmds/list_ports.rs similarity index 100% rename from bestool/src/cmds/list_ports.rs rename to src/oldbestool/src/cmds/list_ports.rs diff --git a/bestool/src/cmds/mod.rs b/src/oldbestool/src/cmds/mod.rs similarity index 100% rename from bestool/src/cmds/mod.rs rename to src/oldbestool/src/cmds/mod.rs diff --git a/bestool/src/cmds/read_image.rs b/src/oldbestool/src/cmds/read_image.rs similarity index 100% rename from bestool/src/cmds/read_image.rs rename to src/oldbestool/src/cmds/read_image.rs diff --git a/bestool/src/cmds/serial_monitor.rs b/src/oldbestool/src/cmds/serial_monitor.rs similarity index 100% rename from bestool/src/cmds/serial_monitor.rs rename to src/oldbestool/src/cmds/serial_monitor.rs diff --git a/bestool/src/cmds/write_image.rs b/src/oldbestool/src/cmds/write_image.rs similarity index 100% rename from bestool/src/cmds/write_image.rs rename to src/oldbestool/src/cmds/write_image.rs diff --git a/bestool/src/cmds/write_image_then_monitor.rs b/src/oldbestool/src/cmds/write_image_then_monitor.rs similarity index 100% rename from bestool/src/cmds/write_image_then_monitor.rs rename to src/oldbestool/src/cmds/write_image_then_monitor.rs diff --git a/bestool/src/main.rs b/src/oldbestool/src/main.rs similarity index 100% rename from bestool/src/main.rs rename to src/oldbestool/src/main.rs diff --git a/bestool/src/serial_monitor/mod.rs b/src/oldbestool/src/serial_monitor/mod.rs similarity index 100% rename from bestool/src/serial_monitor/mod.rs rename to src/oldbestool/src/serial_monitor/mod.rs diff --git a/bestool/src/serial_monitor/monitor.rs b/src/oldbestool/src/serial_monitor/monitor.rs similarity index 100% rename from bestool/src/serial_monitor/monitor.rs rename to src/oldbestool/src/serial_monitor/monitor.rs diff --git a/bestool/supply-chain/audits.toml b/src/oldbestool/supply-chain/audits.toml similarity index 100% rename from bestool/supply-chain/audits.toml rename to src/oldbestool/supply-chain/audits.toml diff --git a/bestool/supply-chain/config.toml b/src/oldbestool/supply-chain/config.toml similarity index 100% rename from bestool/supply-chain/config.toml rename to src/oldbestool/supply-chain/config.toml diff --git a/bestool/supply-chain/imports.lock b/src/oldbestool/supply-chain/imports.lock similarity index 100% rename from bestool/supply-chain/imports.lock rename to src/oldbestool/supply-chain/imports.lock