mirror of
https://github.com/Proxmark/proxmark3.git
synced 2025-08-21 05:43:23 -07:00
fix "Sending bytes to proxmark failed" after BUTTON_PRESS()
This commit is contained in:
parent
1d04b933df
commit
6b34699adc
1 changed files with 10 additions and 17 deletions
|
@ -1483,25 +1483,18 @@ void __attribute__((noreturn)) AppMain(void) {
|
||||||
size_t rx_len;
|
size_t rx_len;
|
||||||
|
|
||||||
for(;;) {
|
for(;;) {
|
||||||
if (usb_poll()) {
|
|
||||||
rx_len = usb_read(rx, sizeof(UsbCommand));
|
|
||||||
if (rx_len) {
|
|
||||||
UsbPacketReceived(rx, rx_len);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
WDT_HIT();
|
WDT_HIT();
|
||||||
|
if (usb_poll() && (rx_len = usb_read(rx, sizeof(rx)))) {
|
||||||
#ifdef WITH_LF_StandAlone
|
UsbPacketReceived(rx, rx_len);
|
||||||
#ifndef WITH_ISO14443a_StandAlone
|
} else {
|
||||||
if (BUTTON_HELD(1000) > 0)
|
#if defined(WITH_LF_StandAlone) && !defined(WITH_ISO14443a_StandAlone)
|
||||||
SamyRun();
|
if (BUTTON_HELD(1000) > 0)
|
||||||
#endif
|
SamyRun();
|
||||||
#endif
|
|
||||||
#ifdef WITH_ISO14443a
|
|
||||||
#ifdef WITH_ISO14443a_StandAlone
|
|
||||||
if (BUTTON_HELD(1000) > 0)
|
|
||||||
StandAloneMode14a();
|
|
||||||
#endif
|
#endif
|
||||||
|
#if defined(WITH_ISO14443a) && defined(WITH_ISO14443a_StandAlone)
|
||||||
|
if (BUTTON_HELD(1000) > 0)
|
||||||
|
StandAloneMode14a();
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue