hi everyone,
Before I start a headsup: I am pretty versed with IT, but I am absolutely noob level on electronic circuits.
I am using a Controllino Maxi based on an arduino mega.
Now I want to use a SMT-50 moisture sensor. The sensor has a 0-3 V linear signal for volumetric water content.
So I power the Controllino and the SMT-50 with a 24V DC power supply.
For testing I fully submerge the SMT-50 in a water bucket. Using a multimeter I can measure 2.96V on the yellow wire which roughly translates to the maximum measurable water content of 50%.
Now I connect this yellow wire to the Controllino A0 input screw terminal. As soon as I do this the voltage drops to 2.64V.
Reading through various documents (someone_with_same_problem_as_me, github_issue) it appears that there is something going on in between the screw terminals and the arduino, namely "Protection resistor and Automatic divider that act as a resistor divider".
So in my uneducated mind what I am gathering is that a "voltage divider" is in effect here that drops the measured voltage. What I am not understanding and what noone in all these posts seems to be able to deduct is the exact formula for calculating the "error" and being able to compensate for it.
From my measurements:
Moisture: without controllino: 2960mV, with controllino: 2640mV, voltage drop: 320mV (10,8%)
Temperatur: without controllino: 757mV, with controllino: 675mV, voltage drop: 82mV (10,8%)
So the SMT-50 specifies that it has a "Output resistance" of 10 kOhm
Can anyone deduct from all these values what kind of "input resistance" the controllino brings to the table and how to compensate?
many thanks in advance! 
for reference:
Controllino Maxi (pinout, manual)
SMT-50 (specs, manual)
I guess that the Controllino is not powered properly and draws parasitic energy from the input pin through the internal body diodes.
The input resistance is a little under 100kΩ.
If it was 100kΩ then the output voltage would be the input voltage x 100/(100+10) or 90.7% of the input voltage.
The actual input resistance calculated from your figures is about 97300Ω
You just need to multiply the 'measured voltage' by 2960/2640 to get the 'corrected voltage'.
1 Like
wow, I didn't expect to get such a precise answer so fast. Where did you get the resistance from? Is there any place to look it up?
THANKS!
From https://www.controllino.com/wp-content/uploads/2023/05/CONTROLLINO_MAXI_AUTOMATION_Technical_Block_Diagram.pdf

The output resistance of your SMT is 10k so the measured voltage will be 81k (see below) divided by (10k+81k)
@JohnLincoln
My electronics knowledge is rusty but based on above should the input resistance not be (33k||22k) + 68k = 81k ?
2 Likes
thank you so much! 81k Ohm is exactly what the measurements say!
Unfortunately I cannot confirm the electronics part of the calculations, that goes over my head.
The rough guess of 100kΩ was just from skill and experience.
The lower value I got by trial and error putting different values in cell D4 of a spreadsheet that I ready had.
See below:

It is the formula in cell D5 that does the calculation.
You can see that the formula is:
=D2*(D4/(D3+D4))
Yes, based on the published schematic that is correct.
Your knowledge doesn't seem rusty to me.
1 Like
@sterretje + @JohnLincoln thank you both SO much for your awesome and quick feedback, it is highly appreciated. thank you!
Since the two 33k and 22k ohm resistors are connected in parallel that are calculated using 1/R = 1/R1 + 1/R2, correct?
Yes, that is correct, or that formula can be rearranged to give:
R = (R1 * R2)/(R1 + R2)
1 Like
Awesome, thanks!
So there is just one component I haven't full understood: what is an output resistance? Is there a formula that I can look up that gives me the (voltage * 81 / 91) formula?
Also what if I don't know the "output resistance" of a sensor?
It looks like we have two different values for the input resistance.
Segal's law is an adage that states:
A man with a watch knows what time it is. A man with two watches is never sure.
My guess is that the discrepancy is due to the quoted value of the sensor's output resistance not being exactly 10kΩ, but has been converted to a nice round figure
I had to look up the formula 
1 Like
You should have kept quiet about that.
2 Likes
wow, this thread has it all, great info, wise quotes, humor, keep it coming ;-))
but back to one unanswered one:
So there is just one component I haven't full understood: what is an output resistance? Is there a formula that I can look up that gives me the (voltage * 81 / 91) formula?
Also what if I don't know the "output resistance" of a sensor?
Below is your circuit.
The SMT has a perfect voltage source and an output resistance; it is usually drawn as a resistor in series.
The Controllino has in input resistance (usually drawn as a resistor to GND).
The Rout and the Rin create a voltage divider. The formula for the voltage into the Controllino is given as
Vin = V * (Rin / (Rout + Rin)
1 Like
What spreadsheet program do you use?
I have Excel but use Open Office's more often; both have a means to "goal seek" which works very well.
Unless that's a kind of fun you like to have.
a7
2 Likes
I use Excel.
I got Microsoft 365 in order to use the add-in 'Microsoft Data Streamer for Excel' that enables you to receive data from an Arduino serial port.
I'll look in to this 'goal seeking' feature
@alto777 is quite right, it is a powerful and generic feature. Tell Excel what cell has the result , tell it what value you are expecting, tell it which cell has the value that Excel can try and change -> profit!
doc
1 Like