Author Topic: C4 Upgrade Bug  (Read 494 times)

mahodder

  • Newbie
  • *
  • Posts: 2
C4 Upgrade Bug
« on: November 24, 2009, 12:42:42 AM »
There is a weird bug I came across with the new rules system / C4.

- Set up x10 on channel 4
- Set up a widget for an on/off state
- Set up a rule to turn on the widget / x10 device when the module loses connectivity
- Sync the rules
- Disconnect the device from the internet

After that the module will not boot again or go online correctly, for me it would start to boot then stop at "3" on the screen. The only way I could get it working again was by holding the flash button while booting and resetting the device.

I replicated the issue twice using the above steps. Weird!

iobridge

  • Administrator
  • Hero Member
  • *****
  • Posts: 668
    • ioBridge Support
Re: C4 Upgrade Bug
« Reply #1 on: November 24, 2009, 01:12:28 AM »
It's actually doing what it is supposed to be doing (to some degree).

What's happening is rule is executing over and over - as fast as the processor can excute the rule. That is interruppting it from getting online.

To fix it you need to make use of the Variable Value.

Add this condition to your rule: Variable A Value is not equal to 10
Add this action to your rule: Set Variable A Value to 10

Add a new standard rule

Add this condition to the new rule: Module is Online
Add this action: Set Variable A Value to 20

Sync Rules

This is not so obvious, but what this does is cause the rule to only execute once while the module is offline. When the module goes back online the condition resets.

I hope this makes some sense...Let us know how it works.

« Last Edit: November 24, 2009, 01:17:31 AM by iobridge »
ioBridge Support
Community Team

mahodder

  • Newbie
  • *
  • Posts: 2
Re: C4 Upgrade Bug
« Reply #2 on: November 24, 2009, 01:16:54 AM »
Ah yes, that makes sense now, thanks for the quick reply! Back to playing with the new features :)