Skip to content

Commit b54a8fc

Browse files
Managarmrrpgarg66
authored andcommitted
add ledger flex
The ledger flex product ids have been added to the remote-wallet crate.
1 parent c13ca2d commit b54a8fc

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

remote-wallet/src/ledger.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,11 @@ const LEDGER_NANO_S_PLUS_PIDS: [u16; 33] = [
5151
0x500b, 0x500c, 0x500d, 0x500e, 0x500f, 0x5010, 0x5011, 0x5012, 0x5013, 0x5014, 0x5015, 0x5016,
5252
0x5017, 0x5018, 0x5019, 0x501a, 0x501b, 0x501c, 0x501d, 0x501e, 0x501f,
5353
];
54+
const LEDGER_FLEX_PIDS: [u16; 33] = [
55+
0x0007, 0x7000, 0x7001, 0x7002, 0x7003, 0x7004, 0x7005, 0x7006, 0x7007, 0x7008, 0x7009, 0x700a,
56+
0x700b, 0x700c, 0x700d, 0x700e, 0x700f, 0x7010, 0x7011, 0x7012, 0x7013, 0x7014, 0x7015, 0x7016,
57+
0x7017, 0x7018, 0x7019, 0x701a, 0x701b, 0x701c, 0x701d, 0x701e, 0x701f,
58+
];
5459
const LEDGER_TRANSPORT_HEADER_LEN: usize = 5;
5560

5661
const HID_PACKET_SIZE: usize = 64 + HID_PREFIX_ZERO;
@@ -559,6 +564,7 @@ pub fn is_valid_ledger(vendor_id: u16, product_id: u16) -> bool {
559564
LEDGER_NANO_S_PIDS,
560565
LEDGER_NANO_X_PIDS,
561566
LEDGER_NANO_S_PLUS_PIDS,
567+
LEDGER_FLEX_PIDS,
562568
];
563569
vendor_id == LEDGER_VID && product_ids.iter().any(|pids| pids.contains(&product_id))
564570
}

0 commit comments

Comments
 (0)