Robo-Tank pH circuit accuracy

nomsmon

Community Member
View Badges
Joined
Sep 7, 2020
Messages
53
Reaction score
35
Location
Northern CA
Rating - 0%
0   0   0
Has anyone done comparisons between the Robo-Tank pH circuit and other measuring methods? It seems likely that it would depend on the probe being used, but I'm curious if anyone has tested it or just has some general observations to share.

Maybe @robsworld78 would be willing to share some information about their test methodology?
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Has anyone done comparisons between the Robo-Tank pH circuit and other measuring methods? It seems likely that it would depend on the probe being used, but I'm curious if anyone has tested it or just has some general observations to share.

Maybe @robsworld78 would be willing to share some information about their test methodology?

Hi nomsmon, this is something I would also like to know. :) If anyone has some experience please share.

Unfortunately I don't have the environment or equipment to do real accurate tests, my limit was comparing to the Atlas Scientific circuit but based on how pH is read and the tests I've done I think it's quite accurate.

A pH circuit is essentially a high resolution volt meter, the readings are based on micro volts, 0mV is a pH value of 7 and it's +/-59.16 mV per +/- 1 off the 7, for example a pH value of 8.153 is -68.21148 mV. So the probe is important but it's also important for the pH circuit to be isolated. It doesn't take much interference to affect things.

I believe after a 2 point calibration on mine and Atlas there was a slight difference but close. Unfortunately I didn't document everything but I was happy with it. I did find my circuit was more stable than Atlas, the 3rd digit would bounce more with Atlas but on mine would move 7.001, 7.002 etc. Going to 10,000ths was all over on both so no point.

My circuit uses an ATtiny85 microcontroller, it's always calculating the pH and gets polled for the data. It has a decent opamp that connects to the microcontroller ADC and gives it high resolution so it can read in the 1000th's pretty well. It also has full isolation on power and data lines which stops interference from other probes and interference.

Currently the onboard code can manage a 1 and 2 point calibration and temperature compensation for readings but it's actually capable of much more. Sadly I'm not the best programmer and had to disable some features to use the Atlas driver in reef-pi. It can also do temperature compensation for the buffer solutions, a 3 point calibration and the ability to report the low and high slope of the probe to see health. If any programmers read this and can remove the Arduino Wire library I would love to hear from you. :)

With all that said you can only read the pH in reef-pi, if you want to calibrate on circuit you need to use a script I have. I also have a script that allows you to change the I2C address, reset the defaults and recall any of the stored information. The circuit is slow compared to Atlas, I think Atlas takes about 1.5 seconds to produce a reading, mine is set to every 3 seconds as I do a lot of sampling to get a better average, I found that made it more stable.

Here's some readings over 12 days I recently captured from my tank using this probe but it's over a year old now and it wasn't calibrated, my tank sits at about 8.2, I had a collection of 30 days in reef-pi but didn't save the chart, it was similar.



This chart shows a rolling average over 20 readings so you get smoother lines, you can see how it goes up and down during a 24 hour period. The temperature of the tank also fluctuated during this period and you can see it in the low/highs. I think Aug 30 and 31 the temps dropped. Aug 26 and 29 I was messing with controller so they got screwed up. So even if it isn't completely accurate you can still spot any changes in your system.

pH-rolling-average.png


This chart is same data but actual saved values, no averaging.

pH-raw-chart.png


You can see it's a lot more choppy but for a graph like that it still looks pretty good.

And while I've been typing this I started up a terminal capturing some readings so you can see what kind of data the bottom chart represents, these are every 4 seconds. This is off the controller, during my tests with the standalone version it would stick to a reading and I would think it stopped or locked but it's not quite as stable integrated into the controller, I'm trying to improve this, I want 10,000ths lol. And on occasion I have seen small spikes, it could be 8.632 and then go to something like 8.751 for a reading so I don't like that and trying to improve.

pH-readings.png


Interesting question! I’m waiting for my ROBO Tank set to get here. Very excited and this is a good question. I got rid of my Apex because I couldn’t get it calibrated

Hi Doglips56, I might have packaged your order tonight, either way it's going out tomorrow, thanks again!

