A method for detecting a water level in a water tank, comprising: a probe voltage value acquiring step comprising periodically acquiring a voltage value of a water level probe as a probe voltage value; a voltage value comparing step comprising comparing the probe voltage value with a stored voltage threshold value, wherein if the probe voltage value is lower than the voltage threshold value, the method determines that the water tank level is higher than the water level probe and updates water data to be the probe voltage value, and if the probe voltage value is higher than the voltage threshold value, the method determines that the water tank level is lower than the water level probe and updates waterless data to be the probe voltage value; a threshold value updating step comprising updating the voltage threshold value in response to the water data and the waterless data, and providing a memory chip; the water data, the waterless data, and the voltage threshold value are stored in the memory chip, a water logic regarding the water level probe is executed in response to the probe voltage value being lower than the voltage threshold value; a waterless logic regarding the water level probe is executed in response to the probe voltage value being higher than the voltage threshold value; characterised in that the voltage threshold value is updated to be an average of the water data and the waterless data, and in that the memory chip does not lose the water data, the waterless data, and the voltage threshold value in the event of a power failure, and when the water tank is powered on again after the power failure, the method first reads the voltage threshold value saved before the power failure from the memory chip as the basis for a first time determination of water level, and in that the water logic and the waterless logic are used to operate a water inlet solenoid valve that controls a water inlet of the water tank. a probe voltage value acquiring step comprising periodically acquiring a voltage value of a water level probe as a probe voltage value; a voltage value comparing step comprising comparing the probe voltage value with a stored voltage threshold value, wherein if the probe voltage value is lower than the voltage threshold value, the method determines that the water tank level is higher than the water level probe and updates water data to be the probe voltage value, and if the probe voltage value is higher than the voltage threshold value, the method determines that the water tank level is lower than the water level probe and updates waterless data to be the probe voltage value; a threshold value updating step comprising updating the voltage threshold value in response to the water data and the waterless data, and providing a memory chip; the water data, the waterless data, and the voltage threshold value are stored in the memory chip, a water logic regarding the water level probe is executed in response to the probe voltage value being lower than the voltage threshold value; a waterless logic regarding the water level probe is executed in response to the probe voltage value being higher than the voltage threshold value; characterised in that the voltage threshold value is updated to be an average of the water data and the waterless data, and in that the memory chip does not lose the water data, the waterless data, and the voltage threshold value in the event of a power failure, and when the water tank is powered on again after the power failure, the method first reads the voltage threshold value saved before the power failure from the memory chip as the basis for a first time determination of water level, and in that the water logic and the waterless logic are used to operate a water inlet solenoid valve that controls a water inlet of the water tank.