   mag.getEvent(&mag_event);
 
   if (dof.fusionGetOrientation(event, &mag_event, &orientation)) {
-    Serial.print("X: "); Serial.print(event->acceleration.x); Serial.print(", ");
-    Serial.print("Y: "); Serial.print(event->acceleration.y); Serial.print(", ");
-    Serial.print("Z: "); Serial.println(event->acceleration.z);
 
     if (which) {
       pulse(3, &accel_event_1, &accel_event_2);

#define NUM_PIXELS 8
Adafruit_NeoPixel strip = Adafruit_NeoPixel(NUM_PIXELS, PIN, NEO_GRB + NEO_KHZ800);
RGBPixel frame[NUM_PIXELS];

void setup() {
  Serial.begin(115200);
  strip.begin();
  strip.show();

  // Init Sensors
  bool successful = accel.begin() && mag.begin() && bmp.begin();

  if (!successful) {
    Serial.println("Check your wiring!");
    strip.setPixelColor(4, 128, 0, 0);
    strip.show();
    while (1);
  }
  Serial.println("Beginning");
}

void pulse(int x, sensors_event_t *event, sensors_event_t *previous_event)

  int8_t y_delta = abs(event->acceleration.y - previous_event->acceleration.y);
  int8_t z_delta = abs(event->acceleration.z - previous_event->acceleration.z);

  hsvpix.hue = map(x_delta, 0, maxAcceleration, 0, 255);
  hsvpix.value = map(y_delta, 0, maxAcceleration, 0, 255);
  hsvpix.saturation = map(z_delta, 0, maxAcceleration, 0, 255);

  hsvpix.loadTo(&rgbpix);

  avg_color(x,
            rgbpix.red,
            rgbpix.green,
            rgbpix.blue
           );
}

void loop() {
