A versatile networked embedded platform for KNX/EIB - CiteSeerX

16 downloads 12333 Views 435KB Size Report
Receiving stations know their dedicated group (or groups) and can accordingly ... plement multiple network services like e.g. for TCP/IP. Both hardware and ... and mini host support is integrated into the controller and appropriate connectors ...
A versatile networked embedded platform for KNX/EIB Fritz Praus and Wolfgang Kastner Institute of Computer Aided Automation Vienna University of Technology Vienna, Austria Email: {fpraus,k}@auto.tuwien.ac.at Abstract — The deployment of home and building automation systems (BAS) allows to increase comfort, safety and security and to reduce operational cost in the building domain. Today such systems typically follow a hierarchical distributed approach. While control networks interconnect smart sensors and actuators, a backbone network provides the infrastructure for management tasks. Devices interconnecting these networks play a strategic role. Especially in the home domain, the integration of various control and data networks is essential for maximum benefit. The objective of my diploma thesis [1, 2] was to design such an embedded and versatile interconnection platform in hard- and software with a particular focus on the European Installation Bus (KNX/EIB) Twisted Pair (TP).

I.

I NTRODUCTION

KNX/EIB [3] is a popular control network based on an open specification and designed to enhance electrical installations in buildings. It is well-established in central Europe, i.e. Germany, Austria and Switzerland. KNX/EIB is primarily found in large building installations with main application areas being lighting, control of window blinds and HVAC systems. In home area the increase of comfort, safety and security is the major reason for using KNX/EIB. KNX/EIB features a decentralised design. It is a peerto-peer network system: Nodes communicate directly with each other using a distributed algorithm for medium access. There are hardly any central control nodes that solely fulfil regulation functions as, for instance, a Programmable Logic Controller (PLC) does. In fact, control and working logic is located at every single node. To put it differently: Every single sensor or actuator implementing the KNX standard is able to handle network communication as well as implementation of the desired logic on its own. A key feature in KNX/EIB is group communication (process data exchange) based on a form of publisher subscriber model, allowing to address an arbitrary number of receivers by way of a single message. A sender uses a logical group address as its destination address. Receiving stations know their dedicated group (or groups) and can accordingly ignore or process incoming messages. For configuration and management purposes point-to-point messages are used. KNX/EIB allows various media. The primary used medium is shielded or unshielded Twisted Pair (TP) cabling known as KNX TP1, allowing a free topology with

