fix bug in st detect +

adjust nrz t55xx detection to reduce false positives on weak antennas
adjust t55xx read wait to get past initial startup wave.
This commit is contained in:
marshmellow42 2017-04-04 17:22:21 -04:00
commit bf85d22f96
4 changed files with 9 additions and 5 deletions

View file

@ -570,7 +570,7 @@ bool tryDetectModulation(){
}
}
clk = GetNrzClock("", false, false);
if (clk>0) {
if (clk>8) { //clock of rf/8 is likely a false positive, so don't use it.
if ( NRZrawDemod("0 0 1", false) && test(DEMOD_NRZ, &tests[hits].offset, &bitRate, clk, &tests[hits].Q5)) {
tests[hits].modulation = DEMOD_NRZ;
tests[hits].bitrate = bitRate;

View file

@ -150,7 +150,7 @@ int GetAskClock(const char str[], bool printAns, bool verbose)
start = DetectASKClock(grph, size, &clock, 20);
}
// Only print this message if we're not looping something
if (printAns) {
if (printAns || g_debugMode) {
PrintAndLog("Auto-detected clock rate: %d, Best Starting Position: %d", clock, start);
}
return clock;