Deploy IMU driver and configure IRQs

The IRQs didn't match the existing IRQs.  Update them to be more
flexible and not depend on IRQ numbers since those appear to change.

wiringpi wasn't building for me, so I built the .deb and installed that
in the rootfs so I could make progress again.

While we are here, deploy to ~/bin instead of ~/robot_code/ so it is in
the path everywhere.  To make things actually easy to use, we need to
change how the config is found, but until then, this gets us closer to
easy to use.

Change-Id: Ib2f900f59bb6cc3de8f97e7687e723f6c8d003e7
Signed-off-by: Austin Schuh <austin.linux@gmail.com>
diff --git a/aos/starter/starter.sh b/aos/starter/starter.sh
index d5812c2..ff210dc 100755
--- a/aos/starter/starter.sh
+++ b/aos/starter/starter.sh
@@ -1,62 +1,27 @@
 #!/bin/bash
 
+set -x
+
 if [[ "$(hostname)" == "roboRIO"* ]]; then
   /usr/local/natinst/etc/init.d/systemWebServer stop
 
-  ROBOT_CODE="/home/admin/robot_code"
+  ROBOT_CODE="/home/admin/bin"
 
   # Get the CTRE libraries in the shared library search path
   for f in $(ls *.so);
   do
-    ln -f -s /home/admin/robot_code/$f /usr/local/frc/third-party/lib/$f
+    ln -f -s /home/admin/bin/$f /usr/local/frc/third-party/lib/$f
   done
 
   ln -s /var/local/natinst/log/FRC_UserProgram.log /tmp/FRC_UserProgram.log
   ln -s /var/local/natinst/log/FRC_UserProgram.log "${ROBOT_CODE}/FRC_UserProgram.log"
 elif [[ "$(hostname)" == "pi-"* ]]; then
-  function chrtirq() {
-    ps -ef | grep "\\[$1\\]" | awk '{print $2}' | xargs chrt $2 -p $3
-  }
-
-  chrtirq "irq/20-fe00b880" -f 50
-  chrtirq "irq/66-xhci_hcd" -f 1
-  chrtirq "irq/50-VCHIQ do" -o 0
-  chrtirq "irq/27-DMA IRQ" -f 50
-  chrtirq "irq/51-mmc1" -o 0
-  chrtirq "irq/51-mmc0" -o 0
-  chrtirq "irq/51-s-mmc0" -o 0
-  chrtirq "irq/64-v3d" -o 0
-  chrtirq "irq/24-vc4 hvs" -o 0
-  chrtirq "irq/42-vc4 hdmi" -o 0
-  chrtirq "irq/43-vc4 hdmi" -o 0
-  chrtirq "irq/39-vc4 hdmi" -o 0
-  chrtirq "irq/39-s-vc4 hd" -o 0
-  chrtirq "irq/38-vc4 hdmi" -o 0
-  chrtirq "irq/38-s-vc4 hd" -o 0
-  chrtirq "irq/29-DMA IRQ" -f 50
-  chrtirq "irq/48-vc4 hdmi" -o 0
-  chrtirq "irq/49-vc4 hdmi" -o 0
-  chrtirq "irq/45-vc4 hdmi" -o 0
-  chrtirq "irq/45-s-vc4 hd" -o 0
-  chrtirq "irq/44-vc4 hdmi" -o 0
-  chrtirq "irq/44-s-vc4 hd" -o 0
-  chrtirq "irq/30-DMA IRQ" -f 50
-  chrtirq "irq/19-fe004000" -f 50
-  chrtirq "irq/34-vc4 crtc" -o 0
-  chrtirq "irq/35-vc4 crtc" -o 0
-  chrtirq "irq/36-vc4 crtc" -o 0
-  chrtirq "irq/35-vc4 crtc" -o 0
-  chrtirq "irq/37-vc4 crtc" -o 0
-  chrtirq "irq/23-uart-pl0" -o 0
-  chrtirq "irq/57-eth0" -f 10
-  chrtirq "irq/58-eth0" -f 10
-
   # We have systemd configured to handle restarting, so just exec.
-  export PATH="${PATH}:/home/pi/robot_code"
+  export PATH="${PATH}:/home/pi/bin"
   rm -rf /dev/shm/aos
   exec starterd
 else
-  ROBOT_CODE="${HOME}/robot_code"
+  ROBOT_CODE="${HOME}/bin"
 fi
 
 cd "${ROBOT_CODE}"