X-Git-Url: http://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/bb4e6dbd62423f5e6907ee44de86b5a57a408d1e..2deb4b6b46ac7210984f5b3a6fc4c45b33ee8aea:/client/cmdlfem4x.c diff --git a/client/cmdlfem4x.c b/client/cmdlfem4x.c index 6b1fa883..66c4221a 100644 --- a/client/cmdlfem4x.c +++ b/client/cmdlfem4x.c @@ -152,7 +152,9 @@ int AskEm410xDecode(bool verbose, uint32_t *hi, uint64_t *lo ) if (Em410xDecode(BitStream, &BitLen, &idx, hi, lo)) { //set GraphBuffer for clone or sim command - setDemodBuf(BitStream, BitLen, idx); + setDemodBuf(DemodBuffer, (BitLen==40) ? 64 : 128, idx+1); + setClockGrid(g_DemodClock, g_DemodStartIdx + ((idx+1)*g_DemodClock)); + if (g_debugMode) { PrintAndLog("DEBUG: idx: %d, Len: %d, Printing Demod Buffer:", idx, BitLen); printDemodBuff(); @@ -703,6 +705,8 @@ bool EM4x05testDemodReadData(uint32_t *word, bool readCmd) { } setDemodBuf(DemodBuffer, 32, 0); + //setClockGrid(0,0); + *word = bytebits_to_byteLSBF(DemodBuffer, 32); } return true;