I thought a bit about the original scheme from post # 1 and # 4, more precisely about the physical nature of the whole humidity measurement by this method.
From a physical point of view.
We generate a Dirac unit impulse (her 35ns 5V pulse) and let him into a line of known lengt (her for example 0,5m wire conducted coaxially with GND wire).
If the dielectric around our "coaxial" will form a vacuum or air in general an environment with a relative permittivity around 1.
There will be a pulse delay of approx. 800-900ps through the passage of a pulse through a 0.5 m coaxial.
If we immerse the whole coaxial in water, it will change dielectric constant
( relative permittivity ) from 1 to 80 (RP for water) and this causes the pulse to delay by about 14.8ns on the same 0.5m path.
Heureka. The 0-14ns signal delay will be a directly proportional amount of water around the coaxial (humidity 0-100%)
From a electronics design point of view.
We need a phase comparator that can compare the difference between the sent and received pulse and return something directly proportional delay in the order of fractions and units ns.
Unfortunately, most simple phase comparators suffer from so-called
Phase detector dead zone (they do not register small differences in phase)
Therefore the author of the given connection to use the divider 2 and thus obtained two identical signals of rotation by 180 degrees (250ns) , subsequently using U2A and U3A for change dutty cykle and create two 35ns pulse which are rotatable by 180 degrees.
Finally, on U3B compares the inverse values of these two pulses.
If they were rotated by 180 degrees (there was no delay in one) the output Q and Q- would be active at the same time, ie. Voltage at C3 C4 identical theoretical 2,5V (for 5V logic) voltge differnece C3-C4=0
As the signal delay increases, the voltage difference between C3 and C4 also increases.
Thanks to the measurement of 180 degrees of rotated signals, the dead zone is eliminated
Anticipated problems
1. 74HC logic have transition time typ 7ns which is relatively slow and the sensor will probably be saturated before at 100% humidity. may be use 74LVC with transition time typ 2ns , but the inverters in the short circuit would have to remain HC.
If someone comes up with another, simplify the solution ...
2. Relative permittivity of water is temperature dependent, I calculated it and changed the water temperature from 20C to 25C causes shortening the delay by approx. 160ps to 0.5m. The solution is to measure the temperature of the measuring electrode (ground wire), which should correspond to the water temperature, and then perform a mathematical correction in the MCU
3. The propagation speed is affected by dielectric losses in the dielectric,in the case of water, therefore, the amount of salts dissolved in the water. If the rainwater is generally surface soft, it will not have a practical effect, but with hard and especially even slightly salty water, yes. Cheap technical solution probably not max to allow correction if I know it is about salt water.
I'm just playing with LoRaWAN and the Internet of Things, for such sensors as made.I was quite interested, I will try to build a soil moisture meter with an MCU on this physical principle.
Due to a certain frequency dependence of the Relative permittivity of water, it should work regularly with pulses with a frequency of 10MHz.
If anyone has any idea on the issue, I'll be happy.