summaryrefslogtreecommitdiffstats
path: root/examples/Alert_Window_Mode_with_Latch
diff options
context:
space:
mode:
authorWolfgang (Wolle) Ewald <wolfgang.ewald@wolles-elektronikkiste.de>2020-06-28 20:57:05 +0200
committerGitHub <noreply@github.com>2020-06-28 20:57:05 +0200
commit96b442808d480d4c8adf44ab1026bf2c22a57b1e (patch)
treef6fbb7faebc17ba2ff9c26de02165abfebbb766e /examples/Alert_Window_Mode_with_Latch
parentUpdate Alert_Window_Mode.ino (diff)
downloadADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar.gz
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar.bz2
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar.lz
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar.xz
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.tar.zst
ADS1115_WE-96b442808d480d4c8adf44ab1026bf2c22a57b1e.zip
Diffstat (limited to 'examples/Alert_Window_Mode_with_Latch')
-rw-r--r--examples/Alert_Window_Mode_with_Latch/Alert_Window_Mode_with_Latch.ino5
1 files changed, 2 insertions, 3 deletions
diff --git a/examples/Alert_Window_Mode_with_Latch/Alert_Window_Mode_with_Latch.ino b/examples/Alert_Window_Mode_with_Latch/Alert_Window_Mode_with_Latch.ino
index 232283c..85f3667 100644
--- a/examples/Alert_Window_Mode_with_Latch/Alert_Window_Mode_with_Latch.ino
+++ b/examples/Alert_Window_Mode_with_Latch/Alert_Window_Mode_with_Latch.ino
@@ -3,7 +3,7 @@
*
* This sketch shows how you can use the alert pin with the latch function. The
* only difference to Alert_Window_Mode.ino is that latch is enabled (line 112)
-* and that the alert pin needs to be unlatched (line 148). Try and see the difference.
+* and that the alert pin needs to be unlatched (line 147). Try and see the difference.
* As an alternative to the unlatchAlertPin function you can use getResult_V.
* Internally unlatchAlertPin just performs a read of the conversion register.
*
@@ -131,7 +131,6 @@ void setup() {
Serial.println();
Serial.println("Waiting for Value out of Limit");
attachInterrupt(digitalPinToInterrupt(interruptPin), outOfLimitAlert, FALLING);
- adc.startSingleMeasurement();
}
void loop() {
@@ -150,6 +149,6 @@ void loop() {
}
void outOfLimitAlert(){
- detachInterrupt(2);
+ detachInterrupt(interruptPin);
outOfLimit = true;
}