idea based on @jamchamb PR in official pm3 https://github.com/Proxmark/proxmark3/pull/584
This commit is contained in:
@@ -3,6 +3,7 @@ All notable changes to this project will be documented in this file.
|
||||
This project uses the changelog in accordance with [keepchangelog](http://keepachangelog.com/). Please use this to write notable changes, which is not the same as git commit log...
|
||||
|
||||
## [unreleased][unreleased]
|
||||
- 'hf mfu dumop / read' - now retries five times. (@jamchamb)
|
||||
- Added `hf list mf` - deciphers crypto1 stream and works with first authentication and weak nested authentications (@Merlok)
|
||||
- Adjusted `lf cmdread` to respond to client when complete and the client will then automatically call `data samples` (@marshmellow42)
|
||||
- Added a bitbang mode to `lf cmdread` if delay is 0 the cmd bits turn off and on the antenna with 0 and 1 respectively (@marshmellow42)
|
||||
|
||||
@@ -330,9 +330,9 @@ void MifareUReadCard(uint8_t arg0, uint16_t arg1, uint8_t arg2, uint8_t *datain)
|
||||
if (len) {
|
||||
if (MF_DBGLEVEL >= MF_DBG_ERROR) Dbprintf("Read block %d error",i);
|
||||
// if no blocks read - error out
|
||||
if (i==0){
|
||||
if (i == 0) {
|
||||
OnError(2);
|
||||
return;
|
||||
return;
|
||||
} else {
|
||||
//stop at last successful read block and return what we got
|
||||
break;
|
||||
|
||||
@@ -362,10 +362,9 @@ int mifare_ultra_readblockEx(uint8_t blockNo, uint8_t *blockData) {
|
||||
}
|
||||
int mifare_ultra_readblock(uint8_t blockNo, uint8_t *blockData) {
|
||||
#define MFU_MAX_CRC_RETRIES 5
|
||||
uint8_t retries = 0;
|
||||
uint8_t res;
|
||||
|
||||
for (retries = 0; retries < MFU_MAX_CRC_RETRIES; ++retries) {
|
||||
|
||||
for (uint8_t retries = 0; retries < MFU_MAX_CRC_RETRIES; ++retries) {
|
||||
res = mifare_ultra_readblockEx(blockNo, blockData);
|
||||
|
||||
// break if OK, or NACK.
|
||||
|
||||
Reference in New Issue
Block a user