BACnet MSTP

From AutomationWiki
Jump to: navigation, search

Introduction[edit]

BACnet MSTP is a token passing protocol. Here the MS stands for Master - Slave and the TP stands for Token Passing. This flavor of BACnet is mainly used for connecting field devices to controllers / routers / control applications. BACnet MSTP uses RS485/EIA485 as its physical layer which allows up to 128 devices to be installed on a single network with a max physical length of 4000ft/1219.2m and speeds up to 115k baud. Using repeaters allows the length to be increased. General baud rates are 19200, 38400 and 76800. All devices have to operate at the same baud rate and upon autosensing the baud rate, more and more devices configure themselves correctly.

MSTP master and slave[edit]

Only nodes with the token are permitted to initiate service requests like requests for data. A device that receives a request, a request that requires a response, might respond without having the token. Based on this behavior it is simple to understand the difference between a MSTP master and slave. A slave is a device that can only send responses. A master is an initiator of a service request.

MSTP Messages[edit]

Messages on a MSTP network are divided into two categories:

  1. Overhead i.e. token, poll for master etc.
  2. Application: These types of messages carry payloads

Only a device with the token can set off an application layer message. It can send the message to any device on the network. Some messages require an immediate reply while some don’t. The receiving device doesn’t call for the token to respond. There is a limit to how many application layer messages a device can send before it must pass the token on.

Merits of token passing networks[edit]

  1. They are self healing
  2. They can discover new devices
  3. They ensure each device gets its chance
  4. They avoid collisions making network performance deterministic to some extent.

Demerits[edit]

Major disadvantage of the token system is that any one device gets a limited use of the bandwidth and thereby a device may necessitate keeping an internal queue of application layer messages it wants to send, waiting to use the token. There are some vendors' systems which fill the queue and then drop subsequent messages without notifying the user of the problem. Limited access combined with the overhead makes it effortless to consume all the bandwidth on the network in case there are many devices with many objects and many properties of concern.

Common BACnet MSTP problems[edit]

  1. Configuration needs to be checked properly. Do not poll for properties that don’t exist or properties of objects that don’t exist or devices that don’t exist. There is a 250msec timeout to these polls.
  2. Duplicate Mac Addresses are a disaster since both addresses will try and use the token and this will cause token breakdown and force the system to recover the token. This all results in immense waste of time and will consume all our bandwidth.
  3. Duplicate Device Instance ID’s are a severe problem as one will get data whose source is not reliably known.

Read more at Chipkin Automation