so do you mean I should do something more like this code?
Yes. You also need two variables to keep track of where to write in the arrays.
this snippet comes from this code I found online:
Crappy code. Don't use it.
if (ORP.available() > 0)
{
for (int i=0;i<13;i++) {
inData_ORP[i] = char(ORP.read());
}
}
If there is at least one byte available, read all 14 of them. Yeah, right. Great idea.
Unfortunately, this code prints out for the pH value something like this: [3.863.863.8] and spits out from time to time random characters during the readout on the serial monitor...
And, now you know why. At least, I hope you see why.
Honestly, I am completely lost...
You are the one sitting in front of the hardware. Look at it. What pins is the pH probe connected to?
The SoftwareSerial instance should be given a meaningful name. mySerial is not such a name. When the instance is used to read data from pins that a gps, or phone, or modem, or pH probe are connected to, instance names like gps, phone or cell, modem, and pHprobe or probe make a lot more sense. Then, there is no confusing what the instance represents.
There is also no mistakenly doing probe.print() to send data to the serial monitor.
So, you should look at the various pieces of code you have posted, especially the one I was questioning, and see if is clear to you what each .read() and each .print() method is communicating with. If it is, fine. If not, see if using a more meaningful name for the SoftwareSerial instance wouldn't help clear up the confusion. Also, make sure that each .read() is reading from the correct source, and that each .print() is sending data to the correct destination.
It is not clear to me that this is happening in that code.