1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-16 04:29:08 +00:00
trezor-firmware/rust/trezor-client/examples/find.rs

12 lines
324 B
Rust
Raw Normal View History

2023-06-05 05:50:39 +00:00
fn main() {
let trezors = trezor_client::find_devices(false);
println!("Found {} devices: ", trezors.len());
for t in trezors.into_iter() {
println!("- {}", t);
{
let mut client = t.connect().unwrap();
println!("{:?}", client.initialize(None).unwrap());
}
}
}