You can build a DIY pH Probe, and have it be as precise or more precise than commercial equipment!
See the code here:
pH Probe Demo - First Time in pH 10 Buffer Solution
Demonstration of the pH Probe data feed and GUI
Background
When we previously attempted to create biodegradable bioplastics from cellulose, we encountered a severe issue with the (cheap) commercial pH probe we purchased from Amazon. We had a complex pH-moderated reaction that would move in one direction, but would need to actively be pushed in another direction by direct addition of pH-altering chemicals (a catalyst would consume the added chemicals until a reactant in solution was consumed and the pH would stabilize). Our pH probe was TOO SLOW, and we had strong reason to believe that the values were inaccurate, despite making careful attempts over multiple runs, and multiple days. An example of our historical setup is below:



We thus decided we needed a better solution. Thanks to the project vision and guidance of Brian Mustafa, we realized it would be a great opportunity to try and build a better pH probe.
Our Goals
- Build a faster pH Probe, that could keep up with high-speed sensitive pH reactions. Many reactions complete in less than a second, and if a device is updating too slowly, it can really mess things up.
- Note most commercial pH probes average results over a large sample window to attempt to increase the accuracy of a reading, but this only works well for static pH solutions. Dynamic pH solutions are not a good fit!
- Create a probe with comparable or even improved accuracy from industrial devices
- Create a streaming, IoT-capable system that can generalized to running for example six solutions in parallel, and support IoT data processing
- Learn, have fun, and shake the world of science to it’s core!

We therefore endeavored to create our own pH Probe!
nota bene: We are still adding information to the below sections, so please check back in a few weeks!
Technical Background
You need to familiarize yourself with these concepts:
- Design of the probe part of a pH Probe. We used a glass bead with an electrode, as most devices do. The hydrogen ions embed in the glass causing a slight positive charge, causing an opposing negative charge on the inside of the fluid-filled bead that the sensitive electrode can detect.
- Op Amp Design – an operational amplifier is the first thing a pH probe electrode connects to, and it amplifies a voltage signal from a tiny level (think 59 millivolt per change in pH). Insulating the electrical signal from the probe to the op amp is critical, and should be as short, insulated, and well soldered as possible.
- Transfer functions – inside the firmware of the pH probe circuit board, the voltage reading is turned to floating decimals after going through a digital to analog converter. Transfer functions allow the microcontroller to alter a stream of voltages into binary math that results in a pH value.
- The Nernst equation (voltage to pH). For a given temperature, voltage potential can be correlated to a pH value. See the equation here: https://www.vernier.com/blog/the-theory-behind-ph-measurements/ Note that temperature is a dynamic variable for any given room or reaction, so you need to build in a solution temperature probe, and factor that into your transfer functions.. which we did!
- Python, and USB, and our device’s API. This part is specific to our project, but we have code that captures our ability to stream high-speed values using the pH probe. Note that like most pH Probes you need to calibrate the device against 2 or three reference buffer solutions, and our firmware supports that as well!
Brian gives a talk on Op Amps



The day hardware merged with software


Key Contributors
MoCo Makers is a public DIY community, and our projects are always free and open to all backgrounds. Our original series was here: https://www.meetup.com/mocomakers/events/288938917/ and join us on Meetup for future adventures!

Brian Mustafa
Software Developer

Oleksii Panchenko
PCB and Firmware Designer

Matt Zamora
Project Coordinator