Over at gardenbot.org Andrew Frueh has an interesting article on a DIY soil moister sensor. It is simply two large nails with wires attached. By measuring the resistance of the soil between the nails, he gets a crude measurement of how wet the soil is. The more water, the lower resistance. He points to a few problems with this approach, including temperature affecting the resistance, as well as salinity and pH levels playing a role. Furthermore, electrolysis and corrosion is a problem over time. Frueh has improved on the basic circuit by using a H-bridge to alternate the direction of the current for the readings. That way, the nails last longer.

A different approach to measuring soil moisture, is to measure the dielectric constant. An example of such a sensor is the commercial product VG400 from Vegetronix. It sells for $37, so it doesn't scale to use it for many plants the same way as two nails does. The method is interesting though, with more basic information in this University of Cambridge module.