Page 3 of 4

Re: Python plugin - Solax Inverters

Posted: Tuesday 08 March 2022 16:28
by syrhus
In Domoticz settings, did you enter Local networks value like 192.168.1.* ?

Re: Python plugin - Solax Inverters

Posted: Tuesday 08 March 2022 18:26
by dospider
Yes i have. Sometimes when i try to add it again it says that is having problems adding new hardware.

Re: Python plugin - Solax Inverters

Posted: Tuesday 08 March 2022 18:33
by syrhus
Try to get the log in debug mode to see the error because without it is very difficult to understand what happened.
Regards

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 15:30
by ErikM
Just wondering: Does this plugin only work with the Pocket WIFI? I use the Pocket Lan V3.0 and would love to have this plugin work, but keep getting the following error after creating the hardware:

'/home/pi/domoticz/plugins/SolaxHTTP/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 15:33
by waltervl
ErikM wrote: Monday 19 December 2022 15:30 Just wondering: Does this plugin only work with the Pocket WIFI? I use the Pocket Lan V3.0 and would love to have this plugin work, but keep getting the following error after creating the hardware:

'/home/pi/domoticz/plugins/SolaxHTTP/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'
This is not an error there should be more. Probably an Module is not loading. see Wiki https://www.domoticz.com/wiki/Using_Pyt ... ules_Fails

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 16:56
by ErikM
Qh
waltervl wrote: Monday 19 December 2022 15:33
This is not an error there should be more. Probably an Module is not loading. see Wiki https://www.domoticz.com/wiki/Using_Pyt ... ules_Fails
Ah, I see. I had another look at my logs and this is everything I get after creating the SolaxHTTP hardware:

2022-12-19 15:13:11.131 Error: Solax Test: (SolaxHTTP) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/SolaxHTTP/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'.
2022-12-19 15:13:11.160 Error: Solax Test: Exception: 'SyntaxError'. No traceback available.

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 17:32
by waltervl
Did yoy have local nettworks field filled in? As it should.
https://www.domoticz.com/wiki/Applicati ... stem_Setup

Else it perhaps is type error somehere in the plugin.py. Did you modify it yourself?

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 18:41
by ErikM
waltervl wrote: Monday 19 December 2022 17:32 Did yoy have local nettworks field filled in? As it should.
https://www.domoticz.com/wiki/Applicati ... stem_Setup

Else it perhaps is type error somehere in the plugin.py. Did you modify it yourself?
I thought I had to fill in the Solax's IP address when I created the new hardware. Should that be my Domoticz IP address? And I didn't modify anything in the plugin. I don't know any Python, so I'm not taking risks there.

Re: Python plugin - Solax Inverters

Posted: Monday 19 December 2022 21:00
by waltervl
For having this plugin run properly you have to have your local network settings filled in (menu setup - settings).
In the plugin settings you fill in the IP of the inverter.

Re: Python plugin - Solax Inverters

Posted: Tuesday 20 December 2022 8:58
by ErikM
waltervl wrote: Monday 19 December 2022 21:00 For having this plugin run properly you have to have your local network settings filled in (menu setup - settings).
In the plugin settings you fill in the IP of the inverter.
I have my local network settings in the settings menu and also the Solax PockteLan V3 IP (as provided by my FritzBox) in the plugin settings, but I still get this syntax error and the inability to load the plugin.

Re: Python plugin - Solax Inverters

Posted: Tuesday 20 December 2022 10:06
by waltervl
Did you make the plugin.py file executable?
Is it readable for the user running domoticz?
Is it the first python plugin you are running? Else check wiki https://www.domoticz.com/wiki/Using_Python_plugins for all prerequisits

Re: Python plugin - Solax Inverters

