]> git.zerfleddert.de Git - proxmark3-svn/blame - client/cmdlfcotag.c
ADD: 'hf standalone 14a mode", added "mifare 4k" detection.
[proxmark3-svn] / client / cmdlfcotag.c
CommitLineData
4653da43 1//-----------------------------------------------------------------------------
2// Authored by Iceman
3//
4// This code is licensed to you under the terms of the GNU GPL, version 2 or,
5// at your option, any later version. See the LICENSE.txt file for the text of
6// the license.
7//-----------------------------------------------------------------------------
8// Low frequency COTAG commands
9//-----------------------------------------------------------------------------
10#include "cmdlfcotag.h" // COTAG function declarations
11
12static int CmdHelp(const char *Cmd);
13
14int CmdCOTAGRead(const char *Cmd) {
15
16// if (Cmd[0] == 'h' || Cmd[0] == 'H') return usage_lf_cotag_read();
17
507afbf3 18 CmdLFSetConfig("q 89");
19
4653da43 20 UsbCommand c = {CMD_COTAG, {0, 0, 0}};
21 clearCommandBuffer();
22 SendCommand(&c);
b828a4e1 23 if ( !WaitForResponseTimeout(CMD_ACK, NULL, 2500) ) {
bdf387c7 24 PrintAndLog("command execution time out");
b828a4e1 25 return 1;
26 }
507afbf3 27 getSamples("", true);
b828a4e1 28 return 0;
4653da43 29}
30
31static command_t CommandTable[] = {
32 {"help", CmdHelp, 1, "This help"},
33 {"read", CmdCOTAGRead, 0, "Attempt to read and extract tag data"},
34 {NULL, NULL, 0, NULL}
35};
36
37int CmdLFCOTAG(const char *Cmd) {
38 clearCommandBuffer();
39 CmdsParse(CommandTable, Cmd);
40 return 0;
41}
42
43int CmdHelp(const char *Cmd) {
44 CmdsHelp(CommandTable);
45 return 0;
46}
Impressum, Datenschutz