 
 void loop() {
 
+  if(masterEnableFlag) //Only save/buffer data if we're actively sensing data
+  {
 /* Get a new sensor event */ 
   sensors_event_t mainEvent;
   gyro.getEvent(&mainEvent);
   accel.getEvent(&mainEvent); // Assume Z-axis is vertical for accel/gyro?
   bmp.getEvent(&mainEvent);
+    
+  Record_Data(mainEvent);//Save sensor data (accel, baro, time, GPS) to the SD card
+  BufferUpdate(mainEvent);
+  }
+  
   if(gpsOnFlag)
   char c = GPS.read(); //Must call GPS.read() at some point for data transmission to occur
 
   if(startTime != 0)
   flightTime = millis() - startTime; //Timer backup variable
-
-  Record_Data(mainEvent);//Save sensor data (accel, baro, time, GPS) to the SD card
+  
   if(radioWorkingFlag) {
   Radio_Transmit(); //Transmit/receive select data
   }
-
-  BufferUpdate(mainEvent);
  
 switch(flightState) { //Switch statement for entire rocket flight
   /* 

  * Running-average calcs for critical sensor values and Simpson's Rule integration of gyro data
  * Multi-sensor verification of flight progress switch-case transitions (untested)
  * Github Sync system working
 * 
 * To-dos:
 *  THE CODE IS ALREADY TOO BIG!!!!!
      *  This is a pretty serious problem, considering there is still a significant amount of code that needs to be written. Part of the problem is that the
      *  Adafruit flight controller uses four different libraries, each of which eats up memory space. Maybe replace our flight sensor package? Otherwise,
      *  we're going to need to severely ramp down the scale of our operations...
  * Figure out what the ground station will be transmitting and configure the receiver accordingly
  * Figure out what data the payload transmits pre-burnout
  * Revise and enhance the staging/thresholds, particularly burnout/apogee accel values
  * Reconfigure the SD datalogging section to allow for easy spreadsheet conversion
  * TEST EVERYTHING

   */

case waiting:
if(accelAverage > LIFTOFF_ACCEL_THRESHOLD && masterEnableFlag)
{
  flightState = launched;
  startTime = millis();
