Anybody using a particle device with SDI-12 interface?

I have an sdi-12 moisture probe that I’m wanting to get to work with an electron. Is there anybody in the community that has successfully used anything similar using sdi-12? Or even better, know of a library that would be compatible?

There are several Arduino libraries around, the most likely one being
It uses a pin for the data and implements the protocol.
I have written libraries for other chips and am currently working on doing an Electron version. In my case I will use an Electron USART and external circuitry to combine the TX and RX to an SDI-12 line. That is not hard and I think in the case of the Electron it will make the code very simple.
I will probably end up with public functions similar to the Joran Beasley library above.


@pNrie - Any updates on your efforts? Especially an example circuit?

I’ve got a Pressure Systems submersible stream depth sensor I’m looking to hook up to a Photon and/or Electron.
Been playing with the EnviroDIY/Arduino-SDI-12 library and a Leonardo with some success, but need to transition to a platform we can deploy and monitor remotely.

No update. I don’t have any library experience so I was unable to port the sdi-12 library to fit our needs. We still need the library so as soon as someone who is able to accomplish it does it we will move forward with trying it out. Keeping our fingers crossed until then :grinning:

I have developed a working SDI-12 library with limited functions. However it probably covers all you want. It uses a RX/TX pair on the Electron to communicate and then this is combined in a single chip to create the SDI-12 signal. I am happy to share this with you. It is not at the point where I would put it on GitHub.
I am developing (revA, soon to be revB) shield board for the Electron. It provides solar charger, 5V supply to SDI-12 circuitry and the Electron charge, has one terminal block for SDI-12, one for TTL level RS232, one for 4 discrete AI,DI or counter inputs plus a few other connections like onboard serial Flash or Ram and a microSD connector. Not sure when it will be available but probably late September.

1 Like

I’d be interested in buying one of these shields from you, if you plan to sell them.

Sure, the design is to be part of our suite of environmental monitoring gear but if there is a home for it elsewhere then that would be good. I think Rev B should have ironed out most of the issues I have found and as I said that should surface in September. Initially we would build up only a few ourselves to prove that they are ready for manufacture so I don’t know when a full run will happen.
The bare board is 100*50 mm with mounting holes in each corner. One side has the Phoenix 3.81mm style plug in connectors for sensors, communication and power. The SDI-12 connector can be jumpered to provide 12V, Data and Ground or RS485 A, B and Ground. The TTL RS232 connector is 12V, Tx, RX and Ground. The discrete input is !2V, I1,I2,I3,I4 and Ground. There is an expansion connector containing SDI-12 data, SDA, SCL, Ground and Electron wake. Also another expansion which is wired to Electron Serial 5. The Electron mounts on the top of the board, all the SM is on the bottom including the microSD connector.
I currently have all the individual software modules working, am starting on putting them together to fit into our monitoring framework.
I dont have any real idea what the board would sell for, obviously that depends on the level of demand and the production run but my guess is that with a small production run of about 100 boards it will sell for about US$100.
I will try and keep an update of progress on this post.
The original question related to an SDI-12 library which is working but not ready for general release. If anyone is interested I can send the library and example code. I don’t think I can post a snapshot of the combiner circuitry on this forum so I will try and do that on our web site and post a link to it.

A link to the SDI-12 circuitry used on the Electron shield is

1 Like

Yes, you should be able to.
You can even just drag’n’drop images into the input box :wink:

I took the liberty to edit your post, to have the schematics right there

1 Like

Would you believe it, learn something new every day

1 Like

I’m interested too. I need to set up soil moisture monitoring stations across multiple states that operate on SDI-12. We would want about 30 the first year.

@screberg We are now building up a few Rev B boards so I will be able to post some photos and more detailed specifications soon. Most of the sites we will be using them in will be associated with soil moisture monitoring mainly using Sentek or EnviroPro profile probes.
I have already tested the firmware with both these probes and all is well.
The shield board will be built to industrial temperature specifications. It has ended up being 110x55 mm, a little larger than Rev A but it now allows space for the Electron battery to be placed on the board and also provision of a standard SMA socket for the antenna.

@pNrie Are you closer to making your firmware that you are using available?

@Buds444 The SDI-12 firmware works and I can send it to you as is, I have not polished it up for Github yet. I did publish a library to allow the Electron to send and receive SMS messages using the AT commands. It is at it does not meet the Particle laws in that I did not name the library as they wanted it, will do that later.