You can do a 1 or 2 point calibration through reef-pi which is fine but the calibration data then gets saved in the reef-pi database so if you replace SD card or reformat it will be gone. I just finished a script that you can run in the terminal window and perform an automated calibration that gets saved to the circuit so it can't be lost. Enter your buffer values, start it up on each point and it'll complete when things stabilize. I haven't posted the script yet as I still want to add a scanner to find the I2C address automatically in case not everyone uses the default so when you get the controller if it isn't up yet send me an email.
 

Doglips56

Well-Known Member
View Badges
Joined
Jan 28, 2020
Messages
650
Reaction score
611
Location
Dacula
Rating - 0%
0   0   0
Hi @robsworld78! This is Nancy. I believe you’ve already shipped mine and it should be here tomorrow? Maybe you’re thinking I’m someone else. I hope I can work this thing! Reading all this about running and writing scrips makes me a little nervous but I’m just going to take my time so I can learn it all. Don’t you worry! I’m sure I’ll have lots of questions!
 
OP
OP
N

nomsmon

Community Member
View Badges
Joined
Sep 7, 2020
Messages
53
Reaction score
35
Location
Northern CA
Rating - 0%
0   0   0
I was already interested in buying some stuff from Robo-Tank, but after this response I am absolutely sold :)

Hi nomsmon, this is something I would also like to know. :) If anyone has some experience please share.

Unfortunately I don't have the environment or equipment to do real accurate tests, my limit was comparing to the Atlas Scientific circuit but based on how pH is read and the tests I've done I think it's quite accurate.

I'll design some tests to run when I get mine; may ping you for input on test parameter design

A pH circuit is essentially a high resolution volt meter, the readings are based on micro volts, 0mV is a pH value of 7 and it's +/-59.16 mV per +/- 1 off the 7, for example a pH value of 8.153 is -68.21148 mV. So the probe is important but it's also important for the pH circuit to be isolated. It doesn't take much interference to affect things.

Makes sense and also explains why isolation is so important on the circuit.

I believe after a 2 point calibration on mine and Atlas there was a slight difference but close. Unfortunately I didn't document everything but I was happy with it. I did find my circuit was more stable than Atlas, the 3rd digit would bounce more with Atlas but on mine would move 7.001, 7.002 etc. Going to 10,000ths was all over on both so no point.

My circuit uses an ATtiny85 microcontroller, it's always calculating the pH and gets polled for the data. It has a decent opamp that connects to the microcontroller ADC and gives it high resolution so it can read in the 1000th's pretty well. It also has full isolation on power and data lines which stops interference from other probes and interference.

Currently the onboard code can manage a 1 and 2 point calibration and temperature compensation for readings but it's actually capable of much more. Sadly I'm not the best programmer and had to disable some features to use the Atlas driver in reef-pi. It can also do temperature compensation for the buffer solutions, a 3 point calibration and the ability to report the low and high slope of the probe to see health. If any programmers read this and can remove the Arduino Wire library I would love to hear from you. :)

The AT micro controllers are awesome and that's an awesome feature set; I'd be super interested in the temperature compensation. I'm a programmer by trade and hobby. I don't do embedded systems, but I've been looking for a good project to jump into it :)

With all that said you can only read the pH in reef-pi, if you want to calibrate on circuit you need to use a script I have. I also have a script that allows you to change the I2C address, reset the defaults and recall any of the stored information. The circuit is slow compared to Atlas, I think Atlas takes about 1.5 seconds to produce a reading, mine is set to every 3 seconds as I do a lot of sampling to get a better average, I found that made it more stable.

Here's some readings over 12 days I recently captured from my tank using this probe but it's over a year old now and it wasn't calibrated, my tank sits at about 8.2, I had a collection of 30 days in reef-pi but didn't save the chart, it was similar.

This chart shows a rolling average over 20 readings so you get smoother lines, you can see how it goes up and down during a 24 hour period. The temperature of the tank also fluctuated during this period and you can see it in the low/highs. I think Aug 30 and 31 the temps dropped. Aug 26 and 29 I was messing with controller so they got screwed up. So even if it isn't completely accurate you can still spot any changes in your system.

pH-rolling-average.png


This chart is same data but actual saved values, no averaging.

pH-raw-chart.png


You can see it's a lot more choppy but for a graph like that it still looks pretty good.

