+//-----------------------------------------------------------------------------
+// Copyright (C) 2010 iZsh <izsh at fail0verflow.com>
+//
+// This code is licensed to you under the terms of the GNU GPL, version 2 or,
+// at your option, any later version. See the LICENSE.txt file for the text of
+// the license.
+//-----------------------------------------------------------------------------
+// Data and Graph commands
+//-----------------------------------------------------------------------------
+
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int i, j, invert= 0;
int bit;
int clock;
- int lastval;
+ int lastval = 0;
int low = 0;
int high = 0;
int hithigh, hitlow, first;
int warnings = 0;
/* check if we're inverting output */
- if (*Cmd == 'i')
+ if (*(Cmd + 1) == 'i')
{
PrintAndLog("Inverting output");
invert = 1;
+ ++Cmd;
do
++Cmd;
while(*Cmd == ' '); // in case a 2nd argument was given