(x) unexpected behavior (using node-bacnet lib and supplying the interface IP works)
Current behavior
My setup has multiple IP's on the same Network Interface in the same Subnet /22, the first IP 192.168.252.234 is used by another BACnet client and the second is free 192.168.252.235 intended to be used by node-red-contrib-bacnet.
in this senario, the library cannot bind exclusively only to the second IP address, instead tries to bind to all and fails everytime with "Error: ERR_TIMEOUT"
Expected behavior
should be able to bind the the specified IP in the Interface>Client>IP_address
Minimal reproduction of the problem with instructions
Simple BACnet Read Flow attached (file extn. changed to .txt to allow attaching)
BACrpm.txt
First set the interface with 2 IP addresses atleast and then assign the first one to another Program like YABE or backstack from skarg, the second free IP use that for the node-red-contrib-bacnet.
Make a simple Read Prop Request to a BACnet Device and instantaly after the ADPU times out we get the "Error: ERR_TIMEOUT" message, this is the correct failure as we are not bound to any interface.
I'm noticing that the lib tries to bind to 0.0.0.0 as seen in the file .node-red\node_modules\node-bacnet\lib\client.js line 18 where the const ALL_INTERFACES = '0.0.0.0'; is set , also needed is line 20 where the const BROADCAST_ADDRESS = '255.255.255.255';
Inside node-red setting the Inteface>Client>IP_address seems to have no effect as it alwalys tries to bind to ALL_INTERFACES IP 0.0.0.0 , which can also result in a Error: bind EACCES as the interface IP is already in use by another client (as seen in the console if node-red is restarted after IP address change and Deployed.
Dirty workaround is to set line 18 with const ALL_INTERFACES = '192.168.252.235'; as in my case and line 20 to const BROADCAST_ADDRESS = '192.168.255.255'; since i have a /22 subnet
Your Environment
Please tell us about your environment:
(x) I am using just the Node-RED package and installed node-bacstack locally (with npm i)
Device :
(x) Windows: v 10
Description of the connecting BACnet system:
(NA) The Problem is on the BACnet Client originating side and not yet out on the wire.
This issue is stale because it has been open 60 days with no activity. It will be closed in 30 days, but can be saved by removing the stale label or commenting.
Problem
(x) unexpected behavior (using node-bacnet lib and supplying the interface IP works)
Current behavior My setup has multiple IP's on the same Network Interface in the same Subnet /22, the first IP 192.168.252.234 is used by another BACnet client and the second is free 192.168.252.235 intended to be used by node-red-contrib-bacnet.
Expected behavior
Minimal reproduction of the problem with instructions
First set the interface with 2 IP addresses atleast and then assign the first one to another Program like YABE or backstack from skarg, the second free IP use that for the node-red-contrib-bacnet.
Make a simple Read Prop Request to a BACnet Device and instantaly after the ADPU times out we get the "Error: ERR_TIMEOUT" message, this is the correct failure as we are not bound to any interface.
I'm noticing that the lib tries to bind to 0.0.0.0 as seen in the file .node-red\node_modules\node-bacnet\lib\client.js line 18 where the
const ALL_INTERFACES = '0.0.0.0';
is set , also needed is line 20 where theconst BROADCAST_ADDRESS = '255.255.255.255';
Inside node-red setting the Inteface>Client>IP_address seems to have no effect as it alwalys tries to bind to ALL_INTERFACES IP 0.0.0.0 , which can also result in a Error: bind EACCES as the interface IP is already in use by another client (as seen in the console if node-red is restarted after IP address change and Deployed.
Dirty workaround is to set line 18 with
const ALL_INTERFACES = '192.168.252.235';
as in my case and line 20 toconst BROADCAST_ADDRESS = '192.168.255.255';
since i have a /22 subnetYour Environment
Please tell us about your environment:
(x) I am using just the Node-RED package and installed node-bacstack locally (with npm i)
Device :
(x) Windows: v 10
Description of the connecting BACnet system:
(NA) The Problem is on the BACnet Client originating side and not yet out on the wire.
node-red-contrib-bacnet version:
node-red-contrib-bacnet@0.2.4
Node: (min. 6.10.x)**
node --version v12.19.0