Effekta / Enersolis support

others protocols
mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Mon Jan 13, 2014 1:52 pm

I, well actually my colleague who is a much better coder, managed to get the data in the right form from the Effekta inverter.
He was also able to calculate the total power in Wh from the measured values (every 20 secs) and the total power counter in kWh.
First testruns over some time show, that the calculated value is pretty accurate. There is only a 2-5wh difference to the kWh value from the inverter. Other loggers which officially support the Effekta must calculate it the same way.
There is also a "effekta_checks.php" to read errors/alarms from the device.
He also prepared a "effekta_startup.php" to read inverter type.
But so far, we do not get anything shown in the InverterInfo window.

Does "effekta_startup.php" get only called once in the morning, or every time i start 123solar newly?

If you are interested, i would make the code publicly available.

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

Re: Effekta / Enersolis support

Post by jeanmarc » Mon Jan 13, 2014 2:22 pm

Great 8-)
yes _startup is called once in a day no matter how often 123s is stop/started (it is launched 60 min after startup to make sure the inverter is fully awake). It generate the info file and the time sync if they are available.
I'd be glad to put your (and your colleague) work in the next release. I've slowly restarted working in 123s today ;)

mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Thu Jan 16, 2014 9:33 am

Hi!
Unfortunately either our _startup.php nor the _checks.php work correct.
For testing we filled the variable $CMD_ALARM with a static text (TestfehlerAmWr) but it does not get shown in eventlog.

from effekta_checks.php

Code: Select all

//zwecks Debugging:
$error_txt = "TestfehlerAmWR";

if($log2console) echo "Fehlertext: $error_txt\r\n";

$ILEAK = 0;     //current ileak in mA
$RISO = 3000;   //r isulation in Mohm
$PPEAK = 1000;  //peak power of all time
$PPEAKOTD = 500;        //peak power of the day
$RET = 'OK';

$CMD_STATE = "running!";        //State text file shown in dashboad
$CMD_ALARM = "$error_txt";        //Alarm command
Here the interesting part of effekta_startup.php

Code: Select all

$CMD_INFO = "WRName: $wrname\r\n$type WRType: $wrtype\r\nWRSerial: $wrserial\r\n";
Also the _startup script gets called, the text "no Info" in the Inverter-Information disappears but our text does not get shown.
Which guideline do we have to follow to get our texts in 123solar?

For getting the data from the effekta inverter, a new service would habe to be started. Could this be taken over from 123solar similar to sma_get or the aurora, if we describe how?

mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Thu Jan 16, 2014 10:28 am

I am also working on getting data to pvoutput.org.
Even i got it completely similar set up to a working system, i do not get any data uploaded.
Every 5 mins i get a entry in "pvoutput_err.txt" and "pvoutput_return.txt" gets updated with following info:

Code: Select all

PVoutput returned: root@TestIgel:/var/www/123solar/data# cat pvoutput_return.txt
#invt1 (26213) 135 Wh 220 W 224 V 22 C

Send for SYSID 26213 : 20140116 09:55- 135 Wh 220 W 224 V 22 C
PVoutput returned: root@TestIgel:/var/www/123solar/data#
Date is ok as you can see and pvoutput.org reachable. I started a sniffer trace but there are no outgoing packets to their ip at all. On another working machine i can see the IP-traffice fine every 5 mins.

So it looks like 123solar does not setup the IP connection at all because of any reason.

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

Re: Effekta / Enersolis support

Post by jeanmarc » Thu Jan 16, 2014 10:47 am

Hi,
I'am glad you're close to get this running :)

For the $CMD_ALARM : check on scripts/debugmem_read.php if PROTOCOL isn't set to aurora or sma.
You may also check the date flag "AWPeak" of this inverter.The first number is in epoch format. You can see when the last ckeck is done or more simply via the dashboard.
I don't get why $CMD_INFO don't show.

The best way to debug is to stop 123s. Change the Alarm/Warning pooling down to 1 min, then launch in a terminal "php scripts/worker.php" until it check the command. If there is a problem php should return an error.
You may also uncomment
#$WWWDIR"/scripts/worker.php" 2>> $WWWDIR"/scripts/worker.err" in the 123solar.sh and comment the line above ;)

For the daemon, i had to add this via an option in the same way i did with sma_get.

ps: about PVoutput you better open a new topic and make sure curl is installed

mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Thu Jan 16, 2014 12:42 pm

Thx for the tip with curl! Now i get at least uploads and OK answers.
PROTOCOL is set to effekta.
I activated error logging to worker.err and got following output:

Code: Select all

effekta_checks.php[1560]: Byte (Hex): 00
effekta_checks.php[1560]: Ergebnisse: running,0,TestfehlerAmWR
sh: 1: running: not found
sh: 1: TestfehlerAmWR: not found
Any idea what's wrong?

BTW: 123solar does not like the ' in the "Title". Maybe somewhere else too.

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

Re: Effekta / Enersolis support

Post by jeanmarc » Thu Jan 16, 2014 1:14 pm

i am stupid ;)
Yes the problem is than $CMD_ALARM and other $CMD_ are commands which will be launched with a shell_exec.
It mean than your_com app will have to be executed and return an ouput.

I'll look for the title issue.

mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Thu Jan 16, 2014 2:25 pm

ok, that was it.
Now we get the infos in 123solar.
We'll see 2morrow if the startup script works also now.

We get also this fault message, every time our effekta.php gets called:

Code: Select all

PHP Notice:  Undefined variable: EFF in /var/www/123solar/scripts/worker.php on line 172
PHP Notice:  Undefined variable: EFF in /var/www/123solar/scripts/worker.php on line 172
We just put a "0" as efficiency, since we do not get it from the inverter and calculation seems to be complicated. Obviously the worker does not like it.

Can u tell us, how it should corretly look like?

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

Re: Effekta / Enersolis support

Post by jeanmarc » Thu Jan 16, 2014 2:43 pm

Well, it's should be ok even if you've set EFF to zero. Maybe force it with a settype($EFF, 'float')
That say, efficiency is a pretty simple calcul= (Pout AC/Pin DC) * 100

Could you take a look on sma_daemon_control function in worker.php to see if you can use it in the same manner ? Also, keep an eye on worker.err, it maybe bring interesting infos.

mstuetz
Posts: 94
Joined: Sun Dec 29, 2013 1:20 pm

Re: Effekta / Enersolis support

Post by mstuetz » Thu Jan 16, 2014 3:25 pm

I guess to calculate the efficiency is not that simple. I agree from a electro-technical side = Eff = Pout/Pin*100.

But: Inverter efficiencies are usually values in the mid to high 90 percentages.
In my case (SMA SB2500) this value is arround 95%, even the measured input power is almost double of the measured output power. This percentage fits the data sheet.
Image

I just found a pretty complicated formula to calculate this - so i'd better ignore this value, since it is not that important to us at all.

So far everything else looks good now and we'll give it a couple of days testrun.
Many thanx for the fast help!

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest