Connecting Water Level sensor to Digital pin

Hello, I just fried Arduino UNO R3 by my fault and meanwhile I get new one, I need to solve this problem. I am using LCD display (connected to SDA and SCL ports), 4 soil moisture sensors on pins A0 - A3, and other not important parts in my project. Problem is that I wanted to connect Water Level sensor to pin A4, but as A4 and A5 are directly connected to SDA and SCL pins, I cannot use it on any analog pin. So the question is, can I use the Water Level sensor on Digital pin? It should output only 0 or 1, is that right? Thats how I want to use it, only if there is, or is not any water, I dont need the exact water height. Also, when will it output which value (0 when in water or 0 when dry) and does it need to just touch the water or it needs to be like halfway in water to change the state of output? I havent found anything, so you can send links if there is mentioned the Ditigal pin. If anyone could at least maybe try it for me, that would be also helpful.
image

I moved your topic to an appropriate forum category @dukla.

In the future, please take some time to pick the forum category that best suits the subject of your topic. There is an "About the _____ category" topic at the top of each category that explains its purpose.

This is an important part of responsible forum usage, as explained in the "How to get the best out of this forum" guide. The guide contains a lot of other useful information. Please read it.

Thanks in advance for your cooperation.

1 Like

sounds like you are using a Nano - if so could you use A6 and A7

1 Like

Oh, I didnt state that... I am using UNO R3

UPDATE: I tried this in TinkerCAD, but with Soil Moisture sensor, as none of the simulators have the Water Level sensor... It worked like I want it to, but will it work the same on the WL?



There is another module for that sensor that will convert the output to a digital signal (On/Off). It is basically a comparator with an adjustable reference (potentiometer). My sensors always came with that module. You can also get a I2C A/D to read it.

Can you give me the name of the converter? I only have the ones that come with Soil Moisture sensors and they only have 2 input pins...

There are many available, you can search for "arduino analog to digital converter" You should get a lot of choices. Pick any one that has enough bits. Also be sure you can get the software needed to make it operate.

ANSWER: New R3 came today, the sensor doesnt work without the Soil Moisture converter module, but with it it works as intended on the Digital pin.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.