]> cvs.zerfleddert.de Git - proxmark3-svn/blobdiff - client/proxmark3.c
fix 'hf mf perso' result feedback (#920)
[proxmark3-svn] / client / proxmark3.c
index 6fb066e8a5dbdaf5e4b7c8bbda22eafd6f6c27b5..fb17d13d13ce94501a35cb3f14145504ce6b5868 100644 (file)
@@ -28,6 +28,7 @@
 #include "cmdhw.h"
 #include "whereami.h"
 #include "comms.h"
+#include "uart.h"
 
 void
 #ifdef __has_attribute
@@ -48,6 +49,7 @@ main_loop(char *script_cmds_file, char *script_cmd, bool usb_present) {
                SetOffline(true);
        }
 
+
        // file with script
        FILE *script_file = NULL;
        char script_cmd_buf[256] = {0};  // iceman, needs lua script the same file_path_buffer as the rest
@@ -284,7 +286,7 @@ int main(int argc, char* argv[]) {
        set_my_executable_path();
 
        // try to open USB connection to Proxmark
-       usb_present = OpenProxmark(argv[1], waitCOMPort, 20, false);
+       usb_present = OpenProxmark(argv[1], waitCOMPort, 20);
 
 #ifdef HAVE_GUI
 #ifdef _WIN32
@@ -307,8 +309,10 @@ int main(int argc, char* argv[]) {
        main_loop(script_cmds_file, script_cmd, usb_present);
 #endif 
 
-       // Clean up the port
+       // Switch off field and clean up the port
        if (usb_present) {
+               UsbCommand c = {CMD_FPGA_MAJOR_MODE_OFF};
+               SendCommand(&c);
                CloseProxmark();
        }
 
Impressum, Datenschutz