Measure resistance with ADS1115 & Arduino - Page 1
Forum section: electronics / beginners

author: hollensted
author_rank: Newbie
timestamp: October 06, 2016, 06:25:28 am
content: Hi there!I'm pretty new here so let me just start up slowly.I am measuring resistancewith ADS 1115 as an A/D convertor and an Arduino to switch between series resistors.It is used in a multiplexer setup where i want to measure the resistance of a small wooden piece inside bricks of a wall.Is this just a dumb way of doing it? (Simple diagram attached)The input resistance of both the Arduino and the ADS1115 will influence my readings at Mohm, but it will all be calibrated.The idea is to put a HIGH(output) on pin 8, 9 or 10 and the 2 other pins to be inputs.And then read the supply voltage(ADS 1,2 or 3) and the voltage divider voltage. (ADS 0) to figure out what the resistance is.

author: danadak
author_rank: Super Contributor
timestamp: October 06, 2016, 12:13:00 pm
content: If you do an error budget the contributing errors are -1) Arduino outputs do not pull to the rail, and pin to pinthere will be drive differences as well.2) The rail of the Arduino is usually poorly regulated in terms ofabsolute accuracy. So plan on doing a ratiometric measurement.3) R divider accuracy/tolerances.Regards, Dana.

author: Kleinstein
author_rank: Super Contributor
timestamp: October 06, 2016, 05:33:20 pm
content: The shown circuit might be OK for low resistance. There is even a milliohms meter using a similar way (though better, using differential readings). However in the MOhms range the method shown with directly reading with the ADS1115 is not hat good anymore. One can compensate for the input impedance, but that value is not that fixed and there will also be current noise.The piece of wood will likely be really high resistance. So the shown circuit is not good for it. In the MOhms range one could get better results using an OP and the Arduino internal ADC.

author: Wimberleytech
author_rank: Super Contributor
timestamp: October 07, 2016, 01:12:08 pm
content: Yes, the 15M range could be a problem as noted. Depending on your FS range for the ADS1115, the differential input impedance can be as low as 710K and best case for largest FS, 22M. You must also consider the common-mode impedance.

author: Rick Law
author_rank: Super Contributor
timestamp: October 07, 2016, 08:15:11 pm
content: Quote from: danadak on October 06, 2016, 12:13:00 pmDana point is important, particularly as the Arduino's voltage load (or input power) varies. Even worst if you are using USB power, you will go nuts! The USB power feeds through a diode first. This diode (as "power selector") will vary voltage a lot if your load (on the +5V of Arduino board) changes a lot.Since you are using only 3 channels with the ADS1115, you have 1 channel left open. You can use that channel to measure the board's +5V or measure another digital-out line. You can scale the other voltage according to that measurement. However, you are still left with the variation between digitial-out lines.

author: Kalvin
author_rank: Super Contributor
timestamp: October 07, 2016, 08:54:27 pm
content: ADS1115 can be configured to make differential measurements. Use two resistors instead of three resistors, and you can measure two differential voltages across the known two resistors. Then measure absolute voltage across the DUT. The measured voltage ratios will determine the DUT. It is practically insensitive to the VREF. The ADS1115 is a 16-bit ADC, so the dynamic range should be sufficient for the two resistors.

author: danadak
author_rank: Super Contributor
timestamp: October 07, 2016, 09:49:08 pm
content: A word of caution on this approach. Since sampling the 3 voltages is notdone simultaneously errors due to Vref changes still potentially a problem.In code turn off all other processes so that load on Vref is constant, unaffectedby I/O load changes, like flipping an LED on and off, or other load.Regards, Dana.

author: Inverted18650
author_rank: Frequent Contributor
timestamp: November 25, 2017, 01:47:40 am
content: I know this thread has been dead a while but Im playing with a similar project. I am actually making a complete multimeter. You can power the Mega from an outside VRef and use one of the 1115 pins to monitor the stability of the reference. Comparator mode seems very stable so far as well. I am curious if you completed this project and what you have learned along the way.Thank you.

author: Rick Law
author_rank: Super Contributor
timestamp: November 25, 2017, 10:53:58 pm
content: Quote from: Inverted18650 on November 25, 2017, 01:47:40 amFirst, regarding the use of ADS1115 to monitor your external reference. One would assume you would use a good external reference. That being the case, why would you trust ADS1115's internal reference over your presume good external reference?To the point of learning:One would think, what one can learn depends on where one started at. I was and still am a novice, so I had and still have a lot of room to improve. I did a project a few years back to see what I could learn from making a 4-channel volt-meter using the UNO (with AT Mega on DIP) internal ADC. I learned a hell of a lot just making it to work. The new of things I found most interesting were:(0) well, got better with working around the Arduino. Programming, using the LCD, using I2C, how to squeeze more function out of the limited memory...(1) because of the non-linear nature, a single ADC count at one end of the spectrum does not equal a count at the other end of the spectrum. As a novice, I was not expecting it to be significant. I experimented using the count as index to a lookup table with correction factor. That actually helped!(2) OpAmp oscillates far more easily than I expected. I learned that they would eons ago, but I didn't expect I would encounter it as often as one encounters cows on a cow farm.(3) hard to keep it consistent. I can get it working really nice, but the flipping the 2p3t switch one way and back would introduce far more errors than I thought. Little things like the quality of the switch contact or the jumpers all needs good attention.(4) in a nutshell, accuracy really do cost!(5) most important - I really did need reading glasses. I cannot be in denial anymore. My soldering improved 10 fold after I invest in a 10$ reading glasses.