sftool_lib/common/
reset.rs

1use crate::Result;
2use crate::common::ram_command::{Command, RamCommand};
3
4/// 通用的复位操作实现
5pub struct ResetOps;
6
7impl ResetOps {
8    /// 发送软件复位命令
9    pub fn soft_reset<T>(tool: &mut T) -> Result<()>
10    where
11        T: RamCommand,
12    {
13        tool.command(Command::SoftReset)?;
14        Ok(())
15    }
16}