X-Git-Url: http://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/40c6a02bc9b602885f2887c023e17a8559cc733c..dda5a928f0a598f21ee01396eae9b2c6da603f11:/common/lfdemod.c diff --git a/common/lfdemod.c b/common/lfdemod.c index f5fee22a..12511208 100644 --- a/common/lfdemod.c +++ b/common/lfdemod.c @@ -1759,6 +1759,10 @@ bool DetectST(uint8_t buffer[], size_t *size, int *foundclock) { for(i=0; i < clk/2-tol; ++i) { buffer[dataloc+i] = high+5; } + } //test for single sample outlier (high between two lows) in the case of very strong waves + if (buffer[dataloc] >= high && buffer[dataloc+2] <= low) { + buffer[dataloc] = buffer[dataloc+2]; + buffer[dataloc+1] = buffer[dataloc+2]; } for (i=0; i