Of course, testing for humidity might not alert us to a major leak problem. During a severe rainstorm, the basement could be flooded quickly if it relies on a sump pump and that breaks down.
One device we could use with an Arduino or attach to the Raspberry Pi via the bridge shield is a water sensor.
Seeed Studios offer such a device (http://www.seeedstudio.com/depot/Grove-Water-Sensor-p-748.html) that can be connected to either the analog or digital pins on your microcontroller.
With this device hooked up, the following example sketch can be run to check whether device is working correctly.
Note
The example sketch is available on GitHub, at https://github.com/Seeed-Studio/Grove_Water_Sensor.
Integrating this module with your existing damp detection circuit is simple. Attach the device to one of the digital pins on your Uno. Next, add the following code to your damp detection device sketch:
boolean waterDetected() { if(digitalRead(WATER_SENSOR) == LOW) { return true; } else...