The LC1BD04 Water Level Sensor, manufactured by Aliexpress, is a versatile device designed to detect and monitor the level of water in tanks, reservoirs, or other liquid storage systems. It is commonly used in automation systems to control water pumps, prevent overflow, and ensure efficient water management. This sensor is ideal for applications in agriculture, industrial automation, home automation, and water conservation systems.
The LC1BD04 Water Level Sensor has a 3-pin interface. The table below describes each pin:
Pin | Name | Description |
---|---|---|
1 | VCC | Power supply input (3.3V to 5V DC). |
2 | GND | Ground connection. |
3 | OUT | Output pin. Provides an analog signal proportional to water level or a digital |
HIGH/LOW signal depending on the water level threshold. |
Below is an example of how to use the LC1BD04 Water Level Sensor with an Arduino UNO to read analog values and control an LED based on water level.
// Define pin connections
const int sensorPin = A0; // Connect OUT pin of the sensor to A0 on Arduino
const int ledPin = 13; // Connect an LED to pin 13 (optional)
// Threshold for water level (adjust based on your setup)
const int waterLevelThreshold = 500;
void setup() {
pinMode(ledPin, OUTPUT); // Set LED pin as output
Serial.begin(9600); // Initialize serial communication
}
void loop() {
int waterLevel = analogRead(sensorPin); // Read analog value from sensor
// Print water level to Serial Monitor
Serial.print("Water Level: ");
Serial.println(waterLevel);
// Turn on LED if water level exceeds threshold
if (waterLevel > waterLevelThreshold) {
digitalWrite(ledPin, HIGH); // Turn on LED
} else {
digitalWrite(ledPin, LOW); // Turn off LED
}
delay(500); // Wait for 500ms before next reading
}
No Output Signal
Inconsistent Readings
Sensor Not Responding to Water Level Changes
Corrosion on Sensor
Q1: Can this sensor detect other liquids besides water?
A1: The LC1BD04 is optimized for water detection. It may work with other liquids, but accuracy and lifespan may vary depending on the liquid's properties.
Q2: How do I extend the sensor's lifespan?
A2: Avoid prolonged exposure to corrosive liquids, clean the sensor regularly, and ensure proper mounting to minimize wear.
Q3: Can I use this sensor with a 3.3V microcontroller?
A3: Yes, the sensor operates within a voltage range of 3.3V to 5V, making it compatible with 3.3V microcontrollers like ESP32 or Raspberry Pi Pico.
Q4: What is the maximum water depth this sensor can measure?
A4: The sensor does not measure depth directly. It detects water presence along its sensing area. For depth measurement, consider using ultrasonic or pressure-based sensors.