How much more specific do you want it to be than this script? I don't think you can find a 2nd device that this works for.
If you don't want values less than zero written, put an if around the calls to .updateCurrent(). Then your devices will not be updated, and thus no values will be written.
Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Moderator: leecollings
- laco
- Posts: 86
- Joined: Tuesday 30 October 2018 12:57
- Target OS: NAS (Synology & others)
- Domoticz version: 2021.1
- Location: Slovensko
- Contact:
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Do I have it written correctly?
It hasn't written me any value yet
It hasn't written me any value yet
Code: Select all
if darling > 0 then
dmoticz.devices(40).updateCurrent(darling) -- update command depends on device type. See dzVents Wiki
end
-
- Posts: 470
- Joined: Thursday 26 October 2017 13:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Delft
- Contact:
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Yes, that looks ok. I think you will want to write 0 itself too, though. So I would put >= 0 in there.
-
- Posts: 470
- Joined: Thursday 26 October 2017 13:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Delft
- Contact:
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Yes, that looks ok. I think you will want to write 0 itself too, though. So I would put >= 0 in there.
- laco
- Posts: 86
- Joined: Tuesday 30 October 2018 12:57
- Target OS: NAS (Synology & others)
- Domoticz version: 2021.1
- Location: Slovensko
- Contact:
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
I had two bugs there, now it works
Code: Select all
if darling >0 then
domoticz.devices(40).updateCurrent(darling) -- update command depends on device type. See dzVents Wiki
end
Who is online
Users browsing this forum: manjh and 1 guest