sophienyaa / NodeRenogy

Utility to retrieve data from Renogy solar controllers and publish it to MQTT, written in NodeJS
MIT License
60 stars 13 forks source link

TransactionTimedOutError #4

Open rizalafif opened 2 years ago

rizalafif commented 2 years ago

Hi , Anyone have this kind of error? pi@renogyrover:~ $ node-renogy -s /dev/ttyUSB0 -m 192.168.0.11 -u mqtt -p mqttpasswd [1658487181379] INFO (9450 on renogyrover): Starting NodeRenogy... [1658487181402] INFO (9450 on renogyrover): Connected to controller! [1658487181909] ERROR (TransactionTimedOutError/9450 on renogyrover): message: "Timed out" errno: "ETIMEDOUT"

Is it the cable? I am running this on raspbian with Renogy Rover 20A

SP410 commented 2 years ago

I get the same; I know it is not the cable because I can talk to it over: https://github.com/rosswarren/renogymodbus

Fibdorius commented 2 years ago

I have the same Error. I will try renogymodbus

Joe13183 commented 1 year ago

I have the same error. Has anyone found an answer please?

marcuslib commented 1 year ago

Is there any update on this one, as I get the same error.

MaffooClock commented 1 year ago

It's an exception from the modbus-serial dependency, raised because a connection to the serial device couldn't be established here: https://github.com/sophienyaa/NodeRenogy/blob/58de92db156c0314c8813d0ce01eb5e7272d8aa1/renogy.js#L188

The line above that has a hard-coded timeout of 500ms, which you might tinker with to see if an increased value might help.

In my case, after trying rosswarren/renogymodbus and getting "No communication with the instrument (no answer)", it appears that my serial connection isn't working at all 😞.

Joe13183 commented 1 year ago

I tried to tinker with that timeout but never got it working. I went back to the rosswarren/renogymodbus and amended to read all data sets and send to MQTT in home assistant. Took awhile and still needs tidying up but basically works. Shame this one doesn't work for whatever reason

sophienyaa commented 1 year ago

How much did you bump the timeout by? Also, confirm the modbus address of your device as it seems some of them differ from the default.