so im writing a plugin and i need to use greater that & lesser than but it runs in the Implementation file the problem is i cant get it to work
using < or > in xml indicates a tag which give me Lua error
sp here is my code
[code]<?xml version="1.0"?>
function virtual_dimmable_light_startup (lul_device)
luup.log (“Virtual dimmable light running…”)
end
virtual_dimmable_light_startup
urn:upnp-org:serviceId:Dimming1
SetLoadLevelTarget
local CompSet
luup.variable_set (“urn:upnp-org:serviceId:Dimming1”, “LoadLevelTarget”, lul_settings.newLoadlevelTarget, lul_device)
luup.variable_set (“urn:upnp-org:serviceId:Dimming1”, “LoadLevelStatus”, lul_settings.newLoadlevelTarget, lul_device)
local CompSet = luup.variable_get ("urn:upnp-org:serviceId:Dimming1", "LoadLevelTarget", 523)
local CompSet = luup.variable_get ("urn:upnp-org:serviceId:Dimming1", "LoadLevelTarget", 523)
if (tonumber (CompSet, 10) == 0) then
luup.call_action(weofwofejwfowf)
elseif ((tonumber (CompSet, 10) >= 1) and (tonumber (CompSet, 10) <= 33 )) then
luup.call_action(weofwofejwfowf)
elseif ((tonumber (CompSet, 10) >= 34) and (tonumber (CompSet, 10) <= 66 )) then
luup.call_action(weofwofejwfowf)
elseif ((tonumber (CompSet, 10) >= 67) and (tonumber (CompSet, 10) <= 100 )) then
luup.call_action(weofwofejwfowf)
end
if (tonumber (lul_settings.newLoadlevelTarget, 10) == 0) then
luup.variable_set ("urn:upnp-org:serviceId:SwitchPower1", "Status", "0", lul_device)
else
luup.variable_set ("urn:upnp-org:serviceId:SwitchPower1", "Status", "1", lul_device)
end
return 4, 5
</job>
</action>
</actionList>
[/code]
I have tried replacing it with (“>=” but still nothing
“luup.call_action(weofwofejwfowf)” is really not what im calling but its just a place holder
the function works perfectly when not in the xml format