pH meter Arduino, pH Meter Calibration, DIYMORE pH Sensor, pH Sensor Arduino Code, pH of liquids
Вставка
- Опубліковано 21 сер 2024
- My Latest ESP32 Hydroponic System using pH sensor and EC Sensor
• ESP32 Hydroponic Syste...
Xmas Surprise‘s Back, ALLPCB
Random Secret Coupon for Any Order Over $500 Before 24th December, 2020
$10, $20, $50 or $500 Coupon Immediate Use, for more information visit:
www.allpcb.com...
Download:
pH meter Arduino Code, Libraries, and programming:
www.electronic...
Subscribe to my New UA-cam Channel, if you want to watch my videos in Hindi/Urdu
/ @letsgetstartedd
Related Tutorials using the DFrobot pH Sensor Kit:
DFrobot pH Sensor with Arduino, working, calibration, and pH value of different liquids:
• Arduino Project: pH se...
DFrobot pH Sensor with NodeMCU ESP8266 for water quality monitoring:
• IOT based Water Qualit...
Support me on Patreon and get access to hundreds of projects:
/ electroniclinic
sign up for a free account and download hardware designing and programming books:
amzn.to/2WeBCw1
***********
free Amazon Business Account:
amzn.to/2MiPiBT
************
Project Description:
********************
This is the analog pH sensor kit from the DIY MORE which is a bit different from the one developed by the DFrobot which I have already used in some of my previous videos explaining what is a pH sensor, it’s working, Calibration, and how to use a pH sensor to find the pH value of different liquids. I also used the DFrobot pH sensor kit for measuring the water quality using the Arduino board and I also used the pH sensor kit from the DFrobot in an IoT based water quality monitoring system using the NodeMCU ESP8266 WiFi module. So, if you want to learn how to use the pH sensor kit from the DFrobot then I highly recommend watching my previous videos.
********************
Amazon Purchase links:
*****************
Arduino Nano USB-C Type ( recommended):
amzn.to/4ahGLdk
ESP32 WiFi + Bluetooth Module for iOT Projects (recommended), more IO pins, improved speed, and supports a Lipo Battery:
amzn.to/3v40DkE
pH Sensor Kit DIYMORE
amzn.to/3ghOzR4
pH Sensor Kit DFrobot
amzn.to/2MEtRzy
128x64 SSD1306 Oled display Module
amzn.to/3h1COwT
LM7805 Voltage Regulator:
amzn.to/39V2vx3
DC Female Power Jack:
amzn.to/2Pnoljp
Other Must-Have Tools and Components:
Top Arduino Sensors:
amzn.to/3vZbnfM
Super Starter kit for Beginners
amzn.to/3cq56C5
Top Oscilloscopes
amzn.to/3ctF3d8
Variable Supply:
amzn.to/2PEAqE7
Digital Multimeter:
amzn.to/2QGRPg1
Top Soldering iron kits: "best"
amzn.to/39nqDtb
Top Portable drill machines:
amzn.to/3suQMh7
Jumper Wires:
amzn.to/2NYPEDA
3D printers:
amzn.to/3ruG1dt
CNC Machines:
amzn.to/3cuZWVv
Electronics Accessories:
amzn.to/3sueV7z
Hardware Tools:
amzn.to/3m9UhaN
DISCLAIMER: This video and description contain affiliate links, which means that if you click on one of the product links, I will receive a small commission. This helps support the channel and allows me to continue to make videos like this. Thank you for your support!
****************
Follow me on Facebook:
/ electronic-clinic-7697...
Email: stu_engineering@yahoo.com
About the Electronic Clinic:
Electronic Clinic is the only channel on UA-cam that covers all the engineering fields. Electronic Clinic helps the students and other professionals to learn electronics designing and programming. Electronic Clinic has tutorials on
Arduino
Raspberry PI
image processing
gsm based projects
Bluetooth based projects
esp8266 projects
Nodemcu projects
robotics
desktop application designing and programming
Project Related Tags:
#pHsensor
#pHmeterArduino
#pHsensorCalibration
PH SENSOR ARDUINO
ARDUINO PH SENSOR
PH METER ARDUINO
ARDUINO PH METER
ARDUINO PH METER CODE
PH SENSOR ARDUINO CODE
PH SENSOR CALIBRATION
HOW TO CALIBRATE PH SENSOR
DIY MORE PH SENSOR
PH SENSOR FROM DIYMORE
DIY ARDUINO BASED PH METER
PH SENSOR WITH ARDUINO
PH SENSOR CALIBRATION
CALIBRATE PH SENSOR
EASIEST WAY TO CALIBRATE PH SENSOR
PH SENSOR KIT BY DIYMORE
PH SENSOR KIT BY DFROBOT
To calibrate properly you need ph calibration fluids, usually 4.01 and 7.01. Then add this to code:
Before setup:
float calibph7 = 2.50; // example voltage at pH 7 calibration point
float calibph4 = 3.00; // example voltage at pH 4 calibration point
float m;
float b;
In setup:
m = (4.0 - 7.0) / (calibph4 - calibph7);
b = 7.0 - m * calibph7;
In loop:
float Voltage = analogRead(Pin) * 5 / 1024;
float phValue = m * Voltage + b;
This will give you very precive measurements even with cheap sensor. You can use something like ads1115 to improve accuracy.
Also i recommend setting the pot to 2.5 when probe is in pH 7 calibration fluid.
i just wanna say you guys are one of the best... if not, the best when explaining these stuff to beginners!
i hate watching UA-cam videos for "beginners", and yet the person explains it like they're talking to some experienced engineer.. though i could understand what they say, i just hate it cause they're not "teaching"... they're only "showing".. and sometimes they come off as arrogant to me, cause its like they expect everyone to understand what they're showing..
though the electronic clinic shows their expertise by knowing how to make someone with no idea in the electronics field be knowledgeable in just a couple of videos..
simple demonstration, simple and easy to understand code.... English is not your primary language, but i appreciate how on every video you do your best explaining things so that you could help as many as you can.. you deserve more views..
I experienced some wild variations in the collected PH value at first but increasing the delay in the time between measurements from 30 to 100 seemed to have solved my issue. Thank you so much for creating this video. It helped me a lot.
Can you share mi the program code
Great project for IT or engineering students who trying to explore IoT projects using Arduino board. Very detailed explanation and easy to understand.
Most comprehensive tutorial i have seen on this module
Very simple and clear about ph, thanks for nice tutorial
don't underestimate the importance of cleaning your pH probe with the cleaning liquid. Before cleaning I got a reading of 0.5V in water and after it I got 2.8V. Still some calibration to do, but the difference is VERY big.
good video my friend with indian accent
Thanks a ton
Very good project. I liked it
Great work
My ph probe does not reads below 2.55 volt, what to do?
did you find a solution?
@@wesly22dh I found another way, I changed callibration value and it worked
@@inderjeetkaur8270 so what voltage range do you have? i have now used the 3.3 volt and found a reliable range
@@wesly22dh 2.55 , and I power it with 5v Arduino
@@wesly22dh will try 3.3
Also about the 21.34 value
Thanks, very good video! One question, I have read is not ideal to storage the PH probe with distilled water in order to last longer, should be PH 4 solution instead. do you have any information about this? thanks again! cheers
today i will upload another video on ph sensor. this sensor is not good enough, i recommend the dfrobot ph sensor. i have a video on dfrobot ph sensor. check playlist.
@@ElectroniClinic yes I agree the reading fluctuates a lot and very inaccurate for me.
where did you get this:
float calibration_value = 21.34 - 0.7
Why do I need to use 3.3v for ESP32-Dev and how does that affect the calibration formula? I've tried the "(id(ph_raw).state) * (3.3 / 4095);" and I'm getting very low number 0.00082
That because the analog pin on esp32 can only be activated with 3.3v input.And if you using sensor with 5v work voltage like this pH sensor it wont show you the same amount of Analog Signal as you using another board like arduino which is it can be activated by 5v on analog pin.
The maximum analog signal output you can get if you use esp32 is 2800 at 3.3v max.
Thanks for the video. I'm trying this with a Micro:bit, but it is only showing max PH regardless of actual PH of liquid. Any help would be appreciated
hi! Is there an alternative code I can use to display the results without requiring adafruit? I don't plan to use a separate display for the results. Thank you and great video!
Awesome video, I need to say one of the best I found....could you give more detail for what is used the other component 4:03 You use one for calibration...but, what is the function behind the other one?
Excellent
Thanks for the video, it was really helpful.
hello what a good video
I am using the same module to measure ph, but I am feeding it with 3.3v
At what levels is the analog output of the module calibrated?
makasih mas atas ilmunya,,doain saya mahu menyiapin projek akhir..makasihhhhh
what is the role of the ph sensor module (or shield), the little card that links the probe to the arduino card?
I do not have this module and I cannot obtain it, How could I replace it and make everything work?
i have problem using the coding and when i calibrate i only reach 2.6 volt
same
Waw, this is excellent !!
thank you Philip
@@ElectroniClinic this sensor can also measure temperature?
Hello, thanks for sharing your knowledge. If I'm using ESP32, to calibrate, I should adjust the potentiometer so that the Po pin is also 2.5 volts or I should do it to 3.3v/2.
Do u solved it? I have the same question
@@its_ndy3674 Greetings, I adjusted it to 2.5 v, it is the closest the potentiometer to the sensor allows me.
@@samanedu thanks for your answer 🤗
oh man... that's not how you use a pH sensor! You are not supposed to put your test samples into the cap, that's only for holding pH sensor solution (KCL solution). You are supposed to keep the sensor submerged in KCL solution when not in use, and no other liquids are allowed in the cap of your ph sensor, you are decreasing life of the sensor drastically. Instead you are always supposed to put the probe into a beaker holding your sample and there needs to be a gentle movement of the liquid around the probe.
i used nodemcu esp8266 , 3.3 v with ph sensor , output is 3.3 , when i used trimmer does not change volt.
Estimated Senior
When I want to compile the program. The system shows a fail for SimpleTimer.h it says (SimpleTimer.h "no such file or directory") Could you help me about it ?
Best Regards
On my ph sensor only the green light shines and i only get a stable value of around 5 , whether i change the liquid ph or not ... is this an issue with the probe maybe?
same here
Dear i hv same black color pH probe when i short its connector and try to get 2.5 V, min voltage came at 2.7 & VR reached its end then i adjust VR to give 3.5 volt as i want to read pH from 6.5 to 9.0 on my aquarium. Its working good only issue is the variation in value from 2.0 to 9.0 when i put probe direct in aquarium but read stable value when i put water in separate small bowl, plz guide me what can be issue of pH value variation, is voltage set at 3.5 instead of 2.5 is issue.
Why you using 5.0/1023?, the Arduino reference say: “a resolution between readings of: 5 volts / 1024 units or, 0.0049 volts (4.9 mV) per unit” for analog pins.
I can only turn it down to 2.68 than it will not go any lower
hlo sir nice video but i want to know about if i display the milli volt also what is the procedure plse tell me
MUITO BOM, ME AJUDOU MUITO EM UM PROJETO.
PARABÉNS E OBRIGADO
boa tarde, sabe me dizer se posso utilizar o arduíno uno? também estou fazendo um trabalho de automação e estou com essa duvida... Desde já, agradeço!!!
Any good tutorial on how to use this with esp32 or esp8266? Those have a 3,3v ADC instead of 5v....
Try this! Voltage = pH_Value * (3.3 / 4095);
@@danielpayne2452 so i have to renormalize the sensor
@@cuteanimals4069 hi did u get anything
@@davidfrancis285 Try with ads1115 with esp for more stable readings!!
My pH meter only reads down to 2.55, where it simply stops going down. Any help?
Hi friend, did you got some advice about your situation? I have the same issue, I can't down below 2.7 😓 I'm planning to adjust by code, x= voltage-0.02, but I'm no sure if this don't affect to ph measures
@@FernandoMondragonJackZerox did u get anything
Hi from France, I would like to know utility of the second trimer on the board DIY-More ? And how setup it ?
you did liquid PH readings. Is there a better sensor for say like soil?
Dear Friend best explanation, i made pH meter with arduino i hv 1 problem if i put pH probe direct into my aquarium value start variation but when i put probe in a small bowl water value become stable, plz can u guide me what's issue.
this is a common problem, i have a 400$ ph/ec meter, if i try to use both probes in the same container the reading is unstable... it has something to do with them sharing the ground.
i also cannot read either ph or ec directly from the tank, other equipment like heater or pumps may interfere, somehow there is some current messing with the reading, try turning off everything else in the tank while reading ph to see what is causing it.
somehow you must isolate the currents
I am having problem in calibrating the module, it gets stuck in 2.66. What to do?
Hi friend, did you got some advice about your situation? I have the same issue, I can't down below 2.7 😓 I'm planning to adjust by code, x= voltage-0.02, but I'm no sure if this don't affect to ph measures
@@FernandoMondragonJackZerox I solved it by adjusting the calibration constant
@@taharataminpronoy148 how do you do that?
Good day sir! Is it normal for the result of pH reading to change of value sir, for example sir, the value that I always get in tap water is 6.35 to 6.98 is it normal sir?
wait! pinMode(pH_Value, INPUT);
Is this statement working!!!!! where where pH_Value is an uninitialized variable!
How is the A0 reading analog input when there is no pinMode defined for it!
Good job, thanks 🙏🏻
Great explanation. Many thanks
Hello, I want to use this project, but I have problems with the library in programming. Can you help me? Adafruit_GFX.h>
By any chance do you have the circuit of the PH sensor amplifier and would you be willing to share?
How do i supose that this code is correct when in the esp32 documentation says: "The ADC should be configured before reading is taken." ?
Im having headache with my project because i never get proper readings to do the right calculation...
Can we use it for measuring the pH of soil ??
Hi, may I know whether the blue ph electrode can be substituted by the black ph electrode?
i have connected the wire then connect the with laptop, i am getting 0.0 and 0.24 and values like that repeatedly after the gap with 0.00 so what would be the probable error, and one more thing by mistake i change the second screw then what i can do to correct it.
I have a Problem i can enter the PH calibration MODE with “ENTERPH”
but not able to “CALPH” when I enter this word in CMD Serial monitor nothing happens.
Good day sir! May I ask where can I get the ALLPCB Arduino Nano Development Board and the components that you put in sir, I hope you will read and answer my question sir. Thankyou sir for the great tutorial sir!
Kindly check the playlist. I have a video on how to make Arduino nano development board. You can download the pcb and components from the article.
Kindly check the playlist. I have a video on how to make Arduino nano development board. You can download the pcb and components from the article.
Just asking if the PCB board only applicable if you will be using Arduino Nano or is it needed also for Arduino UNO?
You can also use Arduino uno.
can you put this sensor in a tank of water and constantly monitoring the PH?
whats the deference between using it with the glass and without ?? please can anyone answer asp
Using esp32 do I need to use a 5v to 3.3v logic level converter?
hlo sir if i make it i need to first time calibration or daily need to calibration of unit ..............
what is the liquid inside the probe?
may i ask. why calibration value is 21,34?
You have to get these values by measuring the voltages of at least two calibration solutions, usually PH 4.01 and PH 6.86. The sensor is linear so with these voltages you can solve y = a x + b for a and b, with a the slope (which is always negative, higher voltage = lower PH/more acidic) and b your offset/calibration value.
Hi, great video. My sensor will not go below 2.51 and is at the lowest setting. Is something wrong?
So what did you do?
I am having the same problem
I returned it and got another, it had different problems and I gave up.
same problem... Several people on the Arduino forum. It appears that this probe is made without minimal testing
Hi. This is a very interesting project.
Can you send me the pcb layout projet that you order at ALLPCB? Please?
Thanks.
ya sure.
mazevedo852@gmail.com
@@ElectroniClinic Hey, this project's pretty cool. Could you please send it to me aswell? Cheers
The solution at the probe is distilled water?
There is a compilation error in pH Meter Arduino Code,
I.e code for checking pH of different solutions, solve the problem!
i encountered a problem where it re-calibrates to 5.00. pls help
Trying to find your gerber file so i can have some made :D, hard to find
Hello sir, can I ask for your help about my project. I am using ads1115 to my nodemcu so that I can connect the ec and ph sensor. I am also using blynk application to monitor the readings but I am having trouble with the code
the step in 8:06 (testing the voltage output) gives a value in range (0.06-0.09) in the serial monitor, I have tried adjusting the terminals of teh pH sensor but it does not work, further more the same value keeps on showing up even if I removed the connections from the esp.
this pH sensor isn't as cool as the DFrobot pH sensor, you can watch my video on the DFrobot pH sensor"its more stable and accurate" than the diymore ph sensor.
How to get temperature value from this device. Cz there is have a pinout TO
Can I connect this pH sensor to raspberry pi 4 using mcp3204 for converting analog input
Excusme Sir, when I upload the program to Arduino, the program "#include " no such file or directory in my computer. How to solve this problem, Sir?. Thank you.
My ph sensor is only down to 2.63
i want to go 2.5 but i do not know what to do help me please
Have you solved it, facing the same question too
Hi, any datasheet of the sensor and module?
code download link not available need to copy past, getting much confusion, taking much time, thanks for video
I checked the link it's working.
I HAVE YET TO FIND SOME PH CODE THAT ACTUALLY LOADS IN AND WORKS CORRECTLY. IT SEEMS THAT NONE OF THE SUPPLIED CODE FROM DOZENS OF DIFFERENT PH METER PROJECTS EVEN LOADS IN WITHOUT SHOWING UP ERRORS AND INCONSISTENCIES, RIDICULOUS.
I want to ask u why u put volt on 2.5?
i also want to know why
is there a way of exporting the readings via s0 pulse?
Im having problems calibrating the sensor, the lowest number i can get is 4.03, can u help me?
is there a way to add pump motors to automate?
hi, give me a way to preserve the probe like that
Could you please explain that part ?
hi why may votage is high i got 14 volt lowest the highest is 20.01 what should i do?
ph_act = -5.70 * volt + calibration_value;
What does this line means. -5. 7 is from where?
You have to get these values by measuring the voltages of at least two calibration solutions, usually PH 4.01 and PH 6.86. The sensor is linear so with these voltages you can solve y = a x + b for a and b, with a the slope (which is always negative, higher voltage = lower PH/more acidic) and b your offset/calibration value.
when trying to calibration it stop on 2.6 not going under it to 2.5???
same issue
i did everything as told and im getting 12.84 for lemon juice. please help me out brother
can i make the same connection with arduino uno? I'm doing a project and I would like to know if this adaptation would work.
Ya of course you can use Arduino uno. Nano and uno are similar.
Chimpo wants a copy of that accordian song
i will send you.
Hey by BNC connector shows 5 volt when I vary the knob value doesn't change can anyone help me with it
good morning friend
I bought this sensor, however when I calibrate it in a solution with ph = 7 as you did, and put it to read a ph = 2.5, it is reading a ph of 5, what did I do wrong? Would you help me?
my question is: if i want to read a solution close to 2.5 do i need to use a solution for calibration close to that?
the ph reading is a conversion of a volt reading, 0-14 ph is converted from 0-5 volt... so at 2.5 volt it should read 7ph... either way, after uploading the code, put probe in ph7 solution, then adjust the potentiometer until it reads 7ph, if you want to check accuracy further put probe in ph4 solution and see what it reads, if it is reading 4ph or very close you are good!
Can you please share program with me thanks.
My pH Sensor can only calibrated down to 3.97 Volt? Is there some problem with the probe? Please help! Thanks!
After adjusting to 3.3 volt due to WeMos Mini, the analogRead only go down to 830 (max 1024) with 2.68 V? Any reasons? Thanks!
@ElectronicClinic Is good electrode for suddenly pH change can i keep ph data sudden ph change
this isn't a good ph electrode, you should try a ph electrode developed by the Atlas scientific.
this one needs to be calibrated after every few hours which is a headache.
i am unable to connect serial port sir please help mee how
Hello, I have a problem. Help please.
I am using the Nodemcu ESP8266 board and microship which are quite similar to Arduino. I have been testing with a potenciometer if the AnalogRead() is working well or not, and yes it is. But when I connect my pH sensor, the programe reads always the maximum voltage(1023, if I map it 5.5...etc)and there's no way ro regulate it using the screws, it won't go down.
What do you think? Is it worth it to buy new pH sensor? could it be something else? I have followed all your steps and watched first 8 minutes many times.
Thanks! Have my upvote anyway if i get the solution or not!
of you have tried many times and still you don't get the desired result then you should buy another pH sensor kit. this time you can try the dfrobot kit.
Instead of powering it up with 5V, use 3.3V from 8266 board. It will work.
When trying to adjust the output with the trimmers the value does not move at all. Does anyone know the solution or is it a faulty board. My value only displays 4.26V.
any solution
hii bro,for me the pH value is showing as 14.08 and some very small variation like 14.05,14.09 like this.... can you pls help me bro
you have to do the calibration process he showed at the start
Sir, how if i dont have the external part of the bnc connector on the center of the bnc prop ? 6:25
i have done with sensor ph sir, Thankyou for tutorial, Gbu
Please i want the type and the number of ph prob
all the details are available on my website. You can find link in the description.
@@ElectroniClinic
Ok thank you very much
why do you need to setup it to 2.5 volts?
2.5 Volts is half of the total voltage (if you have it wired to the 5V output), and the scale of pH this can read is from 0 to 14. When shorting the sensor, it should read half the voltage, which would represent 7 on the pH scale (half of the max pH value)
wish i could find where to grab your code
It's available on electroniclinic. Com
Can we mesure soil pH with this device?
for this watch my video on npk sensor