Most functions work, but I am struggling with a few last problems.
One of them is in a LUA script, where I need the latitude/longitude settings from Domoticz.
I changed the syntax (type-=command¶m=getsettings).
Here's a snippet of my code:
Code: Select all
JSON = require('JSON')
local url = "http://10.0.0.199:8080/json.htm?type=command¶m=getsettings"
local handle=assert(io.popen('curl -s ' .. url))
local Dom_Data = handle:read('*all')
handle:close()
local decoded_response = JSON:decode(Dom_Data)
But when I copy the json command into a browser tab, it comes back with a complete list of settings!
Why? Any ideas?