mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 13:23:51 -07:00
minor styleish
This commit is contained in:
parent
9d8cfd13a7
commit
c583570a3d
4 changed files with 8 additions and 5 deletions
|
@ -421,7 +421,8 @@ int ASKDemod_ext(const char *Cmd, bool verbose, bool emSearch, uint8_t askType,
|
||||||
|
|
||||||
bool st = false;
|
bool st = false;
|
||||||
size_t ststart = 0, stend = 0;
|
size_t ststart = 0, stend = 0;
|
||||||
if (*stCheck) st = DetectST(BitStream, &BitLen, &foundclk, &ststart, &stend);
|
if (*stCheck)
|
||||||
|
st = DetectST(BitStream, &BitLen, &foundclk, &ststart, &stend);
|
||||||
|
|
||||||
if (st) {
|
if (st) {
|
||||||
*stCheck = st;
|
*stCheck = st;
|
||||||
|
|
|
@ -1064,8 +1064,7 @@ bool detectPSK(){
|
||||||
// try manchester - NOTE: ST only applies to T55x7 tags.
|
// try manchester - NOTE: ST only applies to T55x7 tags.
|
||||||
bool detectASK_MAN(){
|
bool detectASK_MAN(){
|
||||||
bool stcheck = false;
|
bool stcheck = false;
|
||||||
int ans = ASKDemod_ext("0 0 0", false, false, 1, &stcheck);
|
if ( !ASKDemod_ext("0 0 0", false, false, 1, &stcheck) ) {
|
||||||
if (!ans) {
|
|
||||||
if (g_debugMode) PrintAndLog("DEBUG: Error - EM: ASK/Manchester Demod failed");
|
if (g_debugMode) PrintAndLog("DEBUG: Error - EM: ASK/Manchester Demod failed");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -106,7 +106,10 @@ int CmdNoralsyDemod(const char *Cmd) {
|
||||||
if (g_debugMode) PrintAndLog("DEBUG: Error - Noralsy: ASK/Manchester Demod failed");
|
if (g_debugMode) PrintAndLog("DEBUG: Error - Noralsy: ASK/Manchester Demod failed");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
if (!st) return 0;
|
if (!st) {
|
||||||
|
if (g_debugMode) PrintAndLog("DEBUG: Error - Noralsy: sequence terminator not found");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
size_t size = DemodBufferLen;
|
size_t size = DemodBufferLen;
|
||||||
int ans = detectNoralsy(DemodBuffer, &size);
|
int ans = detectNoralsy(DemodBuffer, &size);
|
||||||
|
|
|
@ -1050,7 +1050,7 @@ bool DetectST(uint8_t buffer[], size_t *size, int *foundclock, size_t *ststart,
|
||||||
// now do it again to find the end
|
// now do it again to find the end
|
||||||
int dummy1 = 0;
|
int dummy1 = 0;
|
||||||
end = skip;
|
end = skip;
|
||||||
i+=3;
|
i += 3;
|
||||||
if (!findST(&dummy1, &end, tmpbuff, waveLen, clk, tol, j, &i)) {
|
if (!findST(&dummy1, &end, tmpbuff, waveLen, clk, tol, j, &i)) {
|
||||||
//didn't find second ST - ERROR
|
//didn't find second ST - ERROR
|
||||||
if (g_debugMode==2) prnt("DEBUG STT: second STT not found - quitting");
|
if (g_debugMode==2) prnt("DEBUG STT: second STT not found - quitting");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue