mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2026-09-09 09:35:48 +00:00
Fixed a bug in reading hitagU and hitagS on RDV4.
This commit is contained in:
@@ -272,10 +272,12 @@ uint16_t RAMFUNC GetLoEdgeCaptureCount(void) {
|
||||
}
|
||||
|
||||
lo_edge_t RAMFUNC GetLoEdgeCaptureStatus(void) {
|
||||
if (AT91C_BASE_TC1->TC_SR & INPUT_CAPTURE_EVT_RISING_EDGE) {
|
||||
// Read Once Only: Reading TC_SR will simultaneously clear status bits such as LDRAS/LDRBS.
|
||||
uint32_t sr = AT91C_BASE_TC1->TC_SR;
|
||||
if (sr & INPUT_CAPTURE_EVT_RISING_EDGE) {
|
||||
return LO_EDGE_RISING;
|
||||
}
|
||||
if (AT91C_BASE_TC1->TC_SR & INPUT_CAPTURE_EVT_FALLING_EDGE) {
|
||||
if (sr & INPUT_CAPTURE_EVT_FALLING_EDGE) {
|
||||
return LO_EDGE_FALLING;
|
||||
}
|
||||
return LO_EDGE_NO;
|
||||
|
||||
Reference in New Issue
Block a user