Announcement

Collapse
No announcement yet.

Debounce ?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Debounce ?

    Hi all,

    i have a simple reed relais connected to my mailbox.
    Everytime when it is being opened i get a push message from pushover.

    This seemed to work pretty good for some time, although i did get false notices, it takes a picture also and then nobody was there.
    Yesterday i also noticed when i was at home and a lightning storm was there. that when lightning strikes the alarm also was being triggered.

    Another thing is that, when i open the lid like today just once.
    I get flooded with messages, like 10- 20 -30 -50 in a row and the lid is just being opened once.

    It is connected by a network cable from thats aprox 20 meters, to the mega and on the other and a simple reed relais tube with a magnet.

    Is this where debounce comes in because this is a very unreliable thing right now , i even disabled it because not only it is using all my push messages but when im at work my phone is vibrating from the message flood for several minutes...

    Thanks


    This is what i logged at debug: as being 5 input 5 , the relay.
    1-9-2015 ,09:42:33.508 Data Received:1 I 5 0
    1-9-2015 ,09:42:33.510 Timer 1 Reset
    1-9-2015 ,09:42:58.336 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.338 Timer 1 Reset
    1-9-2015 ,09:42:58.371 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.373 Timer 1 Reset
    1-9-2015 ,09:42:58.405 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.406 Timer 1 Reset
    1-9-2015 ,09:42:58.592 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.594 Timer 1 Reset
    1-9-2015 ,09:42:58.621 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.623 Timer 1 Reset
    1-9-2015 ,09:42:58.692 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.692 Timer 1 Reset
    1-9-2015 ,09:42:58.719 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.721 Timer 1 Reset
    1-9-2015 ,09:42:58.821 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.823 Timer 1 Reset
    1-9-2015 ,09:42:58.844 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.846 Timer 1 Reset
    1-9-2015 ,09:42:58.895 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.897 Timer 1 Reset
    1-9-2015 ,09:42:58.922 Data Received:1 I 5 1
    1-9-2015 ,09:42:58.924 Timer 1 Reset
    1-9-2015 ,09:42:58.971 Data Received:1 I 5 0
    1-9-2015 ,09:42:58.973 Timer 1 Reset
    1-9-2015 ,09:42:59.002 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.004 Timer 1 Reset
    1-9-2015 ,09:42:59.071 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.073 Timer 1 Reset
    1-9-2015 ,09:42:59.102 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.104 Timer 1 Reset
    1-9-2015 ,09:42:59.211 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.215 Timer 1 Reset
    1-9-2015 ,09:42:59.240 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.242 Timer 1 Reset
    1-9-2015 ,09:42:59.352 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.354 Timer 1 Reset
    1-9-2015 ,09:42:59.383 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.385 Timer 1 Reset
    1-9-2015 ,09:42:59.440 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.442 Timer 1 Reset
    1-9-2015 ,09:42:59.461 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.463 Timer 1 Reset
    1-9-2015 ,09:42:59.510 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.512 Timer 1 Reset
    1-9-2015 ,09:42:59.545 Data Received:1 I 5 1
    1-9-2015 ,09:42:59.547 Timer 1 Reset
    1-9-2015 ,09:42:59.614 Data Received:1 I 5 0
    1-9-2015 ,09:42:59.617 Timer 1 Reset
    1-9-2015 ,09:43:00.768 Data Received:1 I 5 1
    1-9-2015 ,09:43:00.770 Timer 1 Reset
    1-9-2015 ,09:43:00.940 Data Received:1 I 5 0
    1-9-2015 ,09:43:00.942 Timer 1 Reset
    1-9-2015 ,09:43:00.963 Data Received:1 I 5 1
    1-9-2015 ,09:43:00.965 Timer 1 Reset
    1-9-2015 ,09:43:01.153 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.155 Timer 1 Reset
    1-9-2015 ,09:43:01.188 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.190 Timer 1 Reset
    1-9-2015 ,09:43:01.233 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.235 Timer 1 Reset
    1-9-2015 ,09:43:01.264 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.266 Timer 1 Reset
    1-9-2015 ,09:43:01.311 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.313 Timer 1 Reset
    1-9-2015 ,09:43:01.346 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.348 Timer 1 Reset
    1-9-2015 ,09:43:01.455 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.457 Timer 1 Reset
    1-9-2015 ,09:43:01.487 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.489 Timer 1 Reset
    1-9-2015 ,09:43:01.574 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.576 Timer 1 Reset
    1-9-2015 ,09:43:01.617 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.621 Timer 1 Reset
    1-9-2015 ,09:43:01.670 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.670 Timer 1 Reset
    1-9-2015 ,09:43:01.699 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.705 Timer 1 Reset
    1-9-2015 ,09:43:01.752 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.754 Timer 1 Reset
    1-9-2015 ,09:43:01.780 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.781 Timer 1 Reset
    1-9-2015 ,09:43:01.864 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.865 Timer 1 Reset
    1-9-2015 ,09:43:01.883 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.885 Timer 1 Reset
    1-9-2015 ,09:43:01.932 Data Received:1 I 5 0
    1-9-2015 ,09:43:01.934 Timer 1 Reset
    1-9-2015 ,09:43:01.959 Data Received:1 I 5 1
    1-9-2015 ,09:43:01.963 Timer 1 Reset
    1-9-2015 ,09:43:02.030 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.031 Timer 1 Reset
    1-9-2015 ,09:43:02.065 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.065 Timer 1 Reset
    1-9-2015 ,09:43:02.117 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.119 Timer 1 Reset
    1-9-2015 ,09:43:02.139 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.141 Timer 1 Reset
    1-9-2015 ,09:43:02.209 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.209 Timer 1 Reset
    1-9-2015 ,09:43:02.240 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.242 Timer 1 Reset
    1-9-2015 ,09:43:02.373 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.375 Timer 1 Reset
    1-9-2015 ,09:43:02.403 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.405 Timer 1 Reset
    1-9-2015 ,09:43:02.508 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.510 Timer 1 Reset
    1-9-2015 ,09:43:02.541 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.543 Timer 1 Reset
    1-9-2015 ,09:43:02.656 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.660 Timer 1 Reset
    1-9-2015 ,09:43:02.688 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.690 Timer 1 Reset
    1-9-2015 ,09:43:02.731 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.735 Timer 1 Reset
    1-9-2015 ,09:43:02.762 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.764 Timer 1 Reset
    1-9-2015 ,09:43:02.832 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.834 Timer 1 Reset
    1-9-2015 ,09:43:02.865 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.865 Timer 1 Reset
    1-9-2015 ,09:43:02.951 Data Received:1 I 5 0
    1-9-2015 ,09:43:02.951 Timer 1 Reset
    1-9-2015 ,09:43:02.981 Data Received:1 I 5 1
    1-9-2015 ,09:43:02.983 Timer 1 Reset
    1-9-2015 ,09:43:03.030 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.031 Timer 1 Reset
    1-9-2015 ,09:43:03.063 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.065 Timer 1 Reset
    1-9-2015 ,09:43:03.112 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.114 Timer 1 Reset
    1-9-2015 ,09:43:03.145 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.147 Timer 1 Reset
    1-9-2015 ,09:43:03.190 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.192 Timer 1 Reset
    1-9-2015 ,09:43:03.223 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.225 Timer 1 Reset
    1-9-2015 ,09:43:03.272 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.276 Timer 1 Reset
    1-9-2015 ,09:43:03.301 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.303 Timer 1 Reset
    1-9-2015 ,09:43:03.352 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.354 Timer 1 Reset
    1-9-2015 ,09:43:03.381 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.381 Timer 1 Reset
    1-9-2015 ,09:43:03.446 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.448 Timer 1 Reset
    1-9-2015 ,09:43:03.485 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.487 Timer 1 Reset
    1-9-2015 ,09:43:03.528 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.530 Timer 1 Reset
    1-9-2015 ,09:43:03.563 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.563 Timer 1 Reset
    1-9-2015 ,09:43:03.656 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.658 Timer 1 Reset
    1-9-2015 ,09:43:03.680 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.682 Timer 1 Reset
    1-9-2015 ,09:43:03.752 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.756 Timer 1 Reset
    1-9-2015 ,09:43:03.797 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.799 Timer 1 Reset
    1-9-2015 ,09:43:03.836 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.838 Timer 1 Reset
    1-9-2015 ,09:43:03.862 Data Received:1 I 5 1
    1-9-2015 ,09:43:03.864 Timer 1 Reset
    1-9-2015 ,09:43:03.990 Data Received:1 I 5 0
    1-9-2015 ,09:43:03.994 Timer 1 Reset
    1-9-2015 ,09:43:04.022 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.024 Timer 1 Reset
    1-9-2015 ,09:43:04.092 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.096 Timer 1 Reset
    1-9-2015 ,09:43:04.123 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.127 Timer 1 Reset
    1-9-2015 ,09:43:04.192 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.194 Timer 1 Reset
    1-9-2015 ,09:43:04.221 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.223 Timer 1 Reset
    1-9-2015 ,09:43:04.311 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.313 Timer 1 Reset
    1-9-2015 ,09:43:04.338 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.340 Timer 1 Reset
    1-9-2015 ,09:43:04.389 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.391 Timer 1 Reset
    1-9-2015 ,09:43:04.422 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.424 Timer 1 Reset
    1-9-2015 ,09:43:04.496 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.498 Timer 1 Reset
    1-9-2015 ,09:43:04.522 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.524 Timer 1 Reset
    1-9-2015 ,09:43:04.573 Data Received:1 I 5 0
    1-9-2015 ,09:43:04.574 Timer 1 Reset
    1-9-2015 ,09:43:04.600 Data Received:1 I 5 1
    1-9-2015 ,09:43:04.600 Timer 1 Reset
    1-9-2015 ,09:43:05.830 Data Received:1 I 5 0
    1-9-2015 ,09:43:05.832 Timer 1 Reset
    1-9-2015 ,09:43:05.860 Data Received:1 I 5 1
    1-9-2015 ,09:43:05.860 Timer 1 Reset
    1-9-2015 ,09:43:05.914 Data Received:1 I 5 0
    1-9-2015 ,09:43:05.916 Timer 1 Reset
    1-9-2015 ,09:43:05.942 Data Received:1 I 5 1
    1-9-2015 ,09:43:05.944 Timer 1 Reset
    1-9-2015 ,09:43:06.010 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.012 Timer 1 Reset
    1-9-2015 ,09:43:06.039 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.045 Timer 1 Reset
    1-9-2015 ,09:43:06.090 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.092 Timer 1 Reset
    1-9-2015 ,09:43:06.137 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.139 Timer 1 Reset
    1-9-2015 ,09:43:06.311 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.313 Timer 1 Reset
    1-9-2015 ,09:43:06.346 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.348 Timer 1 Reset
    1-9-2015 ,09:43:06.590 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.590 Timer 1 Reset
    1-9-2015 ,09:43:06.621 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.623 Timer 1 Reset
    1-9-2015 ,09:43:06.672 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.674 Timer 1 Reset
    1-9-2015 ,09:43:06.699 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.701 Timer 1 Reset
    1-9-2015 ,09:43:06.774 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.776 Timer 1 Reset
    1-9-2015 ,09:43:06.807 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.807 Timer 1 Reset
    1-9-2015 ,09:43:06.928 Data Received:1 I 5 0
    1-9-2015 ,09:43:06.930 Timer 1 Reset
    1-9-2015 ,09:43:06.959 Data Received:1 I 5 1
    1-9-2015 ,09:43:06.961 Timer 1 Reset
    1-9-2015 ,09:43:07.035 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.037 Timer 1 Reset
    1-9-2015 ,09:43:07.061 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.063 Timer 1 Reset
    1-9-2015 ,09:43:07.153 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.166 Timer 1 Reset
    1-9-2015 ,09:43:07.180 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.182 Timer 1 Reset
    1-9-2015 ,09:43:07.248 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.250 Timer 1 Reset
    1-9-2015 ,09:43:07.283 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.285 Timer 1 Reset
    1-9-2015 ,09:43:07.330 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.332 Timer 1 Reset
    1-9-2015 ,09:43:07.358 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.360 Timer 1 Reset
    1-9-2015 ,09:43:07.406 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.412 Timer 1 Reset
    1-9-2015 ,09:43:07.442 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.444 Timer 1 Reset
    1-9-2015 ,09:43:07.490 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.490 Timer 1 Reset
    1-9-2015 ,09:43:07.518 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.526 Timer 1 Reset
    1-9-2015 ,09:43:07.569 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.571 Timer 1 Reset
    1-9-2015 ,09:43:07.600 Data Received:1 I 5 1
    1-9-2015 ,09:43:07.602 Timer 1 Reset
    1-9-2015 ,09:43:07.653 Data Received:1 I 5 0
    1-9-2015 ,09:43:07.655 Timer 1 Reset
    I have shortened it a bit since it took 20 seconds to scroll down but you get the point haha
    Last edited by Vincenttor; September 1, 2015, 03:10 AM.

    #2
    Yes this is exactly what debounce is for. Try and up the time you have set. Do you have it set at 0 as even with the default there should not be that many changes per second. This could also be interface on the 20m cable you have that is causing this. I would also set your event to not retrigger for 1min to stop you getting lots of messages.

    Greig.

    Sent from my HTC One using Tapatalk
    Zwave = Z-Stick, 3xHSM100� 7xACT ZDM230, 1xEverspring SM103, 2xACT HomePro ZRP210.
    X10 = CM12U, 2xAM12, 1xAW10, 1 x TM13U, 1xMS13, 2xHR10, 2xSS13
    Other Hardware = ADI Ocelot + secu16, Global Cache GC100, RFXtrx433, 3 x Foscams.
    Plugings = RFXcom, ActiveBackup, Applied Digital Ocelot, BLDeviceMatrix, BLGarbage, BLLAN, Current Cost, Global Cache GC100,HSTouch Android, HSTouch Server, HSTouch Server Unlimited, NetCAM, PowerTrigger, SageWebcamXP, SqueezeBox, X10 CM11A/CM12U.
    Scripts =
    Various

    Comment


      #3
      Originally posted by Vincenttor View Post
      Hi all,

      i have a simple reed relais connected to my mailbox.
      Everytime when it is being opened i get a push message from pushover.

      This seemed to work pretty good for some time, although i did get false notices, it takes a picture also and then nobody was there.
      Yesterday i also noticed when i was at home and a lightning storm was there. that when lightning strikes the alarm also was being triggered.

      Another thing is that, when i open the lid like today just once.
      I get flooded with messages, like 10- 20 -30 -50 in a row and the lid is just being opened once.

      It is connected by a network cable from thats aprox 20 meters, to the mega and on the other and a simple reed relais tube with a magnet.

      Is this where debounce comes in because this is a very unreliable thing right now , i even disabled it because not only it is using all my push messages but when im at work my phone is vibrating from the message flood for several minutes...

      Thanks


      This is what i logged at debug: as being 5 input 5 , the relay.


      I have shortened it a bit since it took 20 seconds to scroll down but you get the point haha
      I set my debounce to 500 and snub noise on longer cables with a 1uf capacitor. The capacitor is a non-polarized and is located at the board between the input pin and ground. This also may help with the lightning - your 20 meter cable is a long antenna during lightning storms. I would set any associated event to "cannot re-run for" 5 minutes to stop repeated notifications if they were to occur.
      Last edited by randy; September 1, 2015, 07:48 AM.

      Comment


        #4
        Thanks guys for the quick reaction.
        I have set the debounce to 500 now and will set a rule that the event can't be re triggered in x minutes.
        Stupid that i haven't thought of this....
        Ordered a capacitor as well to connect it at the board side and hope this solves everything described above

        Will let you guys know how it goes.

        Comment


          #5
          Originally posted by Vincenttor View Post
          Thanks guys for the quick reaction.
          I have set the debounce to 500 now and will set a rule that the event can't be re triggered in x minutes.
          Stupid that i haven't thought of this....
          Ordered a capacitor as well to connect it at the board side and hope this solves everything described above

          Will let you guys know how it goes.
          That should work. I helped a friend with an especially troublesome input on a long wire. We ended up using an opto-isolated relay board, between his tilt sensor and the Arduino input. The mercury switch was connected to the relay board input, then the relay was used to pull the Arduino input down. We put a capacitor on the Arduino as well as the input to the relay board. This stopped every false trigger. Because the opto-isolator provides a very low impedance load to the switch, it is much less susceptible to noise.

          Comment


            #6
            Well , since the modifications that you described i haven't had any trouble
            Thanks for that, always great how fast the response on questions is for this great plugin !
            and for the clear explanation !!!
            hat off

            Comment


              #7
              Originally posted by Vincenttor View Post
              Well , since the modifications that you described i haven't had any trouble
              Thanks for that, always great how fast the response on questions is for this great plugin !
              and for the clear explanation !!!
              hat off
              Great news.

              I think we try our best and as Randy has tested my plugin for a long time now I think he gets my way of working and also is a big help to me with explaining things in detail as I am not the best at that.

              Greig.
              Zwave = Z-Stick, 3xHSM100� 7xACT ZDM230, 1xEverspring SM103, 2xACT HomePro ZRP210.
              X10 = CM12U, 2xAM12, 1xAW10, 1 x TM13U, 1xMS13, 2xHR10, 2xSS13
              Other Hardware = ADI Ocelot + secu16, Global Cache GC100, RFXtrx433, 3 x Foscams.
              Plugings = RFXcom, ActiveBackup, Applied Digital Ocelot, BLDeviceMatrix, BLGarbage, BLLAN, Current Cost, Global Cache GC100,HSTouch Android, HSTouch Server, HSTouch Server Unlimited, NetCAM, PowerTrigger, SageWebcamXP, SqueezeBox, X10 CM11A/CM12U.
              Scripts =
              Various

              Comment

              Working...
              X