Go Down

Topic: two ADS1115 on the same Arduino (Read 405 times) previous topic - next topic

Wawa

#15
Jul 16, 2017, 11:31 pm Last Edit: Jul 16, 2017, 11:41 pm by Wawa
I have two ESP8266 and two Feather Huzzah ESP8266.  I will keep my actual project with the Arduino UNO and add later the ESP8266 to it for the wi-fi.
Don't add the ESP. Replace it with the ESP.
The MCU of the ESP is far more powerful than an Uno.

Migrating from a 5volt Arduino to a 3.3volt Arduino requires hardware changes.
Different voltage dividers and settings for the ADS1115, and maybe a different display.
You might have to start all over with an ESP based board.
Leo..

hddforensic

Ok

But I don't want to start from zero.  Everything is working for now
and I need my compressor to work next Wednesday.

I don't have the wi-fi conexion for now but it was not important
at the beginning.

I will continue the way I am and I will see what need to be improve
and I'm sure I will find some. (code etc...)

Question

except for the more powerful MCU, Is it possible to make the UNO communicate
with the ESP8266 and have full wi-fi conexion and feature ?


I have two model,

The ESP8266 with a USB conexion and a second 8266 smaller and that one
doesn't have any usb port.

Except for the USB, what is the difference ?
 

Wawa

Yes, an ESP module can work as WiFi bridge.
The module with USB probably has an onboard 3.3volt supply.
I use my (bare) ESP8266-12 modules stand-alone. never used them for WiFi only.
Somebody else has to answer that question.
Leo..

Johnny010

I often now just use esp8266 as it has an 80MHz clock and a WiFi chip. They are 3.3V but many components are available in 3.3V logic. The 80MHz is a nice bonus over the 16MHz of an UNO.

wvmarle

The ADS1115 can be used directly with the ESP8266, no changes needed. The display may be a bigger problem, operating at 5V only. Software needs some minor changes (mostly adding yield() calls to keep the tcp/ip part happy).

Most components can operate on both 3.3V and 5V, many only on 3.3V nowadays.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

Wawa

The ADS1115 can be used directly with the ESP8266, no changes needed.
Except for the voltage dividers and PGA settings.
The ADS1115 (any A/D) can't measure outside it's power/ground limits.
Voltage dividers have to drop to 2.048volt max, and PGA gain has to be set to 2.
Code has to be adjusted for these changes.
Leo..

wvmarle

I've used the ADS to read an NTC - 3.3V supply, NTC wired as voltage divider, ADS set to full range. No problem.
You indeed can't measure above 3.3V but with the NTC also in the 3.3V circuit that's not an issue. Loss of half the range doesn't matter really, either, as it's 16 bits so plenty of accuracy left.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

Wawa

An ADS1115 and thermistor (or pot) is not a very good match.
No ratiometric relationship between thermistor and reference voltage.
Leo..

wvmarle

An ADS1115 and thermistor (or pot) is not a very good match.
No ratiometric relationship between thermistor and reference voltage.
Why not? I'm using Vcc as reference, the ADS gets the same Vcc on the input.
I don't know how they internally create the reference voltages, but if this is not a good match, it's hard to think of anything that would be a good match as so many analog sensors give a 0-Vcc output.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

Wawa

Why not? I'm using Vcc as reference, the ADS gets the same Vcc on the input.
I don't know how they internally create the reference voltages, but if this is not a good match, it's hard to think of anything that would be a good match as so many analog sensors give a 0-Vcc output.
Keyword is ratiometric.

Take a 10k thermistor (@25C) and a 10k pull up resistor.
Connect it to a common 5volt Arduino (default Aref).
Thermistor/resistor tap has 2.5volt on it.
You get an A/D value of about 512.
Now lower supply voltage to 4volt.
You get 2volt on the tap, but... Aref has dropped to 4volt.
You still get an A/D value of 512 (= same temp readout).

The ADS1115 has an internal 1.25volt reference, that does not change.
If you power a thermistor/resistor from the 5volt or 3.3volt pin, any change in that supply voltage will change the temp readout.
Leo..

wvmarle

I see.
The 3.3V/5V output should be pretty stable (from the regulator - not expecting significant voltage drop there unless pushing the limits of the current draw), not expecting serious issues there. The error in B-coefficient and resistor values (all of which may be up to 5% from nominal) is likely to be a greater source of error, albeit a stable one (could be calibrated).
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

Go Up