Python script - From APS inverter to PVOutput

Python and python framework

Moderator: leecollings

Post Reply
krizzz
Posts: 200
Joined: Wednesday 20 November 2013 20:36
Target OS: Linux
Domoticz version:
Location: The Netherlands
Contact:

Python script - From APS inverter to PVOutput

Post by krizzz »

I have 2 pi's over 2 locations. On the first pi I have a script (https://github.com/willemstoker/aps-to-pvoutput) to get my solar panel data to PVoutput and it is working beautifully. On the 2nd Pi, its not.

When adding the script, and changing ECU ID, PVoutput system number and API-key. I tried to run the script. But it gives an error, and I cannot find out why. As mentioned, the exact same script, works on the other system perfect. Maybe some python here's can point me in the right direction.

pi@raspberrypi:~/domoticz/scripts/python $ ./apstopvoutput.py Traceback (most recent call last): File "./apstopvoutput.py", line 69, in <module> rootdict = getDataFromAPS() File "./apstopvoutput.py", line 47, in getDataFromAPS response = requests.post(APSYSTEMS_URL, headers=headers, data=data) File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 119, in post return request('post', url, data=data, json=json, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/api.py", line 61, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 530, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/sessions.py", line 643, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python2.7/dist-packages/requests/adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPConnectionPool(host='api.apsystemsema.com', port=8073): Max retries exceeded with url: /apsema/v1/ecu/getPowerInfo (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x764d8d10>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution',))
Post Reply