I am trying to control a relay board on my local ethernet but I cannot get this code working. It does not look like I am sending anything!.
I am supposed to send “192.168.1.19/30000/31” when i press my button.
Anyone can shed a light on this ?
def on() {
sendEvent(name: “switch”, value: “on”)
def ip = "192.168.1.19"
def port = "80"
def deviceNetworkId = “545558100024”
// def ip = “192.168.1.246”
// def port = “80”
// def deviceNetworkId = “24770354BC28”
// sendHubCommand(new physicalgraph.device.HubAction(""“GET /30000/31\n\n”"", physicalgraph.device.Protocol.LAN, “${deviceNetworkId}”))
sendHubCommand(new physicalgraph.device.HubAction(""“GET /30000/31\n\nHOST:${ip}:${port}”"", physicalgraph.device.Protocol.LAN, “${deviceNetworkId}”))
log.debug “Using ip: ${ip} and port: ${port} for device: ${deviceNetworkId}”
log.debug “lukke gardin høyre”
}