Library
2.8.0
  • ABB - AC500
  • CODESYS - Application
  • CODESYS - Use Cases
  • CODESYS - System
  • CODESYS - Intern
    • CANbus
    • CAA
    • 3SLicense (LIB)
    • AlarmManager
    • SFC
    • Networking
    • BACnet
      • BACnet (LIB)
      • CODESYS BACnet library - detailed information
      • BACnet2 (LIB)
      • CODESYS BACnet2 library - detailed information
        • Contents:
          • BACnetClient
          • BACnetHooksCallbacks
          • BACnetObjects
          • BACnetServer
            • Async
            • BACnetDataLink (FB)
            • BACnetIPdatalink (FB)
            • BACnetMSTPdatalink (FB)
              • Runtime changes of broadcast distribution table entries as well as foreign device table
                • BACnetMSTPdatalink.Baudrate (PROP)
                • BACnetMSTPdatalink.Connection (PROP)
                • BACnetMSTPdatalink.DatalinkType (PROP)
                • BACnetMSTPdatalink.DeviceName (PROP)
                • BACnetMSTPdatalink.MSTPaddr (PROP)
                • BACnetMSTPdatalink.MaxInfoFrames (PROP)
                • BACnetMSTPdatalink.MaxManager (PROP)
                • BACnetMSTPdatalink.MaxMsgReq (PROP)
                • BACnetMSTPdatalink.NetworkNumber (PROP)
                • BACnetMSTPdatalink.ReplyTimeout (PROP)
                • BACnetMSTPdatalink.TokenTimeout (PROP)
                • protected
            • BACnetServer (FB)
            • IBACnetServer (ITF)
          • BACnetServerPlugin
          • Constants (GVL)
          • Debug
          • Doc
          • Enums
          • Library Information
          • Persistence
          • PropertyConfiguration
          • Structs
          • Utilities
        • Indices and tables
      • BACnet2DefaultImpl (LIB)
      • BACnetDefaultImpl (LIB)
    • IoDriverBase
    • Breakpoint Logging Functions (LIB)
    • DataSources
    • DataServer
    • Common Behaviour Model (LIB)
    • Element Collections (LIB)
    • IoDrivers
    • Utils
    • SymbolConfiguration
    • NetVars
    • RecipeManagement
    • Rts Service Handler (LIB)
    • Strings
    • Visu
    • Unit Conversion Interfaces (LIB)
Library
  • »
  • CODESYS - Intern »
  • BACnet »
  • BACnet2 (LIB) »
  • BACnetServer »
  • BACnetMSTPdatalink (FB)

BACnetMSTPdatalink (FB)

FUNCTION_BLOCK BACnetMSTPdatalink EXTENDS BACnetDatalink

BACnet MS/TP datalink.

Information configured in BACnetMSTPdatalink (including the serial configuration) is used to generate the BACstack configuration file (bacstac.ini) on the PLC.

CODESYSControl.cfg contains a setting:

[CmpBACnet] IniFile=bacstac.ini

to define where the BACstack configuration file is to be found. Because the BACstack configuration file is written using the information from BACnetMSTPdatalink, it is accessed from either the runtime system (component) CmpBACnet and the IEC application. So an absolute path or placeholders has to be used for this setting, for example:

[CmpBACnet] IniFile=/tmp/bacstac.ini

If sandboxing the runtime system filesystem is chosen, the setting [SysFile] ForceFilePath= has to be used to allow access for the absolute path of the BACstack ini file.

Runtime changes of broadcast distribution table entries as well as foreign device table

The BACnetServer configuration AutoGenerateBACstackConfig allows to control if the BACstack configuration file is generated during BACnetServer.StartBACnetStack. If AutoGenerateBACstackConfig is set to FALSE, BACnetServer.GenerateBACstackConfig can be used to generate the BACstack configuration file on demand.

BBMD broadcast distribution table (BDT) entries as well as foreign device table (FDT) entries added by clients requests are stored in the BACstack configuration file. This happens at runtime of your application and is not reflected in the configuration parameters of the BACnetMSTPdatalink. Re-generating the BACstack configuration file each time at application start would eliminate the entries written at application runtime. So take care to generate the BACstack configuration file only if needed (most likely at initial setup, or at changes in network structure) to ensure keeping those entries. In case you’r using the BACnet device with BBMD functionality and clients requests are to be expected to add/change/remove BDT/FDT entries, you need to set AutoGenerateBACstackConfig := FALSE to keep them persistent.

Properties:

Baudrate

Connection

DatalinkType

DeviceName

MSTPaddr

MaxInfoFrames

MaxManager

MaxMsgReq

NetworkNumber

ReplyTimeout

TokenTimeout

Methods:

CheckMstpDeviceDriverReady

Structure:

  • BACnetMSTPdatalink.Baudrate (PROP)
  • BACnetMSTPdatalink.Connection (PROP)
  • BACnetMSTPdatalink.DatalinkType (PROP)
  • BACnetMSTPdatalink.DeviceName (PROP)
  • BACnetMSTPdatalink.MSTPaddr (PROP)
  • BACnetMSTPdatalink.MaxInfoFrames (PROP)
  • BACnetMSTPdatalink.MaxManager (PROP)
  • BACnetMSTPdatalink.MaxMsgReq (PROP)
  • BACnetMSTPdatalink.NetworkNumber (PROP)
  • BACnetMSTPdatalink.ReplyTimeout (PROP)
  • BACnetMSTPdatalink.TokenTimeout (PROP)
  • protected
    • BACnetMSTPdatalink.CheckMstpDeviceDriverReady (METH)
Next Previous

© Copyright 2024, ABB.