   * If button is pressed (active-low):
   *   Set serialOn flag.
   *   call serialPowerUp()
+  *   If device is not configured:
+  *     Prompt user
   \*****************************************/  
   if((digitalRead(5) == 0) && !State.serialOn)
   {

*          Update the time
*          Construct a timestamp
*          Write data
*        If sleep is enabled (disabled when serial is enabled)
*          Enter Sleep (low-power mode)
*          < Will wake up on Interrupt and continue: >
*        If the Magnetometer interrupted:
*          Read the magnetometer data and check for peaks.
*      Repeat Loop
*      
* Interrupts:
*   1. INT0_ISR()
*      
*   2. INT1_ISR()
*      
\*****************************************************************/

#include <SPI.h>

// Firmware for the CIWS Residential Datalogger
// Arduino IDE ver. 1.8.8
// Utah Water Research Lab
// Updated: 7/30/2019 (Updated comments)
// Daniel Henshaw and Josh Tracy
// Note: F("String") keeps string literals in program memory and out of RAM. Saves RAM space. Very good. Don't remove the F. I know it looks funny. But don't do it. Really. The program might crash if you do. And then you'll have dishonor on yourself, dishonor on your cow, and you'll find out your cricket ain't lucky.
// Note: Be sure to process resulting data file as ASCII characters, not Unicode. 
