thingsboard / thingsboard-gateway

Open-source IoT Gateway - integrates devices connected to legacy and third-party systems with ThingsBoard IoT Platform using Modbus, CAN bus, BACnet, BLE, OPC-UA, MQTT, ODBC and REST protocols
https://thingsboard.io/docs/iot-gateway/what-is-iot-gateway/
Apache License 2.0
1.72k stars 829 forks source link

modbus_connector - 301 With result Modbus Error #474

Closed PRiOTiers closed 2 years ago

PRiOTiers commented 3 years ago

Connected 3 modbus RTU devices. It worked fine until one device (device 2) was not reachable.

devices 1 and 3 stoped also and error 301 was reported:

{ "name": "Modbus Default Server", "type": "serial", "method": "rtu", "port": "/dev/ttymxc0", "baudrate": 9600, "stopbits": 1, "bytesize": 8, "timeout": 35, "unitId": 102, "deviceName": "device_2", "deviceType": "type", "attributesPollPeriod": 3600000, "timeseriesPollPeriod": 60000, "sendDataOnlyOnChange": false, "attributes": [ {.....

imbeacon commented 3 years ago

Hi @yvo-pfenninger ,

Could you try to use the version from the master branch? It should reconnect to the devices if one of them is unavailable.

PRiOTiers commented 3 years ago

Hi @zbeacon

I tried the "Installation from source" and had exactly the same error. It is not connecting unfortunately.

imbeacon commented 3 years ago

Hi @yvo-pfenninger ,

I have checked one more time and in my environment, it processed the next device. It shows the error, but other devices are OK.

PRiOTiers commented 3 years ago

Hi @zbeacon

In my enviroment, it is not processing. What kind of setup do you use? Modbus RTU or TCP? Latest version tb gateway?

PRiOTiers commented 3 years ago

Hi @zbeacon I installed once again the latest version from master branch. I tested it with RTU and TCP: If I disconnect one of my devices, it is still not proceeding.

samson0v commented 2 years ago

Hi @yvo-pfenninger, your bug was fixed, please, update your Gateway to the newest version via the master branch. Thanks for your interest in ThingsBoard IoT Gateway.