Realization of the Communication Between Devices of BACnet/IP and Real-time Database

Realization of the Communication Between Devices of BACnet/IP and Real-time Database

Guangchao Zhi Feng ZengHui Liu Fuhua Kuang 

School of Software, Central South University, China

Post-Doctoral Research Station of Shenzhen Das Co., Ltd., China

Department of Computer Science, Missouri State University, USA

Corresponding Author Email: 
dr.zeng@qq.com
Page: 
17-22
|
DOI: 
http://dx.doi.org/10.18280/rces.010104
Received: 
| |
Accepted: 
| | Citation

OPEN ACCESS

Abstract: 

Aimed at interoperability and mutual communication limitations of building automation equipment for different manufacturers and systems, a device driver of DasRdb real-time database is designed and developed independently based on BACnet/IP technology after the BACnet/IP technology and real-time database was analyzed. The device driver adopts UDP communication mode to write and read operations respectively by driving the real-time database DasRdb. This can effectively realize the communication between BACnet devices and DasRdb real-time database, and make it possible for building automation equipment to interoperate. The field engineering application shows that the designed driver conforms to the requirements of the consistency of BACnet, and it has the characteristics of simple, efficient, high precision and good real-time.

Keywords: 

BACnet/IP, UDP, Real-time database, Device driver, Building automation equipment

1. Introduction

With the further development of intelligent building and smart city, building automation system (BAS) is moving in the direction of network, intelligent and integrated [1]. It is inevitable to integrate the central air conditioning systems, power monitoring systems, intelligent lighting systems, elevator systems, fire and intrusion alarm systems and other subsystems to the same network platform.

Due to the interoperability of intelligent building communication devices to continuously strengthen and seamless integration of intelligent building rising, intelligent building storage capacity of status data is increasing, and the efficiency of stored data is decreasing, which has become the bottleneck to improve the performance of building automation system. The rise of real-time database technology and its wide application in ISCS (Integrated Supervisory Control System) provides a new way to solve this problem. Real-time database can be timely and accurately access to real-time data, suitable for processing continuous updated data and affairs with time constraints [2]. At present, real-time database has already been applied in IBMS (Intelligent Building Management System) .

2. The Realization of the BACnet/IP Technology

2.1 BACnet standard system

BACnet(A Data Communication Protocol for Building Automation and Control Network)[3] is a data communication protocol special customized for intelligent building and control system network . It is funded by the American Society of Heating Refrigerating and Air Engineers (ASHRAE)[4], used to open field bus of building automation systems, and it has become an unique ISO standard (ISO16484-5) in the field of building automation system[4,5].

2.2 BACnet/IP architecture

Intelligent building control network is moving into the direction of integration of the Internet, entering the network era. BACnet/IP technology through two layers of micro protocol BACnet/IP (BIP) protocol and BACnet virtual link layer (BVLL) to shield the difference between BACnet and the bottom of the Internet, to realize the seamless interconnection based on IP protocol [6]. In BACne/IP network, you can send messages to any of the BACnet devices based on TCP/IP protocol through a unique IP address. At the other end of the transmission network, the data block encapsulated in the data segment will be taken out from the transmission network and restored to the original data packets [7]. BACnet/IP architecture is shown in Fig.1.

Figure 1. BACnet/IP architecture

3. DasRdb Real-Time Database

Real-time database DasRdb is responsible for on-site data acquisition and conversion as well as storage of engineering values of ​​historical data. Device drivers simply need to provide on-site acquisition value, and the mutual conversion between acquisition value and engineering value will be accomplished through the formula. Running real-time database need to read fast, be flexible access, be easy data sharing between modules. Device drivers are written by regular way of DLL, and real-time database DasRdb loads these DLL drivers dynamically when it starts. Each device DLL drivers also use standardized interface functions, and the driver achieve its specific functions by calling the standard interface functions. ECDINFO driver information structure is shown in Figure 2 (filled out by the driver, fixed length of 512 bytes), including specific information for each device manufacturer.

Figure 2. Information structure of the device driver

4. Realization of the Communication between Real-Time Database and Communication Equipment

