Go Down

Topic: Measuring 2 voltages (Read 314 times) previous topic - next topic

bikemind

I'm working on a solar powered project. I need to measure voltage on the battery and voltage coming from the solar panels.

I made two simple voltage dividers and they work great on either Battery or Solar Panel, but it gets real funny when I try to measure both at the same time. I think it has to do with a common ground. Has anyone managed to do this? Any ideas?

Thanks

Hackscribble

Hi bikemind

You'll have to be a bit more specific than ...

Quote
but it gets real funny when I try to measure both at the same time.
:)

But, at a guess, do the readings get better if you analogRead() one device twice and use the second of the two readings, and then do the same for the other device?

All the best

Ray

Hackscribble.  Writing about making things.
arduino@hackscribble.com | www.hackscribble.com

raschemmel

If this is a hardware question , what is the chance a schematic would help ?
Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

spycatcher2k

If you can, measure them at least 100ms apart, the ADC need a little time to charge (It's a lot less than this, but its a good guide).
Drew.
http://www.uk-pcb.co.uk - My UK Based PCB Fab & Assembly Company
Design work undertaken
SMD & Thru-Hole assembly

m_nedix

Do you think that this might help? http://www.gammon.com.au/forum/?id=11916

Grumpy_Mike

Quote
I think it has to do with a common ground.

Unless you post a schematic of your setup all we can do is guess and you wouldn't want that would you?

Schematic = answer

zoomkat

Quote
I made two simple voltage dividers and they work great on either Battery or Solar Panel, but it gets real funny when I try to measure both at the same time. I think it has to do with a common ground. Has anyone managed to do this? Any ideas?


You got any code?
Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   8)

raschemmel

Quote
Any ideas?   

Not without a schematic and code.
Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

Chagrin

The solar panel's voltage will drop in relation to the current being drawn from it. If you have it connected to the battery then the voltage will appear to be nearly the same as the battery.

As an addendum, measuring the voltage from a solar panel when it's not connected to any load is referred to as the "open circuit" voltage. Measuring that might be helpful in finding out the panel's peak voltage but it has very little to do with the panel's power generating capability.

The Wikipedia article on Maximum Power Point Tracking (MPPT) is helpful in explaining this behavior.

raschemmel

Quote
I made two simple voltage dividers and they work great on either Battery or Solar Panel, but it gets real funny when I try to measure both at the same time. I think it has to do with a common ground. Has anyone managed to do this? Any ideas? 


Yes, we already gave you our ideas and we're waiting for you to do something
Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

JimboZA


it gets real funny when I try to measure both at the same time.


Funny "ha ha" or Funny "peculiar"?
Roy from ITCrowd: Have you tried turning it off an on again?
I'm on LinkedIn: http://www.linkedin.com/in/jimbrownza

raschemmel

no schematic, no code , no answer
Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

Robin2

11 replies and none from the OP.

Perhaps delay(48hrs); is needed?

...R

Go Up