From 3e7f687e485144bd63fe464ff593ab9c8ac756d5 Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Thu, 9 Jan 2020 20:02:01 +0100 Subject: [PATCH] not verbose --- client/cmdlfawid.c | 2 +- client/cmdlffdx.c | 2 +- client/cmdlfgallagher.c | 2 +- client/cmdlfguard.c | 2 +- client/cmdlfhid.c | 2 +- client/cmdlfindala.c | 8 +++++--- client/cmdlfio.c | 2 +- client/cmdlfkeri.c | 2 +- client/cmdlfmotorola.c | 6 +++--- client/cmdlfnedap.c | 2 +- client/cmdlfnoralsy.c | 2 +- client/cmdlfpac.c | 2 +- client/cmdlfparadox.c | 2 +- client/cmdlfpresco.c | 2 +- client/cmdlfpyramid.c | 2 +- client/cmdlfsecurakey.c | 2 +- client/cmdlfviking.c | 2 +- client/cmdlfvisa2000.c | 2 +- client/cmdmain.c | 2 +- 19 files changed, 25 insertions(+), 23 deletions(-) diff --git a/client/cmdlfawid.c b/client/cmdlfawid.c index e9fe6d6e1..38c3675d1 100644 --- a/client/cmdlfawid.c +++ b/client/cmdlfawid.c @@ -333,7 +333,7 @@ static int CmdAWIDDemod(const char *Cmd) { // this read is the "normal" read, which download lf signal and tries to demod here. static int CmdAWIDRead(const char *Cmd) { - lf_read(true, 12000); + lf_read(false, 12000); return CmdAWIDDemod(Cmd); } diff --git a/client/cmdlffdx.c b/client/cmdlffdx.c index 06e45f515..2f3f81d1d 100644 --- a/client/cmdlffdx.c +++ b/client/cmdlffdx.c @@ -258,7 +258,7 @@ static int CmdFdxDemod(const char *Cmd) { } static int CmdFdxRead(const char *Cmd) { - lf_read(true, 10000); + lf_read(false, 10000); return CmdFdxDemod(Cmd); } diff --git a/client/cmdlfgallagher.c b/client/cmdlfgallagher.c index df822f24a..ef28f1326 100644 --- a/client/cmdlfgallagher.c +++ b/client/cmdlfgallagher.c @@ -135,7 +135,7 @@ static int CmdGallagherDemod(const char *Cmd) { } static int CmdGallagherRead(const char *Cmd) { - lf_read(true, 4096 * 2 + 20); + lf_read(false, 4096 * 2 + 20); return CmdGallagherDemod(Cmd); } diff --git a/client/cmdlfguard.c b/client/cmdlfguard.c index 79ec13c71..8597f4759 100644 --- a/client/cmdlfguard.c +++ b/client/cmdlfguard.c @@ -147,7 +147,7 @@ static int CmdGuardDemod(const char *Cmd) { } static int CmdGuardRead(const char *Cmd) { - lf_read(true, 10000); + lf_read(false, 10000); return CmdGuardDemod(Cmd); } diff --git a/client/cmdlfhid.c b/client/cmdlfhid.c index f5ad3717b..a41d183e7 100644 --- a/client/cmdlfhid.c +++ b/client/cmdlfhid.c @@ -255,7 +255,7 @@ static int CmdHIDDemod(const char *Cmd) { // this read is the "normal" read, which download lf signal and tries to demod here. static int CmdHIDRead(const char *Cmd) { - lf_read(true, 12000); + lf_read(false, 12000); return CmdHIDDemod(Cmd); } diff --git a/client/cmdlfindala.c b/client/cmdlfindala.c index c5c32d62d..11950a0c5 100644 --- a/client/cmdlfindala.c +++ b/client/cmdlfindala.c @@ -115,7 +115,7 @@ static void encodeHeden2L(uint8_t *dest, uint32_t cardnumber) { dest[i/8] = bytebits_to_byte(template + i, 8); } - PrintAndLogEx(INFO, "Heden2L Cardnumber %u ; RawID %s", cardnumber, sprint_hex(dest, 8)); + PrintAndLogEx(INFO, "Heden-2L card number %u", cardnumber); } static void decodeHeden2L(uint8_t *bits) { @@ -483,7 +483,7 @@ static int CmdIndalaDemodAlt(const char *Cmd) { // this read is the "normal" read, which download lf signal and tries to demod here. static int CmdIndalaRead(const char *Cmd) { - lf_read(true, 30000); + lf_read(false, 30000); return CmdIndalaDemod(Cmd); } @@ -601,8 +601,10 @@ static int CmdIndalaClone(const char *Cmd) { max = 8; } else { // 64 BIT UID - if (got_cn) + if (got_cn) { encodeHeden2L(data, cardnumber); + datalen = 8; + } // config for Indala 64 format (RF/32;PSK1 with RF/2;Maxblock=2) PrintAndLogEx(INFO, "Preparing to clone Indala 64bit tag with RawID %s", sprint_hex(data, datalen)); diff --git a/client/cmdlfio.c b/client/cmdlfio.c index b640bed41..1a25fca17 100644 --- a/client/cmdlfio.c +++ b/client/cmdlfio.c @@ -184,7 +184,7 @@ static int CmdIOProxDemod(const char *Cmd) { // this read is the "normal" read, which download lf signal and tries to demod here. static int CmdIOProxRead(const char *Cmd) { - lf_read(true, 12000); + lf_read(false, 12000); return CmdIOProxDemod(Cmd); } static int CmdIOProxSim(const char *Cmd) { diff --git a/client/cmdlfkeri.c b/client/cmdlfkeri.c index 394d16330..4846b5378 100644 --- a/client/cmdlfkeri.c +++ b/client/cmdlfkeri.c @@ -115,7 +115,7 @@ static int CmdKeriDemod(const char *Cmd) { } static int CmdKeriRead(const char *Cmd) { - lf_read(true, 10000); + lf_read(false, 10000); return CmdKeriDemod(Cmd); } diff --git a/client/cmdlfmotorola.c b/client/cmdlfmotorola.c index dbcf28e40..9f0ee1f41 100644 --- a/client/cmdlfmotorola.c +++ b/client/cmdlfmotorola.c @@ -124,8 +124,8 @@ static int CmdMotorolaRead(const char *Cmd) { // Motorola Flexpass seem to work at 74 kHz // and take about 4400 samples to befor modulating sample_config sc = { - .decimation = 0, - .bits_per_sample = 0, + .decimation = -1, + .bits_per_sample = -1, .averaging = false, .divisor = LF_FREQ2DIV(74), .trigger_threshold = -1, @@ -135,7 +135,7 @@ static int CmdMotorolaRead(const char *Cmd) { lf_config(&sc); // 64 * 32 * 2 * n-ish - lf_read(true, 5000); + lf_read(false, 5000); // reset back to 125 kHz sc.divisor = LF_DIVISOR_125; diff --git a/client/cmdlfnedap.c b/client/cmdlfnedap.c index 84b433a0c..c3d6d1ace 100644 --- a/client/cmdlfnedap.c +++ b/client/cmdlfnedap.c @@ -299,7 +299,7 @@ lf t55xx wr b 4 d 4c0003ff */ static int CmdLFNedapRead(const char *Cmd) { - lf_read(true, 16000); + lf_read(false, 16000); return CmdLFNedapDemod(Cmd); } diff --git a/client/cmdlfnoralsy.c b/client/cmdlfnoralsy.c index ceebb8e2d..d7728a3d9 100644 --- a/client/cmdlfnoralsy.c +++ b/client/cmdlfnoralsy.c @@ -133,7 +133,7 @@ static int CmdNoralsyDemod(const char *Cmd) { } static int CmdNoralsyRead(const char *Cmd) { - lf_read(true, 8000); + lf_read(false, 8000); return CmdNoralsyDemod(Cmd); } diff --git a/client/cmdlfpac.c b/client/cmdlfpac.c index 040c8af0a..63a3e16cd 100644 --- a/client/cmdlfpac.c +++ b/client/cmdlfpac.c @@ -181,7 +181,7 @@ static int CmdPacDemod(const char *Cmd) { } static int CmdPacRead(const char *Cmd) { - lf_read(true, 4096 * 2 + 20); + lf_read(false, 4096 * 2 + 20); return CmdPacDemod(Cmd); } diff --git a/client/cmdlfparadox.c b/client/cmdlfparadox.c index c154e7efa..29e247b59 100644 --- a/client/cmdlfparadox.c +++ b/client/cmdlfparadox.c @@ -126,7 +126,7 @@ static int CmdParadoxDemod(const char *Cmd) { //by marshmellow //see ASKDemod for what args are accepted static int CmdParadoxRead(const char *Cmd) { - lf_read(true, 10000); + lf_read(false, 10000); return CmdParadoxDemod(Cmd); } diff --git a/client/cmdlfpresco.c b/client/cmdlfpresco.c index abce377f4..a0619d794 100644 --- a/client/cmdlfpresco.c +++ b/client/cmdlfpresco.c @@ -100,7 +100,7 @@ static int CmdPrescoDemod(const char *Cmd) { //see ASKDemod for what args are accepted static int CmdPrescoRead(const char *Cmd) { // Presco Number: 123456789 --> Sitecode 30 | usercode 8665 - lf_read(true, 12000); + lf_read(false, 12000); return CmdPrescoDemod(Cmd); } diff --git a/client/cmdlfpyramid.c b/client/cmdlfpyramid.c index a36bd34e3..5737c87b9 100644 --- a/client/cmdlfpyramid.c +++ b/client/cmdlfpyramid.c @@ -209,7 +209,7 @@ static int CmdPyramidDemod(const char *Cmd) { } static int CmdPyramidRead(const char *Cmd) { - lf_read(true, 15000); + lf_read(false, 15000); return CmdPyramidDemod(Cmd); } diff --git a/client/cmdlfsecurakey.c b/client/cmdlfsecurakey.c index 48ec731ce..ef4b5be8e 100644 --- a/client/cmdlfsecurakey.c +++ b/client/cmdlfsecurakey.c @@ -125,7 +125,7 @@ static int CmdSecurakeyDemod(const char *Cmd) { } static int CmdSecurakeyRead(const char *Cmd) { - lf_read(true, 8000); + lf_read(false, 8000); return CmdSecurakeyDemod(Cmd); } diff --git a/client/cmdlfviking.c b/client/cmdlfviking.c index c404b4f0a..69d8aee65 100644 --- a/client/cmdlfviking.c +++ b/client/cmdlfviking.c @@ -79,7 +79,7 @@ static int CmdVikingDemod(const char *Cmd) { //by marshmellow //see ASKDemod for what args are accepted static int CmdVikingRead(const char *Cmd) { - lf_read(true, 10000); + lf_read(false, 10000); return CmdVikingDemod(Cmd); } diff --git a/client/cmdlfvisa2000.c b/client/cmdlfvisa2000.c index 677562e12..551a1efbb 100644 --- a/client/cmdlfvisa2000.c +++ b/client/cmdlfvisa2000.c @@ -159,7 +159,7 @@ static int CmdVisa2kDemod(const char *Cmd) { // 64*96*2=12288 samples just in case we just missed the first preamble we can still catch 2 of them static int CmdVisa2kRead(const char *Cmd) { - lf_read(true, 20000); + lf_read(false, 20000); return CmdVisa2kDemod(Cmd); } diff --git a/client/cmdmain.c b/client/cmdmain.c index 06f44e1aa..c2364d8f1 100644 --- a/client/cmdmain.c +++ b/client/cmdmain.c @@ -94,7 +94,7 @@ static int CmdAuto(const char *Cmd) { PrintAndLogEx(INFO, "Trying 'lf read' and save a trace for you..."); CmdPlot(""); - lf_read(true, 40000); + lf_read(false, 40000); char *fname = calloc(100, sizeof(uint8_t)); AppendDate(fname, 100, "f lf_unknown_%Y-%m-%d_%H:%M"); CmdSave(fname);