only use SerialInterface if on UNIX machine

This commit is contained in:
Stephen Birarda 2013-03-18 15:36:26 -07:00
parent 6e9fa80966
commit 158270f20d
3 changed files with 7 additions and 3 deletions

View file

@ -30,6 +30,8 @@ const int ZERO_OFFSET = 2048;
const short NO_READ_MAXIMUM_MSECS = 3000;
const short SAMPLES_TO_DISCARD = 100;
#ifdef UNIX
void SerialInterface::pair() {
#ifdef __APPLE__
@ -232,6 +234,7 @@ void SerialInterface::resetSerial() {
}
}
#endif

View file

@ -13,9 +13,11 @@
#include <iostream>
// These includes are for serial port reading/writing
#ifdef UNIX
#include <unistd.h>
#include <fcntl.h>
#include <termios.h>
#endif
#define NUM_CHANNELS 6
@ -31,7 +33,7 @@
class SerialInterface {
public:
SerialInterface() {};
SerialInterface() { active = false; };
void pair();
void readData();
int getLED() {return LED;};

View file

@ -27,7 +27,6 @@
#include <ifaddrs.h>
#include <glm/glm.hpp>
#include <arpa/inet.h>
#include "SerialInterface.h"
#include "Field.h"
#include "world.h"
#include "Util.h"
@ -43,7 +42,7 @@
#include "Finger.h"
#include "Oscilloscope.h"
#include "UDPSocket.h"
#include "SerialInterface.h"
using namespace std;