History

integrates logging for interface

tosh committed 13 years ago

Commit 349e89a1 parent e78101713 files · +96 −89Browse files

Showing the changes to interface/src/SerialInterface.cpp (1 of 13 files). Show all

Unified · Split

interface/src/SerialInterface.cpp+3−3
@@ -67,10 +67,10 @@ int SerialInterface::initializePort(char* portname, int baud) · 66 unmodified lines
67#ifdef __APPLE__67#ifdef __APPLE__
68 serialFd = open(portname, O_RDWR | O_NOCTTY | O_NDELAY);68 serialFd = open(portname, O_RDWR | O_NOCTTY | O_NDELAY);
69 69
70 printf("Opening SerialUSB %s: ", portname);70 printLog("Opening SerialUSB %s: ", portname);
71 71
72 if (serialFd == -1) {72 if (serialFd == -1) {
73 printf("Failed.\n");73 printLog("Failed.\n");
74 return -1; // Failed to open port74 return -1; // Failed to open port
75 } 75 }
76 struct termios options;76 struct termios options;
@@ -101,7 +101,7 @@ int SerialInterface::initializePort(char* portname, int baud) · 24 unmodified lines
101 tcsetattr(serialFd,TCSANOW,&options);101 tcsetattr(serialFd,TCSANOW,&options);
102 102
103 103
104 printf("Connected.\n");104 printLog("Connected.\n");
105 resetSerial(); 105 resetSerial();
106 active = true;106 active = true;
107 #endif107 #endif