rlindner / node-red-contrib-sma-webconnect

Node-RED node to query the web interface of SMA inverters
MIT License
13 stars 9 forks source link

Contribution to code #5

Closed HoLo85 closed 4 years ago

HoLo85 commented 4 years ago

Hello, first of all I want to thank you for this node, it made it possible for me to integrate my inverter quickly into Node Red.

But I also have a SMA storage unit from which I wanted to read the data from. Because the inverter and the storage have similar webinterfaces, but not the same messages and data keys, I changed the code of the node a bit to make it configurable.

Since I think that my changes could be helpful for other users, I would like to contribute them here. Would you be okay with that?

rlindner commented 4 years ago

Hey @HoLo85 that would be very welcomed!

And always nice to hear that somebody else uses the node with success. As I only have my own specific inverter model, I'm unable to test for any other types, but if you can confirm it's working and you have a different one than my "Sunny Tripower 10.0", I'd be happy to add it to the compatibility section here: https://github.com/rlindner/node-red-contrib-sma-webconnect#compatibility

HoLo85 commented 4 years ago

Hi, I also have a "Sunny Tripower 10.0", but also a "Sunny Boy Storage 2.5" and this can also be read with your Node and my modifications.

I already wanted to create a PR for my changes, but when trying to push a new branch I get a 403 error from github.

But it looks like I can't use two of the nodes in one flow because they always overwrite the "sid" of the other node. OK, found a solution that works :)

rlindner commented 4 years ago

Hi, I also have a "Sunny Tripower 10.0", but also a "Sunny Boy Storage 2.5" and this can also be read with your Node and my modifications.

Ah ok. 👍

I already wanted to create a PR for my changes, but when trying to push a new branch I get a 403 error from github.

You need to fork the repository under your account, where you can push your branch then. From this branch you can open a pull request against my repository.

~But it looks like I can't use two of the nodes in one flow because they always overwrite the "sid" of the other node.~ OK, found a solution that works :)

Good to hear! Haven't thought about one could use the node more than once at the time of writing, but sure it should be able to handle that case. The _sid is just a global variable within the node. If I remember correctly there should be different types of contexts provided by Node-RED, which should be the way to go here.

gabrio79 commented 4 years ago

Hello, thanks for you code, i have Sunny Tripower 9000 that is very similar, when use your node i receive this issue: "Error: ETIMEDOUT" any ideas?

HoLo85 commented 4 years ago

Have you tried connecting to you Tripower with a browser and do you get a webinterface? If not, you won't be able to use this node because it tries to access the data with webrequests.

Please have a look here: https://github.com/rlindner/node-red-contrib-sma-webconnect/issues/4

Edit. Looks like your device does not offer a webinterface as you wrote in https://github.com/rlindner/node-red-contrib-sma-webconnect/issues/1 or it's disabled and if so, you should refer to the manual of your inverter if it is possible to activate it.

gabrio79 commented 4 years ago

thanks for your fast answer. I called SMA support, my model doesn't have web interface... so I will try to connect via modbus

Il Gio 25 Giu 2020, 18:29 HoLo85 notifications@github.com ha scritto:

Have you tried connecting to you Tripower with a browser and do you get a webinterface? If not, you won't be able to use this node because it tries to access the data with webrequests.

Please have a look here: #4 https://github.com/rlindner/node-red-contrib-sma-webconnect/issues/4

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/rlindner/node-red-contrib-sma-webconnect/issues/5#issuecomment-649675482, or unsubscribe https://github.com/notifications/unsubscribe-auth/APW3TYAYQAGUFMQIDIKNFUTRYN3QBANCNFSM4NONLPNA .