I have a simple voltage read circuit:
1) 2 resistors divide input of 15v (solar source), the middle of connected resistors connect o arduino uno analog input (just like tutorial). 2) Same input source connect to a relay, which is disconnected by default. Relay load is a pump. When arduino uno detect input voltage above a threshold, relay will be on.
1) Relay off. Program is able to read input voltage correctly. 2) Relay on. Program is not able to read input voltage accurately. It is +0.5 v that real voltage.
1) When relay on, the 2 resistor circuit to read voltage may not be "accurate" anymore. It's equivalent of another "resistor"(pump) is connected from input of source to ground. Is this the source of the problem?
2) What's is the circuit to solve this problem?
3) Is this programing issue? I should use different parameter to adjust the reading when relay on/off?