   }
 }
 
+/** Setup method. */
 void setup() {
   while (!Serial);
   delay(500);

                              BLUEFRUIT_UART_MODE_PIN,
                              BLUEFRUIT_UART_CTS_PIN,
                              BLUEFRUIT_UART_RTS_PIN);
                      
void error(const __FlashStringHelper* err) {
  Serial.println(err);
  while (1);
}                              

void connect_to_host() {
  ble.reset();

  ble.echo(false);

  Serial.println(F("Requesting Bluefruit info:"));
  ble.info();

  ble.verbose(false);

  Serial.println(F("Waiting for connection"));

  while (!ble.isConnected())
    delay(500);

  Serial.println(F("Connected"));

  if (ble.isVersionAtLeast(MINIMUM_FIRMWARE_VERSION)) {

#define MINIMUM_FIRMWARE_VERSION    "0.6.6"
#define MODE_LED_BEHAVIOUR          "MODE"

#define TIME_BETWEEN_READINGS 30 * 60 * 1000
#define WARMUP_TIME 10 * 1000
#define NUM_SAMPLES 30
#define DELAY_BETWEEN_SAMPLES 500

const int sensor_pin = A0;
const int enable_sensor_pin = 7;

