AnswerBun.com

I am facing a problem of firing multiple interrupts on nodemcu 1.0 on single rising edge pulse.what is problem and what are the solutions?

Arduino Asked by CHETAN NIRADWAR on October 20, 2020

I am working on a project which involves counting the drops falling in a drip chamber of a IV fluid gravity based therapy bottle(saline bottle).I am using IR trans-receiver at the drip chamber to detect a drop falling. I am using a comparator to generate a pulse when ir voltage drops below a certain threshold. The output of comparator is connected to D1 of nodemcu. The ISR is called at rising pulse of comparator .But the nodemcu calls the ISR 3 to 5 times on a single drop.what should I do?plz help.

One Answer

The signal is probably "bouncing" between HIGH and LOW instead of performing a clean edge, just like it happens with buttons.

Two simple solutions:

  1. Hardware solution: use a schmidt-trigger instead of a comparator
  2. Software solution: define a dead-time for the signal aquisition (disable the interrupt when the desired edge has been detected and enable it again after "dead-time")

Answered by Sim Son on October 20, 2020

Add your own answers!

Related Questions

Ethernet Shield doesn’t work at all

0  Asked on December 30, 2021 by silencefog

   

Problem with STM32 and SDFat lib on other SPI port

1  Asked on December 28, 2021 by lucasn

     

Sea level pressure for BMP280

2  Asked on December 28, 2021

 

Receive an array of characters using SIM900 module

2  Asked on December 24, 2021 by reza-qasemi

         

Using a template inside a class

1  Asked on December 24, 2021 by guyd

 

Understanding heap fragmentation

0  Asked on December 19, 2021

 

Arduino Nano 33 Sense won’t upload

0  Asked on December 14, 2021 by electrouino

 

Serial port usage in code

2  Asked on December 11, 2021 by joe-mann

   

Arduino Nano 33 IoT StandardFirmataPlus

0  Asked on December 9, 2021 by girish-ravi

     

Ask a Question

Get help from others!

© 2023 AnswerBun.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP