rklogger problem in the Version : 123Solar 1.6.5.3.2

others protocols
ginorosi
Posts: 29
Joined: Sun Jun 22, 2014 10:47 pm

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by ginorosi » Mon Jun 23, 2014 3:15 pm

test comunication does not work , I do not remember all the attempts , but in debug mode from /admin the all value is 0, only the date is correct

the launch of 123solar.php from terminal was an attempt :)

bye

jeanmarc
Posts: 1866
Joined: Thu Aug 29, 2013 7:16 am

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by jeanmarc » Mon Jun 23, 2014 3:39 pm

Verify your com app permission (ls -l path to rklogger)
What is your com port permission ? You'll need to give access to http/www user (Check help page)

ginorosi
Posts: 29
Joined: Sun Jun 22, 2014 10:47 pm

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by ginorosi » Mon Jun 23, 2014 7:50 pm

my plants are far away, and I'm only on weekends , I have a Pogoplug where is
thinking, I log in as root I can 'this be the problem ? but on the system with PVI is not problems...where development and then I transfer it to the system where I can test the communication
i create the group http , as your instruction
usermod -a -G uucp http
thank you for your availability

jeanmarc
Posts: 1866
Joined: Thu Aug 29, 2013 7:16 am

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by jeanmarc » Mon Jun 23, 2014 8:54 pm

Well, i don't know much about rklogger. Create this simple test.php file

Code: Select all

<?php
$KWHT = shell_exec("rklogger 11 1 2 4a 8");
echo "You total counter is $KWHT kWh";
?>
Open it in your browser, if it show the value it mean http user can launch rklogger.

ginorosi
Posts: 29
Joined: Sun Jun 22, 2014 10:47 pm

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by ginorosi » Mon Jun 23, 2014 9:06 pm

well just go to the plant , try....

ginorosi
Posts: 29
Joined: Sun Jun 22, 2014 10:47 pm

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by ginorosi » Tue Jun 24, 2014 9:09 pm

Today I managed to start, thanks to your instructions, I did not understand exactly what was not working , I also reinstalled 3-4 times the new Archlinux , the procedure of install ARC has changed from 10 days with new uboot , the pen now you have to recreate on your PC, almost like the Raspberry , perhaps I had not activated user http , and in my last danfoss3.php , I have create instruction rklogger with ('rklogger X X X X X') when the right command is ("rklogger X X X X X")
that is :

$a = exec('rklogger 1 1 1 1 1'); // is OK
$a = exec('rklogger 1 1 $ADR 1 1'); // does not work
$a = exec("rklogger 1 1 $ADR 1 1"); // is OK

This the right files for Danfoss TLX 3phase , the call of routine is long 9-10" :

Code: Select all

<?php

// ./home/rklogger is a command line program for reading the parameters out of Danfoss inverters.
// http://www.petig.eu/./home/rklogger/
// With the help of Gino Rosi

//$CMD_POOLING = "rklogger 11 1 ";

$SDTE = date("Ymd H:i:s");

$c = ${'ADR'.$invt_num};

$a = exec("rklogger 11 $c 2 28 8"); 
$I1V = $a/10;
$a = exec("rklogger 11 $c 2 2d 8");
$I1A = $a/1000;
$a = exec("rklogger 11 $c 2 32 8");
$I1P = $a;

$a = exec("rklogger 11 $c 2 29 8");
$I2V = $a/10;
$a = exec("rklogger 11 $c 2 2e 8");
$I2A = $a/1000;
$a = exec("rklogger 11 $c 2 33 8");
$I2P = $a;

$I3V = null;
$I3A = null;
$I3P = null;
$I4V = null;
$I4A = null;
$I4P = null;

$a = exec("rklogger 11 $c 2 3c 8");
$G1V = $a/10;
$a = exec("rklogger 11 $c 2 3d 8");
$G2V = $a/10;
$a = exec("rklogger 11 $c 2 3e 8");
$G3V = $a/10;

$a = exec("rklogger 11 $c 2 3f 8");
$G1A = $a/1000;
$a = exec("rklogger 11 $c 2 40 8");
$G2A = $a/1000;
$a = exec("rklogger 11 $c 2 41 8");
$G3A = $a/1000;

$a = exec("rklogger 11 $c 2 42 8");
$G1P = $a;
$a = exec("rklogger 11 $c 2 43 8");
$G2P = $a;
$a = exec("rklogger 11 $c 2 44 8");
$G3P = $a;

$a = exec("rklogger 11 $c 2 50 8");
$FRQ = $a/1000;

$EFF = round((($G1P+$G2P+$G3P)/($I1P+$I2P)),3);

$a = exec("rklogger 11 $c 2 53 8");
$INVT = $a;

$a = exec("rklogger 11 $c 2 54 8");
$BOOT = $a;

$a = exec("rklogger 11 $c 1 2 8");
$KWHT = $a/1000;

$RET = 'OK';

$CMD_INFO = "rklogger 11 $c 2 4 8";

?>
settype($XXXX, 'float'); not needed
sorry for my incompetence , thank's for all , ciao

jeanmarc
Posts: 1866
Joined: Thu Aug 29, 2013 7:16 am

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by jeanmarc » Wed Jun 25, 2014 7:42 am

Hi,
Yes you'll need to use double quote to use variables or it will take the text as is.
That should be $a = exec("rklogger 1 1 ${'ADR'.$invt_num} 1 1");

It is preferable to force to float as it may lead to odd values when doing the calculation (eg for production). I encounter the problem few times.

I still find odd that you call each time rklogger for each variable, can't you get them all in a one ?
Also the $RET should be set to OK if the communication is done completly. If you set it to OK you may also have "holes" and issues in your data if the com haven't complete correclty.

Cheers

ginorosi
Posts: 29
Joined: Sun Jun 22, 2014 10:47 pm

Re: rklogger problem in the Version : 123Solar 1.6.5.3.2

Post by ginorosi » Wed Jun 25, 2014 8:47 am

Hi,
the protocoll Comlynx Danfoss is this : one call one given , take it or leave :)

for the 'float' : on the version 1.5 it's round one year , without problems .
there are no "holes" of communication and for the wait of reading that's okay.

Now I have to adjust the reading of the operating mode of the inverter, while the location of the Riso and Ileak not known.
From yesterday at 2 pm , is online on pvout the version 1.6.5.4 http://www.pvoutput.org/intraday.jsp?id=13060&sid=20737 :D , previously is 1.5.4.1 .

ciao

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest