Welcome to EnviroDIY, a community for do-it-yourself environmental science and monitoring. EnviroDIY is part of WikiWatershed, an initiative of Stroud Water Research Center designed to help people advance knowledge and stewardship of fresh water.
New to EnviroDIY? Start here

Shannon Hicks

Forum Replies Created

Viewing 10 posts - 1 through 10 (of 568 total)
  • Author
    Posts
  • in reply to: Error Compiling for board EnviroDIY Mayfly 1284p #18842
    Shannon Hicks
    Moderator

      It looks like you’re having the same issues a few other people have reported lately. We’re working on a fix, but in the meantime, the easiest thing to do is to replace all your “MyDocuments/Arduino/libraries” files with the stable versions from last summer.  In order to do this, you’ll have to delete all the current library files on your PC.  If you’re only using a Mayfly board with the standard sensors and accessories we typically recommend, and you haven’t downloaded other library files for other non-EnviroDIY devices or equipment, then it’s fine to delete all your library files.  If you HAVE downloaded other non-EnviroDIY library files for other things, then don’t proceed because you’ll delete the files for those other things.  Otherwise, follow these instructions:

      First, close the Arduino IDE (it’s best to do this without the IDE running).  Then use Windows File Manager (assuming you’re on a windows PC) to browse to MyDocuments/Arduino.

      In there you’ll see any customized sketches you’ve saved, plus a folder called “libraries”

      Double click on “libraries”, and in that folder you should see about 45 folders (if you’re using the most recent version of ModularSensors and it’s dependencies).  Highlight them all (using Ctrl+A) and then hit Delete key (or right click on them with the mouse and choose Delete).

      Now you should have a libraries folder that is completely empty.

      Now use your browser to visit this page: https://github.com/EnviroDIY/ModularSensors/releases

      Scroll down to the May 17, 2024 entry which is for version v.0.35.0

      At the bottom of that section, click on “Assets” and you should see 3 files listed.  Right-click on the one called “ModularSensors_Dependencies_v.0.35.0.zip” and save the file to your computer.

      Now use windows File Manager to double-click on that zip file.  Inside it you should see 32 folders.  Select all of them, hit Ctrl-C to copy (or right-click and Copy).  Then switch to the empty “libraries” folder within your “MyDocuments/Arduino” folder, and paste the 32 directories into the libraries folder.

      You have now installed the old, stable versions of the library files.  Restart your Arduino IDE and you should still have all your saved personal sketched in the Sketchbook, and when you compile the sketch for your logger, you should have no errors now.

      Shannon Hicks
      Moderator

        That means your IDE’s Serial Monitor baud rate is not the same as the baud rate in your sketch

        Shannon Hicks
        Moderator

          Did you make sure the sensor is properly wired to your Mega, (tip to 5v, sleeve to GND, and ring to data) and that the pin number in the sketch matches whatever pin number you connected the data line to?  If all the wiring is correct, then it might be an issue with the latest SDI12 library that a few people have reported.  You could try replacing all of the latest SDI12 library files you downloaded (the entire folder) and replace it with a stable legacy version (v2.1.4) from a few years ago (https://github.com/EnviroDIY/Arduino-SDI-12/tree/v2.1.4) and see if that fixes it.

          in reply to: Connecting Arduino MEGA or NANO with Teros 12 Sensor #18835
          Shannon Hicks
          Moderator

            The baud rate in the example sketches is usually 57600 or 115200, which is the rate for the Arduino board’s serial output port that it uses to communicate with your computer, not the sensor.  For whatever rate you choose, you have to manually change your IDE’s baud rate to match, otherwise you’ll just get gibberish on the monitor.  The baud rate of the SDI12 sensor port (pin 7 in most examples because of how the Mayfly board is wired) is hard-coded to 1200 in the library files and can’t (or shouldn’t) be easily changed by end users.

            If you use a Meter sensor on a Meter logger, it MUST be set to channel 0.  Their logger will not communicate with any sensor that has an address other than 0.  So if you change your sensor address to 1 (or A, or x, or any other valid SDI12 address) to use with your Arduino board, in the future if you want to put that sensor on a Meter brand logger, you’ll have to use your Arduino board and the b_change_address sketch again to change it back to 0.  Alternatively, if you think you’ll be doing this switching a lot, it would be worth it to get one of the ZSC modules from Meter.  It’s a low cost device that uses a bluetooth connection and an app on your phone to read and configure Meter sensors.  It’s great for reading live sensor data and changing SDI12 addresses.

            Shannon Hicks
            Moderator

              I’ve attached a screenshot from Meter Group’s Teros 12 Integrator Guide.  It shows the wiring scheme for the bare-wire version and the 3.5mm stereo plug version.  If you’ve got the sensor with the 3.5mm plug, then you’ll need to compare this diagram to whatever breakout board you’re using to match the tip, ring, and sleeve to the power, ground, and data lines.

              Then you can connect those 3 lines to whichever board you’re using.  Power to Vcc (3.3v or 5v, depending on your board’s operating voltage).  Ground to Ground.  Data to a digital pin.  We usually use D7 in our example sketches because that’s the line on the Mayfly’s dedicated SDI12 Grove jack.  If you’re using a different board, you can select the pin, as long as it’s free and not used by anything else in your sketch or on-board circuitry.

              The sketches you could use to communicate with the sensor can be found on our Github repo here:  https://github.com/EnviroDIY/Arduino-SDI-12

              Note that Meter Group’s sensors always get shipped to you on SDI12 channel 0 (zero).  They MUST be changed to something other than 0 in order to make the sensor respond to SDI12 commands.  Otherwise, they are stuck in their default TTL serial mode, which isn’t great if you want to use more than one sensor on the same bus.  So use the example sketch named “b_address_change” to set the channel on your sensor.  Once you do this the first time, you won’t have to do it again, the sensor will remember this preference until you manually change it at a later date.

              How you can use any of the other examples for the SDI12 library to query the sensor and display the data to Arduino IDE’s Serial Monitor.  If you want to integrate other hardware like a wifi board or other telemetry module, you’ll have to write your own sketches, since all our other examples are mainly written for the EnviroDIY Mayfly Data Logger board, which has a onboard microSD card socket, realtime clock, and xbee socket for compatible telemetry modules like wifi, cellular, LoRa, etc.

               

              Attachments:
              Shannon Hicks
              Moderator

                How many sensors are you wanting to connect to your Arduino board?  Do you have a Mega, or Nano, or both?  What sort of termination is on the end of your sensors?  Are you just wanting to display instantaneous sensor data on your computer or are you trying to build a logging device?

                Shannon Hicks
                Moderator

                  Thanks for the update.  We’re looking into it, my guess is there’s a conflict between two libraries that is causing some issues, so we’ll have to dig into it and narrow it down.

                  in reply to: Continous HAB monitoring #18796
                  Shannon Hicks
                  Moderator

                    There’s information on this page, in Section 6.2 about the holes for the cable glands: https://www.envirodiy.org/knowledge-base/building-an-envirodiy-monitoring-station/

                    As mentioned on that page, the 1/2″ NPT cable glands require you to drill a 23/32” hole and tap it with a 1/2″ NPT tap.  I don’t know what the diameter of the cable for your sensor is, but it’s probably between 0.2″ and 0.35″ so you can probably use McMaster-Carr part number 69915K54.   The larger gland that comes with the EnviroDIY kit is for cables 0.24″ to 0.47″ (part number 69915K53)  because of the rubber molded 3.5mm stereo plug on the end of the CTD cables.  If your Turner cable is larger than 0.35″ you’ll need to use the larger size.

                    Shannon Hicks
                    Moderator

                      That’s one of the older, now-discontinued Xbee models.  Have you used that module before or is it completely new and unused?  We had many of them die after about a year of service.  Did you modify the SJ19 solder jumper on the back of the Mayfly to change the bee status pin from the usual Bee pin 12 to Bee pin 13.  I see you have it listed correctly in your sketch, but the jumper also has to be changed.   Have you tried running the sketch without the modem attached at all, to see if it sleeps and wakes appropriately (maybe set it to 5 minute interval instead of 15 so you don’t have to wait quite so long during testing).  It might also help to manually set the RTC first in case you haven’t successfully made a cell connection with that board yet to sync the clock.

                      Shannon Hicks
                      Moderator

                        What modem are you using with this setup?

                      Viewing 10 posts - 1 through 10 (of 568 total)