====== Engine Temperature ======
Sensored motor have a thermistor inside that this connected to ground and available on PIN5 of the sensored connector. To read engine temperature, the ESC most probably use a voltage divider of which the thermistor is one of the resistance. The problem is to measure the resistance without impacting the reading made by the ESC itself while we have no idea of the internal ESC resistance.
The ideas is to first measure the ESC internal resistor by isolating the themistor with a schematic like this :
{{:karmon:monitoring:motorthermistor.png?direct&400|}}
At startup, by closing D1, we can infer Rv (internal ESC resistor) by reading A0.
Once Rv is known, we can infer Rm by reading A0 and integrating Rv in the equation.
Once D1 is pushed, we can first calculate the current I=A0/Rref then inferred Rv = (Vref-A0)/I = Ref * (Vref-A0)/A0 where VRef = 5V in the case of RC cars.
Once Rv is known, we can release D1 and calculate Rm=A0*Rv/(Vref-A0)