this commit fixes #2244 #2246 #1596 #2101. Its kind of a big refactoring and I most likely broke something. With that said. Now: HF 15 commands now uses NG packets, hf 15 raw support -k keepfield on and -s select, hf 15 dump/rdbl/rdmulti should handle blocksizes of 4 or 8, the error messages are unified and error handling the same. Some understanding how add_option impacts response message from card. A more clear separation between PM3 flags and ISO15693 protocol flags.
This commit is contained in:
1 parent
224da75e7a
commit
8d0b41a911
11 files changed
+824
-544
No files matched your search
+7
-2
@@ -202,17 +202,22 @@ void ResetSspClk(void) {
|
||||
AT91C_BASE_TC2->TC_CCR = AT91C_TC_CLKEN | AT91C_TC_SWTRG;
|
||||
while (AT91C_BASE_TC2->TC_CV > 0);
|
||||
}
|
||||
|
||||
uint32_t RAMFUNC GetCountSspClk(void) {
|
||||
uint32_t tmp_count = (AT91C_BASE_TC2->TC_CV << 16) | AT91C_BASE_TC0->TC_CV;
|
||||
if ((tmp_count & 0x0000ffff) == 0) //small chance that we may have missed an increment in TC2
|
||||
|
||||
// small chance that we may have missed an increment in TC2
|
||||
if ((tmp_count & 0x0000ffff) == 0) {
|
||||
return (AT91C_BASE_TC2->TC_CV << 16);
|
||||
}
|
||||
return tmp_count;
|
||||
}
|
||||
|
||||
uint32_t RAMFUNC GetCountSspClkDelta(uint32_t start) {
|
||||
uint32_t stop = GetCountSspClk();
|
||||
if (stop >= start)
|
||||
if (stop >= start) {
|
||||
return stop - start;
|
||||
}
|
||||
return (UINT32_MAX - start) + stop;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user