Patent ID: 8576384

Claim:
A distance detecting sensor for a sanitary ware, the distance detecting sensor comprising: a first light emitting source; a second light emitting source; a light receiving unit; and a control circuit; wherein the light receiving unit is a photoelectric device that is sensitive to the position of light, and wherein the light receiving unit is configured to receive light emitted by both the first light emitting source and second light emitting source; wherein the control circuit is configured to activate the first light emitting source to emit a first light and to determine whether the light receiving unit receives a first reflected light signal comprising the first light; wherein the control circuit is configured to activate the second emitting source to emit a second light in response to a negative determination, and to determine whether the light receiving unit receives a second reflected light signal comprising the second light; wherein the control circuit is configured to calculate a distance value of an object to be detected based on a position of at least one of the first reflected light signal and the second reflected light signal received at the infrared light receiving unit, and to control the sanitary ware to perform an action if the calculated distance value is within a preset range.