>Anand, this is a "simple" and cheap not-optical solution. > >regards >Marco >> > Use no float at all, just water light diffraction. The ray will bend >when >> > there is water, and you can detect that easily. >> >> That sounds vry interesting; could you give some pointers on how that >could >> be done? Why do you say this is not an optical solution? It is more reliable than having something float on the water that could get stuck and not drop down when the water level falls. The meniscus of the water in the tube will give you a very good optical interruption point. There are some proviso's (which would mostly be relevant if you had a float anyway) such as the tube being clean, and having to calibrate the sensor as the water is not a total block to the light, but the change in light transmission through the water will do all you need. -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.