more G-Labs products

Author Topic: Another wall switch question  (Read 6047 times)

October 25, 2014, 12:11:41 PM
Reply #15

mvdarend

  • *****
  • Information
  • Hero Member
  • Posts: 431
Quote
u should return false, and if your code didn't find the event it should return true. ie, the opposite of what u have.

That's probably the reason a second Program wasn't firing properly, thanks for the tip. I've switched the true/false returns so it won't get in the way of other stuff in the future.

Edit: Yes, you are correct, by having the true/false returns the wrong way round, the Switch wasn't firing in a different program.
« Last Edit: October 25, 2014, 12:22:42 PM by mvdarend »

October 31, 2014, 08:41:24 PM
Reply #16

mvdarend

  • *****
  • Information
  • Hero Member
  • Posts: 431
While test/playing with my new RFXtrx433E I noticed a *lot* of events firing, see image. (1084, 1086 and 1087 are each programs like the code in my previous post)

Is this something I should be worried about? The Pi isn't running hot or anything like that, CPU cycles between 10 - 30%

October 31, 2014, 11:37:31 PM
Reply #17

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
That is indicating that HG is running those programs on a timer of some kind most likely.  I have similar events in my activity logs.  If you don't have a timer then that might be different, but I don't believe it's an issue.

EDIT:  After looking again, I see that these events are firing every 10 seconds or so.  If you want them to run less often you would have to change your timer to a longer duration.  If there is no timer (which I'm not seeing in the code you posted), it is most likely triggering off the "When.ModuleParameterChanged( (module, parameter) => " statement. 
« Last Edit: October 31, 2014, 11:41:04 PM by bkenobi »