Used new WPILIB2015 macro to mark differences with the old WPILib.

Change-Id: I9e45a22096bdb108f74f9dc341037d5f64506ff5
diff --git a/aos/externals/forwpilib/dma.cc b/aos/externals/forwpilib/dma.cc
index 148ff29..3d41c43 100644
--- a/aos/externals/forwpilib/dma.cc
+++ b/aos/externals/forwpilib/dma.cc
@@ -175,7 +175,7 @@
     return;
   }
 
-  nFPGA::nFRC_2015_1_0_A::tDMA::tExternalTriggers new_trigger;
+  nFPGA::nRoboRIO_FPGANamespace::tDMA::tExternalTriggers new_trigger;
 
   new_trigger.FallingEdge = falling;
   new_trigger.RisingEdge = rising;
diff --git a/bot3/wpilib/wpilib_interface.cc b/bot3/wpilib/wpilib_interface.cc
index cc340cb..685b125 100644
--- a/bot3/wpilib/wpilib_interface.cc
+++ b/bot3/wpilib/wpilib_interface.cc
@@ -116,7 +116,12 @@
     ::aos::SetCurrentThreadName("SensorReader");
 
     my_pid_ = getpid();
-    ds_ = DriverStation::GetInstance();
+    ds_ =
+#ifdef WPILIB2015
+        DriverStation::GetInstance();
+#else
+        &DriverStation::GetInstance();
+#endif
 
     LOG(INFO, "Things are now started\n");
 
diff --git a/frc971/wpilib/buffered_pcm.h b/frc971/wpilib/buffered_pcm.h
index 50f86fc..e2613d7 100644
--- a/frc971/wpilib/buffered_pcm.h
+++ b/frc971/wpilib/buffered_pcm.h
@@ -29,7 +29,9 @@
 
  private:
   // WPILib declares this pure virtual and then never calls it...
+#ifdef WPILIB2015
   virtual void InitSolenoid() override {}
+#endif
 
   void Set(int number, bool value);
 
diff --git a/frc971/wpilib/joystick_sender.cc b/frc971/wpilib/joystick_sender.cc
index 236cc0f..4942eaa 100644
--- a/frc971/wpilib/joystick_sender.cc
+++ b/frc971/wpilib/joystick_sender.cc
@@ -12,7 +12,12 @@
 namespace wpilib {
 
 void JoystickSender::operator()() {
-  DriverStation *ds = DriverStation::GetInstance();
+  DriverStation *ds =
+#ifdef WPILIB2015
+      DriverStation::GetInstance();
+#else
+      &DriverStation::GetInstance();
+#endif
   ::aos::SetCurrentThreadName("DSReader");
   uint16_t team_id = ::aos::network::GetTeamNumber();
 
diff --git a/y2014/wpilib/wpilib_interface.cc b/y2014/wpilib/wpilib_interface.cc
index ffb10e2..1e70fb2 100644
--- a/y2014/wpilib/wpilib_interface.cc
+++ b/y2014/wpilib/wpilib_interface.cc
@@ -235,7 +235,12 @@
     LOG(INFO, "In sensor reader thread\n");
 
     my_pid_ = getpid();
-    ds_ = DriverStation::GetInstance();
+    ds_ =
+#ifdef WPILIB2015
+        DriverStation::GetInstance();
+#else
+        &DriverStation::GetInstance();
+#endif
 
     top_reader_.Start();
     bottom_reader_.Start();
diff --git a/y2015/wpilib/wpilib_interface.cc b/y2015/wpilib/wpilib_interface.cc
index 758ecf1..eaaeff9 100644
--- a/y2015/wpilib/wpilib_interface.cc
+++ b/y2015/wpilib/wpilib_interface.cc
@@ -127,7 +127,7 @@
     arm_left_encoder_.set_encoder(::std::move(encoder));
   }
 
-  void set_arm_left_index(::std::unique_ptr<DigitalSource> index) {
+  void set_arm_left_index(::std::unique_ptr<DigitalInput> index) {
     filter_.Add(index.get());
     arm_left_encoder_.set_index(::std::move(index));
   }
@@ -142,7 +142,7 @@
     arm_right_encoder_.set_encoder(::std::move(encoder));
   }
 
-  void set_arm_right_index(::std::unique_ptr<DigitalSource> index) {
+  void set_arm_right_index(::std::unique_ptr<DigitalInput> index) {
     filter_.Add(index.get());
     arm_right_encoder_.set_index(::std::move(index));
   }
@@ -157,7 +157,7 @@
     elevator_left_encoder_.set_encoder(::std::move(encoder));
   }
 
-  void set_elevator_left_index(::std::unique_ptr<DigitalSource> index) {
+  void set_elevator_left_index(::std::unique_ptr<DigitalInput> index) {
     filter_.Add(index.get());
     elevator_left_encoder_.set_index(::std::move(index));
   }
@@ -172,7 +172,7 @@
     elevator_right_encoder_.set_encoder(::std::move(encoder));
   }
 
-  void set_elevator_right_index(::std::unique_ptr<DigitalSource> index) {
+  void set_elevator_right_index(::std::unique_ptr<DigitalInput> index) {
     filter_.Add(index.get());
     elevator_right_encoder_.set_index(::std::move(index));
   }
@@ -187,7 +187,7 @@
     wrist_encoder_.set_encoder(::std::move(encoder));
   }
 
-  void set_wrist_index(::std::unique_ptr<DigitalSource> index) {
+  void set_wrist_index(::std::unique_ptr<DigitalInput> index) {
     filter_.Add(index.get());
     wrist_encoder_.set_index(::std::move(index));
   }
@@ -219,7 +219,12 @@
     ::aos::SetCurrentThreadName("SensorReader");
 
     my_pid_ = getpid();
-    ds_ = DriverStation::GetInstance();
+    ds_ =
+#ifdef WPILIB2015
+        DriverStation::GetInstance();
+#else
+        &DriverStation::GetInstance();
+#endif
 
     wrist_encoder_.Start();
     dma_synchronizer_->Start();
@@ -369,7 +374,7 @@
         fridge_(".frc971.control_loops.fridge_queue.output"),
         claw_(".frc971.control_loops.claw_queue.output") {}
 
-  void set_pressure_switch(::std::unique_ptr<DigitalSource> pressure_switch) {
+  void set_pressure_switch(::std::unique_ptr<DigitalInput> pressure_switch) {
     pressure_switch_ = ::std::move(pressure_switch);
   }
 
@@ -469,7 +474,7 @@
   ::std::unique_ptr<BufferedSolenoid> claw_pinchers_;
   ::std::unique_ptr<BufferedSolenoid> grabber_latch_release_;
   ::std::unique_ptr<BufferedSolenoid> grabber_fold_up_;
-  ::std::unique_ptr<DigitalSource> pressure_switch_;
+  ::std::unique_ptr<DigitalInput> pressure_switch_;
   ::std::unique_ptr<Relay> compressor_relay_;
 
   ::aos::Queue<::frc971::control_loops::FridgeQueue::Output> fridge_;