 SimpleTimer timer;
 
 #define IO_BUF_SIZE 200
+char cmd_buf[IO_BUF_SIZE];
 char input_buf[IO_BUF_SIZE];
 char output_buf[IO_BUF_SIZE];
 

// Periodic write to Serial to test RPi <-> Arduino
void timerWrite()
{
  char write_buf[80];

  ++prefix_write_count;
  sprintf(write_buf,"timerWrite %d\r",prefix_write_count);
  fifoCmdBufEnqueueCommand(write_buf,sizeof(write_buf),output_buf,IO_BUF_SIZE);
}

// Remove the first character in output_buf and write to serial

  timer.run();
  writeOutput();
  readSerialInput();
  doCommand();
}

// Look for a <cr> terminated string at the beginning of input_buf