And while I've been typing this I started up a terminal capturing some readings so you can see what kind of data the bottom chart represents, these are every 4 seconds. This is off the controller, during my tests with the standalone version it would stick to a reading and I would think it stopped or locked but it's not quite as stable integrated into the controller, I'm trying to improve this, I want 10,000ths lol. And on occasion I have seen small spikes, it could be 8.632 and then go to something like 8.751 for a reading so I don't like that and trying to improve.

pH-readings.png

That's awesome, thank you so much for sharing. Those numbers look great to me; deviation is relatively small and we do expect some natural fluctuations in pH.

So the controller emits a reading every 3 seconds but it is sampling off the ADC much more frequently than that? Does that mean you're doing some kind of aggregation over the 3 second window to produce the single measurement value?
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Hi @robsworld78! This is Nancy. I believe you’ve already shipped mine and it should be here tomorrow? Maybe you’re thinking I’m someone else. I hope I can work this thing! Reading all this about running and writing scrips makes me a little nervous but I’m just going to take my time so I can learn it all. Don’t you worry! I’m sure I’ll have lots of questions!

Hey Nancy, I had no idea who you were but now I do, at least for now. :) All these usernames are too much to remember for me.

The manuals should get your started and if you need help start a build thread and tag me or send me a message.

I was already interested in buying some stuff from Robo-Tank, but after this response I am absolutely sold :)



I'll design some tests to run when I get mine; may ping you for input on test parameter design



Makes sense and also explains why isolation is so important on the circuit.



The AT micro controllers are awesome and that's an awesome feature set; I'd be super interested in the temperature compensation. I'm a programmer by trade and hobby. I don't do embedded systems, but I've been looking for a good project to jump into it :)



That's awesome, thank you so much for sharing. Those numbers look great to me; deviation is relatively small and we do expect some natural fluctuations in pH.

So the controller emits a reading every 3 seconds but it is sampling off the ADC much more frequently than that? Does that mean you're doing some kind of aggregation over the 3 second window to produce the single measurement value?

I'm pretty happy with it, if you're willing to run some tests and report results I would send a circuit for free to play with. You can run it on Arduino or Pi.

I think isolation is more important than high quality probe, I've only tested with that $50 probe and it works great. I think for circuit on the controller I can still use a bit more.

If you can get a programmer like this maybe you can shrink code size so those features I disabled could be enabled again. At one point on my old controller after calibration it would produce a simple report on the health of probe based on slope, don't know how accurate it was but had the cool factor. :)


You would also need the clamp like in the picture.


I thought the temp compensation would do a lot more than it does and was disappointed. The affect is very minimal, the closer you are to 7.0 the less it affects the reading, at 7.0 it has no effect. With my tank around 8.2 if I enabled/disabled the compensation I could hardly see the change, it's the same with Atlas so I'm confident the formulas are correct, I got them from pretty good sources.

I think the pH actually takes about 2.x seconds, can't remember, but I have it check every 3 seconds. It never outputs the data, you have to send a request to circuit to retrieve it. When it reads the ADC pin it does so 4096 times and gets the average so that's why it takes so long. When it calculates mV it uses the input voltage as a reference, instead of stating 3.3v in formula it also calculates this every read so if input is 3.25v it's based of that, in theory that should help with accuracy.

I attached the code.
 

Attachments

  • RoboTank_pH.zip
    4.1 KB · Views: 94

theatrus

Valuable Member
View Badges
Joined
Mar 26, 2016
Messages
1,993
Reaction score
3,381
Location
Sacramento, CA area
Rating - 0%
0   0   0
pH probes are very high impedance - lots of little things can shift it around, but if you ever crack open a commercial unit (cough AP maybe EX) its a super cheaply done setup. To be honest, the sensor is the least stable component - you are measuring potential difference between a (often?) potassium chloride solution and the other side of the membrane. The glass membranes get coated, solutions change, etc etc. I tested a ton of sensors when first bringing this up, and most sensors are similar in short term stability - the only dubious ones were the $5 liquid filled Chinese ones which had very large offset voltages at pH 7, which is pretty surprising. I don't suggest using them :)

I use a similar arrangement on the old Pico boards, but its a bit more gold plated (probably not needed) with the dedicated reference measured in differential mode and on a 12-bit ADC, which is honestly more precision than you would possibly need. Also does oversampling to 4096, just runs continuously so it responds the last reading more or less immediately.