Posted: Tuesday 20 December 2022 13:42
by ErikM
It's just this one is that's giving me trouble. The other Solax plugin works perfectly fine, but doesn't give me as much information. I've updated Python, the file is executable and is, as far as I can see, available. :(

Re: Python plugin - Solax Inverters

Posted: Tuesday 20 December 2022 14:31
by waltervl
I am out of options, perhaps the developer can kick in....

Re: Python plugin - Solax Inverters

Posted: Friday 23 December 2022 11:33
by Ayep
Hi all,

First and foremost - many thanks to the dev for the creation of this plugin. I've recently switch to a solax inverter and am looking forward to getting some data.

Now, i've started off fresh, and am running into some troubles. Here is my error log :

Code: Select all

2022-12-23 11:20:14.214 Error: SolaX: Call to function 'onStart' failed, exception details:
2022-12-23 11:20:14.215 Error: SolaX: Traceback (most recent call last):
2022-12-23 11:20:14.215 Error: SolaX: File "/home/pi/domoticz/plugins/solax_inverter/plugin.py", line 255, in onStart
2022-12-23 11:20:14.215 Error: SolaX: _plugin.onStart()
2022-12-23 11:20:14.215 Error: SolaX: File "/home/pi/domoticz/plugins/solax_inverter/plugin.py", line 92, in onStart
2022-12-23 11:20:14.215 Error: SolaX: self.getSunset()
2022-12-23 11:20:14.215 Error: SolaX: File "/home/pi/domoticz/plugins/solax_inverter/plugin.py", line 125, in getSunset
2022-12-23 11:20:14.215 Error: SolaX: self.sunrise = datetime.time(hour=int(dJson['Sunrise'].split(':')[0]),minute=int(dJson['Sunrise'].split(':')[1]),second=0)
2022-12-23 11:20:14.215 Error: SolaX: TypeError: 'NoneType' object is not subscriptable 
Setup and steps so far :
- Totally fresh bullseye installation, on rpi4, with latest stable domoticz.
- I've had to install python-dev for python version to appear in domoticz, and initially attempt to run the plugin.
- I've had to chmod +x the plugin.py, which has removed one initial error.
- Settings are set to accept new hardware devices
- I've input tokenID, wifi dongle S/N, domoticz IP and port.

Many thanks for any insight you may have in resolving this.

Re: Python plugin - Solax Inverters

Posted: Friday 23 December 2022 11:52
by waltervl
This probably has to do with incorrect entering in plugin configuration;
  • Domoticz IP Address
  • Domoticz Port number
Is the following URL working when entered in a browser (after changing IP and Port)?

Code: Select all

http://Domoticz-IP:Port/json.htm?type=command&param=getSunRiseSet

Re: Python plugin - Solax Inverters

Posted: Friday 23 December 2022 12:24
by Ayep
Ah well spotted, you could indeed be onto something. This command

Code: Select all

http://192.168.1.38:8080/json.htm?type=command&param=getSunRiseSet
yields a

Code: Select all

401 Unauthorized

Re: Python plugin - Solax Inverters

Posted: Friday 23 December 2022 12:31
by Ayep
Superb, huge progress indeed.

Since I had done a fresh installation, I had forgotten to input the 192.168.1.* in the "Local Networks (no username/password)" settings.

Now json works... And I have one new device named "Solax - [myserialkey]". I assume the next devices will populate with time.

Thank you very much for your help here, I was stuck speculating on python issues... Much appreciated!

Re: Python plugin - Solax Inverters

Posted: Wednesday 01 March 2023 17:19
by Biarritz
Hi,
I have just updated to the latest version of Domoticz 2023.1 on Docker and getting the following error on the Solax Inverter
Knipsel.JPG
Knipsel.JPG (117.8 KiB) Viewed 932 times
When using:
http://Domoticz-IP:Port/json.htm?type=command&param=getSunRiseSet

The result is:
{
"AstrTwilightEnd" : "19:09",
"AstrTwilightStart" : "04:33",
"CivTwilightEnd" : "17:52",
"CivTwilightStart" : "05:51",
"DayLength" : "10:54",
"NautTwilightEnd" : "18:30",
"NautTwilightStart" : "05:12",
"ServerTime" : "2023-03-01 16:18:33",
"SunAtSouth" : "11:51",
"Sunrise" : "06:24",
"Sunset" : "17:18",
"status" : "OK",
"title" : "getSunRiseSet"
}

Re: Python plugin - Solax Inverters

Posted: Wednesday 01 March 2023 17:58
by syrhus
Hi Biarritz (French guy? ;) )

Could you please try to install the latest version 1.2.2?
Let me know if you still have the issue.

Re: Python plugin - Solax Inverters

Posted: Wednesday 01 March 2023 19:30
by Biarritz
Hi, Sorry no I'm not French, just like Cadillac's and Biarritz the city :D .
I have plugin.py version which was committed on Nov 28, 2022
And in the log is see the version number you mentioned
Knipsel.JPG
Knipsel.JPG (125.58 KiB) Viewed 920 times