Bond Setspeed Help


#1

1) Give a description of the problem
I’m trying to use a virtual switch + bond requests to set it up so that if the fan is off down tap up on the switch sets the speed to 1. It’s not working.

my code is as follows, I’ve also tried other variants.

concat(text(“http://192.168.xx.xxx/v2/devices/"),DeviceID,text("/actions/SetSpeed1,DeviceID,text(/actions/SetSpeed1)”))

i already know the deviceid and concat function is fine as increasespeed works without any issues.

2) What is the expected behaviour?
(see above)’

3) What is happening/not happening?
it’s not turning on

**4) Post a Green Snapshot of the piston!
The code issue is the last section.


#2

I would try combining IF statements at line 34 and 46 and eliminate competing triggers.

IF Device's button #1 gets pushed
  Then
    IF Switch 7 switch is on
      Then
        Make a PUT (IncreaseSpeed)
      Else
        Make a PUT (SetSpeed)
    END IF
END IF

#3

i tried this and it’s still failing. Support said: The action is SetSpeed , you need to do a PUT to http://192.168.xx.xxx/v2/devices/{deviceID}/actions/SetSpeed with a HTTP body {"argument":1}

You can check the docs here:
http://docs-local.appbond.com/#tag/Device-Actions

But this didn’t help me