Power management in a sensor network for automated water quality monitoring