Real-time database DasRdb used in this article is developed by Shenzhen DAS Intellitech Co., LTD, which has independent intellectual property rights, and its real-time values ​​of variables in the real-time database can be dynamically refreshed efficiently. Communications equipment adopted global controller of BCM-ETH and BCM-MS/TP, field controller such as VLC-853, VLC-1600, VLC-550 and VLC-660R, which is produced by the U.S. ALERTON company [8] .The bus connection of BCM-ETH, BCM-MS/TP, and  each of BCM-MS/TP adopted the way of hand in hand, and BACnet/IP mode is used for communication. The equipment on the MS/TP bus is also using hand in hand with the bus connection and MS/TP mode is used for communication. The rate of MS/TP bus transfer can be up to 76.8Kbps [9], and the rate of transmission on the BACnet/IP bus can reach 10/100Mbps [9,10].

4.1 The network structure model of field engineering application system

In the field of engineering applications, a global controller connected three BCM-MS/TP via the way of hand in hand, and each global controller BCM-MS/TP used the same way of hanging 127 different field controllers, such as  VLC-853, VLC1600, VLC550 and VLC660R. Real-time database DasRdb can read and write the real-time dynamic data when it is running on the PC and the PC terminal is connected to the BCM-ETH through network cable. The network structure of field engineering application is shown in Figure 3.

Figure 3. The network structure of field engineering application

4.2 Device driver process

The main process Run of the Device driver is shown in Figure 4.

Figure 4. Drivers flowchart

The driver process can be described as follows:

(1) After entering the main process Run, the program first initializes, including open communication port, open threads, group command frame, etc., and then enters the main loop.

(2) Firstly, the real-time database DasRdb carries on write operation, judging whether the thread is open in the first nested loop of the main loop, if the thread is off, then exit; otherwise, it will immediately send frames to send buffer.

(3) To determine whether there is data in the data buffer, if there is no data, then enter the next read operation; if there is data, it will immediately send frames (i.e. write command frame) to the external devices, and receive response frame operation from the external devices.

(4) Determine whether the response frame is successfully received from the external devices, if not successfully received, return and immediately send frames to send buffer; Otherwise, the received data will be processed, and invoke the callback function to refresh real-time database DasRdb, and then enter the next step.

(5) The real-time database DasRdb carries on read operation, judging whether the thread is open in the second nested loop of the main loop, if the thread is off, then exit; otherwise, it will immediately send fixed transmission frame (i.e. read command frame) to send buffer.

(6) To determine whether there is data in the data buffer, if there is no data, and then enter the next read operation; if there is data, it will immediately send fixed transmission frame to the external devices, and receive response frame operation from the external devices.

(7) Determine whether the response frame is successfully received from the external devices, if not successfully received, return and immediately send the fixed transmission frame to send buffer; Otherwise, the received data will be processed, and invoke the callback function to refresh real-time database DasRdb, and then enter the next loop.

5. Test and Analysis of Experiments

5.1 Test results

According to the structure of the model shown in Figurer 3, the BCM-ETH and a VLC-853 device access BACnet/IP network; the MAC address conFigureuration of the VLC-853 device is 7, and the IP address of the BCM-ETH is set to 192.168.1.100, port 47808, as a test platform. The driver runs on the PC, which is used to read and write the object of the equipment, and to refresh and display the real-time database DasRdb. Run the driver, get real-time database running interface of the test as shown in Figure 5.

Figure 5. Running interface of DasRdb of the test

5.2 Consistency Analysis

Use VTS (Visual Test Shell) software to access BACnet devices and to read the data. VTS sends ReadPropertyMultiple service primitives to specify BACnet device, for example, the service primitives of AI1 is ”0C 00 00 00 01 1E 09 55 1F”, and then BACnet devices run this procedure to reply. The following Figure 8 is the reply results after sending AI1, AO0, AV0, AV1, BI0, BO1, BV0 primitives.

Figure 6. VTS experimental test results

From the VTS test results in Figure 6,  it can be seen that AI1, AO0, AV0, AV1, BI0, BO1, BV0 of BACnet device returns the value of the Real respectively are 4095.00, 3.25000, 7.00000, 1.45600, 1, 0, 1. Comparing DasRdb results of experimental tests in Figure 7, we are pleasantly surprised to find that in addition to the different bits of data retention, numerical value completely consistent.

Test results show that data acquired in real-time database DasRdb and response data acquired using VTS software on a PC to send ReadPropertyMultiple instructions are exactly the same, in line with BACnet standard conformance specification. It can be seen that the proposed driver is feasible and efferent.

6. Field Engineering Applications

According to the network structure model of field engineering application shown in Figure 4, BCM-ETH, three BCM-MS/TP connects hand in hand in bus-type mode, each global controller BCM-MS/TP hang multiple field controllers such as VLC-853, VLC1600, VLC550 and VLC660R. Running the device drivers on a PC, the PC as a master node is connected to the BACnet/IP network, to read and write the object of the equipment, and to refresh and display the real-time database DasRdb. Run the driver, get real-time database running interface as shown in Figure 7.

Figure 7. Running interface of DasRdb field engineering applications

In Figure 9, the VLC-550_B1F_02_1, LC-853_B1F_01_1 and VLC-1600_B1F_01_1 are the three device name, used to distinguish between different devices and device location; “SFY” represents air blower, “PFY” represents exhaust fan, “XF” represents air supply, “ST” represents a running state, “C-ST” represents the closed state, “O-ST” indicates the off-state, “ALM” indicates fault alarm, “MA” indicates auto mode. As can be seen from the diagram, the real-time database can read a variety of different BACnet standard objects.

The inevitable direction of automatic control and communication protocol is IP-based. Field application shows that, through independent research and development, device driver based on BACnet/IP protocol is capable of driving real-time database DasRdb efficiently to collect real-time data of BACnet/IP devices. It solves that the equipment of various manufacturers is not compatible and difficult integration in the building automation system, and provides a unified standard to realize the integration of different building control equipment. On the current situation of social technology, BACnet/IP protocol used in the field controller is feasible, due to the decreasing cost of Ethernet, using integrated wiring technology to establish a BACnet/IP communication network has great practical value, and has already started to get a wide range of application. In addition, the engineering application found that device driver using BACnet/IP protocol communication is the best choice, compared to Modbus, OPC and other protocols in terms of remote monitoring.

7. Conclusions

With the growing rise of intelligent building and the further promotion of BACnet protocol, BACnet/IP can enable the building automation equipment of different manufacturers, different systems to be mutual communication, coordination, which make it possible for building intelligent, network and integrated. Accordingly, ISCS throughout the building automation equipment is also more and more attention. Due to real time database timely and accurately to read and write the status of the building automation equipment, it can be used to design and integrate the ISCS of the whole intelligent building, which has a very broad application prospects, and it is significant of the intelligent building and smart city to facilitate each subsystem integration.

Acknowledgements

The research work was supported by National Natural Science Foundation of China under Grant No. 61103202 and Strategic Emerging Industry Development Special Fund Project of Shenzhen under Grant No. CXZZ20120618142442306.

  References

1. Wang Ruihua, Wang Pu, Yin Jinyu, et al., TCP/IP-Based Building Automation and Control Network BACnet [J], Journal of Measurement & Control Technology, 2003, 22(4): 38-41.

2. Liang Hua, Liu Xiande, Implementation of BACnet Based on TCP/IP [J], Journal of Computer & Digital Engineering, 2004, 32(3): 63-65.

3. Zhou Ye, Pan Luoping, Application of Real-time Database in State Monitoring of Hydroelectric Generating Set [J], Journal of Mechanical &Electrical Technique of Hydropower Station, 2011, 34(1): 16-18.

4. BACnet—A Data Communication Protocol for Building Automation and Control Network [S], ANSI/ASHRAE Standard 135-2012.

5. Zhang Jing-fang, Yu Jun-qi, Application of large public buildings energy efficient BACnet network information platform [J], China (International) Electrical Building Technology Forum on Energy Saving in 2010 Proceedings, 2010.

6. Wang Kai-hang, Liu Xinde, Hui Xiaoshi, Implement the Foundation Software of BACnet/IP Based on Java [J], Journal of Computer Engineering and Applications, 2003, 39(17): 230-232.

7. Dong Chunqiao, Principle and Application of Intelligent Building BACnet [M], Publishing House of Electronics Industry, 2003.

8. Yang Zhishen, Zhang Xin, Mu Song, Honeywell-Alerton as Pioneer of BACnet [J], Journal of China Instrumentation, 2013 (6): 23-26.

9. He Haizhou, Meng Lingyuan, Analysis of the Building Control System Based on BACnet [J], Journal of China Information Technology, 2013 (4).

10. [10] Yao Yuan, Yi Benshun, Yang Bo, Design of Embedded Data Acquisition and Control System Based on 10/100M Network [J], Journal of Computer Applications, 2005, 24(B12): 287-288.