![]() |
flux sdk
v01.05.00-3-gedf3296
Embedded C++ SDK
|
Device object for the SparkFun Soil Moisture sensor. More...
Variables | |
| const uint8_t | kCalibrationIterations = 5 |
| const uint16_t | kCachedValueDeltaTicks = 1000 |
Device object for the SparkFun Soil Moisture sensor.
This file contains the implementation of the device object for the SparkFun Soil Moisture sensor. Note - this is a GPIO device, which depends on the Soil Moisture Sensor being connected to defined GPIO pins. The required pins are VCC - a digitally controlled pin (to set low and high to power the sensor during reading), and Sensor - which is an ANALOG pin to read the sensor value. These pins are settable via properties.
The class provides methods to initialize the sensor, read moisture values, and calibrate the sensor for dry and wet states. It also includes properties to enable the sensor, set the GPIO pins, and retrieve the moisture values.
| const uint16_t kCachedValueDeltaTicks = 1000 |
| const uint8_t kCalibrationIterations = 5 |