summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWolfgang (Wolle) Ewald <wolfgang.ewald@wolles-elektronikkiste.de>2021-05-14 17:35:13 +0200
committerGitHub <noreply@github.com>2021-05-14 17:35:13 +0200
commit5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa (patch)
treedbbeb8efbd59e5cf9c296f48882f0f488014c971
parentUpdate Result_Format_Options.ino (diff)
downloadADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar.gz
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar.bz2
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar.lz
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar.xz
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.tar.zst
ADS1115_WE-5cf680fa5e3d9b684d86f5571dd5c4c5c2b98aaa.zip
Diffstat (limited to '')
-rw-r--r--examples/Single_Shot_Conv_Ready_Controlled/Single_Shot_Conv_Ready_Controlled.ino10
1 files changed, 8 insertions, 2 deletions
diff --git a/examples/Single_Shot_Conv_Ready_Controlled/Single_Shot_Conv_Ready_Controlled.ino b/examples/Single_Shot_Conv_Ready_Controlled/Single_Shot_Conv_Ready_Controlled.ino
index ea76f8f..8009dcc 100644
--- a/examples/Single_Shot_Conv_Ready_Controlled/Single_Shot_Conv_Ready_Controlled.ino
+++ b/examples/Single_Shot_Conv_Ready_Controlled/Single_Shot_Conv_Ready_Controlled.ino
@@ -14,8 +14,14 @@
#include<Wire.h>
#define I2C_ADDRESS 0x48
-ADS1115_WE adc(I2C_ADDRESS);
-// ADS1115_WE adc = ADS1115_WE(); // Alternative: uses default address 0x48
+/* There are several ways to create your ADS1115_WE object:
+ * ADS1115_WE adc = ADS1115_WE() -> uses Wire / I2C Address = 0x48
+ * ADS1115_WE adc = ADS1115_WE(I2C_ADDRESS) -> uses Wire / I2C_ADDRESS
+ * ADS1115_WE adc = ADS1115_WE(&wire2) -> uses the TwoWire object wire2 / I2C_ADDRESS
+ * ADS1115_WE adc = ADS1115_WE(&wire2, I2C_ADDRESS) -> all together
+ * Successfully tested with two I2C busses on an ESP32
+ */
+ADS1115_WE adc = ADS1115_WE(I2C_ADDRESS);
void setup() {
Wire.begin();