Page 7 has the schematic: https://github.com/blueacro/reefpi-pico/blob/master/reefpi_pico_v2.pdf
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Thanks, I'll check that out.

I don't know anything about the probes but yeah those $5 ones aren't a good idea, don't ask how I know. I think the one I'm using was pretty close to 7.0, the slope calculations are based on the offset.

I thought about adding a 12-bit ADC but I didn't think it was necessary based on what I was seeing. That's why I do a longer average when it reads.

Soon I'm going to post things on a github but need to clean up my files.
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
@robsworld78 thanks for sharing the code and info. I'm a bit busy with moving at the moment so it'll be a bit before I can get to it. No need to send me anything, happy to just share the info when I get a chance to test

No problem, whenever you're ready let me know. Have a good move, that can't be fun.
 

servus

Active Member
View Badges
Joined
Jun 7, 2020
Messages
176
Reaction score
165
Rating - 0%
0   0   0
Continuing on this thread as I have a similar problem and also measured using multiple systems. I am using the robotank controller, not sure how to identify which version. I do not have an external isolation module.

@robsworld78 here's what I am getting, you might find this useful:
- Hanna checker - 8.5 - I believe this is wrong
- pH probe robotank
- pH 10 calibration - excellent 9.95 readout​
- pH 7 calibration - excellent 6.95 readout​
- aquarium water measured in sump - all over the place, steady intervals, between 4 and 6.5; varies when turning off various equipment, still there is no identifiable trend (turning off a pump multiple times will not give the same results)​
- aquarium water - ALL equipment turned off - approx 6.5​
- aquarium water SAME equipment turned on, last week - 6.9 to 7.3​
- aquarium water measured in vial - perfectly steady measurement 7.52!!!!!​
If anyone has any advice, please let me know.
 

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Continuing on this thread as I have a similar problem and also measured using multiple systems. I am using the robotank controller, not sure how to identify which version. I do not have an external isolation module.

@robsworld78 here's what I am getting, you might find this useful:
- Hanna checker - 8.5 - I believe this is wrong
- pH probe robotank
- pH 10 calibration - excellent 9.95 readout​
- pH 7 calibration - excellent 6.95 readout​
- aquarium water measured in sump - all over the place, steady intervals, between 4 and 6.5; varies when turning off various equipment, still there is no identifiable trend (turning off a pump multiple times will not give the same results)​
- aquarium water - ALL equipment turned off - approx 6.5​
- aquarium water SAME equipment turned on, last week - 6.9 to 7.3​
- aquarium water measured in vial - perfectly steady measurement 7.52!!!!!​
If anyone has any advice, please let me know.
can you try a grounding probe?
 

servus

Active Member
View Badges
Joined
Jun 7, 2020
Messages
176
Reaction score
165
Rating - 0%
0   0   0
Hi Ranjib, I tried a grounding probe in the sump, I did not observe any changes in the pH readout. While testing the scenarios above, for some of them I did the test with AND without the grounding probe, to see if there's a difference.
Again, the only thing that's missing is the isolation module, I presume my version of robotank doesn't come with an internal isolation module.

Would and external isolation module help? If you think so, I will get one and try it out, se what results we get and how it can benefit us.
 

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Hi Ranjib, I tried a grounding probe in the sump, I did not observe any changes in the pH readout. While testing the scenarios above, for some of them I did the test with AND without the grounding probe, to see if there's a difference.
Again, the only thing that's missing is the isolation module, I presume my version of robotank doesn't come with an internal isolation module.

Would and external isolation module help? If you think so, I will get one and try it out, se what results we get and how it can benefit us.
Robo tank ph circuit implements the open source reef-pi ph circuit, which has galvanic isolation built in. In fact that’s why it’s bit cheaper than equivalent commercial ph setups.
Can you check if the aberration is related to any specific equipment ? We have seen in past specific equipment that cause this..
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Continuing on this thread as I have a similar problem and also measured using multiple systems. I am using the robotank controller, not sure how to identify which version. I do not have an external isolation module.

