X-Git-Url: http://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/f822a063b3c3efd970e6c24651de720e16d37a36..45dda9fcd7d47018c81a86688e2aaa63ba09d018:/client/cmddata.c diff --git a/client/cmddata.c b/client/cmddata.c index f10d7b53..d8a0fcf6 100644 --- a/client/cmddata.c +++ b/client/cmddata.c @@ -234,8 +234,9 @@ int Cmdaskmandemod(const char *Cmd) setGraphBuf(BitStream,BitLen); PrintAndLog("EM410x pattern found: "); printEM410x(lo); + return 1; } - if (BitLen>16) return 1; + //if (BitLen>16) return 1; return 0; } @@ -952,6 +953,15 @@ int CmdLtrim(const char *Cmd) RepaintGraphWindow(); return 0; } +int CmdRtrim(const char *Cmd) +{ + int ds = atoi(Cmd); + + GraphTraceLen = ds; + + RepaintGraphWindow(); + return 0; +} /* * Manchester demodulate a bitstream. The bitstream needs to be already in @@ -1342,13 +1352,14 @@ static command_t CommandTable[] = {"fskdemod", CmdFSKdemod, 1, "Demodulate graph window as a HID FSK"}, {"fskhiddemod", CmdFSKdemodHID, 1, "Demodulate graph window as a HID FSK using raw"}, {"fskiodemod", CmdFSKdemodIO, 1, "Demodulate graph window as an IO Prox FSK using raw"}, - {"fskrawdemod", CmdFSKrawdemod, 1, "[clock rate] [invert] Demodulate graph window from FSK to binary (clock = 64 or 50)(invert = 1 or 0)"}, + {"fskrawdemod", CmdFSKrawdemod, 1, "[clock rate] [invert] [rchigh] [rclow] Demodulate graph window from FSK to binary (clock = 50)(invert = 1 or 0)(rchigh = 10)(rclow=8)"}, {"grid", CmdGrid, 1, " -- overlay grid on graph window, use zero value to turn off either"}, {"hexsamples", CmdHexsamples, 0, " [] -- Dump big buffer as hex bytes"}, {"hide", CmdHide, 1, "Hide graph window"}, {"hpf", CmdHpf, 1, "Remove DC offset from trace"}, {"load", CmdLoad, 1, " -- Load trace (to graph window"}, {"ltrim", CmdLtrim, 1, " -- Trim samples from left of trace"}, + {"rtrim", CmdRtrim, 1, " -- Trim samples from right of trace"}, {"mandemod", CmdManchesterDemod, 1, "[i] [clock rate] -- Manchester demodulate binary stream (option 'i' to invert output)"}, {"manrawdecode", Cmdmandecoderaw, 1, "Manchester decode binary stream already in graph buffer"}, {"manmod", CmdManchesterMod, 1, "[clock rate] -- Manchester modulate a binary stream"},