mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-14 10:37:23 -07:00
Abort when Manchester goes wrong rather than outputting wrong values
This commit is contained in:
parent
52640422f1
commit
d2fb44710f
1 changed files with 4 additions and 0 deletions
|
@ -1538,6 +1538,10 @@ void ReaderHitag(hitag_function htf, hitag_data *htd) {
|
|||
// Pack the response into a byte array
|
||||
for (size_t i = 5; i < nrzs; i++) {
|
||||
uint8_t bit = nrz_samples[i];
|
||||
if (bit > 1) { // When Manchester detects impossible symbol it writes "7"
|
||||
//Dbprintf("Error in Manchester decoding, abort");
|
||||
break;
|
||||
}
|
||||
rx[rxlen / 8] |= bit << (7 - (rxlen % 8));
|
||||
rxlen++;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue