Page 2 of 2
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Posted: Sunday 07 November 2021 15:50
by rrozema
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.
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Posted: Tuesday 09 November 2021 17:25
by laco
Do I have it written correctly?
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
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Posted: Tuesday 09 November 2021 21:52
by rrozema
Yes, that looks ok. I think you will want to write 0 itself too, though. So I would put >= 0 in there.
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Posted: Tuesday 09 November 2021 21:52
by rrozema
Yes, that looks ok. I think you will want to write 0 itself too, though. So I would put >= 0 in there.
Re: Electricity Current/Ampere 3 Phase IPX800V3 + X400CT
Posted: Wednesday 10 November 2021 8:49
by laco
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