Hi Ali Reza! Thank you for taking time to create these videos. If one externally power this sensor(s), then the yellow wire(s) get connected to appropriate GPIO pins. Does the Ground wire also need to be connected to the ESP32? مرسی
Hi, Thank you a lot for your compliment. ❤❤ Connect the ground of the Sensor to the GRN of your power. But if the power of sensor and ESP is the same you can connect Ground of sensor to GND of ESP.
I have an ESP8266 and the only way to work is to use the pinMode(pin, INPUT_PULLUP) and pin is any GPIO that the ESP8266 has, currently I´m using GPIO 5, and when there is water the sensor turns on the red led and the digitalRead function reads a 0, and when there is no water the sensor turns off the red led and the digitalRead function reads a 1, so I have it backwards, is there some way to have it properly? I tried chaning to GPIO16 and use the pinMode(pin, INPUT_PULLDOWN_16) but it doesn´t work at all.
Hello! If I use an ESP32 module for that project, can I still install some more code to track a BLE device with ESP32 Bluetooth Low Energy Tracker Hub? My question is simple, when using an ESP32 for such a project, does it have to be dedicated to only one project or I can still install more code onto it? This will be my first project, I am not familiar with the limitations of an ESP32 module.
Thanks for the informative video - especially the integration into esphome and HA. I ended up here trying to find info concerning the difference between the NPN and PNP versions of such a water level sensor. In the beginning, you show us a PNP version but in the diagram there's a NPN version. What exactly are the differences? I'm interested strictly in a binary read out and not driving any external items directly with the sensor (LED, etc.). Which version would be ideal for this (lowest operating power)? Thanks.
I was able to get this working, but once it switches to "wet" it stays wet. The led on the sensor goes out. If I unplug the sensor from the GPIO for a few seconds then plug it back in it will go to dry but as soon as it senses wet it stays on wet. Any suggestions?
@@kian.smarthome After messing with this some more, I realized it isn't resetting just from plugging/unplugging the sensor wire. It resets only if I touch the signal wire while I have it unplugged. I'm guessing this is a sensor problem.
So, I fixed this by moving to GPIO16 and setting to pulldown to "true" binary_sensor: - platform: gpio pin: number: GPIO16 mode: input: true pulldown: true device_class: moisture name: "Chlorine Level Sensor"
@@kian.smarthome Dear Sir , I have gone through line of code but which device class I need to use for MQ135 is not getting clear . Device class is not showing me data in 4 digit compare to blynk application which shows accurate reading.
I liked your video!! I need to monitor the water level in my home's water tank and I have 2 questions. Please, help me. FIRST QUESTION: Which sensor to use, as I noticed that there are several models (XKC-Y25-V, XKC-Y25-NPN, XKC-Y25-PNP and XKC-Y25-RS485). What is the difference between model V and model PNP? SECOND QUESTION: The distance between this sensor and the panel where the circuit will be (Arduino, buzzer, LCD, etc.) is 15 meters. Will I have losses with this distance? Do I need to install a special cable? THANK YOU SO MUCH!
Hi, Great that my videos are informative. Firs answer: XKC-Y25-PNP. Second answer: try to place them as close as possible but if it is not possible have noises into consideration .
it is Suitable for detecting various toxic materials, strong acid, strong alkali and various liquids in high pressure sealed container. I think you can use it but if I were you I wouldn't use it for "Petrol" as it is extremely explosive.
Como se puede hacer para que prenda una luz simplemente cuando esté bajo el nivel de agua ????
Saludos
Hi Ali Reza! Thank you for taking time to create these videos. If one externally power this sensor(s), then the yellow wire(s) get connected to appropriate GPIO pins. Does the Ground wire also need to be connected to the ESP32? مرسی
Hi, Thank you a lot for your compliment. ❤❤
Connect the ground of the Sensor to the GRN of your power. But if the power of sensor and ESP is the same you can connect Ground of sensor to GND of ESP.
Complimeti per i video bravo
great video!
but do you can determine if there is water or not.
any suggestion for a sensor which can give me the water level in a plastic water tank?
Hi, Watch this video and comment you opinion about it:
czcams.com/video/R77rBTkCjfg/video.html
Thanks for video
🙏🙏🙏
I have an ESP8266 and the only way to work is to use the pinMode(pin, INPUT_PULLUP) and pin is any GPIO that the ESP8266 has, currently I´m using GPIO 5, and when there is water the sensor turns on the red led and the digitalRead function reads a 0, and when there is no water the sensor turns off the red led and the digitalRead function reads a 1, so I have it backwards, is there some way to have it properly? I tried chaning to GPIO16 and use the pinMode(pin, INPUT_PULLDOWN_16) but it doesn´t work at all.
Hi, Set inverted to true. As an example:
pin:
number: GPIO 5
inverted: true
Good video. What was the switch in home assistant for?
It is not related to this project
Hello! If I use an ESP32 module for that project, can I still install some more code to track a BLE device with ESP32 Bluetooth Low Energy Tracker Hub? My question is simple, when using an ESP32 for such a project, does it have to be dedicated to only one project or I can still install more code onto it? This will be my first project, I am not familiar with the limitations of an ESP32 module.
Good question, Yes you can add more codes. But take into consideration that do not add more than it can cope
how can i add a ky-016 led to get red and green status?
Do you want me to do it for you?
@@kian.smarthome yes please. i haven't found the yaml code to use
wow great
Hello great video, so if I understand correctly the sensor worked ok with 3.3 volts. Im I right?
yes
@@kian.smarthome Input Voltage: DC 5-24V?
@ pay more attention to video
Thanks for the informative video - especially the integration into esphome and HA. I ended up here trying to find info concerning the difference between the NPN and PNP versions of such a water level sensor. In the beginning, you show us a PNP version but in the diagram there's a NPN version. What exactly are the differences? I'm interested strictly in a binary read out and not driving any external items directly with the sensor (LED, etc.). Which version would be ideal for this (lowest operating power)? Thanks.
I have the same question here. Did you find an answer? Cheers
PNP sensors produce a positive output to your industrial controls input, while NPN sensors produce a negative signal during an “on” state
Can it sense water drops? I would like to use it to activate windshield wipers when it rains.
it must be tested. supporting me by buying me a coffee motivates me to test it sooner.
Hi, can this sensor use with the PLC ?
Hi, yes, You can
Great. Thanks
You're Welcome
I was able to get this working, but once it switches to "wet" it stays wet. The led on the sensor goes out. If I unplug the sensor from the GPIO for a few seconds then plug it back in it will go to dry but as soon as it senses wet it stays on wet. Any suggestions?
check your codes. Could you send them for me?
@@kian.smarthome
esphome:
name: chlorine-level
esp8266:
board: esp01_1m
# Enable logging
logger:
# Enable Home Assistant API
api:
encryption:
key: "*******"
ota:
password: "********,"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Chlorine-Level Fallback Hotspot"
password: "******"
captive_portal:
binary_sensor:
- platform: gpio
pin: GPIO4
device_class: moisture
name: "Chlorine Level Sensor"
@@kian.smarthome After messing with this some more, I realized it isn't resetting just from plugging/unplugging the sensor wire. It resets only if I touch the signal wire while I have it unplugged. I'm guessing this is a sensor problem.
So, I fixed this by moving to GPIO16 and setting to pulldown to "true"
binary_sensor:
- platform: gpio
pin:
number: GPIO16
mode:
input: true
pulldown: true
device_class: moisture
name: "Chlorine Level Sensor"
my question..doest it work for non transparent plastic water tank???
A new video soon will be uploaded..
@@kian.smarthome hii , may i know where the video you uploaded for transparent plastick water bag ?
@@iffahfatnin7456 czcams.com/video/R77rBTkCjfg/video.html
Dear Sir, Please confirm which platform to use for MQ135 air quality sensor under esphome (i.e. coding part ).
Please pay attention to lines of codes
@@kian.smarthome Dear Sir , I have gone through line of code but which device class I need to use for MQ135 is not getting clear . Device class is not showing me data in 4 digit compare to blynk application which shows accurate reading.
I liked your video!! I need to monitor the water level in my home's water tank and I have 2 questions. Please, help me. FIRST QUESTION: Which sensor to use, as I noticed that there are several models (XKC-Y25-V, XKC-Y25-NPN, XKC-Y25-PNP and XKC-Y25-RS485). What is the difference between model V and model PNP? SECOND QUESTION: The distance between this sensor and the panel where the circuit will be (Arduino, buzzer, LCD, etc.) is 15 meters. Will I have losses with this distance? Do I need to install a special cable? THANK YOU SO MUCH!
Hi, Great that my videos are informative.
Firs answer: XKC-Y25-PNP.
Second answer: try to place them as close as possible but if it is not possible have noises into consideration .
Thank you very much for your answer. Please let me know what is the difference between model V and model PNP.
can detect fuel level?? (fuel gauge). thx
it is Suitable for detecting various toxic materials, strong acid, strong alkali and various liquids in high pressure sealed container.
I think you can use it but if I were you I wouldn't use it for "Petrol" as it is extremely explosive.
Could you give any purchase link for this water sensor
Sure,
In Amazon:
t.ly/cGpz
In AliExpress:
t.ly/xmbH
Hi Ali, i tried the sensor but its not changing its state from dry and the light on sensor changing kindly advice what to do
Hi, Do you see the light on sensor? Have you used pins correctly?
@@kian.smarthome i rechecked ok pins but it's not working
@@kian.smarthome yes i see light on sensor
@@benjamink7311 please email me a picture of your board and its connections and a screen shot of your yaml file
@@kian.smarthome yes Ali i have sent you an email please check
Has anyone managed to get two sensors working with this code?
Pay attention to description
@@kian.smarthome I tried the code in the description on both nodemcu v3, wemos D1 mini pro and it didn't work unfortunately.