Search found 1055 matches

by jvdz
Sunday 20 May 2018 21:17
Forum: LUA
Topic: LUA Error: 'then' expected near '1'
Replies: 4
Views: 101

Re: LUA Error: 'then' expected near '1'

Good observation @waaren ! @krazny, You do not want to use put any pause in your script since these are ran by the event system and you will pause the whole event system meaning it will become totally unresponsive during the time it takes that each script is ran. Why are you trying to convert this s...
by jvdz
Sunday 20 May 2018 20:55
Forum: LUA
Topic: LUA Error: 'then' expected near '1'
Replies: 4
Views: 101

Re: LUA Error: 'then' expected near '1'

This line is wrong:

Code: Select all

	if ping - c 1 $IPcam > /dev / null ; then
and probably needs to be something like:

Code: Select all

	if os.execute('ping - c 1 $IPcam')  then
Jos
by jvdz
Saturday 19 May 2018 13:09
Forum: Switches and Scenes
Topic: Door sensor
Replies: 3
Views: 164

Re: Door sensor

Can't you simply edit the created device and specify the Off delay?

Jos
by jvdz
Saturday 19 May 2018 11:34
Forum: Bugs and Problems
Topic: Bug Found: web/json command broken (applies only to rfxcom)
Replies: 14
Views: 292

Re: Bug Found: web/json command broken (applies only to rfxcom)

True, when it is larger it will simply set it to the max value and think that was also what the OP experienced.

Jos
by jvdz
Friday 18 May 2018 12:13
Forum: Bugs and Problems
Topic: Bug Found: web/json command broken (applies only to rfxcom)
Replies: 14
Views: 292

Re: Bug Found: web/json command broken (applies only to rfxcom)

Look for SQLite Expert personal. Just install it and open the db file with it. ;)

Jos
by jvdz
Friday 18 May 2018 11:31
Forum: Bugs and Problems
Topic: Bug Found: web/json command broken (applies only to rfxcom)
Replies: 14
Views: 292

Re: Bug Found: web/json command broken (applies only to rfxcom)

All my ZWAVE devices that have dimming capabilities have a MaxDimLevel = 100, so those are not a problem since the relation is 1-1. I have no idea why the MaxDimLevel would/could have changed, but i've looked at the source and don't find any recent changes for that. A lighting2 type and subtype AC h...
by jvdz
Friday 18 May 2018 10:45
Forum: Bugs and Problems
Topic: Bug Found: web/json command broken (applies only to rfxcom)
Replies: 14
Views: 292

Re: Bug Found: web/json command broken (applies only to rfxcom)

So in your case it is 15. ("MaxDimLevel" : 15,)
This means that 15 is equal to 100%.
So each step from 0 - 15 is 100/15 = 6.6 = 7%
so setting it to 50% would mean setting it to 7 which will lead to probably 46% and 8 to 53%.

Understood?
Jos
by jvdz
Friday 18 May 2018 10:00
Forum: Bugs and Problems
Topic: Bug Found: web/json command broken (applies only to rfxcom)
Replies: 14
Views: 292

Re: Bug Found: web/json command broken (applies only to rfxcom)

What is the JSON return value for this IDX for MaxDimLevel when you do this command: http://192.168.1.110:8080/json.htm?type=devices&rid=185 That value represents 100%, so I have several dummy dimmers that I use for blinds and they have a MaxDimLevel of 32. This means that: 0=0% 16=50% 32=100% and I...
by jvdz
Thursday 17 May 2018 19:28
Forum: Z-Wave
Topic: Cheap chinese z-wave products
Replies: 541
Views: 94420

Re: Cheap chinese z-wave products

What type of Fibaro temperature device are you talking about ? ( maybe a link to to device is helpful )

Jos
by jvdz
Wednesday 16 May 2018 20:31
Forum: Bash / PowerShell / Batch etc.
Topic: SOLVED bash - Error 512 - Script works with ssh but not in event or Switch
Replies: 13
Views: 235

Re: bash - Error 512 - Script works with ssh but not in event or Switch

That look all good. What about adding sudo at the beginning of the commandline in the bash file to see whether that fixes it?

Jos
by jvdz
Wednesday 16 May 2018 20:16
Forum: Bash / PowerShell / Batch etc.
Topic: SOLVED bash - Error 512 - Script works with ssh but not in event or Switch
Replies: 13
Views: 235

Re: bash - Error 512 - Script works with ssh but not in event or Switch

Just SSH into your PI, cd to the correct directory and do: ls -l
Show the output line for the script.

Jos

ps: Doing well ;)
by jvdz
Tuesday 15 May 2018 14:21
Forum: LUA
Topic: LUA script in dir clogs up log
Replies: 10
Views: 299

Re: LUA script in dir clogs up log

That log entry can be disabled easily on regular use by simply going into the domoticz website, go into Setup/Settings and select the Other tab. Scroll down to the Event part and deselect the option "Log 'event script triggers"

Jos
by jvdz
Monday 14 May 2018 9:40
Forum: LUA
Topic: LUA script in dir clogs up log
Replies: 10
Views: 299

Re: LUA script in dir clogs up log

Sorry, i thought (and not understanding how and when the device scripts are called or run, that i was just missing something obvious. No worries, I was just playing a little. :) The thing to understand is that the eventsystem will run all script_device.xxxx.lua files each time when when any device ...
by jvdz
Monday 14 May 2018 0:29
Forum: LUA
Topic: LUA script in dir clogs up log
Replies: 10
Views: 299

Re: LUA script in dir clogs up log

Is there a way to either not have that message appear, or to not have the script trigger unless the devices im interested in change? Sure, just make that change to line 12 of your script! ;) ... oh wait, you didn't post any script and expect us to advise you in how to change it which is asking for ...
by jvdz
Monday 07 May 2018 15:32
Forum: LUA
Topic: Need help in decoding json
Replies: 2
Views: 170

Re: Need help in decoding json

This script assumes the data is stored in file testjson.txt: json = (loadfile "/usr/local/share/lua/5.2/JSON.lua") () file = io.open("testjson.txt", "r") datainp=file:read("*a") file:close() input = json:decode(datainp) result_table = input['Sensors'] tc = #result_table for i = 1, tc do print(result...
by jvdz
Monday 07 May 2018 12:02
Forum: Blockly
Topic: Execute event only once for a day
Replies: 2
Views: 221

Re: Execute event only once for a day

I would normally use a uservariable for that. Simply create a uservariable and reset it to 0 each day at 17:00 with a separate blockly.
Then update the shown blockly with this logic: when the phone is detected and the uservariable is 0, you send the telegram and set the uservariable to 1.


Jos
by jvdz
Sunday 06 May 2018 21:42
Forum: Python
Topic: Multiply on/off switch change
Replies: 9
Views: 262

Re: Multiply on/off switch change

optiserw wrote:
Sunday 06 May 2018 20:43
If I take one of these url it takes about 7 seconds.
So it takes 7 seconds for domoticz to come back with OK when you use that URL in a regular browser like Chrome?

Jos
by jvdz
Sunday 06 May 2018 20:21
Forum: Python
Topic: Multiply on/off switch change
Replies: 9
Views: 262

Re: Multiply on/off switch change

That should be done in milliseconds! How long does it take when you take one of these url's and put them in a browser?
Either way, you have been given a number of answers in the other thread so really don't understand why you started a new one in stead of following up on the posted suggestions.

Jos