cancel scene if trane temp is under 75F?

I have a motion-triggered scene to turn on a ceiling fan. I do not want the fan to come on if it is under 75F. The trane is device 30.

I tried this from the wiki:

Third, the last step is to add the condition. To the right of the scene's description you'll see the button "Luup Scene". Click it and in the code box, copy and paste the following: local lul_temp = luup.variable_get("urn:upnp-org:serviceId:TemperatureSensor1","CurrentTemperature", 30) if (tonumber(lul_temp) < 23.8) then return false end

…but it still triggers. Is “urn:upnp-org:serviceId:TemperatureSensor1”,“CurrentTemperature” correct for the trane?

Any ideas?

It is.

Try it with the temp in Fahrenheit in there:

  if (tonumber(lul_temp) < 75) then

Thanks, OTI.

Well, I had the device ID wrong. Not 30, but 41. Argh.

It works, but do I use F or C? The wiki says to convert to C.

It is now 68 according to the Trane thermostat. The luup using <75 cancels the scene. With <60 it runs. So I assume I do use F?

Yup.