Read battery voltages from 2 batteries w/o common ground

The batteries you are measuring the voltage of are still indirectly connected to the Arduino ground. I don't know if this matters to you as I don't know what you are doing. The ADS1115 is connected to the Arduino ground. It's inputs, while not grounded, are constrained to operate between its 0V - 0.3V and supply voltage + 0.3V, they are not free to be any voltage you like. Only you know if this is going to be a problem.

Not being connected to ground is not the same as being isolated from the other circuit.

OMG... Head hits Wall...

So the ADS1115 solution isnt great as the voltages will be too high. Ugh... I was so hopeful of that solution.

Back to the flying capacitor plan...

I moved the voltage divider before the cap, and added relay before this as suggested by GM.

So now to read the 12v battery:

  1. Activate D10 and charge the cap.
  2. Activate D11 and throw the cap over.
  3. Read the cap on A01.
  4. Deactivate D10 and D11.

This is gunna be the biggest circuit Ive ever made! Quite exciting really!

It will work the way you had it and tested it using differential inputs. The chip is only seeing the divided down voltage. You have a 24 volt and a 12 volt battery to measure and in my example I used an 18 volt and 9 volt battery.

If we look at the actual data sheet for the chip:

While the chip does have some restrictions they do not apply in your goal. You had it working with the batteries and power supply you tried it with didn't you? Worked fine with the batteries I tried it with? So why won't it work? The merit is the ability to measure differential as well as single ended which eliminates the common ground.

Ron

It will work the way you had it and tested it using differential inputs.

Hi Ron,
It might. The problem is we don't know what is also connected to the batteries. For all we know they are connected to something that cannot be directly or indirectly connected to ground for some reason, which is why I said what I did. Only grichfitz knows this and he has not shared that information.

Perry, now that is looking ahead. You did sort of lose me with what you said about ground. All I had was some batteries on a desk doing nothing. :slight_smile: Thanks for the clarification and yes sir we shall see exacyly what these batteries are doing out in the real world.

Thanks
Ron

All I had was some batteries on a desk doing nothing.

Reply #39:

Mmmmm. I hope your suspicion doesn't arise as this is only a small part of a larger project and I've spent enough time on this bit!

From which I inferred that there was other circuitry we are not being told about.

Hay guys,

I’m gunna have to a bit more investigating.

Basically these batteries are engine start batteries. But they will be connected to chargers and other monitoring equipment.

If your Arduino and associated circuitry is not connected to ground and has it's own, independent, not connected to ground power supply, then this isolation you are trying to achieve is probably not needed.

Hay Perry,
The issue is sometimes all the batteries will be connected to a common negative, sometimes they will not. That includes the battery powering the arduino.
(I’ve been calling this common negative, ground, this could have been wrong and misleading).
I don’t want to introduce a common negative.

The issue is sometimes all the batteries will be connected to a common negative, sometimes they will not. That includes the battery powering the arduino.
(I've been calling this common negative, ground, this could have been wrong and misleading).
I don't want to introduce a common negative.

You have read the tutorial on common grounds. I want to include a section on exactly this point, but cannot get it clear in my head in a way that makes for a clear explanation. There are (at least) 3 terms that get used as if they mean the same thing: Earth, ground and 0V. Sometimes they are the same thing, sometimes not. This causes confusion.

OK, being curious I tied together the negative connections of each battery and no change in readings. So they can be the same common or not. This is likely because of how the MUX is switching looking at the data sheet. Then I tied the battery commons to my Arduino ground and no change.

Ron

PerryBebbington:
You have read the tutorial on common grounds. I want to include a section on exactly this point, but cannot get it clear in my head in a way that makes for a clear explanation. There are (at least) 3 terms that get used as if they mean the same thing: Earth, ground and 0V. Sometimes they are the same thing, sometimes not. This causes confusion.

The latter part of my career we adopted using Cadence and my schematic software was primarily Orcad Capture. There was about six different symbols for GND. Today when I use a term to reference ground I try to include how I used the term, ever so briefly. Problem is when we have terms used interchangeably which are not interchangeable. :slight_smile: Then toss in a hopeless pedantic and watch.

I did read the thread "Common Grounds and Why You Need One" and found it to be well written and easy to understand. I saw it as really pretty useful material.

Ron

Hay Guys,
Just wanted to say thank you for your assistance with this.

I´m going to build two versions and do some testing. Ordering the parts now.

At least I´ve learnt something over the past few days. Will be watching this forum from now on!

Tah.

Post back how things go, I am curious. Been interesting.

Ron

Hello,
I am fairly new to electronics, although I understand a fair bit, so far!

I´m wondering if someone could take a look at this and see if this is feasible. I will test myself when I get the parts, but the current situation is slowing delivery times. :confused:

My goal, is to read battery voltages from 2 different batteries. They may not be sharing a common ground, if they do not, I do not want a common ground. They will also be 12v and/or 24v. So I will need voltage dividers to reduce the voltage to be read on the Arduino.

Do you think this will work? Are my components correct?

My programming will be as such...

  1. Activate D07
  2. Activate D12
  3. Take reading at A01
  4. Deactive D07 and D12

Massive TIA... Love the forum very useful!!

Sort of...
I have two questions.

  1. using common grounds.
  2. are my components correct.
    If you need to delete one, pls do, sorry.

To use an n-channel FET as a switch the source terminal must be at ground potential.

Your circuit has several issues, as the sources are not at ground potential and the devices
are wired backwards anyway.

You probably need an isolated way to switch, such as reed-relays or signal relays. Note that the Arduino itself
must have a floating power supply for this to work, so that its like a multimeter.

MOSFETs have an integral diode across them so cannot isolate in both directions.

Hi, and thanks for your input.

I´m using 2N7000 mosfet, this is a N channel.

I´m a bit confused with your answer. Are you suggesting I use a relay instead of a mosfet on the positive supply from the batteries?

This is the first time I´ve used mosfet, so still learning.

Is this better?