Gravity pH sensor in Arduino nano

Dear users

I have recentrly adquire the Gravity pH sensor from the store, and I would like to use with arduino nano. Howerver, I have struggling with calibration, when I put the sensor in buffer 7 it reads value 3.7, and when I place the sensor in buffer 7 it reads value 4.3. I tried several times with the code from DFrobot and also y move the calibrator push. I wonder what I am doing wrong or if the sensor has a problem.

Thank for your help!

Installation and Troubleshooting is for Problems with the Arduino IDE itself NOT your project. It says so in the description of the section.

Therefore I have moved your post here. Please be more careful where you post in future.

You may want to read this before you proceed:-
how to get the best out of this forum

Many thanks

Well you could provide links to

and

is that 2 different buffer solutions?

Dear.

This is the link and code I am using for.

https://wiki.dfrobot.com/Gravity__Analog_pH_Sensor_Meter_Kit_V2_SKU_SEN0161-V2

I have realize that the sensor has been tested for Arduino uno, but now I wonder if this could work well with Arduino nano. As I mentioned before, the sensor read the values, but apparently the values are wrong, it seens to me that values are kind of inverse.

Thanks again!

Make sure that you're meticulously following all the instructions given by dfrobot, including this one: "Before measuring another solution, be sure to wash the probe and absorb residual water-drops with paper to prevent cross-contamination between solutions. The probe can be washed with distilled water".

If nothing helps, I suggest you to contact dfrobot ASAP if the product still has an warranty.

Makes no odds the Classic Nano uses the same chip as the Uno.

Well, yes and no.
Chip is the same, but a classic nano has a different USB supply.
VCC (and Aref) on a classic Nano is about 4.6volt instead of 5volt (on USB supply).
That could make readout 5/4.6 = 8.7% too high if you don't correct this line.

voltage = analogRead(PH_PIN)/1024.0*5000;  // read the voltage

As I pointed out before, DFRobot should have used the 3.3volt supply as reference.
Leo..

1 Like

Thanks for your response.

I modify the values and got the desire readings value for the buffer pH 4. However, when I calibrate to pH 7 I got pH -1. Again, I am pretty sure that for a reason the sensor is giving me inverse values. It is like reading acid as alkaline, and alkaline as acid. I tried the same after calibrating with pH 7, and got the same problem. I am sure that this is not problem with the buffers. So I dont know if I could make like an inverse reading on the code. Also, I did not found any project with arduino nano and gravyti pH sensor, so I dont have a reference point. Very sad :frowning: pipipipipipipipipipipi.

You should be able to test the buffers with ph litmus paper or alternatively react some household bicarbonate with them to see if you have them labeled back to front. Never assume anything

I am sure I have not labeled incorrect them, as they are from laboratory reagment. I also used destilated water and the values return me as acid. Thats no posible!

You are missing an important step.

after this line in the code:

 voltage = analogRead(PH_PIN)/1024.0*5000;  // read the voltage

add this line:

Serial.print("voltage is:  ");;
Serial.println(voltage);

Then tell us the results when you place the probe in buffer pH7 and buffer pH4;
also make up a solution of 1% sodium bicarbonate and tell us the value you get for that. (pH should be 8.5)

Dears,

Sorry for the delayed response. I got depressed for this issue and was kind of gone. But, now I am more motivated, so I tried it again. Same problem, Then I realized your response. The voltage output is about 1889. I wonder if I could modify the code to read correctly.

Dears,

I finally found a solution. I used the old version code that is in the repo:

https://wiki.dfrobot.com/PH_meter_SKU__SEN0161_

and the following tutorial:

Thank you very much to all for your comments and the time you took to answer.

Best wishes in your projects!

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