I made a device to track battery discharge pattern, it works with Arduino and INA219 Sensor, as you can see in the schematic, the system is wired somehow with a common GND, when I put one battery in the device, it works as I expected with 3.9 Ohm resistor in the path, but when I add second and third batteries, the sensor output changes, it results in either decrease in voltage of the first battery or the current, therefore, calculated resistance changes and increase accordingly, can someone suggest what is wrong in here?

the schematic
Note: I guess the common ground in between batteries makes the first battery works as a new path for the second and third batteries, therefore, we see such thing, I thought maybe a diode between the battery and common GND may solve the issue, but it needs a heavy work to destroy everything I made, so I am not sure about it, am I correct?
device
output result

the schematic
Note: I guess the common ground in between batteries makes the first battery works as a new path for the second and third batteries, therefore, we see such thing, I thought maybe a diode between the battery and common GND may solve the issue, but it needs a heavy work to destroy everything I made, so I am not sure about it, am I correct?

