Skip to content

Commit

Permalink
feat: use correct status word when device is locked
Browse files Browse the repository at this point in the history
  • Loading branch information
emmanuelm41 committed Oct 7, 2024
1 parent 4c78813 commit 682a66a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions ledger_device_sdk/src/io.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ pub enum StatusWords {
UserCancelled = 0x6e04,
Unknown = 0x6d00,
Panic = 0xe000,
DeviceLocked = 0x5515,
}

#[derive(Debug)]
Expand Down
2 changes: 1 addition & 1 deletion ledger_device_sdk/src/ui/gadgets.rs
Original file line number Diff line number Diff line change
Expand Up @@ -603,7 +603,7 @@ impl<'a> MultiPageMenu<'a> {
// pin lock management
let (_res, ins) = UxEvent::block_and_get_event::<Temp>(self.comm);
if let Some(_e) = ins {
self.comm.reply::<io::StatusWords>(io::StatusWords::Unknown);
self.comm.reply::<io::StatusWords>(io::StatusWords::DeviceLocked);
}
// notify Ticker event only when redisplay is required
return EventOrPageIndex::Event(io::Event::Ticker);
Expand Down

0 comments on commit 682a66a

Please sign in to comment.