-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected http code #17
Comments
10:15: mmm damn I would have hoped the last line would have mentioned the code it received. Let me check. |
Hi Sincze, thank you for your very quick reply. I altered the script and restarted it, I got no error in the log file. 2023-07-08 12:24:00.257 Status: --->> Cookie File: /var/tmp/Delta.cookie exists! So far so good. I now have to wait till I can see some values. Still 0 watt. Thank you for your assistance. I hope I get it to work. If you have more clues I would like to hear them. |
Extra information, I have very often a reset all device statuses... 2023-07-08 12:33:40.734 Status: EventSystem: reset all device statuses... |
Is it working as expected?? |
I would like to know of there is code or a command so i can see of any data is received or available. |
Option: And run the script from the prompt. |
This is what i got back at the prompt. pi@Domoticz: In the logfile eveything seems normal. |
Did it ever work or stopped working. |
It has never worked. I never tried before.
It a pity you can’t test anymore. Thank you for you replies and for the script.
Good luck.
Ruud
…On 9 Jul 2023 at 18:16 +0200, Sandor ***@***.***>, wrote:
Did it ever work or stopped working.
The DELTA inverter from my monitoring system has been replaced by GoodWe so I don't have working credentials anymore to do further testing on the login proces.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
If you want. you can assign a temp pwd to it and I'll try to use yours to fix the script so you can use it. |
Working on it. In your case 20:32 I now have: Delta Inverter: for domoticz: 147;25891
|
Sorry Sandor, I was very busy and did not check my email for the last 2 days. You found a way to solve the problem. I also notices I have 2 inverters listed but because of former problems i am afraid to delete the first one. Maybe i delete him anyway. |
Hi Sandor, I did not edit the plant information yet. this is the error i get running the php script' pi@Domoticz:~/domoticz/scripts/pass2php $ php /home/pi/domoticz/scripts/pass2php/delta_inverter.php Notice: Undefined offset: 0 in /home/pi/domoticz/scripts/pass2php/delta_inverter.php on line 289 |
Hi Sandor I tried to remove the ['0'] at the end if line 289. After that i didnt get an error message running the script but i still get no data in Domoticz The last line was temporary, running the script now gives me again the php notice. I am no programmer, but has this failure to do with the P_cid value? |
Mmmm interesting. I got ... let me tweak it a bit. for you. New script is live added 1 line of code. Do not alter the script! with the keys e.g. it should work just fine.
|
Hi Sandor, thank you for you reply. I copied the script into the folder. I notice, there is something else going on. Using my deltasolar- owner-account I still get the error messages. Thank you so far. I will get a new password on my head account. I have no idea why this login which I use on the website too, doesn't work. I would never have solved this on my own. |
Something strange happens, off course I tried to use my owner username and password and I don't get that to work. I removed the empty plant so I only have one plant now. Maybe this influences the result. thanks |
I am not able to get it to work anymore. I added some accounts with the same passwords and it doesn't solve the problem. This is the errormessage again: pi@Domoticz:~/domoticz/scripts/pass2php $ php /home/pi/domoticz/scripts/pass2php/delta_inverter.php Notice: Undefined offset: 0 in /home/pi/domoticz/scripts/pass2php/delta_inverter.php on line 290 I feel a little silly because it seemed to work yesterday. My plant-id is 5502re27tijs and i have only one inverter. |
I can see that with the credentials I got provided there now is only 1 inverter left.
Tested 21:13 with separate script still for me shows:
|
Hi Sandor,
I imported the script and I get values now.
The value 25891 is the same as yesterday. It could be the total I produced since my registration
Today I produced 15,46 kWh according to myDeltaSolar.
Thank you so far. I would like to know what commands you used to get info from myDeltaSolar .
Thank you again.
Ruud
…On 13 Jul 2023 at 19:58 +0200, Sandor ***@***.***>, wrote:
I can see that with the credentials I got provided there now is only 1 inverter left.
I updated the code for you.
Delta Inverter: for domoticz: 270;25891
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
A well we will get there eventually. At least you have some data now. To see the commands I used check the URL's in the script that are being called. If you install 'FIDDLER' for example, login to delta portal, you can see all the hidden stuff flying by by just clicking on the delta webpage. I do notice that the DELTA app reveils the total number generated in MWh. |
Thank you again.
Tomorrow I wil take a look at the new data again.
Ruud
…On 13 Jul 2023 at 21:40 +0200, Sandor ***@***.***>, wrote:
> Hi Sandor, I imported the script and I get values now. The value 25891 is the same as yesterday. It could be the total I produced since my registration Today I produced 15,46 kWh according to myDeltaSolar. Thank you so far. I would like to know what commands you used to get info from myDeltaSolar . Thank you again. Ruud
> …
> On 13 Jul 2023 at 19:58 +0200, Sandor @.>, wrote: I can see that with the credentials I got provided there now is only 1 inverter left. I updated the code for you. Delta Inverter: for domoticz: 270;25891 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.>
A well we will get there eventually. At least you have some data now.
The DELTA website is a bit sluggish..... (SLOWWWWWWWWWWW).
To see the commands I used check the URL's in the script that are being called.
If you install 'FIDDLER' for example, login to delta portal, you can see all the hidden stuff flying by by just clicking on the delta webpage.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Hi Sandor,
I put this data in the script and it works, but is not giving me the correct values. We have beautiful weather so the values should change and the value 25891 is not changing.
Using fiddler I found this data : {"no_table":[],"dc_fix":{"25891":false},"pid_arr":[47458],"tbid_arr":["47458"],"mt_pid_arr":[],"bt_pid_arr":[],"ev_pid_arr":[],"today_start":"2023-07-17
00:00:01","today_end":"2023-07-17 23:59:59","a_pos":"2023-07-17","start_time":"2023-08-01
The value 25891 comes back here.
I found another value, that could be interesting "{"plant_ID":["47458"],"tariff":["0"],"te":[19010],"le":[2601690],"btcap":[0],"bt_num":0,"plt_cap":["0"],"de":[153],"btcap_arr":[],"pid_arr":["47458"],"tbid_arr":["47458"],"mt_pid_arr":[],"bt_pid_arr":[],"ev_pid_arr":[],"sum_soc":0,"avbtsoc":0,"plt_type_max":1,"commercial":0,"residential":1,"storage":0}
“te” stand for today energy. And ”le” is the total amount of generated energy.
these values are on page https://mydeltasolar.deltaww.com/includes/process_init_energy.php
besides that I can't find the descriptor or value for P_cid.
Are those values we (you) can work with.
And fiddler is an wonderfull programm.
My best regards,
Ruud
… Op 15 jul. 2023, om 13:57 heeft Sandor ***@***.***> het volgende geschreven:
It could be that we still need 1 tweak as stated by you.
The 25891 in the webinterface is so it seems MWh (total generated).
To put this into a Domoticz sensor this needs to be done in:
ENERGY = Integer, total cumulative energy in Watt-hours (Wh)
<https://www.domoticz.com/wiki/Domoticz_API/JSON_URL's>
So a small tweak in the following function can do that:
function extract_today_power_from_data($plant_id,$queryresult)
{
$today_power=false;
$queryresult = json_decode($queryresult, JSON_PRETTY_PRINT);
if(isset($queryresult['P_cid']))
{
$today_power=$queryresult['P_cid'][$plant_id]['0'];
$today_power=$today_power*1000; // Shown in MWh convert to kWh
$today_power=$today_power*1000; // Convert kWh to Wh
}
}
—
Reply to this email directly, view it on GitHub <#17 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AHLQL6BAWFPJSPXES347BN3XQKATLANCNFSM6AAAAAA2CUQFT4>.
You are receiving this because you authored the thread.
|
Dear Sincze,
I installed the Delta_inverter.php in Domoticz
I altered the username, password and Domoticzdevice and also the website port number to port 8084.
Executing the php command I get no error but in the log I see this error.
I get no values in my Delta screen.
How could I solve this?
2023-07-08 07:45:02.686 Status: --->> Cookie File: /var/tmp/Delta.cookie exists!
2023-07-08 07:45:02.691 Status: --->> Cookie File: /var/tmp/Delta.cookie is writable!
2023-07-08 07:45:02.695 Status: --->> Login OK to proceed ->
2023-07-08 07:45:02.897 Status: --->> Delta inverter: Data: Unexpected HTTP code:
The text was updated successfully, but these errors were encountered: