   else if(currentMode == quad) {
     currentMode = octo;
   }
-  else if(currentMode == octo) {
+  else if(currentMode = octo) {
     currentMode = dual;
   }
   //diag mode is not implemented yet

bool previousModeButton = 1;
unsigned long modeButtonMillis = 0;

MCP_CAN CAN(SPI_CS_PIN); 

void setup() {


  previousModeButton = currentModeButton;
  currentModeButton = digitalRead(MODE_PIN);
  if(currentModeButton != previousModeButton) {
    if(currentModeButton == 0) {
      modeButtonMillis = currentMillis;
      next_mode();
    }
    else {
      if((currentMillis - modeButtonMillis) < DEBOUNCE_DELAY) {
        currentModeButton = 0;
      }
    }
  }

  previousGaugeButton = currentGaugeButton;
  currentGaugeButton = digitalRead(GAUGE_PIN);
  if(currentGaugeButton != previousGaugeButton) {
    if(currentGaugeButton == 0) {
      gaugeButtonMillis = currentMillis;
      Serial.println("next gauge");
    }
    else {
      if((currentMillis - gaugeButtonMillis) < DEBOUNCE_DELAY) {
        currentGaugeButton = 0;
      }
    }
  }
}

void next_mode() {
