chg: 'hf mf static' - now uses file on spiffs for key transfers. speedup on RDV4
This commit is contained in:
@@ -349,10 +349,15 @@ int flashmem_spiffs_load(uint8_t *destfn, uint8_t *data, size_t datalen) {
|
||||
bytes_sent += bytes_in_packet;
|
||||
|
||||
PacketResponseNG resp;
|
||||
if (!WaitForResponseTimeout(CMD_ACK, &resp, 2000)) {
|
||||
|
||||
uint8_t retry = 3;
|
||||
while (!WaitForResponseTimeout(CMD_ACK, &resp, 2000)) {
|
||||
PrintAndLogEx(WARNING, "timeout while waiting for reply.");
|
||||
ret_val = PM3_ETIMEOUT;
|
||||
break;
|
||||
retry--;
|
||||
if (retry == 0) {
|
||||
ret_val = PM3_ETIMEOUT;
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
|
||||
uint8_t isok = resp.oldarg[0] & 0xFF;
|
||||
@@ -363,6 +368,9 @@ int flashmem_spiffs_load(uint8_t *destfn, uint8_t *data, size_t datalen) {
|
||||
}
|
||||
}
|
||||
|
||||
out:
|
||||
clearCommandBuffer();
|
||||
|
||||
// turn off fast push mode
|
||||
conn.block_after_ACK = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user