Antenna verification test for router

Added tests to verify each antenna in the router is working.

BUG=chromium:343184
TEST=1. Verify no connection failure when running this test.
     2. To induce a "failure" with this test, manually put a terminator on one antenna in the router.
	Run this test.
	Verify connection failure or connected with weak signal (signal leak from terminator) when the terminated antenna is the only one active

Change-Id: I47e9e01ee6489b013b29d8f36238da9d1e425268
Reviewed-on: https://chromium-review.googlesource.com/187337
Reviewed-by: Christopher Wiley <[email protected]>
Commit-Queue: Peter Qiu <[email protected]>
Tested-by: Peter Qiu <[email protected]>
diff --git a/server/site_linux_system.py b/server/site_linux_system.py
index eb07e74..0c3b156 100644
--- a/server/site_linux_system.py
+++ b/server/site_linux_system.py
@@ -337,3 +337,21 @@
         if missing:
             raise to_be_raised('AP on %s is missing required capabilites: %r' %
                                (self.role, missing))
+
+
+    def set_antenna_bitmap(self, tx_bitmap, rx_bitmap):
+        """Setup antenna bitmaps for all the phys.
+
+        @param tx_bitmap int bitmap of allowed antennas to use for TX
+        @param rx_bitmap int bitmap of allowed antennas to use for RX
+
+        """
+        for phy in self.phy_list:
+            self.iw_runner.set_antenna_bitmap(phy.name, tx_bitmap, rx_bitmap)
+
+
+    def set_default_antenna_bitmap(self):
+        """Setup default antenna bitmaps for all the phys."""
+        for phy in self.phy_list:
+            self.iw_runner.set_antenna_bitmap(phy.name, phy.avail_tx_antennas,
+                                              phy.avail_rx_antennas)