@Buds444 I will not be making the whole monitoring project publically available as there has been a lot of work in developing that as a complete system. Obviously our company has to get a return on that system which will be commercially selling the shield, Electron and firmware as a going, packaged item, generally with sensors to make up a project. However, our company has never charged top $ for our products anyway. I felt that there were some of the libraries that we developed which could be made public as we have benefited from some of the open source that is around. In particular there is an adaption of Modbus which extends the library to Modbus ASCII and adds some extra hooks. Also one of the open source FTP libraries which we have extended and I will make that available when I tidy it up.

1 Like

Thanks for your circuit post.

Please do continue to post what you can to this topic. I’m working on an all volunteer project to develop and deploy flood monitoring sensors in the lower Snoqualmie Valley (Washington State, USA), and we are looking to try out a couple of submersible pressure sensors that speak SDI-12, along with several ultrasonic sensors, similar to the one I built last winter.

@Buds444 Yes, no problems. I will tidy up the SDI-12 library which has an example program in it. You will need to fit an Electron with the basic TX/RX to SDI-12 circuitry I added to this link a few posts back. If you were able to cobble that together on the proto board Particle supply then you should be able to connect to an SDI-12 sensor without any farther issues.
I am a little way off getting any samples of our finished board out which would make it really easy for you but the bit of extra circuitry is not hard to put together, you will need a DIL version of the chip and a couple of resistors.
Long term I would suggest you think about getting the finished product, we could come to some sort of dealership agreement with you and you would find the cost of the finished board with fully functional firmware, ie all the comms to an FTP server, SMS alarming, microSD card storage etc all working together.
I have uploaded the SDI-12 library to GIT HUB at it works with the converter described previously. Other configurations may need some modifications.
The Decagon probe has a voltage output, not an SDI-12 one, it could be read by our finished pcb which will allow up to four voltage sensors to be connected directly.

@TSayles Tom, yes there is obviously interest in the Electron shield so I will keep posting on this thread. Just looked at your ultrasonic gauge, looks interesting.
Any SDI-12 depth sensor should work fine on the board we are building. I will have some photos in the next few days and a more elaborate write up

1 Like

We have an example of Rev B Electron Shield board assembled.Photo inserted

Shield Connections.

  1. Socket for Electron module, includes the extra pin to allow LiPo battery connection through to the module. Assumed that the Electron is soldered in place for reliability but it could be fitted with strip sockets so that it was removable.
  2. Power connector, separate screw connections for solar panel charge and battery. A switching regulator provides conversion of the charge voltage to 13.8 VDC to keep the battery charged.
  3. Four terminal connector providing +12VDC and Ground and TTL level RX and TX signals. Connected to Electron Serial 1 port.
  4. Three terminal connector providing switched 12VDC and Ground and SDI-12 data signal connected to Serial 4 on the Electron.
  5. Six terminal connector providing switched 12VDC, Ground and four inputs which can be set as 0-1VDC, 0-20mA, digital in or counter. By default the shield comes with the inputs wired as 0-20mA, some removal of the dropping resistors is needed on the board to provide the other functions.
  6. Connector for the two wires from the LiPo battery, cut the Particle connector from the end of the battery wires and insert into this connector. A jumper is provided to disconnect the battery from the Electron. NRIE unsolders the battery connector on the Electron module for their installations.
  7. JTAG header for serious programming of the Electron. This is meant to be a 10 way, 2x5 pin header which is standard for some JTAG programmers. The header is not fitted as standard to the shield as it is rarely used.
  8. Reset switch.
  9. Five way connector containing an Electron wake signal, Ground, SDI-12 Data and the TWI signals SDA and SCL.
  10. Three way connector with full RS232 level TX and RX lines and Ground connected to Electron Serial 5.
  11. SMA connector for an external GSM antenna. Unsolder the standard Electron Taoglas antenna and use the lead to connect the Electron to the lugs on the underside of the SMA connector.
  12. Micro SD card holder connected to the standard Electron SPI port.
  13. Battery enable jumper
  14. Watchdog Reset enable jumper

The standard Particle LiPo battery will fit with double sided tape or peelable adhesive on the top, remove the connector supplied with it and push the wires into the connector on the pcb.
The standard Particle antenna can be used as is or the cable used to connect to the onboard SMA socket. Pass the cable through the hole in the pcb and resolder it to the SMA connector on the underside.


And if anyone is interested in the bottom side, here it is