Logger Example

In this example, the logger sketch was uploaded with the following settings.

// OK to change these
#define LOG_WRAP    true  // Set log wrapping
#define LOG_RATE    5000  // Set log rate in milliseconds

The slide switch was set to the left (+) for logging mode. Both the right and left buttons were pressed at the same time to clear the log. Then the left button was pressed to start logging and the Circuit Playground was placed in the freezer.

Press the left button and place in freezer.

Lights on left are all green. Red LED should blink indicating logging. Buffer is starting to fill.

Lights on right are all red indicating the log buffer is full. However, since wrapping was enabled, it is still logging. Red LED is flashing. White NeoPixel is progressing through buffer.

Remove from freezer. Move slide switch to the right (-) position for Readout Mode. Attach to computer with USB cable.

Looking at Data with Serial Plotter

Open the Serial Plotter:

Tools -> Serial Plotter

Use the right button to select one of the plotting output modes: Celsius Plot or Fahrenheit Plot. Then press the left button and the data should be plotted.

In the example below, the Fahrenheit Plot option was used.

Several cooling cycles can be seen as indicated by the gradual up and down temperature trends. The rapid rise in temperature at the end occurred when the freezer door was opened to take a photo before removing the Circuit Playground.

Looking at Data with Serial Monitor

Open the Serial Monitor:

Tools -> Serial Monitor

Select the Summary output option and press the left button. You should see a brief summary of the log data.

You can also dump the entire contents in a tabular format using one of the Table output options. This is mainly meant to be used for downloading the data as described in the next section.

Downloading Data with Serial Monitor

Open the Serial Monitor

Tools -> Serial Monitor

Select one of the tabular format output options: Table No Headers or Table With Headers. Press the left button and the entire contents of the log buffer will be dumped to the serial port.

Click on the text in the Serial Monitor to make sure it is selected and press <CTRL>-<A> to select all the contents.

Now press <CTRL>-<C> to copy the selection into the clipboard. Open a text editor and paste the contents into a text file using <CTRL>-<V>.

Save the file, giving it a name like data.csv or similar. You can now open that file in other applications, like a spreadsheet, for further analysis and plotting.

Last updated on 2016-11-01 at 12.40.04 PM Published on 2016-11-01 at 01.39.41 PM