Skip to content

Instantly share code, notes, and snippets.

@highfestiva
Created June 18, 2014 20:58
Show Gist options
  • Save highfestiva/ba87fde2474d2c2b5097 to your computer and use it in GitHub Desktop.
Save highfestiva/ba87fde2474d2c2b5097 to your computer and use it in GitHub Desktop.
void setup() {
Serial.begin(9600);
while (!Serial)
;
pinMode(OPIN_LED_STATE, OUTPUT);
pinMode(OPIN_SIREN_ON, OUTPUT);
pinMode(IPIN_SWITCH, INPUT_PULLUP);
pinMode(IPIN_SENSOR1, INPUT);
pinMode(IPIN_SENSOR2, INPUT);
digitalWrite(OPIN_SIREN_ON, LOW);
cmd.reserve(50);
cmdState.reserve(10);
}
...
void loop() {
handleSerial();
checkInput();
handleCrash();
displayState();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment