Search found 71 matches
- Saturday 16 July 2022 16:17
- Forum: dzVents
- Topic: dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
- Replies: 9
- Views: 830
Re: dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
Thank you, this is my script: local scriptVar = 'hidrografico' return { on = { devices = { 'TesteDzvents', --Script can be triggered by a device }, timer = { -- 'every 2 minutes',--'at *:36', }, httpResponses = { scriptVar, }, }, logging = { level = domoticz.LOG_DEBUG, marker = 'hidrografico ...
- Wednesday 13 July 2022 21:35
- Forum: dzVents
- Topic: dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
- Replies: 9
- Views: 830
Re: dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
Even with the new link i get an error parsing json to LUA table, would be because json structure has square brackets?
- Wednesday 13 July 2022 18:48
- Forum: dzVents
- Topic: dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
- Replies: 9
- Views: 830
dzVents OpenURL - Error parsing json to LUA table: (invalid json string)
Hi, I am trying to get the weather details from this link The result from the openurl is in the following format: [{"SDATA":"2022-07-12 18:00","TZ":5.9,"TP":8.2},{"SDATA":"2022-07-12 19:00","TZ":5.9,"TP":7.7},{"SDATA":"2022-07-12 20:00","TZ":5.9,"TP":7.5},{"SDATA":"2022-07-12 21:00","TZ":"NaN","TP ...
- Wednesday 09 February 2022 6:43
- Forum: dzVents
- Topic: Find last line in response
- Replies: 3
- Views: 439
Re: Find last line in response
item.data is not a table is a string, basically I would like to delete all lines before last one or last cases of a string and then fill table with values.If item.data is a table you perhaps can do something like
- Wednesday 09 February 2022 0:21
- Forum: dzVents
- Topic: Find last line in response
- Replies: 3
- Views: 439
Find last line in response
Dear all, I have a big result from a small script execution, how could I delete all the lines except the last one?? 2022-02-08 22:57:02.390 867,2022-02-08 16:50:00,-990.0,-990.0,-990.0,-990.0,-990,18.2,11.0,63,156,15,160,22,0,0,h1,c1,h2,c2,0.0,0.0,19.5,5.2,&value=||||||||||||||||||||| ° 2022-02 ...
- Friday 04 February 2022 14:57
- Forum: dzVents
- Topic: Script Dzvents to read values from webpage [Solved]
- Replies: 4
- Views: 1245
Re: Script Dzvents to read values from webpage
I have got to adapt the waaren script to extract the data from the weather station that I want. Thank you very much waltervl for your help and to waaren, wherever you are, a big hug.
- Wednesday 02 February 2022 22:18
- Forum: dzVents
- Topic: Script Dzvents to read values from webpage [Solved]
- Replies: 4
- Views: 1245
Re: Script Dzvents to read values from webpage
Thank you waltervl, I had tried to make the script with LUA following that post before create this one. I am not able to run socket.http after installed.
- Wednesday 02 February 2022 22:15
- Forum: dzVents
- Topic: Power consumption from json. [Solved]
- Replies: 4
- Views: 1281
Re: Power consumption from json. [Solved]
Do i create a dummy electric and instant counter and name it 'EV-chargers' as you are calling it in the first line of the script? Create a dummy Ampere (3 phase), you don´t need to give that name. Just take note of the IDX number and put here instead 628: local scriptVar = 'EV-chargers' return { on ...
- Tuesday 01 February 2022 22:52
- Forum: dzVents
- Topic: Power consumption from json. [Solved]
- Replies: 4
- Views: 1281
Re: Power consumption from json. [Solved]
Hi, I am not specialist but should be something like this to get phase1Current value in your LOG local scriptVar = 'EV-chargers' return { on = { timer = { 'every 1 minutes', }, httpResponses = { scriptVar, }, }, logging = { level = domoticz.LOG_DEBUG, marker = 'EV-chargers', }, execute = function(dz ...
- Tuesday 01 February 2022 22:29
- Forum: dzVents
- Topic: Script Dzvents to read values from webpage [Solved]
- Replies: 4
- Views: 1245
Script Dzvents to read values from webpage [Solved]
Dear all, I would like to get somes values from a weather station website and store these data into Domoticz. The API request is : http://centronautico.cm-faro.pt/report.php Lines 65 and 66 from html reponse are Wind Speed and Wind Gust: <td class="ws3">3</td> <td class="ws3">5</td> Line 68 is Wind ...
- Thursday 20 May 2021 17:16
- Forum: dzVents
- Topic: Plugin for unknow devices RFlinkLoader?
- Replies: 0
- Views: 180
Plugin for unknow devices RFlinkLoader?
Good afternoon, I'am a happy user of the RFLink gateway with Domoticz from 2 years ago. Now i'm experimenting with unknown devices using debug mode with RFlinkLoader. The remote controller from my shutter gives me a lot of numbers which are not easy to work with. My question is, would be possible to ...
- Thursday 20 May 2021 16:35
- Forum: Python
- Topic: Python Plugin: LG Smart AC (SmartThinQ)
- Replies: 173
- Views: 47697
Re: Python Plugin: LG Smart AC (SmartThinQ)
Hello, my plugin is working correctly
Have you checked your token? May be has expired?When i stop and manually start the LGACServerNew.py I can see Domoticz requests but then the connection immediatly closes
- Friday 19 March 2021 17:40
- Forum: dzVents
- Topic: Interfacing Nabto with Dzvents?
- Replies: 4
- Views: 541
Re: Interfacing Nabto with Dzvents?
Thank you very much for the clarification waaren, in the best case scenario I could create a script that would run every 5 minutes blocking the rest of the system until it is finished. Python script is running well, I have no need to complicate what works well.
- Friday 19 March 2021 16:19
- Forum: dzVents
- Topic: Interfacing Nabto with Dzvents?
- Replies: 4
- Views: 541
Re: Interfacing Nabto with Dzvents?
I don't know if I have understood the question correctly. Once you have the session open with your login, if you type: https://***MAC***.sorel-connect.net/state.json?id=sensor1 You get value for sensor 1: { "val": "66°C" } For sensor2 just change last number to 2. I have not written the Python code, ...
- Friday 19 March 2021 15:02
- Forum: dzVents
- Topic: Interfacing Nabto with Dzvents?
- Replies: 4
- Views: 541
Interfacing Nabto with Dzvents?
Hello, may be this is a strange question but I would like you to help me solve The code I have attached bellow is a Python plugin to get json data from a Sorel solar controller and sent to Domoticz server via HTTP get. Instead the nabto P2P protocol (*), plugin implement an HTTP client to go to ...
- Thursday 11 March 2021 19:20
- Forum: dzVents
- Topic: From Windy to Domoticz [Solved]
- Replies: 18
- Views: 1528
Re: From Windy to Domoticz [Solved]
I understand and that's why I added the "or 0" to windgust. So if _.findLast returns nil, the script will not crash but will replace nil with 0. This will give the same result as the hardcoded 0 in the updateWind statement you used. Understood, thank you very much for the help waaren. Today was the ...
- Thursday 11 March 2021 14:30
- Forum: dzVents
- Topic: From Windy to Domoticz [Solved]
- Replies: 18
- Views: 1528
Re: From Windy to Domoticz [Solved]
@Waaren and @javalin, Is it possible to implement windgust? I had disable Wind Gust line because, before upgrade script with _.findlast method, the script 'froze' when got a nil value. Faro and Rota has not Wind Gust values but others stations may. I have discovered that original source that Windy ...
- Thursday 11 March 2021 9:01
- Forum: dzVents
- Topic: From Windy to Domoticz [Solved]
- Replies: 18
- Views: 1528
Re: From Windy to Domoticz [Solved]
This will do the job in a more robust way using the _.findlast method. Thank you waaren, now it works even better. With the use of #tablename dummy wind device did not update when the wind speed or wind direction value was null. Now, with _.findlast method the wind device can update also to zero ...
- Tuesday 09 March 2021 22:14
- Forum: dzVents
- Topic: From Windy to Domoticz [Solved]
- Replies: 18
- Views: 1528
Re: From Windy to Domoticz [Solved]
Can you try this one? Thank you waaren, it works. local function windDirection( nDir ) windDirections = { 'N', 'NNE','NE','ENE','E','ESE','SE','SSE','S','SSW','SW','WSW','W','WNW','NW','NNW' , 'N'} return ( windDirections[ math.floor( ( nDir + 11.25 ) / 22.50 ) + 1 ] ) end The beatiful way to get ...
- Tuesday 09 March 2021 10:35
- Forum: dzVents
- Topic: From Windy to Domoticz [Solved]
- Replies: 18
- Views: 1528
From Windy to Domoticz [Solved]
Good Morning, I am trying to create code to get data from 2 Windy wind stations to send it to 2 domoticz dummy wind devices in the same script. If I create 1 script independently for each WS there is no problem, it works. But with a single script I am not managing to update the last dummy wind ...