@robsworld78 here's what I am getting, you might find this useful:
- Hanna checker - 8.5 - I believe this is wrong
- pH probe robotank
- pH 10 calibration - excellent 9.95 readout​
- pH 7 calibration - excellent 6.95 readout​
- aquarium water measured in sump - all over the place, steady intervals, between 4 and 6.5; varies when turning off various equipment, still there is no identifiable trend (turning off a pump multiple times will not give the same results)​
- aquarium water - ALL equipment turned off - approx 6.5​
- aquarium water SAME equipment turned on, last week - 6.9 to 7.3​
- aquarium water measured in vial - perfectly steady measurement 7.52!!!!!​
If anyone has any advice, please let me know.
Sorry for taking so long to reply, I had to disappear for a bit.

It does look like there's noise getting in the system from somewhere, it's quite a high level as the pH circuit is fully isolated to the same standard as any other circuits out there. Aside from turning off all equipment if possible start pulling equipment out of the water, some AC equipment when turned off can still draw a little power which might be causing it. As you remove things check the readings and hopefully its clear what's causing it. It's also possible the noise is airborne, I've seen this before from a light ballast.
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Robo tank ph circuit implements the open source reef-pi ph circuit, which has galvanic isolation built in. In fact that’s why it’s bit cheaper than equivalent commercial ph setups.
Can you check if the aberration is related to any specific equipment ? We have seen in past specific equipment that cause this..
My pH circuit is very different than the open source version, it has it's own microcontroller and works similar to an Atlas circuit, in reef-pi it uses the ezo-ph driver.
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
952
Reaction score
1,281
Location
Edmonton, Canada
Rating - 0%
0   0   0
Here's a little update on the circuit as my post 18 months ago wasn't very clear on how well it worked as I didn't really know and didn't want to speculate.

For the first 6 months I did have a lot of issues with circuits corrupting, for a while this was a mystery but eventually I was able to determine it was low voltage causing the problems. If the circuit was underpowered or there was a power outage it was possible for the microcontroller code to corrupt, after enabling low voltage detection on the microcontroller the problem has never occurred again. With this the circuit shuts off if low voltage is detected keeping it safe.

I've also had lots of feedback by now and at this point I'm willing to go on a limb and say my circuit is equivalent to the Atlas Scientific circuit and works just as well or one could argue better. I think the stability is better than Atlas, I've seen this in my own testing using buffers, it will hold 1,000ths better than the Atlas. As for accuracy I still haven't been able to do a test in controlled conditions other than buffers but I've had a few people say it's just as good as Atlas and one lady did some comparison on her own using lab grade equipment and she was very impressed with how close it was. I'm also always finding testers here and there who are willing to do comparisons and results are always good so yeah I'm quite happy with how it works, not to toot my own horn but I don't think there's much better at this price point.
 

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,843
Reaction score
17,058
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
My pH circuit is very different than the open source version, it has it's own microcontroller and works similar to an Atlas circuit, in reef-pi it uses the ezo-ph driver.
oh, forgot that. Is the schematic opensourced ?
 

servus

Active Member
View Badges
Joined
Jun 7, 2020
Messages
176
Reaction score
165
Rating - 0%
0   0   0
Forgot to mention in the initial post: by "turning off" a device, I meant actually turning off all individual switches on the power strips.

Anyways, I unplugged every device today, and that was the ONLY way I got a SOMEWHAT close and stable reading. As soon as I even plugged in a device, even with the power strip switch off, the reading started jumping around.

20220331_181708.jpg



1 - unplugged ALL devices
2 - measured with probe outside the sump, in a vial, pH reading about 7.4 (CORRECT!!!)
3 - placed probe back in the sump
4 - about half between 3 and 4 moved robotank, so the pH wire is not close to ANY other wire
4 - right after 4 plugged in the InkBird controller, without the power strip switch turned on
4 to 5 plugged back in all devices and turned on
5 - all devices plugged back in and turned on, pH reading about 6.4
 
Last edited:

Making themselves at home: Have you intentionally done anything in your aquarium to enhance the natural behavior of your fish?

  • I planned my tank to encourage natural fish behavior.

    Votes: 27 27.8%
  • I did some things to encourage natural fish behavior.

    Votes: 33 34.0%
  • Anything that encourages natural fish behavior was a byproduct of the aquascaping.

    Votes: 16 16.5%
  • I did not do anything to encourage natural fish behavior.

    Votes: 18 18.6%
  • Other.

    Votes: 3 3.1%
Back
Top