Just wonder if anyone has an example sketch for a moisture sensor on a CubeCell?
tried didn’t work
#define SensorPin GPIO2
float sensorValue = 0;
void setup() {
Serial.begin(9600);
}
void loop() {
for (int i = 0; i <= 100; i++)
{
sensorValue = sensorValue + analogRead(SensorPin);
delay(1);
}
sensorValue = sensorValue/100.0;
Serial.println(sensorValue);
delay(30);
}