Since the latest version of Optic supports functionalities like BBMD and FD using the network port, it is essential to write these properties with correct values. Currently, there is no dedicated UI provided for manipulating Network Port properties, so the only way to do this is through Folio queries.

After changing a property value using bacnetWriteNetworkPortProperty, Optic must be restarted for the changes to take effect. For example, if you change the network-number property value, you must restart Optic for it to start with the new network number. The provision for restarting Optic is flag-based, with the default value being false (i.e., don’t restart Optic), provided in the query. However, it is recommended to restart Optic using the bacnetApplyNetworkPortPendingChanges query.

When you change a property value, the Changes-Pending property is set to TRUE, indicating that some changes have been made and need to be applied. Therefore, once you have made the necessary changes to various network port properties, you can apply those changes by running the bacnetApplyNetworkPortPendingChanges query.

The writable properties are listed below. Only network port properties can be written using this query.

Properties that can be modified in the Network Port object using the bacnetWriteNetworkPortProperty folio query

Properties

Network-Number

BACnet-IP-Mode

IP-Address

BACnet-IP-UDP-port

IP-subnet-mask

BBMD-Accept-FD-Registrations

FD-Subscription-Lifetime

BBMD-Broadcast-Distribution-Table

FD-BBMD-Address

Example: bacnetWriteNetworkPortProperty (property, value, reStartFIN, index)

The "reStartFIN" parameter defaults to FALSE, meaning that changes are applied without restarting Optic. Setting it to TRUE will restart Optic and apply the changes. The "Index" parameter defaults to null.

bacnetWriteNetworkPortProperty(400, "192.168.245.1", true,  null)
This will set the IP-Address property (Property Identifier - 400) of Optic.

bacnetWriteNetworkPortProperty("bacnet_ip_udp_port", 47808)
This will set the IP-UDP port property of the Network Port Object. However, the changes will be applied only when the stack restarts. After setting this property, if you check the "Changes-Pending" property, it will show TRUE until the changes are applied.

bacnetWriteNetworkPortProperty("network-number", 65530)
This will set the Network-Number property. However, the changes will be applied only when the stack restarts. After setting this property, if you check the "Changes-Pending" property, it will show TRUE until the changes are applied.