Skip to content

Commit

Permalink
Add explicit 'list' command to list detected probes
Browse files Browse the repository at this point in the history
  • Loading branch information
pdietl authored and andelf committed Feb 19, 2024
1 parent c8cffb7 commit 923ee08
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,8 @@ enum Commands {
#[arg(long)]
dap: bool,
},
/// List probes
List {},
/// SDI virtual serial port,
#[command(subcommand)]
SDIPrint(SDIPrint),
Expand Down Expand Up @@ -216,6 +218,9 @@ fn main() -> Result<()> {
WchLink::switch_from_dap_to_rv(device_index)?;
}
}
Some(List {}) => {
WchLink::list_probes()?;
}

Some(Erase { method }) if method != EraseMode::Default => {
// Special handling for non-default erase: bypass attach chip
Expand Down

0 comments on commit 923ee08

Please sign in to comment.