Smoke detection piston


#1

1) Give a description of the problem
When either detector detects smoke, it should execute lights on, send sms message and turn off HVAC.

2) What is the expected behavior?
See above.

3) What is happening/not happening?
Logs are giving error code. Copied this piston from another member and plugged my info in, not sure whats wrong.

**4)

**5) 6/18/2018, 6:34:32 AM +929ms
+1ms ╔Received event [Spencer].test = 1529321672929 with a delay of 0ms
+90ms ║RunTime Analysis CS > 15ms > PS > 31ms > PE > 44ms > CE
+93ms ║Runtime (40497 bytes) successfully initialized in 31ms (v0.3.104.20180323) (91ms)
+94ms ║╔Execution stage started
+109ms ║║Comparison (enum) clear is (string) detected = false (1ms)
+112ms ║║Comparison (enum) clear is (string) detected = false (1ms)
+118ms ║║Cancelling statement #15’s schedules…
+126ms ║║Error executing virtual command [].setVariable: (2ms) groovy.lang.MissingPropertyException: No such property: result for class: script_app_cc092d6b70234e8c9e377a62bdaf04677830d4380e0db255ca7dca6d8c906145 Possible solutions: request
+131ms ║║Condition #13 evaluated false (31ms)
+132ms ║║Condition group #1 evaluated false (state did not change) (32ms)
+136ms ║║An error occurred while executing the event: java.lang.NullPointerException: Cannot get property ‘v’ on null object
+138ms ║╚Execution stage complete. (45ms)
+142ms ╚Event processed successfully (142ms)


#2

I stopped at 26. You are setting an undefined variable.


#3

Ignorant move, got it now. Thanks, needed another set of eyes.


#4

No worries. You should see some of my first attempts, lol.