The OH1 Daikin binding is broken and does no longer work (at least not with my BRP069B device)
Here is an example how to gain control of your AC using the http binding and the REGEX transformation.
(install both in Paper UI !)
One ‘http://“ip”/aircon/get_control_info?’ returns multiple parameters. (try it in your browser)
Here are my items for picking out single values from the cache string:
ret=OK,pow=1,mode=4,adv=,stemp=24.0,shum=0,dt1=25.0,dt2=M,dt3=25.0,dt4=24.0,dt5=24.0,dt7=25.0,dh1=AUTO,dh2=50,dh3=0,dh4=0,dh5=0,dh7=AUTO,dhh=50,b_mode=4,b_stemp=24.0,b_shum=0,alert=255,f_rate=A,f_dir=0,b_f_rate=A,b_f_dir=0,dfr1=5,dfr2=5,dfr3=5,dfr4=A,dfr5=A,dfr6=5,dfr7=5,dfrh=5,dfd1=0,dfd2=0,dfd3=0,dfd4=0,dfd5=0,dfd6=0,dfd7=0,dfdh=0
http.cfg: (exchange 192.168.1.8 with your IP, set interval times to your liking)
# configuration of the first cache item
ACcache.url=http://192.168.1.8/aircon/get_control_info?
ACcache.updateInterval=10000
# configuration of the second cache item
ACsensorCache.url=http://192.168.1.8/aircon/get_sensor_info?
ACsensorCache.updateInterval=60000
AC.items
// virtual items
Switch vACpowerState // 1=ON, 0=OFF
Number vACsetTemp "Target temperature [%.0f °C]" <temperature>
String vACmode "Mode" <heating>
String vACfanRate "Fan" <fan>
// http items
String ACpowerState {http="<[ACcache:6000:REGEX(.*?pow=.*?([0-9]*).*)]"}
String ACsetTemp {http="<[ACcache:1000:REGEX(.*?stemp=.*?([0-9\\.0-9]*).*)]"}
String ACmode {http="<[ACcache:1000:REGEX(.*?mode=.*?([0-9]*).*)]"}
String ACfanRate {http="<[ACcache:1000:REGEX(.*?f_rate=.*?([AB34567]*).*)]"}
String ACfanDir {http="<[ACcache:1000:REGEX(.*?f_dir=.*?([0-9\\.0-9]*).*)]"}
String ACinDoorTemp "Inside temperature [%s °C]" <temperature> {http="<[ACsensorCache:1000:REGEX(.*?htemp=.*?([0-9\\.0-9]*).*)]"}
String ACoutDoorTemp "Outside temperature [%s °C]" <temperature> {http="<[ACsensorCache:1000:REGEX(.*?otemp=.*?([0-9\\.0-9]*).*)]"}
String NoDaikACinTempOut "Outside temperature not available (< 0 °C)" <temperature> // show this when outside temp == "" aka < 0 °C
.sitemap (proudly stolen from original binding example)
Text item=ac label="AC" icon="climate" {
Frame label="Settings"{
Switch item=vACpowerState label="On/Off"
Setpoint item=vACsetTemp minValue=18 maxValue=30 step=1
Switch item=vACmode mappings=["4"="Heat", "3"="Cool", "6"="Fan", "0"="Auto" ] label="Mode" // not used: 2="Dry"
Switch item=vACfanRate mappings=[ "3"="1", "4"="2", "5"="3", "6"="4", "7"="5", "A"="Auto" ] label="Fan" // not used: B="Silent" when setting B, AC returns A
}
Frame label="Temperature values" {
Text item=ACoutDoorTemp visibility=[ACoutDoorTemp != ""]
Text item=NoDaikACinTempOut visibility=[ACoutDoorTemp == ""] labelcolor=[ACoutDoorTemp== "" ="grey"]
Text item=ACinDoorTemp
}
}
ac.rules
var String acHost = "http://192.168.1.8:80/"
var String acCommandString = ""
rule "System start"
when
System started
then
// force an update to current values. A '-' could be sent to the AC, but is just ignored
postUpdate(ACpowerState, "-")
postUpdate(ACsetTemp, "-")
postUpdate(ACmode, "-")
postUpdate(ACfanRate, "-")
end
// virtual AC items changed
rule 'vACpowerState'
when
Item vACpowerState changed
then
logInfo("vACpowerState", "vACpowerState=" + vACpowerState.state);
var String newState
if (vACpowerState.state == ON) newState="1" else newState="0"
acCommandString = "aircon/set_control_info?pow=" + newState + "&mode=" + ACmode.state + "&stemp=" + ACsetTemp.state + "&shum=0&f_rate=" + ACfanRate.state + "&f_dir=" + ACfanDir.state
logInfo("vACpowerState", "acCommandString=" + acCommandString)
logInfo("vACpowerState", "sendHttpPostRequest() returns: " + sendHttpPostRequest(acHost + acCommandString, 5000))
end
rule 'vACsetTemp'
when
Item vACsetTemp changed
then
logInfo("ACsetTemp", "vACsetTemp=" + vACsetTemp.state)
acCommandString = "aircon/set_control_info?pow=" + ACpowerState.state + "&mode=" + ACmode.state + "&stemp=" + vACsetTemp.state + ".0&shum=0&f_rate=" + ACfanRate.state + "&f_dir=" + ACfanDir.state
logInfo("ACsetTemp", "acCommandString=" + acCommandString)
logInfo("ACsetTemp", "sendHttpPostRequest() returns: " + sendHttpPostRequest(acHost + acCommandString, 5000))
end
rule 'vACmode'
when
Item vACmode changed
then
logInfo("vACmode", "vACmode=" + vACmode.state)
acCommandString = "aircon/set_control_info?pow=" + ACpowerState.state + "&mode=" + vACmode.state + "&stemp=" + ACsetTemp.state + ".0&shum=0&f_rate=" + ACfanRate.state + "&f_dir=" + ACfanDir.state
logInfo("vACmode", "acCommandString=" + acCommandString)
logInfo("vACmode", "sendHttpPostRequest() returns: " + sendHttpPostRequest(acHost + acCommandString, 5000))
end
rule 'vACfanRate'
when
Item vACfanRate changed
then
logInfo("vACfanRate", "vACfanRate=" + vACfanRate.state)
acCommandString = "aircon/set_control_info?pow=" + ACpowerState.state + "&mode=" + ACmode.state + "&stemp=" + ACsetTemp.state + ".0&shum=0&f_rate=" + vACfanRate.state + "&f_dir=" + ACfanDir.state
logInfo("vACfanRate", "acCommandString=" + acCommandString)
logInfo("vACfanRate", "sendHttpPostRequest() returns: " + sendHttpPostRequest(acHost + acCommandString, 5000))
end
// AC settings changed from APP or IR remote (remember: IR remote does not reflect changes made by APP or OH)
rule 'ACpowerUpdate'
when
Item ACpowerState changed
then
if (ACpowerState.state != "-") {
if (ACpowerState.state == "1") postUpdate(vACpowerState, ON) else if (ACpowerState.state == "0") postUpdate(vACpowerState, OFF)
logInfo("ACpowerUpdate", "vACpowerState=" + vACpowerState.state)
}
end
rule 'ACsetTempUpdate'
when
Item ACsetTemp changed
then
if (ACsetTemp.state != "-") {
logInfo("ACsetTempUpdate", "ACsetTemp=" + ACsetTemp.state)
postUpdate(vACsetTemp, Double::parseDouble(ACsetTemp.state.toString))
}
end
rule 'ACmodeUpdate'
when
Item ACmode changed
then
if (ACmode.state != "-") {
logInfo("ACmode", "ACmode=" + ACmode.state)
postUpdate(vACmode, ACmode.state)
}
end
rule 'ACfanRateUpdate'
when
Item ACfanRate changed
then
if (ACfanRate.state != "-") {
logInfo("ACfanRate", "ACfanRate=" + ACfanRate.state)
postUpdate(vACfanRate, ACfanRate.state)
}
end
Basic UI:
To change setting from any other rule, postUpdate to the virtual item.
Example; set temperature to 20 degrees: postUpdate(vACsetTemp, 20)
Have fun!
Please report back if this works on other WiFi adapters as well.