Clean up printing in MCU code and add new options

We now have four different ways of getting debug prints off of boards,
with varying tradeoffs. Split out the printing into dedicated libraries
that are easy to switch between to avoid duplicating even more code, and
also make using the new options easy.

USB is handy for testing the code on a Teensy.
Semihosting is nice in theory, but in practice it's super slow and
messes up the code's timing.
ITM works well, as long as you have a debugger attached.
Serial also works pretty well, but it means having another cable.

Change-Id: I7af5099d421c33f0324aeca92b46732e341848d4
diff --git a/motors/peripheral/uart_buffer.h b/motors/peripheral/uart_buffer.h
index fb7d126..63dd70d 100644
--- a/motors/peripheral/uart_buffer.h
+++ b/motors/peripheral/uart_buffer.h
@@ -13,7 +13,7 @@
 class UartBuffer {
  public:
   // Returns the number of characters added.
-  __attribute__((warn_unused_result)) int PushSpan(gsl::span<char> data);
+  __attribute__((warn_unused_result)) int PushSpan(gsl::span<const char> data);
 
   bool empty() const { return size_ == 0; }
 
@@ -32,7 +32,7 @@
 };
 
 template<int kSize>
-int UartBuffer<kSize>::PushSpan(gsl::span<char> data) {
+int UartBuffer<kSize>::PushSpan(gsl::span<const char> data) {
   const int end_location = (start_ + size_) % kSize;
   const int remaining_end = ::std::min(kSize - size_, kSize - end_location);
   const int on_end = ::std::min<int>(data.size(), remaining_end);