History

fix bad conditional serial pairing

Stephen Birarda committed 13 years ago

Commit 8e4e5d01 parent 660630e1 file · +3 −1Browse files

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

Unified · Split

interface/src/SerialInterface.cpp+3−1
@@ -31,13 +31,14 @@ const short NO_READ_MAXIMUM = 10; · 30 unmodified lines
3131 const short SAMPLES_TO_DISCARD = 100;
3232
3333 void SerialInterface::pair() {
34+
35+#ifdef __APPLE__
3436 // look for a matching gyro setup
3537 DIR *devDir;
3638 struct dirent *entry;
3739 int matchStatus;
3840 regex_t regex;
3941
40−#ifdef __APPLE__
4142 // for now this only works on OS X, where the usb serial shows up as /dev/tty.usb*
4243 if((devDir = opendir("/dev"))) {
4344 while((entry = readdir(devDir))) {
@@ -56,6 +57,7 @@ void SerialInterface::pair() { · 12 unmodified lines
5657 closedir(devDir);
5758 }
5859 #endif
60+
5961 }
6062
6163 // Init the serial port to the specified values