cable lengths of up to 1000 m per physical segment. Data is transmitted at 9600 b/s. Integration of KNX/EIB into existing installations can be achieved using powerline as communication system. Speed is limited to 1200 b/s respectively 2400 b/s depending on used technology. To further extend KNX/EIB, KNX Radio Frequency (RF) can be used. A subband in the 868 MHz frequency band, reserved for short-range devices, is used. For more details see [4]. The primary goal of my interconnection platform named KNXcalibur (Figure 1) is to be universally applicable as a router, gateway and workstation interface for KNX/EIB. The main purpose is to serve as a basis for further work in the scope of home and building automation (e.g. plug and play facilities, integration into Open Services Gateway initiative (OSGi) environments [5], coupling to other networks, extensions with regard to security issues (EIBsec [6]), setup of set-top boxes, access point for BASys [7]). KNXcalibur is designed as a flexible, extensible, compact and low cost stand-alone device. The used hardware is powerful in the sense that enough processing power and memory are present to implement multiple network services like e.g. for TCP/IP. Both hardware and software design are openly available [http://eib.praus.at]. II.

H ARDWARE

The leaded as well as surface mounted components are fitted on a double sided printed circuit board (PCB) in Eurocard (160 mm x 100 mm) format (Figure 1). A Fujitsu MB90330 microcontroller (MCU) with 24 MHz, 24 KB RAM, and 384 KB Flash ROM forms the central part. It features 4 UARTs, which provide the connection to a PC via two EIA-232 interfaces and connection to KNX/EIB via two TP-UART ICs (standard KNX/EIB interface). Moreover, USB functionality with device (2.0 full speed) and mini host support is integrated into the controller and appropriate connectors are mounted. Via the external bus interface of the MCU a Cirrus Logic CS8900A Ethernet controller is connected, providing 10 MBit/s Ethernet support. To support persistent data storage without writing to the MCU’s on-chip flash memory and to extend available memory, a SD/MMC card connection has been integrated. III.

S OFTWARE

The software of KNXcalibur consists of a low level firmware and various network protocol stacks. The for-

Figure 1: KNXcalibur: Hardware mer implements the necessary drivers to communicate with the hardware and provides an API to configure, initialise and access the available hardware. It is split into various parts: The UART and TP-UART firmware allow easy asynchronous serial communication with a PC and the TP-UARTs. The SD/MMC firmware provides raw access (byte, block, sector) to an inserted SD/MMC card. In addition, the FAT16 file system is implemented, allowing easy access for advanced application layers. The CS8900A Ethernet controller is accessed via an interrupt driven ISA bus emulation. Access to the USB slave and mini host functions of the MCU is provided by an open implementation by Thesycon Systemsoftware & Consulting GmbH in cooperation with Fujitsu.

Figure 2: KNXcalibur: Software On top of the low level firmware various layers are implemented (Figure 2). The IP network layer forms the basis for many other network protocol stacks. Relevant parts of ARP, SLIP, IP, ICMP, UDP, TCP and DHCP are implemented. Currently only a single TCP connection and no IP fragmentation are supported. Three HTTP (port 80) applications are possible: The current device status (KNX/EIB connection, SD/MMC card status, ...) is returned in a formatted HTML page.

Second, a simple interface for sending KNX/EIB TP frames is presented, and third, a standard web server facility is implemented: The corresponding file is searched on the SD/MMC card and is then displayed to the user. Besides HTTP, the BASys [7] protocol is implemented. A KNX/EIB protocol extension called EIBnet/IP describes the transportation of KNX telegrams on top of IP networks. The implemented stack is positioned on top of the IP network layer and on top of the cEMI (frame format of KNX/EIB) handler and acts as a gateway/router between the two networks. It accepts EIBnet/IP frames from UDP/TCP level and cEMI frames from the cEMI handler and processes the received frames according to their message types. Valid packets are passed to the destination service. IV.

C ONCLUSION

Due to the modular design concept of KNXcalibur, the platform is not limited to the use in a predefined application area. Since both, hardware and software can easily be extended, a basic device for future research has been created. Interfaces to other networked BAS like BACnet or LONWorks as well as to wireless solutions (KNX RF) and security extensions (EIBsec [6]) are currently under investigation.

R EFERENCES [1] Fritz Praus, Wolfgang Kastner, and Oliver Alt. Yet Another All-purpose EIBNet/IP Gateway. In Konnex Scientific Conference, 2004. [2] Fritz Praus. A versatile networked embedded platform for KNX/EIB. Master’s thesis, Vienna University of Technology, Institute of Computer Aided Automation, Automation Systems Group, 2005. [3] Konnex Association, Brussels. KNX Handbook 1.1 and KNX Standard Extensions, 2004. [4] Wolfgang Kastner and Georg Neugschwandtner. EIB: European installation bus. In The Industrial Communication Technology Handbook, volume 1, chapter 34. CRC Press, 2005. [5] Wolfgang Kastner and Georg Neugschwandtner. Service Interfaces for Field-Level Home and Building Automation. In 5th IEEE International Workshop on Factory Communication Systems (WFCS), pages 103–112, September 2004. [6] Wolfgang Granzer, Wolfgang Kastner, Georg Neugschwandtner, and Fritz Praus. Security in networked building automation systems. In 6th IEEE International Workshop on Factory Communication Systems (WFCS), January 2006. [7] Oliver Alt. Entwicklung eines Softwaresystems zur Planung und Inbetriebnahme von Geb¨audeautomationssystemen. Master’s thesis, Technische Universit¨at Darmstadt, 2003.

Suggest Documents