WikiWatershed is a web toolkit designed to help citizens, conservation practitioners, municipal decision-makers, researchers, educators, and students advance knowledge and stewardship of fresh water. WikiWatershed an initiative of Stroud Water Research Center, a global leader in freshwater science.

7. Sending/Uploading Sensor Data

Last updated on 2022-09-08

After registering your site, you’re ready to add sensor data to it.

Sending Data From a Data Logger

You can send sensor data from an Arduino data logger by following the detailed instructions in the EnviroDIY GitHub repository, Modular Sensors wiki.

REST POST Request Syntax

REST POST request syntax examples can be found in documentation on the Monitor My Watershed GitHub repository.

Uploading CSV Sensor Data

Uploading EnviroDIY Monitoring Station Data – Filling Data Gaps for Real-Time Stations

For EnviroDIY monitoring stations that are programmed to transmit data to Monitor My Watershed (MonitorMW) you can upload data files (i.e., micro SD card files) by following the steps below.

Please note:

  • Uploading continuous data is only necessary when real-time transmission of data to MonitorMW has stopped or is sporadic, i.e., to fill data gaps.
  • Only station owners (or users with permission to use owner’s login info) can upload data.
  • For information on formatting and uploading files from stations not programmed for direct transmission or upload to MonitorMW, see “Uploading CSV Sensor Data Not Already Formatted for MonitorMW” below.

How to Fill Data Gaps

  1. Download the .csv file from the micro SD card to your computer.
  2. Login to your MonitorMW account (contact David Bressler if you don’t know your username or password). Note: only station owners or users with owner login access can upload data.
  3. Click on “My Sites,” scroll down, and click on your site of interest to go to the site details page.
Site details page.
  1. Scroll down on the site details page and click on “Manage Sensors.”
Click on the “Manage Sensors” button.
  1. Scroll to the bottom of the next page, click the paper clip under “Upload a data file (.csv),” and navigate to the file you’d like to upload.
Click the paper clip icon to select a file to upload.
  1. Click the Upload button (see below) and wait (it might take a few minutes and there is no spinning wheel to indicate progress).
    1. If the upload is successful, a pop-up window will appear for a few seconds indicating a successful upload.
    2. If the upload is unsuccessful, it will run for several minutes and then a pop-up window will appear indicating the upload failed.
Monitor My Watershed CSV file upload button.

Uploading CSV Sensor Data Not Already Formatted for MonitorMW

  1. You must be logged in to and be the owner of the site in order to upload data. (Detailed instructions for registering a site on Monitor My Watershed are available in Section 4.1.)
  2. Make sure that you’ve registered all the variables for your site.
    1. Add sensors/variables as needed by selecting “Manage Sensors” in the Sensor Observations section of your site page and adding them with the “+” button.
    2. Note: many sensors can record multiple types of data or “variables” – e.g., conductivity and temperature. For those sensors, you must add every variable you’re measuring independently.
  3. Create a comma delimited data file (csv) with your sensor values and time stamps
    1. Only include data from a single site; do not mix data from multiple sites!
    2. The timestamp must be in the first column with data values in subsequent columns.
    3. The timestamp must be formatted as yyyy-mm-dd HH:MM:SS (e.g., 2019-07-31 11:15:00). If you are editing your file in Excel, you must manually select this date format. By default, Excel will format the timestamp incorrectly! To manually select the correct date format:
      1. Select the cells containing timestamp data.
      2. Right-click and select “Format Cells.”
      3. Make sure you are on the “Number” tab and that “Custom” is selected in the Category list.
      4. The “Type” field will show m/d/yyyy h:mm. DELETE that format completely and type in yyyy-mm-dd HH:MM:SS (Figure 20).
      5. Click OK to save the changes. Please note: the “Custom” time format is not persistent. If you open the file again with Excel it will revert back to Excel default timestamp format and you will have to change it to yyyy-mm-dd HH:MM:SS again. You may consider using a text editor like Notepad or Notepad++ for any subsequent file editing.
    4. All of your timestamps must be in the same time zone – that is, not corrected for daylight savings time. If your timestamps are in local time (with a daylight savings time adjustment) you must recalculate the times to be in a single time zone.
Figure 20. Forcing the correct date-time format in Excel.
  1. Add the following header rows to the top of your CSV:
    Sampling Feature UUID: [sampling feature UUID]
    Date and Time in UTC [timezone] [yyyy-mm-dd HH:MM:SS]
    Result UUID: [variable 1 UUID] [variable 2 UUID] [variable 3 UUID]…
    [data][data][data] …
    1. Replace [sampling feature UUID] with the sampling feature UUID shown at the bottom of the site information on your site page.
      1. A UUID is a Universally Unique Identifier (also called a GUID or Globally Unique Identifier). They are 36 characters long and are made of numbers 0-9 and the letters a-f, e.g.,12345678-abcd-1234-efgh-1234567890ab.
      2. Note: Clicking on the text of the Sampling Feature UUID on the page will cause it to be copied to your clipboard.
    2. Replace [timezone] with the correct UTC offset of your data. Eastern Standard Time would be UTC-5.
    3. Replace [variables 1 UUID] (and subsequent variables) with the UUID of those variables.
    4. The UUID for each variable is shown below the plot of recent data for that variable on the site page. You can also see the UUID of a variable at the top of the window when editing an already existing variable (but not when creating a new one).
    5. Note: the UUIDs necessary to upload data to Monitor My Watershed will be visible under the plot for each variable or all together via the white button at the top of the page (Figure 21). You have to be logged in and the owner of the site in order to get these UUIDs. If you are not logged in or do not own the site, you will not be able to see any UUIDs or upload any data files. Each individual UUID can be quickly copied by hovering your mouse over the value and clicking on it. Note that the registration token is not needed to upload csv files. That value is only needed to post live data.
    6. Add your data below the header.
Button to view the token UUID list
Figure 21. View Token UUID List button.
  1. Here is an example of a file ready for upload. Remember, if you view this CSV file in Excel, the timestamp will be automatically converted and will no longer be in the correct format!
  2. Upload the file to your site by selecting “Manage Sensors” in the Sensor Observations section of your site page and clicking on the paper clip button below the list of variables. Navigate to and select your file and then click “upload.”The maximum size for a single file at this time is only 1MB. If your file is bigger than that, you will need to break it into multiple files.
  3. After you click the upload button, it may take some time for the file to be processed. A pop-up will appear at the bottom of the page and you will receive an email with the processing finishes.
  4. You should be able to see the uploaded data immediately after the processing finishes on both your site page and in Time Series Analyst.

Was this article helpful?

Send Us Feedback

Scroll to the bottom of the article to tell us if it was helpful. A “Yes” will make our day, but if you answer “No” you can then send us a brief message to help us improve.

Can’t Find the Answer?

If you’ve searched the knowledge base and still need help, please reach out to our team.
Contact Us