X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/4653da43318d7b0ac4de7d313ee7c017af4914cb..16cfceb68966bb3022dee37f4c3f4f1bace3f9c5:/client/cmdlfcotag.c diff --git a/client/cmdlfcotag.c b/client/cmdlfcotag.c index e200e834..1a2b2eca 100644 --- a/client/cmdlfcotag.c +++ b/client/cmdlfcotag.c @@ -18,9 +18,12 @@ int CmdCOTAGRead(const char *Cmd) { UsbCommand c = {CMD_COTAG, {0, 0, 0}}; clearCommandBuffer(); SendCommand(&c); - - getSamples("20000", TRUE); - return CmdFSKdemodAWID(Cmd); + if ( !WaitForResponseTimeout(CMD_ACK, NULL, 2500) ) { + PrintAndLog("command execution time out"); + return 1; + } + getSamples("20000", true); + return 0; } static command_t CommandTable[] = {