krommetje Super User
Joined: December 29 2004 Location: Netherlands
Online Status: Offline Posts: 695
|
Posted: January 07 2013 at 23:46 | IP Logged
|
|
|
If you have a YOULESS energymeter (or similar to) here is how you can get the readings into PH:
Install the youless or device similar into your network and note the IP.
- you need 3 GV's YOULESSTEMP1, YOULESSTEMP2 and YOULESSTEMP3
- import the following macro into PH:
Code:
insert into macroheader values ('HVACPWRCONS','HVACPWRCONS',0,0,1);
insert into macrodetail values ('HVACPWRCONS',1,38,'',0,'ph_setvar_s(1,1,ph_geturl("http:// 192.168.1.14/a?f=j"))',0,'','');
insert into macrodetail values ('HVACPWRCONS',2,36,'',NULL,'ph_getvar_s(1,1)',0,'','');
insert into macrodetail values ('HVACPWRCONS',3,10,'YOULESSTEMP1',NULL,'ph_regexdiff1(''"pw r":'',''"'',ph_gevar_s(1,1),1,1,0,0,0)',0,'','');
insert into macrodetail values ('HVACPWRCONS',4,36,'',NULL,'{YOULESSTEMP1}',0,'','');
insert into macroheader values ('HVACPWRCONS','HVACPWRCONS',0,0,1);
insert into macrodetail values ('HVACPWRCONS',1,38,'',0,'ph_setvar_s(1,1,ph_geturl("http:// 192.168.1.14/a?f=j"))',0,'','');
insert into macrodetail values ('HVACPWRCONS',2,10,'YOULESSTEMP1',NULL,'ph_regexdiff1(''"pw r":'',''"'',ph_getvar_s(1,1),1,1,0,0,0)',0,'','');
insert into macrodetail values ('HVACPWRCONS',3,36,'',NULL,'"{YOULESSTEMP1}"',0,'','');
insert into macrodetail values ('HVACPWRCONS',4,10,'YOULESSTEMP3',NULL,'ph_regexdiff1(''"cn t":"'',''"'',ph_getvar_s(1,1),1,1,0,0,0)',0,'','');
insert into macrodetail values ('HVACPWRCONS',5,10,'YOULESSTEMP2',NULL,'DEC("{YOULESSTEMP1} ")',0,'','');
insert into macrodetail values ('HVACPWRCONS',6,1,'YOULESSIMPORT',0,'',0,'','');
|
|
|
Go into the just imported macro and correct the IP to suit your network. Do not password protect the youless so do not open a port on your router to the internet.
You now have 3 GV's which contain the readings on which you can extend.
That is it...
Edited by krommetje - January 07 2013 at 23:50
|