]> git.zerfleddert.de Git - proxmark3-svn/blobdiff - armsrc/appmain.c
fix temp changes
[proxmark3-svn] / armsrc / appmain.c
index aa70e677e7a1cef51e2414085be26301488e8786..f2ae56d850e9ee15173004ca75656c506a968525 100644 (file)
@@ -171,7 +171,7 @@ static int ReadAdc(int ch)
        return d;
 }
 
        return d;
 }
 
-static int AvgAdc(int ch)
+int AvgAdc(int ch) // was static - merlok
 {
        int i;
        int a = 0;
 {
        int i;
        int a = 0;
@@ -694,6 +694,45 @@ void UsbPacketReceived(uint8_t *packet, int len)
                        break;
 #endif
 
                        break;
 #endif
 
+#ifdef WITH_ISO14443a
+               case CMD_MIFARE_READBL:
+                       MifareReadBlock(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_READSC:
+                       MifareReadSector(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_WRITEBL:
+                       MifareWriteBlock(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_NESTED:
+                       MifareNested(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_CHKKEYS:
+                       MifareChkKeys(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_SIMULATE_MIFARE_CARD:
+                       Mifare1ksim(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               
+               // emulator
+               case CMD_MIFARE_SET_DBGMODE:
+                       MifareSetDbgLvl(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_EML_MEMCLR:
+                       MifareEMemClr(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_EML_MEMSET:
+                       MifareEMemSet(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_EML_MEMGET:
+                       MifareEMemGet(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+               case CMD_MIFARE_EML_CARDLOAD:
+                       MifareECardLoad(c->arg[0], c->arg[1], c->arg[2], c->d.asBytes);
+                       break;
+                       
+#endif
+
 #ifdef WITH_ISO14443b
                case CMD_SNOOP_ISO_14443:
                        SnoopIso14443();
 #ifdef WITH_ISO14443b
                case CMD_SNOOP_ISO_14443:
                        SnoopIso14443();
@@ -706,6 +745,13 @@ void UsbPacketReceived(uint8_t *packet, int len)
                        break;
 #endif
 
                        break;
 #endif
 
+#ifdef WITH_ISO14443a
+               // Makes use of ISO14443a FPGA Firmware
+               case CMD_SNOOP_ICLASS:
+                       SnoopIClass();
+                       break;
+#endif
+
                case CMD_SIMULATE_TAG_HF_LISTEN:
                        SimulateTagHfListen();
                        break;
                case CMD_SIMULATE_TAG_HF_LISTEN:
                        SimulateTagHfListen();
                        break;
@@ -901,6 +947,8 @@ void  __attribute__((noreturn)) AppMain(void)
        // Load the FPGA image, which we have stored in our flash.
        FpgaDownloadAndGo();
 
        // Load the FPGA image, which we have stored in our flash.
        FpgaDownloadAndGo();
 
+       StartTickCount();
+       
 #ifdef WITH_LCD
 
        LCDInit();
 #ifdef WITH_LCD
 
        LCDInit();
Impressum, Datenschutz