© Copyright 2026. All Rights Reserved
Turbidity Sensor in Pakistan
The gravity Arduino turbidity sensor detects water quality by measuring the levels of turbidity. It uses light to detect postponed particles in water by measuring the light transmittance and scattering rate, which changes with the amount of total postponed solids (TSS) in water. As the TTS increases, the liquid turbidity level increases. Turbidity arduino sensors are used to measure water quality in rivers and streams, waste water and overflow measurements, control arrangement for settle down ponds, remains transport research, and laboratory measurements. This liquid sensor provides analog and digital signal output modes. The beginning is adjustable when in digital signal mode. You can select the mode according to your MCU.
Specifications:
Interface Description:
Examples:
Here are two examples:
1.Analog output mode
2. uses the Digital output mode
void setup() {
Serial.begin(9600); //Baud rate: 9600
}
void loop() {
int sensorValue = analogRead(A0);// read the input on analog pin 0:
float voltage = sensorValue * (5.0 / 1024.0); // Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
Serial.println(voltage); // print out the value you read:
delay(500);
}
int ledPin = 13; // Connect an LED on pin 13, or use the onboard one
int sensor_in = 2; // Connect turbidity sensor to Digital Pin 2
void setup(){
pinMode(ledPin, OUTPUT); // Set ledPin to output mode
pinMode(sensor_in, INPUT); //Set the turbidity sensor pin to input mode
}
void loop(){
if(digitalRead(sensor_in)==LOW){ //read sensor signal
digitalWrite(ledPin, HIGH); // if sensor is LOW, then turn on
}else{
digitalWrite(ledPin, LOW); // if sensor is HIGH, then turn off the led
}
}
This is a reference chart for the mapping from the output voltage to the NTU according to different temperature. e.g. If you leave the sensor in the pure water, that is NTU < 0.5, it should output “4.1±0.3V” when temperature is 10~50℃.
characteristic curve “Voltage ----Temperature
Package includes:
1 x Turbidity Sensor in Pakistan