Board configuration and programming
Hardware configuration
The Smart Water Ions Sensor Board does not require any other manipulation than the sensor connection to its corresponding socket. There are two kinds of connectors on the Smart Water Ions Sensor Board:
First of all, the temperature sensor is connected through two ways PTSM connectors, which allow to easily assemble the wire by pressing it into the pin. To remove the wires press the slot above the input pin while pulling off the wire softly.
Secondly, SMA-RP connectors have been used for the other four kinds of sensors. Since the sensors are supplied with a BNC connector, it is necessary to connect a pigtail in between.
API
All the software functions necessary to operate the Smart Water Ions Sensor Board have been compiled in a library added to the Waspmote API, so the supply of the board and its components and the reading of the sensors can be easily managed.
When using the Smart Water Ions Sensor Board, remember it is mandatory to include the smartWaterIons.h
library by introducing the next line at the beginning of the code:
#include <smartWaterIons.h>
The Smart Water Ions library includes different classes for managing the different sockets and sensors of the board:
Next, the different functions that make up the library are described:
Power control functions
The power control functions must be managed with the SWIonsBoard
object.
Calibration configuration functions
This functions can be used by creating different objects
socket1Class calciumSensor;
socket2Class pHSensor;
Read sensor functions
socket1Class pHSensor;
socket2Class NO3Sensor;
pt1000Class temperatureSensor;
Conversion functions
Specific declaration for Plug & Sense!
For easy use with the Plug & Sense! platform, the library include specific declaration methods. In the example below, we can see how to associate an Ions Sensor Probe with the corresponding socket in Plug & Sense!.
Example:
You can find a complete example code for Plug & Sense! reading from following link:
https://development.libelium.com/waspmote/swi-07-plugsense-reading/
Last updated