SlideShare a Scribd company logo
Wireless M-Bus Suite and Silabs speci๏ฌc
documetation
Quick Start Guide
January 17, 2014
page 2
Document History
1.00 2013-10-11 First release mr
1.01 2013-11-11 Setup chapter updated mr
1.02 2013-11-14 Note in chapter โ€™Firmwareโ€™ added mr
1.03 2014-01-17 Added chapter 4.1.4 ar
Table 1: Document History
Quick Start Guide
Version 1.02
1 INTRODUCTION page 3
1 Introduction
This document is a hardware and software guide for Silabs devices and the Wireless M-Bus Stack from Steinbeis
Transfer Center Embedded Design and Networking [STZEDN] and describes the installation of Wireless M-Bus devices
to test, to evaluate and to con๏ฌgure with the Wireless M-Bus Suite.
The guide contains the following chapters:
โ€ข Chapter 5.1: System Requirements
This chapter speci๏ฌes the system requirements for the PC to use the Wireless M-Bus Suite for 32-Bit and 64-Bit
operating systems.
โ€ข Chapter 5.2: COM Port Settings
This chapter contains the required settings to connect the target hardware to the PC.
โ€ข Chapter 4: Hardware Setup and Firmware Installation
This chapter describes the hardware setup, de๏ฌnes performance and peripheral information and speci๏ฌes dif-
ferent ways to upload the Wireless M-Bus Stack from STZEDN for each Silabs microcontroller family.
โ€ข Chapter 5: Wireless M-Bus Suite Quick Start Guide
The Wireless M-Bus Suite quick start guide leads the user step by step through the included demo con๏ฌguration
to setup a Wireless M-Bus network in a fast and easy way.
The Wireless M-Bus Suite from STZEDN is a computer program to test, to evaluate and to con๏ฌgure Wire-
less M-Bus devices running the Wireless M-Bus Stack. It contains mechanisms to build up a Wireless M-Bus
network. It provides interfaces to control the different device types of the Wireless M-Bus Stack - collector,
meter and protocol monitor (Wireless M-Bus sniffer). The Wireless M-Bus Suite is designed to handle different
network con๏ฌgurations. Con๏ฌgurations can easily be changed, updated or stored. Furthermore it is capable
to run Wireless M-Bus devices with different parameters and settings (e.g. security, device addresses, uni- or
bidirectional).
The Wireless M-Bus Suite uses a serial interface to communicate with the Wireless M-Bus devices and is able
to upload a new ๏ฌrmware image to a Wireless M-Bus device.
โ€ข Chapter 6: Wireless M-Bus Protocol Monitor
The Wireless M-Bus Protocol Monitor is an integrated application in the Wireless M-Bus Suite. It is a Wireless
M-Bus Sniffer and can be used to monitor Wireless M-Bus packets. Besides meter and collector con๏ฌgura-
tions, the Wireless M-Bus Stack from STZEDN contains con๏ฌgurations is capable of Wireless M-Bus Sniffer
con๏ฌgurations.
โ€ข Chapter 7: Demonstration Application
This chapter presents the demonstration application of the Wireless M-Bus Stack with a sample experimenter
Quick Start Guide
Version 1.02
1 INTRODUCTION page 4
board. Furthermore, it de๏ฌnes the nomenclature, speci๏ฌes the different delivery packages of the Wireless M-Bus
Stack and shows how to use the Wireless M-Bus Stack with and without the Wireless M-Bus Suite.
Table 2 lists the supported Transceivers from Silabs, as well as the supported Starter Kits.
SI4461 SI4463
EFM32LG890 X X
Table 2: Supported Transceivers and Starter Kits
Quick Start Guide
Version 1.02
CONTENTS page 5
Contents
1 Introduction 3
2 Wireless M-Bus Basics 11
2.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.2 Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.2.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.2.2 Communication Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.2.3 Unidirectional vs. Bidirectional Communication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
3 The STZEDN Protocol Stack 15
3.1 Wireless M-Bus Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
3.2 Wireless M-Bus Protocol Stack Deliveries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
3.2.1 Demonstration Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
3.2.2 Wireless M-Bus Stack as Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.3 Con๏ฌguration of the Wireless M-Bus Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.4 Memory Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.4.1 Internal data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
3.4.2 Volatile memory model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
3.4.3 Non-volatile memory model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
3.4.3.1 Data storage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
3.4.3.2 Non-volatile memory management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
3.5 Encryption Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
3.6 Sleep modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
3.7 Wireless M-Bus Channels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
4 Setup 23
4.1 Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4.1.1 Supported Radio Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4.1.2 Hardware requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4.1.3 Wireless M-Bus Hardware Platform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4.1.3.1 EFM32LG-STK3600 Leopard Gecko Starter Kit . . . . . . . . . . . . . . . . . . . . . . . . . 24
4.1.3.2 MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.1.3.3 Connection between Leopard Gecko MCU and EZRadioPRO transceiver . . . . . . . . . 26
4.1.3.4 EZRadioPRO RF Pico Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.1.4 Required hardware resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.2 Firmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
4.2.1 Firmware Installation with Simplicity Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
4.2.2 Install Firmware with IAR compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Quick Start Guide
Version 1.02
CONTENTS page 6
5 Wireless M-Bus Suite 34
5.1 System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
5.2 COM Port Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
5.3 Loading the demo project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
5.4 Collector short description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
5.5 Meter short description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
5.6 Using the Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
5.6.1 Mode selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
5.6.2 Console . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
5.7 Perform a ping test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
5.8 Using the transmission tests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
5.9 Wireless M-Bus Protocol Monitor Quick Start Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
6 Wireless M-Bus Protocol Monitor 54
6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
6.2 Wireless M-BUS protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
6.3 Running the protocol monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
6.4 Packet View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
6.5 CSV View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
6.6 Statistics View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
6.7 Timeline View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
6.8 Details View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
6.9 Filter View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
6.10 No warranty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
7 Demonstration Application 61
7.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.2 The Wireless M-Bus Stack Nomenclature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.2.1 Pre-compiled Firmware Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.2.1.1 Wireless M-Bus Stack Firmware Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.2.2 Wireless M-Bus Stack Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
7.2.3 IAR Projects and Con๏ฌgurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
7.2.3.1 Library Build IAR Workbench Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
7.2.3.2 Library Usage IAR Workbench Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
7.2.3.3 Source Code IAR Workbench Project with serial interface disabled . . . . . . . . . . . . 64
7.2.3.4 Source Code IAR Workbench Project with serial interface enabled . . . . . . . . . . . . . 65
7.3 The Demonstration Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
7.3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
7.3.2 Demonstration Application without Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . 66
Quick Start Guide
Version 1.02
CONTENTS page 7
7.3.3 Demonstration Application with Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . . . 67
7.4 Download Binary Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
7.5 The Wireless M-Bus Stack as Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
7.5.1 Build Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
7.5.2 Use Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
7.6 The Wireless M-Bus Stack as Source Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
8 Contact information 70
References 71
Quick Start Guide
Version 1.02
LIST OF TABLES page 8
List of Tables
1 Document History . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
2 Supported Transceivers and Starter Kits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
3 Operating Modes of Wireless M-Bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
4 Operating Modes of Wireless M-Bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
5 Compatibility matrix for Wireless M-Bus operating modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
6 Available Wireless M-Bus Protocol Stack Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
7 Available Wireless M-Bus memory models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
8 Available Types and Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
9 Internal data of a Wireless M-Bus meter device. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
10 API functions, which case a non-volatile write access imediately. . . . . . . . . . . . . . . . . . . . . . . . . 19
11 Encryption Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
12 Available channels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
13 Supported Transceivers and RF Pico Boards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
14 Hardware requirements for a meter / collector device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
15 Pin compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
16 Hardware Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
17 Memory consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
18 โ€™Smart Meterโ€™ Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
19 Console View Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
20 List of Wireles M-Bus ๏ฌelds. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
21 Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles without a serial interface and without Wire-
less M-Bus Suite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
22 Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles with a serial interface and with Wireless
M-Bus Suite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
23 Nomenclature of the Wireless M-Bus Stack library ๏ฌles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
24 Con๏ฌguration Names of the Library Build porject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
25 Con๏ฌguration Names of the Library Usage porject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
26 Con๏ฌguration Names of the Debug porject with serial interface disabled . . . . . . . . . . . . . . . . . . . 64
27 Con๏ฌguration Names of the Debug porject with serial interface enabled . . . . . . . . . . . . . . . . . . . 65
28 Wireless M-Bus Stack Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Quick Start Guide
Version 1.02
LIST OF FIGURES page 9
List of Figures
1 Bidirectional Communication with a request after the reception of a periodical meter packet. Example
for mode S2. (Supported by the following modes: T2, S2, C2 and N2) . . . . . . . . . . . . . . . . . . . . 14
2 Wireless M-Bus Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
3 Non-volatile memory work ๏ฌ‚ow. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
4 List of frequencies used by Wireless M-Bus mode S, T and C . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
5 List of frequencies used by Wireless M-Bus mode N . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
6 The 32bit W-MBUS Hardware Platform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
7 EFM32LGSTK3600 hardware layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
8 Breakout pads and expansion header . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9 EXP Header Pins on Leopard Gecko Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
10 MSC-RFP2EFM Adapter Board connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
11 EXP header pins on MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
12 RF Pico Board Pins on MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
13 RF Pico Board Front Side . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
14 Simplicity Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
15 Select "energyAwareCommander" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
16 Select the connected board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
17 Select "Flash" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
18 Flash the selected ๏ฌrmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
19 Download . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
20 Workbench con๏ฌguration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
21 Open project options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
22 Driver selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
23 Standard COM port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
24 Virtual COM port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
25 Start -up dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
26 Collector and Meter device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
27 Collector editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
28 Meter connected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
29 Meter disconnected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
30 Meter without collector address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
31 Meter addresses duplicate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
32 COM Port selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
33 Select โ€™Smart Meterโ€™ meter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
34 โ€™Data Collectorโ€™ programmed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
35 โ€™Smart Meterโ€™ Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
36 โ€™Smart Meterโ€™ programmed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Quick Start Guide
Version 1.02
LIST OF FIGURES page 10
37 Mode selection boxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
38 Collector C and Meter T . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
39 Mode Nb example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
40 Console View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
41 Console with serial text output enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
42 Write con๏ฌg to device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
43 Start ping test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
44 Ping test failed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
45 Ping test ok . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
46 โ€™Start wireless M-Bus demoโ€™ button โ€™Data Collectorโ€™ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
47 โ€™Start wireless M-Bus demoโ€™ button โ€™Smart Meterโ€™ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
48 โ€™Data Collectorโ€™ Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
49 Send data test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
50 Open the โ€™Wireless M-Bus Protocol Monitorโ€™ wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
51 Select the serial connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
52 Select the protocol monitor device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
53 Select the protocol monitor device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
54 Wireless M-Bus Protocol Monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
55 Example of a Wireless M-Bus packet. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
56 Starting and stopping the wireless M-Bus protocol monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
57 Packet View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
58 CSV View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
59 Statistic View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
60 Timeline View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
61 Detail View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
62 De๏ฌning a ๏ฌlter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
63 De๏ฌning several rules. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
64 Demonstration Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Quick Start Guide
Version 1.02
2 WIRELESS M-BUS BASICS page 11
2 Wireless M-Bus Basics
2.1 Introduction
The Metering Bus (or in short "M-Bus ") is a ๏ฌeld bus specialized for transmission of metering data from gas, electricity,
heat, water or other meters to a data collector. It is described by European Norm (EN 13757), which includes the
speci๏ฌcation of wired and Wireless M-Bus. The speci๏ฌcation is divided into ๏ฌve parts:
โ€ข EN 13757-1 ([1]):
Communication systems for meters and remote reading of meters - Part 1: Data exchange
The ๏ฌrst part describes the basic communication between the meters and a central data collector. It provides
an overview of the communication system.
โ€ข EN 13757-2 ([2]):
Communication systems for meters and remote reading of meters - Part 2: Physical and link layer
The second part includes the speci๏ฌcation of the physical data transmission using wired connections. It also
includes the description of the protocol to transmit the data.
โ€ข EN 13757-3 ([3]):
Communication systems for meters and remote reading of meters - Part 3: Dedicated application layer
The third part describes a standardized application protocol to enable multivendor capability. So devices of
different manufacturers may be combined in one system.
โ€ข EN 13757-4 ([4]):
Communication systems for meters and remote reading of meters - Part 4: Wireless meter readout (Radio me-
ter reading for operation in the 868 MHz to 870 MHz SRD band)
This part speci๏ฌes the wireless communication of M-Bus and is the main source document for this implemen-
tation. It includes the Physical and the Data Link Layer for wireless devices. It corresponds to speci๏ฌcation EN
13757-2 for wired communication.
โ€ข EN 13757-5 ([5]):
Communication systems for meters and remote reading of meters - Part 5: Relaying
This last part includes different proposals for relaying data frames to overcome the range problem between
remote meters and data collectors.
The sixth part of this norm relates only to wired busses and is disregarded in this document.
All parts of EN 13757 are compliant to the European Norm EN 870-5 [6].
Quick Start Guide
Version 1.02
2 WIRELESS M-BUS BASICS page 12
2.2 Protocol Stack
2.2.1 Introduction
M-Bus is compatible to the international ISO/OSI-model, but only the layers 1, 2 and 7 are implemented.
Layer 7 Application Layer (EN 13757-3)
Layer 2 Data Link Layer (EN 13757-2 or EN 13757-4)
Layer 1 Physical Layer (EN 13757-2 or EN 13757-4)
Table 3: Operating Modes of Wireless M-Bus
Up to now, the application layer implements all other protocol layers required for a speci๏ฌc appliance. Especially
if routing is required according to [5], it is implemented in the application layer. The reduced modularity leads
to compact implementations running on very small devices with minimum computing resources. But the lack of
modularity certainly is one of the reasons why standardized routing protocols are currently not available for Wireless
M-Bus. The M-Bus favours asymmetric network topologies with low-cost or low-power metering devices on the one
side and data collectors or gateways with higher performance on the other side. Currently, only point-to-point or
star network topologies can be supported. Mesh or multi-hop topologies are not possible. This chapter describes the
settings for implementations of the data collector and the metering devices to setup a network in star topology.
2.2.2 Communication Modes
Dependly on the application there are various combinations of communication modes for data collectors and metering
devices. These settings de๏ฌne the communication ๏ฌ‚ow and the con๏ฌguration of the radio channel. Table 4 lists
available communication modes.
Mode Communication Description
S1 Unidirectional In the stationary mode, the metering devices send their data several times a day.
In this mode, the data collector may save power as the metering devices send a
wakeup signal before transmitting their data.
S2 Bidirectional Bidirectional version of S1.
T1 Unidirectional In the Frequent Transmit mode, the metering devices periodically send their data
to collectors in range. The interval is con๏ฌgurable in terms of several seconds or
minutes.
T2 Bidirectional Bidirectional version of T1. The data collector may request dedicated data from
the metering devices.
C1 Unidirectional "Compact Mode" mode. This mode is similar to mode T but it allows for transmis-
sion of more data within the same energy budget and with the same duty cycle. It
is suitable for walk-by and/or drive-by readout. The common reception of mode T
and mode C frames with a single receiver is possible.
C2 Bidirectional Bidirectional version of C1. The data collector may request dedicated data from
the metering devices.
Table 4: Operating Modes of Wireless M-Bus
Table 5 lists the combinations of the communication modes of meters and data collectors.
Quick Start Guide
Version 1.02
2 WIRELESS M-BUS BASICS page 13
In T2 mode, the communication settings for the two data directions are different. Due to different requirements,
both communication devices have to support fast switching of communication speed, coding scheme, and frequency.
Meter Deviceโ€™s channels
Data
Collector
channels
S1, S2 T1, T2 C1, C2 Collector Deviceโ€™s Tx radio
settings
(Freq., data rate, modula-
tion)
S1, S2 X 868,30 MHz 32.768 kcps
Manchester enc.
T1, T2 X 868,30 MHz 32.768 kcps
Manchester enc.
C1, C2 X 868,30 MHz 32.768 kcps
Manchester enc.
C1, C2 X 869,525 MHz 50 kcps NRZ
enc.
MeteringDeviceโ€™s
Txradiosettings
(Freq.,datarate,modulation)
868,30MHz
32.768kcps
Manchesterencoding
868,95MHz
100kcps
3-out-of-6encoding
868,95MHz
100kcps
NRZencoding
Table 5: Compatibility matrix for Wireless M-Bus operating modes
Table 5 shows that although the T- and S-modes cannot be combined, a T2 data collector may not well coexist with a
parallel S-mode communication int its vicinity. Table 5 also shows that the C-mode supports the common reception
of mode T and mode C frames with a single receiver.
2.2.3 Unidirectional vs. Bidirectional Communication
If unidirectional communication is used, data will be sent from the metering device to the data collector only. This
enables simple transmitters as metering devices while the data collector only needs to receive. Because listen-before-
talk (LBT) and dynamic network con๏ฌguration are not possible, it is recommended to use the unidirectional modes
for small and simple constellations with little network load.
In case of bidirectional communication, the collector device can request data from the meter device. This is for
example the case in S2, T2, C2 and N2 mode. In this modes, a bidirectional communication will only be established
if further data or commands need to be exchanged (cf. Fig. 1). Figure 1 shows a typical communication ๏ฌ‚ow.
Quick Start Guide
Version 1.02
2 WIRELESS M-BUS BASICS page 14
Figure 1: Bidirectional Communication with a request after the reception of a periodical meter packet. Example for
mode S2. (Supported by the following modes: T2, S2, C2 and N2)
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 15
3 The STZEDN Protocol Stack
3.1 Wireless M-Bus Protocol Stack
The Wireless M-Bus Stack from STZEDN is a fully Wireless M-Bus complicant protocol stack, including OMS v.3.0.1
[7]. It implements the functionality described in EN-13757 ([1], [2], [3], [4], [5]). Refer to ๏ฌgure 2 for a graphical
overview.
Figure 2: Wireless M-Bus Protocol Stack
The Wireless M-Bus protocol stack from STZEDN basically consists of four different parts:
โ€ข Wireless M-Bus Stack:
The Wireless M-Bus Stack part of the protocol stack contains all Wireless M-Bus functionality.
โ€ข Hardware drivers:
This part of the protocol stack contains all low level drivers to control the microcontroller unit, such as com-
munication interfaces, memory resources and pheripheral units.
โ€ข Utility Module:
This part of the protocol stack contains mechanisms and functions which the stack uses to forward information
through the protocol layers, to report runtime information, to handle time intervals and clocks, to manage
meterlists and to execute software updates.
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 16
โ€ข Con๏ฌguration interfaces:
The con๏ฌguration interfaces are used to setup basic parameters of the target, such as location of the commu-
nication settings or input interrupt sources.
STZEDN offers different packages of the Wireless M-Bus protocol stack. All packages support full Wireless M-Bus
functionality. Refer to table 6 for an overview. To ๏ฌnd the most suitable Wireless M-Bus version for the desired
application, please contact STZEDN (refer to chapter 8).
Layer Basic Extended Extended serial Full
Application Layer x x x
Extended Data Link Layer x x x x
Data Link Layer x x x x
Physical Layer x x x x
RF Driver x x x x
MCU Driver x x x x
Serial Driver x x
Bootloader support x
Table 6: Available Wireless M-Bus Protocol Stack Packages
Table 7 lists the different memory models of the stack. The memory model speci๏ฌes where the Wireless M-Bus Stack
saves internal data and meterlists.
Package Volatile memory Non-volatile memory
Basic x x
Extended x x
Extended serial x x
Full x x
Table 7: Available Wireless M-Bus memory models
Please contact STZEDN for information about currently supported microcontrollers and transceivers. Adaptions of
the Wireless M-Bus protocol stack are possible upon request as well as driver developments for microcontrollers and
transceivers. Please refer to chapter 8 for contact information.
3.2 Wireless M-Bus Protocol Stack Deliveries
3.2.1 Demonstration Applications
Demonstration applications for development boards were delivered as binary ๏ฌles. Please note, that the demon-
stration application contain the full Wireless M-Bus Stack from STZEDN. The Wireless M-Bus Suite can be used to
study, test and evaluate the wmbus demonstration application and Wireless M-Bus, e.g. bidirectional communica-
tion between a Wireless M-Bus collector and a Wireless M-Bus meter device. Furthermore, Wireless M-Bus Suite can
download the binary ๏ฌles to development boards to switch between Wireless M-Bus device types and Wireless M-Bus
modes. Please contact STZEDN for information about supported development boards. The Wireless M-Bus Suite also
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 17
supports Wireless M-Bus sniffer applications for all Wireless M-Bus channels, including decryption and encryption of
data.
3.2.2 Wireless M-Bus Stack as Library
STZEDN delivers the Wireless M-Bus Stack for the Wireless M-Bus devices types and Wireless M-Bus modes in li-
braries. Refer to table 8 for an overview. Please contact STZEDN for information about supported integrated de-
velopment environments. Refer to chapter 8 for contact information. The customer is able to develop application
using the Wireless M-Bus Stack libraries. For a fast and easy development, the Wireless M-Bus Stack comes with
application code example for a collector and a meter device.
Mode Meter Device Collector Device
S1 x
S2 x x
T1 x
T2 x x
C1 x
C2 x x
N1 x
N2 x x
Table 8: Available Types and Modes
Please note, that Wireless M-Bus sniffer con๏ฌgrations are only delivered as binaries.
3.3 Con๏ฌguration of the Wireless M-Bus Stack
STZEDN delivers the Wireless M-Bus protocol stack in fully con๏ฌgured libraries for different device types and modes
(refer to table 8). Depending on the target hardware, the Wireless M-Bus Stack supports several communication
interfaces, to enable customized hardware designs.
Target con๏ฌguration ๏ฌle: stzedn_target_con๏ฌg.h
The target con๏ฌguration ๏ฌle contains de๏ฌnitions about pin and port de๏ฌnitions of the communication interfaces. This
includes e.g. the SPI and UART communication, as well as GPIO input pin de๏ฌnitions. Please note, that the number
of con๏ฌguration parameters for the hardware drivers depends on the target hardware. Refer to the hardware speci๏ฌc
con๏ฌguration guide.
3.4 Memory Models
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 18
3.4.1 Internal data
Table 9 lists the internal data of the Wireless M-Bus Stack, which is effected by the choice of the memory model.
Description Meter Collector
Device status x x
RF channel x x
Frequency offset x x
Serial baud rate x x
Meter Wireless M-Bus address x x
Collector Wireless M-Bus address x
Periodical transmission interval x
Device speci๏ฌc encryption key x x
General encryption key x x
Wireless M-Bus standard speci๏ฌc data x x
Meterlist x
Table 9: Internal data of a Wireless M-Bus meter device.
3.4.2 Volatile memory model
The Wireless M-Bus Stack saves all internal vairables as well as the meterlist in volatile memory. More precisely, in
the random access memory (RAM). Thus, all data which changes at runtime is lost after a reset of the device. Refer
to table 9 for a list of parameters which are effected.
3.4.3 Non-volatile memory model
3.4.3.1 Data storage
The non-volatile memory model stores the data listed in table 9 in the non-volatile memory. The Wireless M-Bus
Stack does not specify which kind of non-volatile memory must be used. E.g. FLASH, EEPROM or FRAM.
In general, the Wireless M-Bus Stack buffers most parameters in volatile memory. It synchronizes the volatile memory
with the non-volatile memory at speci๏ฌc points in time. A complete synchronization of the data in table 9 takes place
at the following actions/events:
โ€ข During initialization of the Wireless M-Bus Stack.
โ€ข A forced synchronization, initiated by user application.
โ€ข When the Wireless M-Bus Stack goes to sleep mode, initiated by user application.
However, some data cannot be buffered in volatile memory. Thus, some API function calls cause a write access to non-
volatile memory immediately - API functions which cause changes of meterlist entries. Thus, this effects only Wireless
M-Bus collector devices. Furthermore, these functions do not initiate a complete synchronization, but apply only the
changes to the non-volatile memory which is described by the API function. Refer to table 10 for a corresponding list
of API functions.
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 19
API
stzedn_apl_meterAdd
stzedn_apl_meterRemove
stzedn_apl_meterSetRfAdapter
stzedn_apl_meterSetKey
Table 10: API functions, which case a non-volatile write access imediately.
Another direct non-volatile memory write access takes place, when a Wireless M-Bus collector device calls the event
stzedn_apl_evt_newMeter, if the return value is set to TRUE. In this case, a new meter which is currently
not in the meterlist will be added to the meterlist.
3.4.3.2 Non-volatile memory management
Figure 3 shows the basic work๏ฌ‚ow of the Wireless M-Bus Stack regarding the memory management. After the start-up
of the device and the initialization of the Wireless M-Bus Stack, the function stzedn_apl_start function must
be called with appropriate parameters. The Wireless M-Bus Stack then synchronizes with the non-volatile memory.
Synchronization at stzedn_apl_start : In this function, the Wireless M-Bus Stack ๏ฌrst checks, if the non-
volatile memory contains valid information. If the non-volatile memory contains no valid information, the Wireless
M-Bus Stack uses the parameters from the stzedn_apl_start function to initialize the device and stores the
parameters afterwards into the non-volatile memory. If the information is valid, the parameters in the start function
stzedn_apl_start were omitted and all parameters were loaded from the non-volatile memory. In this case,
the Wireless M-Bus Stack also omits the optional static meterlist and loads the one in the non-volatile memory, even
if the list is empty (only for collector). After calling this function, the Wireless M-Bus Stack is ready for operation.
Synchronization at stzedn_apl_sleep : When the Wireless M-Bus Stack is set into sleep mode, all internal
parameters from table 9 were stored into non-volatile memory. If the function returns success, the user application
is allowed to set the microcontroller into a hardware sleep mode.
Synchronization at stzedn_apl_wake : This function must be called to run the Wireless M-Bus Stack after
a sleep mode. The stack synchronizes the buffered parameters in the volatile memory with the parameters in the
non-volatile memory.
Synchronization at meterlist write/change operations: When the user changes the meter entries (add, change,
remove), the Wireless M-Bus Stack writes the changes immediately into the non-volatile memory. The reason for this
is that the meterlist entries were not buffered in the volatile memory.
Synchronization at meter installation mode: When a collector detects a new meter, it is possible to add the meter
into the meterlist of the collector. The Wireless M-Bus Stack ๏ฌres the event stzedn_apl_evt_newMeter and
the user application can decide, if the collector should add the meter into the own meterlist. In case the collector
adds the meter into the meterlist, the stack writes the meter parameters into the non-volatile memory immediately.
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 20
In all other cases, there is no non-volatile memory write access.
Figure 3: Non-volatile memory work ๏ฌ‚ow.
3.5 Encryption Modes
Refer to table 11 for the supported encryption modes of the Wireless M-Bus protocol stack. The only mandatory
encryption mode de๏ฌned in OMS v.3.0.1 is mode 5.
Mode Description
0 No encryption.
1 AES Counter Mode (AES-CTR).
5 AES Cipher Block Chaining Mode (AES-CBC) with dynamic initialization vector.
Table 11: Encryption Modes
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 21
3.6 Sleep modes
The stack provides several sleep modes, which can be used to save energy, while the stack is not busy.
โ€ข Sleep
It is assumed that the mcu will enter a lpm state in which the RAM content will be kept. The radio will be set
to power down mode.
โ€ข Deep sleep
It is assumed that the mcu will enter a lpm state in which the RAM content will not be kept. The radio will be
set to power down mode.
3.7 Wireless M-Bus Channels
The modes of Wireless M-Bus are using different channels. Table 12 lists all available channels. Depending on the
deviceโ€™s mode, only a subset of this table can be accessed. Using channels that are not supported result in an error
message at compilation of the ๏ฌrmware.
Mode Frequency
N1a, N2a (Meter Device and Data Collector) 169.406 MHz
N1b, N2b (Meter Device and Data Collector) 169.418 MHz
N1c, N2c (Meter Device and Data Collector) 169.431 MHz
N1d, N2d (Meter Device and Data Collector) 169.443 MHz
N1e, N2e (Meter Device and Data Collector) 169.456 MHz
N1f, N2f (Meter Device and Data Collector) 169.468 MHz
N2g (Meter Device and Data Collector) 169.437 MHz
T2 (Data Collector TX, Meter Device RX) 868.30 MHz
T1, T2 (Meter Device TX, Data Collector RX) 868.95 MHz
S1, S2 (Meter Device and Data Collector) 868.30 MHz
C2 (Data Collector TX, Meter Device RX) 869.525 MHz
C1, C2 (Meter Device TX, Data Collector RX) 868.95 MHz
Table 12: Available channels
Quick Start Guide
Version 1.02
3 THE STZEDN PROTOCOL STACK page 22
Figure 4: List of frequencies used by Wireless M-Bus mode S, T and C
Figure 5: List of frequencies used by Wireless M-Bus mode N
Quick Start Guide
Version 1.02
4 SETUP page 23
4 Setup
4.1 Hardware
4.1.1 Supported Radio Types
The following EZRadioPRO radio ICs are supported by the STZEDN W-MBUS Protocol Stack:
1. Si4461 Transceiver
2. Si4463 Transceiver
The transceivers are delivered on RF Pico Boards. The radio module contains the radio IC, the corresponding match-
ing network and the SMA connector matched to 50โ„ฆ.
Part Number Board Description
4461-PCE14D868 868 MHz matching, Transceiver, 14dBm output power, Direct tied
antenna connection
4463-PSQ20D169 169 MHz matching, Transceiver, 20dBm output power, Direct tied
antenna connection
Table 13: Supported Transceivers and RF Pico Boards
4.1.2 Hardware requirements
The following devices are needed to build either a complete W-MBUS capable data collector or meter device.
Description Part Number
MCU EFM32LG-STK3600 Leopard Gecko Starter Kit
RF Adapter Board MSC-RFP2EFM
RF Pico Board 4461-PCE14D868 / 4463-PSQ20D169
Antenna 868MHz / 169MHz
Table 14: Hardware requirements for a meter / collector device
4.1.3 Wireless M-Bus Hardware Platform
The W-MBUS Hardware Platform is a demo, evaluation and development platform for EZRadioPRO radio ICs. It
consists of a Leopard Gecko Starter Kit, an RF Pico Adapter Board and an interchangeable RF Pico Board.
Quick Start Guide
Version 1.02
4 SETUP page 24
Figure 6: The 32bit W-MBUS Hardware Platform
4.1.3.1 EFM32LG-STK3600 Leopard Gecko Starter Kit
Figure 7: EFM32LGSTK3600 hardware layout
Many of the EFM32โ€™s pins are routed out to "breakout pads" at the top and bottom edges of the kit. A 2.54mm pitch
pin header can be soldered in for easy access to these pins. On the right hand side of the board an angled 20 pin
expansion header is provided to allow connection of peripherals or plugin boards. The connecter contains a number
of I/O pins that can be used with most of the EFM32 Leopard Geckoโ€™s features. Additionally, the VMCU, 3V3 and 5V
power rails are also exported.
Quick Start Guide
Version 1.02
4 SETUP page 25
Figure 8: Breakout pads and expansion header
Figure 9: EXP Header Pins on Leopard Gecko Module
4.1.3.2 MSC-RFP2EFM Adapter Board
The adapter module makes it possible that the EFM32 Leopard Gecko MCU can be connected to the EZRadioPRO
radio IC easily. On the left hand side of the board an angled 20 pin expansion header is provided to allow connection
of EFM32 Leopard Gecko module. The same expansion header can be found on the right hand side. The digital
signals of the radio (SCLK, MISO, MOSI, NSEL, SCLK, VRF, GND and RF_GPIOs) can be accessed on test pins at the
top right side of the board. Four SMA connectors can be soldered on the bottom side for measurement purposes. The
RF Pico Board can be connected in the middle of the adapter board. By default, the radio is powered through the
VMCU pin. If the leopard gecko module is powered by a battery, the supply voltage must be provided to the radio
through the external power source pin. The current consumption of the radio can be measured separately from the
leopard gecko module on current measurement pin.
Quick Start Guide
Version 1.02
4 SETUP page 26
Figure 10: MSC-RFP2EFM Adapter Board connections
Figure 11: EXP header pins on MSC-RFP2EFM Adapter Board
Figure 12: RF Pico Board Pins on MSC-RFP2EFM Adapter Board
4.1.3.3 Connection between Leopard Gecko MCU and EZRadioPRO transceiver
The following table shows which MCU and radio pins are required to be connected for the operation of the stack.
Quick Start Guide
Version 1.02
4 SETUP page 27
Si446x transceiver EFM32LG990F256
RF_SDN PC3
RF_GPIO_0 PC41
RF_GPIO_1 PC51
MOSI PD0
MISO PD1
RF_NSEL PD3
SCLK PD2
Table 15: Pin compatibility
4.1.3.4 EZRadioPRO RF Pico Board
Figure 13: RF Pico Board Front Side
The RF Pico Board is a radio module that contains an EZRadioPRO radio IC, a matching network and an SMA
connector on the top side. These components apart from the antenna connector are covered by a metal shield for
noise reduction. The digital signals of the radio (SCLK, SDI, SDO, NSEL, SCL, SDA, VDD and GND) can be accessed
on test points at the edge of the board. The boards also have a factory loaded board identi๏ฌcation memory (EBID)
on the bottom side that contains data that describes the board properties. Via the uni๏ฌed RF Pico connector pair on
the bottom side of the board, any RF Pico board can be connected to the RF Pico Adapter Board.
4.1.4 Required hardware resources
The following table shows the hardware resources that are required from the MCU.
1
Note that RG0=RG1=0โ„ฆ resistors must be soldered on the adapter board so that RF_GPIO_0 and RF_GPIO_1 will be available for the MCU.
RF_GPIO_2 and RF_GPIO_3 are not used by the stack.
Quick Start Guide
Version 1.02
4 SETUP page 28
Function Resources
MCU SPEED 28MHz
SPI Bus Speed 8MHz
Used Timer TIMER_1
SPI Interface USART_1_Location_1
USART Interface USART_0_Location_2
Flash for Collector informations 0x3E800-0x40000 Collector
Flash for Meter informations 0x3E800-0x3F8FF Meter
Used RF GPIOs of radio RF_GPIO_0, RF_GPIO_1
Table 16: Hardware Requirements
The following table shows the memory consumptions of the different con๏ฌgurations for collectors and meters.
Con๏ฌgurations Read-only code
memory
Read-write code
memory
Read-only data
memory
Read-write data
memory
Collector C2 with serial 47272 288 1000 6135
Collector C2 with apl 32204 288 760 4787
Collector T2 with serial 45328 288 960 6103
Collector T2 with apl 30264 288 720 4755
Collector S2 with serial 45156 288 708 6103
Collector S2 with apl 30088 288 468 4755
Collector N2 with serial 45260 288 972 6139
Collector N2 with apl 30196 288 732 4791
Meter C2 with serial 43472 288 716 6124
Meter C2 with apl 29300 288 472 4766
Meter T2 with serial 41900 288 716 6124
Meter T2 with apl 27660 288 472 4766
Meter S2 with serial 41732 288 676 6124
Meter S2 with apl 27492 288 432 4766
Meter N2 with serial 41988 288 940 6128
Meter N2 with apl 27748 288 696 4770
Table 17: Memory consumption
4.2 Firmware
This section describes how to setup the ๏ฌrmware of the EFM32LG-STK3600 in use with the Wireless M-Bus Suite.
Please note, that if you want to set up the enclosed demo network with the quick start for Wireless M-Bus Suite in
chapter 5, you have to con๏ฌgure at least two devices: one with the collector and one with the meter ๏ฌrmware. The
EFM32LG-STK3600 ๏ฌrmware can either be provided as binary2
(โ€™*.binโ€™๏ฌle) or as source code that is compiled and
๏ฌ‚ashed using IAR compiler. Please check, if a valid serial ๏ฌrmware is available on your boards.
You can do this with Wireless M-Bus Suite with a ping test. If there is no ๏ฌrmware available, refer to chapter 4.2.1
for ๏ฌrmware installation using Simpl. Studio or refer to chapter 4.2.2 for installation using IAR IDE. .
2
Note that these binaries are SERIAL related and the location in our ๏ฌle hierarchy is at the location of ...WMBUS ToolsFirmwareSerial
binaries
Quick Start Guide
Version 1.02
4 SETUP page 29
4.2.1 Firmware Installation with Simplicity Studio
To install a ๏ฌrmware using Simplicity Studio the following steps must be performed.
1. Connect the mini USB port of the target board to your PC using a mini USB cable (J-Link interface)
2. Connect the micro USB port of the target board to your PC using a micro USB cable (serial interface).
3. Open the Simplicity Studio software (Studio software [8]).
Figure 14: Simplicity Studio
4. Select "energyAwareCommander"
Quick Start Guide
Version 1.02
4 SETUP page 30
Figure 15: Select "energyAwareCommander"
5. The energyAwareCommander application will start.
6. Select the connected J-Link-Decvice and push the "Connect" button.
Figure 16: Select the connected board
7. Select option "Flash".
Quick Start Guide
Version 1.02
4 SETUP page 31
Figure 17: Select "Flash"
8. Choose a "*.bin" ๏ฌle and push the button "Flash EFM32".
Figure 18: Flash the selected ๏ฌrmware
9. Wait until the J-Link-Device is programmed successfully.
Quick Start Guide
Version 1.02
4 SETUP page 32
Figure 19: Download
10. To program additional devices, repeat the steps as described above. Make sure to upload the appropriate
๏ฌrmware for each device.
11. Now your boards are ready to run the application.
4.2.2 Install Firmware with IAR compiler
1. Connect the mini USB port of the target board to your PC using a mini USB cable (J-Link interface).
2. Connect the micro USB port of the target board to your PC using a micro USB cable (serial interface).
3. Open the project ๏ฌle (*.eww) with the IAR ARM compiler.
4. There are different con๏ฌgurations available in the workspace window: One for the meter device and one for
the collector device with the different supported modes. Refer to ๏ฌgure 20 for the selection.
Figure 20: Workbench con๏ฌguration
5. Select a workspace con๏ฌguration.
6. Before debugging, please check, if the โ€™Debuggerโ€™ is selected in the project options. Right-click on the project
and select โ€™Optionsโ€™.
Quick Start Guide
Version 1.02
4 SETUP page 33
Figure 21: Open project options
7. Switch to the tab "Debugger" and verify that the "J-Link/.." option is selected.
Figure 22: Driver selection
8. Now you can download and debug the source code.
9. To program additional devices, repeat the steps as described above. Make sure to upload the appropriate
๏ฌrmware for each device.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 34
5 Wireless M-Bus Suite
5.1 System Requirements
The Wireless M-Bus Suite is available for 32-Bit and 64-Bit Win XP/WinVista/Win 7 operating systems. The tool
detects the version of the installed java runtime environment and noti๏ฌes the user if a newer version is available.
It requires the user to download at the of๏ฌcial java homepage (www.java.com). Recommended minimum system
requirements are:
โ€ข 512 MB RAM for Win XP and 1 GB RAM for Win Vista / Win 7
โ€ข 1 GHz CPU
โ€ข 100 MB free hard disk space
โ€ข Serial interface or USB-to-Serial connector
Before installing Wireless M-Bus Suite, please check if your operating system is 32-Bit or 64-Bit:
โ€ข WindowsX P : Open system information: please select Start->Run. Input โ€™winmsd.exeโ€™ and press โ€™enterโ€™. Select
โ€™System Summaryโ€™. Check the โ€™System Typeโ€™ parameter: if the value is X86 โˆ’ basedPC, it is a 32-Bit Windows
XP, if the value is X64 โˆ’ basedPC, it is a 64-Bit Windows XP.
โ€ข WindowsVista/7 : Please go to Start->System control->System. The operating system settings can be found
under the parameter โ€™System Typeโ€™.
Please make sure to run the correct installer for your system type.
5.2 COM Port Settings
This chapter describes how to get information about the com pot settings on Windows operating systems.
Go to โ€™Start->System control->System->Hardware->Device managerโ€™ and check the โ€™COM and LPTโ€™ connections.
Refer to ๏ฌgure 23 and 24 for an example COM port con๏ฌguration in a device manager of a PC. In the following, the
numbers in angle brackets were used to refer to the red numbers in ๏ฌgure 23 and 24. Please expand the node <1>
โ€™Ports(COM & LTP)โ€™. Based on physical connection, there are two types of COM ports to distinguish:
โ€ข Physical COM port of the PC <2> (serial interface, usually COM1)
โ€ข Virtual COM ports
In case of a USB connection, the PC will assign a virtual COM port to the USB interface as shown by <3> in
๏ฌgure 24, COM10. Please note, that the COM port number assignement can vary. If you are not sure which
COM port was assigned to your USB connection (and your device), open the โ€™Device Managerโ€™, unplug the USB
cable. Please wait three seconds and plug in the USB cable again. The โ€™Device Managerโ€™ and the available COM
ports of the PC updates automatically and new devices will be added to the COM port list.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 35
Please note, that connections declared with โ€™LPTโ€™ are no COM ports and cannot be used for a serial communication.
Figure 23: Standard COM port
Figure 24: Virtual COM port
This chapter demonstrates how to start a basic Wireless M-Bus network with the Wireless M-Bus Suite. Wireless M-
Bus Suite comes with a demonstration network project. The project settings are stored in con๏ฌguration ๏ฌles (*.xml).
This quick start guide uses the demonstration project to show the basic concepts of the Wireless M-Bus Suite. The
provided demo con๏ฌguration ๏ฌle includes one collector and one meter device, which communicate via Wireless M-
Bus. Please note that you need to have at least two compatible evaluation boards with a valid application ๏ฌrmware.
You will need one board with the collector and one board with the meter ๏ฌrmware to use the demo application.
The ๏ฌrst step is to connect the boards to your pc and to power them on.
The following chapters of the quick start guide can be read independently. Chapters 5.3 to 5.5 provide information,
how to load the demonstration project as well as basic information, which are used for collector and meter devices.
Chapters 5.7 and 5.8 specify how to perform transmission tests. However, it is recommend to read all chapters in
order of appearance.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 36
5.3 Loading the demo project
The demo project is integrated in the Wireless M-Bus Suite and can be opened after starting the Wireless M-Bus Suite.
Please perform the following steps:
1. Start the Wireless M-Bus Suite.
2. A โ€™Welcomeโ€™ page will be displayed. Press โ€™Watch the tutorialโ€™ to open a video tutorial for the Wireless M-Bus
Suite.
3. Press โ€™Open the demo Projectโ€™.
4. This loads the โ€™wmbs_demo.xmlโ€™ ๏ฌle from the Wireless M-Bus Suite installation folder.
Figure 25: Start -up dialog
5. Now you can see the โ€™Data Collectorโ€™ and the โ€™Smart Meterโ€™ in the con๏ฌguration suite tree. In ๏ฌgure 26, the
correspondig items are framed in red.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 37
Figure 26: Collector and Meter device
Now the โ€™wmbs_demo.xmlโ€™ is loaded. In the con๏ฌguration suite tree, the โ€™Smart Meterโ€™ is located in the subtree of the
โ€™Data Collectorโ€™. This means, that the โ€™Smart Meterโ€™ is assigned to the Wireless M-Bus network of the โ€™Data Collectorโ€™.
5.4 Collector short description
The collector parameters can be displayed by double clicking on the โ€™Data Collectorโ€™ in the navigation tree. By default,
it has a device address and an encryption key. There are several options in the โ€™Collector con๏ฌgurationโ€™ window, which
are grouped in different sections. These sections (e.g. โ€™Collector operationsโ€™ or โ€™Collector detailsโ€™) can be expanded
individually (refer to ๏ฌgure 27 - red framed window in the โ€™Collectors operationsโ€™ section).
The red framed window in the section โ€™Collectors meter listโ€™ in ๏ฌgure 27 shows the meter devices, which are associated
with this collector. In this case it is the โ€™Smart Meterโ€™ device.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 38
Figure 27: Collector editor
If the โ€™Smart Meterโ€™ device is selected in the red framed window, the corresponding parameters such as device address
etc. are displayed. It has a unique device address, an encryption key and the address of the collector device. Note
that the collector device address must be consistent with the parameters of the โ€™Data Collectorโ€™ device. Otherwise no
communication will be possible. The status of the con๏ฌguration of the โ€™Smart Meterโ€™ meter and the โ€™Data Collectorโ€™
will be displayed with the icon of the โ€™Smart Meterโ€™ in the navigation tree. A well de๏ฌned connection is displayed
with the icon in ๏ฌgure 28, otherwise ๏ฌgure 29 noti๏ฌes the user that the meter is not connected. Figure 30 appears,
if a meter has no collector address registered or the collector has no address con๏ฌgured. If two meters within the
Wireless M-Bus network have the same device addresses, ๏ฌgure 31 is shown.
Figure 28: Meter connected
Figure 29: Meter disconnected
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 39
Figure 30: Meter without collector address
Figure 31: Meter addresses duplicate
To start the Wireless M-Bus network with the default settings, please press โ€™Start wireless M-Bus demoโ€™ and select the
COM port related to the โ€™Data Collectorโ€™ device.
Figure 32: COM Port selection
Now press โ€™Nextโ€™ and select the meters which shall be used together with the collector board and press โ€™Finishโ€™.
Figure 33: Select โ€™Smart Meterโ€™ meter
After this, settings are stored in the data collectorโ€™s ๏ฌ‚ash memory. If the device was programmed correctly, the
following dialog is shown.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 40
Figure 34: โ€™Data Collectorโ€™ programmed
5.5 Meter short description
You can view the meter parameters by double clicking on the โ€™Smart Meterโ€™ in the navigation tree. The โ€™Smart Meterโ€™
editor is shown in the following ๏ฌgure. There are several options in the โ€™Meter con๏ฌgurationโ€™ window, which are
grouped in different sections. These sections (e.g. โ€™Meter operationsโ€™ or โ€™Meter detailsโ€™) can be expanded individually.
Figure 35: โ€™Smart Meterโ€™ Window
Table 18 lists the parameters of the โ€™Smart Meterโ€™:
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 41
Parameter Purpose
Device address Address of the โ€™Smart Meterโ€™.
Collector address Address of the โ€™Data Collectorโ€™, to which
the โ€™Smart Meterโ€™ sends data.
Encryption key The key encrypts the Wireless M-Bus
wireless telegrams.
Binding information This checkbox sets the โ€™Smart Meterโ€™ to
the connected state.
Time interval The time interval [ms] of periodical data.
Table 18: โ€™Smart Meterโ€™ Parameters
The โ€™Smart Meterโ€™ meter will send messages in the con๏ฌgured time interval. The โ€™Set binding informationโ€™ checkbox
is used to set manual connections. Please refer to the manual of the Wireless M-Bus Suite for detailed information
regarding this attribute.
To start the network using the default settings, please press โ€™Start wireless M-Bus demoโ€™, select the COM port related
to the โ€™Smart Meterโ€™ device. (refer to ๏ฌgure 32). Then press โ€™Finishโ€™ and the device will be programmed. If the device
was programmed correctly, the following dialog is shown.
Figure 36: โ€™Smart Meterโ€™ programmed
In the demo project, the โ€™Smart Meterโ€™ sends a default packet to the collector every 10 seconds.
5.6 Using the Wireless M-Bus Suite
This chapter describes speci๏ฌc device con๏ฌgurations and special functions of the Wireless M-Bus Suite.
5.6.1 Mode selection
The โ€™Data Collectorโ€™ and the โ€™Smart Meterโ€™ window includes a โ€™Modeโ€™ selection box. The Wireless M-Bus mode can
be selected here. The selection of the mode is necessary only in case of mode C or mode N. The following picture
shows the mode selection boxes.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 42
Figure 37: Mode selection boxes
The selection box can be ignored for modes S and T, as well as for a mode C meter device. If a C collector shall be
used with a T meter, please set the meter to mode T ( as shown in ๏ฌgure 38). The reason is that the collector needs
the information of the supported channels of the meter. Otherwise the collector will only be able to receive packets
of the meter (RX), but is not able to send packets to the meter (TX).
Figure 38: Collector C and Meter T
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 43
For using the device in mode N the selection box must be used to select and con๏ฌgure the channel. The ๏ฌgure 39
shows an example for the mode Nb.
Figure 39: Mode Nb example
5.6.2 Console
The Console View displays the serrial communication ๏ฌ‚ow.
Figure 40: Console View
The commands available in the Console View are listed below.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 44
Command Name Description
Clear Console Clears the currently active console.
Display Selected Console Opens a listing of currently opened con-
soles and allows to select the one to dis-
play.
Open Console Opens a new console of the selected type.
Pin Console Pins the current console to remain on top
of all other consoles.
Scroll Lock Changes if scroll lock should be enabled
or not in the current console.
Text on/off Enables/Disables the serial text output.
Table 19: Console View Commands
The โ€™Text on/offโ€™ button enables or disables the text output for the serial commands (see ๏ฌgure 41).
Figure 41: Console with serial text output enabled
5.7 Perform a ping test
This chapter describes how to send a ping message to a device using the Wireless M-Bus Suite. A ping is a simple
message over the UART interface which is used to verify if a ๏ฌrmware is available on the connected board. If your
board responds to the ping request, a ๏ฌrmware is currently being executed. To send a ping message to your board,
perform the following steps:
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 45
1. Make sure that your device is connected to your PC properly.
2. Load the demo project as described in chapter 5.3.
3. Double click on the โ€™Data Collectorโ€™ device in the device tree. Press on the red framed button โ€™Write con๏ฌg to
deviceโ€™ or โ€™Start wireless M-Bus demoโ€™ (refer ๏ฌgure 42).
Figure 42: Write con๏ฌg to device
4. The wizard shown in ๏ฌgure 43 pops up. Con๏ฌgure the COM port settings to the correct COM port. Then press
โ€™Start ping testโ€™.
Figure 43: Start ping test
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 46
The Wireless M-Bus Suite now tries to send a ping message to the device. If the connection settings are con๏ฌgured
correctly and the ping test fails, the device does not execute a ๏ฌrmware and dialog 44 will pop up. In this case you
have to load a ๏ฌrmware on your device, before you can perform the next steps in chapters 5.4 to 5.8.
Figure 44: Ping test failed
If the ping test is successful, the console window will show the communication of the ping request and the response
of the board. Refer to ๏ฌgure 45. If the ping test is successful, you can stop the ping test with the โ€™Stop ping testโ€™
button.
Figure 45: Ping test ok
5.8 Using the transmission tests
Perform the following steps for the โ€™Data Collectorโ€™ collector:
1. Open Wireless M-Bus Suite
2. Load the demo project as described in chapter 5.3.
3. Open the โ€™Data Collectorโ€™ device by double clicking on the icon in the navigation tree.
4. Press โ€™Start wireless M-Bus demoโ€™ and select the COM port of the collector device.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 47
Figure 46: โ€™Start wireless M-Bus demoโ€™ button โ€™Data Collectorโ€™
5. Press โ€™Nextโ€™ and set the checkbox for the โ€™Smart Meterโ€™ meter. (refer to ๏ฌgure 33)
6. Open the โ€™Smart Meterโ€™ device by double clicking on the icon in the navigation tree.
7. Press โ€™Start wireless M-Bus demoโ€™ and select the COM port of the meter device.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 48
Figure 47: โ€™Start wireless M-Bus demoโ€™ button โ€™Smart Meterโ€™
8. Press โ€™Finishโ€™.
The meter device will now send every time interval a message to the collector. Make sure that the โ€™Connection statusโ€™
is correct. The โ€™Data Collectorโ€™device will receive the data which is sent by the โ€™Smart Meterโ€™ meter. The RSSI value
is displayed in a diagram, shown in ๏ฌgure 48.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 49
Figure 48: โ€™Data Collectorโ€™ Window
You can also send a string from the โ€™Smart Meterโ€™ meter to the โ€™Data Collectorโ€™ collector. Input a message in the text
๏ฌeld and press โ€™Send dataโ€™. The โ€™Data Collectorโ€™will receive and display this message as shown in ๏ฌgure 49.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 50
Figure 49: Send data test
Another test which you can perform is the โ€™RF-Testโ€™. Con๏ฌgure the transmission delay and press โ€™Run RF-Testโ€™ on the
โ€™Smart Meterโ€™. The โ€™Smart Meterโ€™ will send a standard message to the โ€™Data Collectorโ€™ periodically. You can now use
the Wireless M-Bus Suite to view the โ€™Smart Meterโ€™ which is sending data, and the โ€™Data Collectorโ€™, which is receiving
data. This demonstration Wireless M-Bus network represents a star-network in an area with different device roles.
Generally, the collector device is not intended to send custom data to a meter device.
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 51
5.9 Wireless M-Bus Protocol Monitor Quick Start Guide
The wireless M-Bus protocol monitor is a application to monitor wireless networks. It provides a full-featured web
based capture monitor system. This document covers instructions for the use of wireless M-Bus protocol monitor.
Please make sure to read the instructions carefully. If open questions remain after reading this manual, please contact
STZEDN for support.
Requirements:
(a) The Wireless M-Bus device which contains the protocol monitor ๏ฌrmware.
(b) A valid connection of the Wireless M-Bus device to the PC.
(c) Wireless M-Bus Suite.
Perform the following steps to start the wireless M-Bus protocol monitor:
(1) Open Wireless M-Bus Suite.
(2) Select โ€™Connect to protocol monitorโ€™ or โ€™Protocol Monitorโ€™ (refere to ๏ฌgure 50).
Figure 50: Open the โ€™Wireless M-Bus Protocol Monitorโ€™ wizard
(3) Choose the serial connection and press โ€™Nextโ€™. (See ๏ฌgure 51.)
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 52
Figure 51: Select the serial connection
(4) Select the protocol monitor device and press โ€™Nextโ€™ as shown in ๏ฌgure 52.
Figure 52: Select the protocol monitor device
(5) Select the mode and press โ€™Finishโ€™ as shown in ๏ฌgure 53.
Figure 53: Select the protocol monitor device
Quick Start Guide
Version 1.02
5 WIRELESS M-BUS SUITE page 53
(6) Now the wireless M-Bus protocol monitor window will be opend.
(7) To start capturing packets click on the green arrow at the top of the screen as shown in ๏ฌgure 54. Now all
packets are captured from the protocol monitor device. If there are already some packets in the device buffer
they are read, too.
Figure 54: Wireless M-Bus Protocol Monitor
For more informations read chapter 6.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 54
6 Wireless M-Bus Protocol Monitor
6.1 Introduction
This document covers instructions for the use of wireless M-Bus protocol monitor. The ๏ฌrst chapter contains the
speci๏ฌcations of the wireless M-Bus protocol monitor. A quick start guide follows, that describes in short terms how
to get the protocol monitor into operation for the ๏ฌrst time. In the third part, the web interface, being the main user
interface, is described. Especially focussing on the different views of captured data.
6.2 Wireless M-BUS protocol
A Wireless M-Bus packet consists of several blocks. The ๏ฌrst block contains 12 bytes, the following blocks may contain
up to 16 bytes. For each block, a 16 bit wide checksum of the current block is transmitted (2 bytes).
Name Size (Byte) Description
Length (L) 1 Number of packet bytes excluding
the length ๏ฌeld and all CRCs.
Type (C) 1 Packet type.
Manufacturer Id (M) 2 ID of the manufacturer, according
to DLMS.
Type (A) 6 Address of the meter device.
Checksum (CRC) 2 Checksum of the current block.
Application Type (CI) 1 Type ๏ฌeld of the application layer.
(Application Layer) x Data of the application layer
Table 20: List of Wireles M-Bus ๏ฌelds.
Figure 55: Example of a Wireless M-Bus packet.
This document assumes that the reader is familiar with the Wireless M-Bus speci๏ฌcation, according to EN 13757 [9]
and its application layer extensions of Open Metering System (OMS) [10] and the Dutch Smart Meter Requirements
(DSMR). Otherwise, please contact STZEDN [11] for further documentation or training.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 55
6.3 Running the protocol monitor
Figure 56: Starting and stopping the wireless M-Bus protocol monitor
To start capturing packets click on the start button of the button bar at the top of the screen. Now all packets from
the protocol monitor device are captured. If there are already some packets in the protocol monitor buffer they are
read, too.
To stop snif๏ฌng click on the stop button. This only stops receiving the packets of the browser application, the pro-
tocol monitor device continues to capture all packets. This allows to run several instances of the protocol monitor
application on several hosts.
To start snif๏ฌng again click on the start button.
To clear the screen click on the clear button. This action removes all cached packets of the browser application.
6.4 Packet View
Figure 57: Packet View.
In the packet view all received packets are shown from top to bottom as they are received over the air. New packets
are appended at the bottom of the list, while the list scrolls up automatically over the time.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 56
One line represents one packet.
Different blocks delimit the various ๏ฌelds of the protocol such as header and data sections.
The ๏ฌrst four ๏ฌelds, however, contain data created by the protocol monitor:
โ€ข Timestamp: This value contains the time the telegram was received by the protocol monitor device. The
timestamp is calculated relatively to the current time of the web browser. A relative time stamp is being
received by the protocol monitor device.
โ€ข RSSI and LQI: These values describe the link quality of the received telegram. Read chapter 6.8 to get further
information.
Protocol sections not active for the selected packet are hidden.
Each ๏ฌeld of the packet has two rows:
โ€ข The name of the protocol section.
โ€ข The data of the protocol section in hexadecimal notation.
6.5 CSV View
Figure 58: CSV View.
The delimiter character, which separates the ๏ฌelds is set by default to a semicolon โ€™;โ€™. However, you can enter a
different character the input text ๏ฌeld "Delimiter". To change this ๏ฌeld enter your desired delimiter and press set.
The delimiters are changed immediately.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 57
6.6 Statistics View
Figure 59: Statistic View.
The statistics view is used to group packets. Packets with the same ๏ฌeld values can be set up as statistic to get the
overall count of the number of packets.
To create a group select the ๏ฌeld of the drop down list in the header row and click on "Add group". Now all packets
are grouped by this ๏ฌeld. To add further groups repeat this step.
To remove a grouping ๏ฌeld, click on the red x behind the ๏ฌeld value of "Grouped by" line.
The grouped packets are shown as tree view. If several groups are chosen, click on the [+] in front of the group name
to display the subgroups of the current group. For faster opening or closing all groups click on the button "Expand
all" or "Collapse all".
The statistics view works independently of the other views. If all packets of the views cleared by pressing the clear
button, the packets in the statistic are kept. Click on the button "Clear statistic" to clear the packets from the statistic
view.
6.7 Timeline View
Figure 60: Timeline View.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 58
Additionally to the main view, a second section provides additional information about the radio activity. In the
timeline view, all received packets are displayed by ports and addresses.
In the ๏ฌrst lines the activities on the ports are shown. The ports may represent different radio settings for the internal
modules. Each coloured box marks an activity on the port.
The next lines show the received packets categorised by their address. Selecting a packet in the timeline automatically
selects it in the main window as well and vice versa.
6.8 Details View
Figure 61: Detail View.
The details view expands the protocol sections with further details as listed in the table or packet views. Additional
protocol speci๏ฌc information are listed here for the currently selected packet.
To display the details of a speci๏ฌc packet in the detail view, select any packet in either the packet view (chapter 6.4)
or the time line view (chapter 6.7). The same packet will be selected across all views and its extended information
in the detail view can be inspected.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 59
Moving the mouse over a speci๏ฌc packet highlights the packet in the different views without selection. For selection
and packet detail investigation, left-clicking is necessary.
6.9 Filter View
The wireless M-Bus protocol monitor allows to de๏ฌne ๏ฌlter rules to concentrate on packets of interest. E.g., it is
possible to hide all packets of a special device.
For de๏ฌning the ๏ฌlter rules open the tab "Filter".
By default, one dummy ๏ฌlter is displayed. For each ๏ฌlter, the following options can be set:
โ€ข The ๏ฌeld, to which the rule applies.
โ€ข The logic operation the value is compared to (==, !=, >, <, >=, <=).
โ€ข The value, which has to be used for comparison.
Figure 62: De๏ฌning a ๏ฌlter.
To set a ๏ฌlter press the button "Enable". The icon at the top of the screen is then switched to green.
The rules are applied to all views and all received packets. If new packets are detected, they are stored to the local
packet memory, but they will be only displayed, if they meet the ๏ฌlter rules. Consequently if the ๏ฌlter is disabled,
older packets, which were ๏ฌltered out, appear then.
If several rules shall be de๏ฌned, press "+" at the top of the ๏ฌlter tab. A further box to speci๏ฌy rules is opened. To
combine multiple rules, select the desired operation next to the set-button:
โ€ข AND: To display a packet, all rules have to be true.
โ€ข OR: At least one rule has to be true to display the packet.
Quick Start Guide
Version 1.02
6 WIRELESS M-BUS PROTOCOL MONITOR page 60
Figure 63: De๏ฌning several rules.
To remove a rule, select it by left-clicking and press the remove button "-".
After a rule is changed, the button "Enable" has to be pressed to update the views.
For disabling all ๏ฌlters, click "Disable". The icon at the top of the screen is then switched to red.
6.10 No warranty
The wireless M-Bus protocol monitor is provided โ€œas isโ€ and use of it is at userโ€™s risk. STZEDN expressly disclaims all
warranties, representations of conditions of any kind, express or implied or statutory, including but not limited to,
any warranty of merchantable quality or ๏ฌtness for a particular purpose and any warranty that the protocol monitor
is delivered free of any third party claims by way of infringement or otherwise. STZEDN does not warrant nor make
any condition or representations that the functions contained in the protocol monitor will meet the requirements
of the customer, that the operation of the protocol monitor will be uninterrupted nor error free that defects in the
protocol monitor will be corrected. Further, STZEDN does not warrant or make any conditions or representations
regarding the use or the results of the use of the protocol monitor in terms of its correctness, accuracy, reliability or
otherwise. No oral or written information or advice given by STZEDN or others shall create a warranty, condition or
representation or in any way extend the scope of the โ€œas is" provision of the protocol monitor.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 61
7 Demonstration Application
7.1 Introduction
The following chapters specify the nomenclature and the usage of the different Wireless M-Bus Stack resources.
Chapter 7.3 is a description of the demonstration application in general. Furthermore, chapters 7.4 to 7.6 show how
the demonstration application can be downloaded to the EFM Starter Kit to run the application. Please note, that in
this chaper โ€™deviceโ€™ and โ€™boardโ€™ are used as synonyms for the EFM Starter Kit.
The Wireless M-Bus Stack from STZEDN is delivered in different assamblies:
โ€ข Pre-compiled binary ๏ฌles.
โ€ข Pre-compiled library sources which can be used with the IAR Workbench.
โ€ข Source code IAR Workbench project.
7.2 The Wireless M-Bus Stack Nomenclature
This chapter describes the nomenclature of the Wireless M-Bus Stack resources from STZEDN.
7.2.1 Pre-compiled Firmware Files
7.2.1.1 Wireless M-Bus Stack Firmware Files
In general, the Wireless M-Bus Stack ๏ฌrmwares without a serial interface and without Wireless M-Bus Suite are
made up of
โ€ข the pre๏ฌx โ€™demoโ€™,
โ€ข the name of the development board,
โ€ข the corresponding transceiver,
โ€ข the device type,
โ€ข and the Wireless M-Bus mode.
Feel free to change the names of the ๏ฌrmware ๏ฌles. These ๏ฌrmware ๏ฌles are generated by the project in chapter
7.2.3.2.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 62
Name Transceiver Type Mode File Name
EFM32LG990 SI446X Collector c2 demo_efm32lg990_si446x_collector_c2.bin
EFM32LG990 SI446X Collector n2 demo_efm32lg990_si446x_collector_n2.bin
EFM32LG990 SI446X Collector s2 demo_efm32lg990_si446x_collector_s2.bin
EFM32LG990 SI446X Collector t2 demo_efm32lg990_si446x_collector_t2.bin
EFM32LG990 SI446X Meter c2 demo_efm32lg990_si446x_meter_c2.bin
EFM32LG990 SI446X Meter n2 demo_efm32lg990_si446x_meter_n2.bin
EFM32LG990 SI446X Meter s2 demo_efm32lg990_si446x_meter_s2.bin
EFM32LG990 SI446X Meter t2 demo_efm32lg990_si446x_meter_t2.bin
Table 21: Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles without a serial interface and without Wireless
M-Bus Suite.
In general, the Wireless M-Bus Stack ๏ฌrmwares with a serial interface and with Wireless M-Bus Suite are made up
of
โ€ข the pre๏ฌx โ€™serialโ€™,
โ€ข the name of the development board,
โ€ข the corresponding transceiver,
โ€ข the device type,
โ€ข and the Wireless M-Bus mode.
Feel free to change the names of the ๏ฌrmware ๏ฌles. These ๏ฌrmware ๏ฌles are generated by the project in chapter
7.2.3.4. Please note, that all serial Wireless M-Bus Stack ๏ฌrmwares use 115200 baud.
Name Transceiver Type Mode File Name
EFM32LG990 SI446X Collector c2 serial_efm32lg990_si446x_collector_c2.bin
EFM32LG990 SI446X Collector n2 serial_efm32lg990_si446x_collector_n2.bin
EFM32LG990 SI446X Collector s2 serial_efm32lg990_si446x_collector_s2.bin
EFM32LG990 SI446X Collector t2 serial_efm32lg990_si446x_collector_t2.bin
EFM32LG990 SI446X Meter c2 serial_efm32lg990_si446x_meter_c2.bin
EFM32LG990 SI446X Meter n2 serial_efm32lg990_si446x_meter_n2.bin
EFM32LG990 SI446X Meter s2 serial_efm32lg990_si446x_meter_s2.bin
EFM32LG990 SI446X Meter t2 serial_efm32lg990_si446x_meter_t2.bin
Table 22: Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles with a serial interface and with Wireless M-Bus
Suite.
7.2.2 Wireless M-Bus Stack Libraries
In general, the library ๏ฌle names are made up of
โ€ข the name of the development board,
โ€ข the corresponding transceiver,
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 63
โ€ข the device type,
โ€ข and the Wireless M-Bus mode.
Name Transceiver Type Mode Type
EFM32LG990 SI446X Collector c2 EFM32LG990_SI446X_Collector_C2.a
EFM32LG990 SI446X Collector n2 EFM32LG990_SI446X_Collector_N2.a
EFM32LG990 SI446X Collector s2 EFM32LG990_SI446X_Collector_S2.a
EFM32LG990 SI446X Collector t2 EFM32LG990_SI446X_Collector_T2.a
EFM32LG990 SI446X Meter c2 EFM32LG990_SI446X_Meter_C2.a
EFM32LG990 SI446X Meter n2 EFM32LG990_SI446X_Meter_N2.a
EFM32LG990 SI446X Meter s2 EFM32LG990_SI446X_Meter_S2.a
EFM32LG990 SI446X Meter t2 EFM32LG990_SI446X_Meter_T2.a
Table 23: Nomenclature of the Wireless M-Bus Stack library ๏ฌles
7.2.3 IAR Projects and Con๏ฌgurations
It is possible to open all IAR projects with the project ๏ฌle:
Project Name: Complete_efm32lg990_si446x.eww
7.2.3.1 Library Build IAR Workbench Project
The library build project produces the Wireless M-Bus Stack libraries for the different Wireless M-Bus network devices
and the different Wireless M-Bus modes. The project contains all con๏ฌgurations with the type and mode correspond-
ing settings listed in table 24.
Project Name: Lib_Build_efm32lg990_si446x.ewp
Type Mode Con๏ฌguration Name
Collector c2 Lib_Build_EFM32LG990_SI446X_Collector_C2
Collector n2 Lib_Build_EFM32LG990_SI446X_Collector_N2
Collector s2 Lib_Build_EFM32LG990_SI446X_Collector_S2
Collector t2 Lib_Build_EFM32LG990_SI446X_Collector_T2
Meter c2 Lib_Build_EFM32LG990_SI446X_Meter_C2
Meter n2 Lib_Build_EFM32LG990_SI446X_Meter_N2
Meter s2 Lib_Build_EFM32LG990_SI446X_Meter_S2
Meter t2 Lib_Build_EFM32LG990_SI446X_Meter_T2
Table 24: Con๏ฌguration Names of the Library Build porject
7.2.3.2 Library Usage IAR Workbench Project
The library usage project includes the Wireless M-Bus Stack libraries. The customer can use this project to program
own applications based on the Wireless M-Bus Stack libraries. A sample main ๏ฌle for the meter and the collector
device is included in the project to quickly setup a wireless communication. The project contains all con๏ฌgurations
with the type and mode corresponding settings listed in table 25.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 64
Project Name: Lib_Use_efm32lg990_si446x.ewp
Collector Main File: app_aplmain_collector.c
Meter Main File: app_aplmain_meter.c
Con๏ฌguration File: app_aplstzedn_wmbus_global.h
Type Mode Con๏ฌguration Name
Collector c2 Lib_Use_EFM32LG990_SI446X_Collector_C2
Collector n2 Lib_Use_EFM32LG990_SI446X_Collector_N2
Collector s2 Lib_Use_EFM32LG990_SI446X_Collector_S2
Collector t2 Lib_Use_EFM32LG990_SI446X_Collector_T2
Meter c2 Lib_Use_EFM32LG990_SI446X_Meter_C2
Meter n2 Lib_Use_EFM32LG990_SI446X_Meter_N2
Meter s2 Lib_Use_EFM32LG990_SI446X_Meter_S2
Meter t2 Lib_Use_EFM32LG990_SI446X_Meter_T2
Table 25: Con๏ฌguration Names of the Library Usage porject
7.2.3.3 Source Code IAR Workbench Project with serial interface disabled
The source code project contains all source ๏ฌles from the Wireless M-Bus Stack. A sample main ๏ฌle for the meter
and the collector device is included in the project to quickly setup a wireless communication. The project contains
all con๏ฌgurations with the type and mode corresponding settings listed in table 26.
Project Name: Debug_Demo_efm32lg990_si446x.ewp
Collector Main File: app_aplmain_collector.c
Meter Main File: app_aplmain_meter.c
Con๏ฌguration File: app_aplstzedn_wmbus_global.h
Type Mode Con๏ฌguration Name
Collector c2 Debug_Demo_EFM32LG990_SI446X_Collector_C2
Collector n2 Debug_Demo_EFM32LG990_SI446X_Collector_N2
Collector s2 Debug_Demo_EFM32LG990_SI446X_Collector_S2
Collector t2 Debug_Demo_EFM32LG990_SI446X_Collector_T2
Meter c2 Debug_Demo_EFM32LG990_SI446X_Meter_C2
Meter n2 Debug_Demo_EFM32LG990_SI446X_Meter_N2
Meter s2 Debug_Demo_EFM32LG990_SI446X_Meter_S2
Meter t2 Debug_Demo_EFM32LG990_SI446X_Meter_T2
Table 26: Con๏ฌguration Names of the Debug porject with serial interface disabled
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 65
7.2.3.4 Source Code IAR Workbench Project with serial interface enabled
The source code project contains all source ๏ฌles from the Wireless M-Bus Stack. A sample main ๏ฌle for the meter
and the collector device is included in the project to quickly setup a wireless communication. The project contains
all con๏ฌgurations with the type and mode corresponding settings listed in table 27. Please note, that there is one
shared main ๏ฌle for the collector and meter.
Project Name: Debug_Serial_efm32lg990_si446x.ewp
Collector Main File: app_serialstzedn_app_serial.c
Meter Main File: app_serialstzedn_app_serial.c
Con๏ฌguration File: app_serialstzedn_wmbus_global.h
Type Mode Con๏ฌguration Name
Collector c2 Debug_Serial_EFM32LG990_SI446X_Collector_C2
Collector n2 Debug_Serial_EFM32LG990_SI446X_Collector_N2
Collector s2 Debug_Serial_EFM32LG990_SI446X_Collector_S2
Collector t2 Debug_Serial_EFM32LG990_SI446X_Collector_T2
Meter c2 Debug_Serial_EFM32LG990_SI446X_Meter_C2
Meter n2 Debug_Serial_EFM32LG990_SI446X_Meter_N2
Meter s2 Debug_Serial_EFM32LG990_SI446X_Meter_S2
Meter t2 Debug_Serial_EFM32LG990_SI446X_Meter_T2
Table 27: Con๏ฌguration Names of the Debug porject with serial interface enabled
Please note, that all serial Wireless M-Bus Stack con๏ฌgurations use 115200 baud.
7.3 The Demonstration Application
7.3.1 Introduction
The demonstration application builds up a wireless network with two network devices - a collector and a meter
device. Thus, the application needs two EFM Starter Kits. Figure 64 shows the basic setup.
The ๏ฌrst step is to download the collector and the meter ๏ฌrmware to the EFM Starter Kits. Refer to chapters 7.4 to
7.6 to get detailed information about how to download a ๏ฌrmware to the boards.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 66
Figure 64: Demonstration Application
There are two different setups to run the demonstration application. One setup runs without the Wireless M-Bus
Suite (refer to chapter 7.3.2) and one setup with it (refer to chapter 7.3.3) 1
.
The Wireless M-Bus Stack ๏ฌrmware differs for the two setups. Please make sure to se-
lect the correct ๏ฌrmware ๏ฌles. Refer to chapter 7.2 for details about the nomenclature
of the ๏ฌrmware ๏ฌles or IAR projects.
7.3.2 Demonstration Application without Wireless M-Bus Suite
In this setup, the demonstration application works without the optional serial interface and thus, without Wireless
M-Bus Suite. The following Wireless M-Bus Stack ๏ฌrmware ๏ฌles or projects are applicable:
โ€ข The pre-compiled Wireless M-Bus Stack ๏ฌrmware ๏ฌles in chapter 7.2.1, table 21. Refer to chapter 4.2.1 for
details about downloading a binary ๏ฌrmware ๏ฌle to a EFM Starter Kit.
โ€ข The IAR Workbench project in chapter 7.2.3.2 or the project in chapter 7.2.3.3. Refer to chapter 4.2.2 for
details about downloading an IAR Workbench Project to a EFM Starter Kit.
If the demonstration application is installed on both boards, the meter device starts sending sample data packets to
the collector device.
1
It is recommended to use the USB interface as power supply. If the EFM Starter Kits are powered with batteries, the display may not work
correctly.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 67
7.3.3 Demonstration Application with Wireless M-Bus Suite
The Wireless M-Bus Suite (refer to chapter 5) can be used to control the demonstration application on both boards
via the serial interface. In the Wireless M-Bus demonstration application without Wireless M-Bus Suite, the meter
device sends a telegram to the collector device in a de๏ฌned time interval. Please note, that the serial demonstration
application is limited in the number of supported meter devices. There are many advantages and extensions for the
demonstration application, which allow fast and easy wireless communications, if Wireless M-Bus Suite is used:
โ€ข Perform an RF-Test.
โ€ข Set serveral user telegrams and send them from the meter to the collector device.
โ€ข Perform a bidirectional communication.
โ€ข Communication with and without encryption.
โ€ข Access to internal parameters of the devices. E.g. in case of a collector device the โ€™Received Signal Strength
Indicationโ€™ value is displayed for a speci๏ฌc meter.
โ€ข Access to the serial console. Thus, all commands from the serial speci๏ฌcation from STZEDN can be send to the
devices.
โ€ข Create fast and easily own Wireless M-Bus con๏ฌgurations.
โ€ข Wireless M-Bus Suite supports Wireless M-Bus Stack sniffer (refer to chapters 5.9 and 6 ).
โ€ข Wireless M-Bus Suite includes an AES encryption and decryption tool.
โ€ข Download binary ๏ฌrmware ๏ฌles to the EFM Starter Kits, to switch or update applications, if a bootloader is
available.
The following Wireless M-Bus Stack ๏ฌrmware ๏ฌles or projects are applicable:
โ€ข The pre-compiled Wireless M-Bus Stack ๏ฌrmware ๏ฌles in chapter 7.2.1, table 22. Refer to chapter 4.2.1 for
details about downloading a binary ๏ฌrmware ๏ฌle to a EFM Starter Kit.
โ€ข The IAR Workbench project in chapter 4.2.1. Refer to chapter 4.2.2 for details about downloading an IAR
Workbench Project to a EFM Starter Kit.
7.4 Download Binary Files
This chapter describes how to prepare the the demonstration application of the Wireless M-Bus Stack from STZEDN
with a pre-compiled ๏ฌrmware, delivered as a โ€™*.binโ€™ binary ๏ฌle. To start the demonstration application, the Wireless
M-Bus Stack ๏ฌrmware must be downloaded to the EFM Starter Kits. The ๏ฌrmware ๏ฌles in chapter 7.2.1, table 21 and
table 22, are applicable.
To upload the ๏ฌrmware, please perform the steps in chapter 4.2.1.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 68
Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kits.
7.5 The Wireless M-Bus Stack as Library
This chapter describes the usage of the Wireless M-Bus Stack as library. Regarding the libraries, there are two IAR
Workbench projects available. The project in chapter 7.2.3.1 builds the Wireless M-Bus Stack libraries. The project
in chapter 7.2.3.2 uses the libraries to setup an application project. If you want to build the libraries, go to chapter
7.5.1. If the libraries should be built, please refer to chapter 7.5.2.
Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kit. Refer to chapter
4.2.2 for more detailed information about uploading an IAR Workbench project to the EFM Starter Kits.
7.5.1 Build Libraries
The corresponding IAR Workbench project is the โ€™lib_buildโ€™ project in chapter 7.2.3.1. The purpose of the project
is only to build Wireless M-Bus Stack libraries. Thus, there are no main ๏ฌles necessary. The project contains all
precon๏ฌgured con๏ฌguration for the different Wireless M-Bus types and modes. Refer to table 23 in chapter 7.2.2 for
detailed information about the nomenclature of the library ๏ฌles. Please note, that the serial interface is disabled in
all project con๏ฌgurations.
7.5.2 Use Libraries
The corresponding IAR Workbench project is the โ€™lib_useโ€™ project in chapter 7.2.3.2. The purpose of this project is to
use the Wireless M-Bus Stack libraries to develop applications. For a fast and easy development, the project contains
sample main ๏ฌles for the meter and the collector device which implement the demonstration application. The user
can change and extend these ๏ฌles for own applications. The project contains precon๏ฌgured con๏ฌgurations for all
supported Wireless M-Bus types and modes. Please make sure to include the correct library ๏ฌle for the intended
Wireless M-Bus type and mode. Please note that the serial interface is disabled in all project con๏ฌgurations.
7.6 The Wireless M-Bus Stack as Source Code
The corresponding IAR Workbench projects are described in chapter 7.2.3.3 and chapter 7.2.3.4. In the ๏ฌrst project,
the serial interface is enabled. In the second project, the serial interface is disabled. However, these projects support
full access to every source ๏ฌle at each communication layer of the Wireless M-Bus Stack from STZEDN. Thus, the
user is able to change e.g. the availibility of the serial interface.
Quick Start Guide
Version 1.02
7 DEMONSTRATION APPLICATION page 69
Please note, that changes in the source code can have major impact on the prin-
ciple of operation of the Wireless M-Bus Stack. Please perform changes on the
source code only, if you are completly con๏ฌdent about the impacts. There is no
support from STZEDN to projects with changed source code (The only exception
to this restriction are the main application ๏ฌles and the con๏ฌguration header ๏ฌle,
stzedn_wmbus_global.h).
Please make sure, that the following requirements are ful๏ฌlled:
Number Description
1 The function stzedn_tmr_tick() must be called 2000 times per second.
2 The microcontroller main clock must be fast enough to ensured that
the timings in the bidirectional communication can be hold.
Table 28: Wireless M-Bus Stack Requirements
Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kit. Refer to chapter
4.2.2 to get detailed information about uploading an IAR Workbench project to the EFM Starter Kits.
Quick Start Guide
Version 1.02
8 CONTACT INFORMATION page 70
8 Contact information
In case of questions, requests for quotations or ideas for further improvements, please contact:
Steinbeis Transfer Center for Embedded Design and Networking (STZEDN)
Poststrasse 35
D-79423 Heitersheim
Germany
Tel: +49 7634-6949-340
Fax: +49 7634-5049-886
Url: http://www.stzedn.de/smart-metering.html
E-mail: metering@stzedn.de
Quick Start Guide
Version 1.02
REFERENCES page 71
References
[1] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 1: Data exchange; English version EN
13757-1, 2002.
[2] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 2: Physical and link layer; English
version EN 137572, 2004.
[3] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 3: Dedicated application layer; English
version EN 137573, 2004.
[4] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 4: Wireless meter readout (Radio
meter reading for operation in the 868 MHz to 870 MHz SRD band); German version EN 137574, 2005.
[5] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 5: Wireless Relaying; English version
prEN 13757-5, 2009.
[6] โ€œTelecontrol equipment and systems.โ€ Part 5: Transmission protocols; EN 870-5, 2002.
[7] โ€œOpen metering system speci๏ฌcation - volume 2: Primary communication.โ€ http://www.oms-
group.org/download/OMS-Spec_Vol2_Primary_v301.pdf, 2011.
[8] S. Labs, โ€œSimplicity studio homepage, "http://www.energymicro.com/software/simplicity-studio".โ€
[9] โ€œEuropean committee for standardization.โ€ [Online; accessed 15-December-2011] http://www.cen.eu.
[10] โ€œOms-group.โ€ [Online; accessed 15-December-2011] http://www.oms-group.org.
[11] โ€œSteinbeis transfer center for embedded design and networking.โ€ [Online; accessed 15-December-2011]
http://www.stzedn.de.
Quick Start Guide
Version 1.02

More Related Content

PPT
Non linear effects in optical fibers
PPTX
What is Satelite Internet
PPTX
The Wireless M-Bus technology
PDF
5G massive mimo & planning.pdf
PDF
Intoduction to TinyOS, nesC and TOSSIM
PDF
Lte Ran Architecture Aspects
PPT
Wireless sensor network and its application
PDF
LPWAN technology overview
ย 
Non linear effects in optical fibers
What is Satelite Internet
The Wireless M-Bus technology
5G massive mimo & planning.pdf
Intoduction to TinyOS, nesC and TOSSIM
Lte Ran Architecture Aspects
Wireless sensor network and its application
LPWAN technology overview
ย 

What's hot (20)

PDF
Base Station Antenna needs for the 5G RAN
ย 
PPTX
PPT on Bluetooth Based Wireless Sensor Networks
PPTX
Introduction To LoRaWan
PDF
Intermediate: Vehicle to Everything (V2X) Introduction
ย 
DOCX
Frame structure 5G
PPTX
Topology control protocols for WSNs challenges and research opportunities, 14...
PPTX
What is LoRaWaN
PDF
wcdma-paging-problem-analysis
PPTX
Wsn unit-1-ppt
PPTX
border-security-using-wins
PDF
Overview 5G Architecture Options from Deutsche Telekom
PDF
LPWAN Technologies for Internet of Things (IoT) and M2M Scenarios
PDF
Optical satellite communications
PPTX
WSN-IEEE 802.15.4 -MAC Protocol
PPT
Seminar Presentation on raspberry pi
PPT
lora.ppt
PDF
IoT and LoRaWAN
PPTX
CCNA PPT
ย 
PPTX
Chapter 2c
PPTX
Ultra-wide band Technology
Base Station Antenna needs for the 5G RAN
ย 
PPT on Bluetooth Based Wireless Sensor Networks
Introduction To LoRaWan
Intermediate: Vehicle to Everything (V2X) Introduction
ย 
Frame structure 5G
Topology control protocols for WSNs challenges and research opportunities, 14...
What is LoRaWaN
wcdma-paging-problem-analysis
Wsn unit-1-ppt
border-security-using-wins
Overview 5G Architecture Options from Deutsche Telekom
LPWAN Technologies for Internet of Things (IoT) and M2M Scenarios
Optical satellite communications
WSN-IEEE 802.15.4 -MAC Protocol
Seminar Presentation on raspberry pi
lora.ppt
IoT and LoRaWAN
CCNA PPT
ย 
Chapter 2c
Ultra-wide band Technology
Ad

Similar to Wireless m-bus-quick-start-guide (20)

PDF
MFR4310.pdf
PDF
Motorola solutions wing 4.4 ap7131 n access point product reference guide (pa...
PDF
Motorola solutions wing 4.4 ap7131 n access point product reference guide (pa...
PDF
SPI Concepts.pdf
PDF
Emf2192 ib _ethercat aif module__v3-1__en
PDF
Bx310x Product Specification
PDF
RF Management Applications Using ZigBee Networks
PDF
Ff wiring
PDF
Motorola solutions wing 4.4 ap51xx access point product reference guide (part...
PDF
ATV320_Modbus_TCP_EtherNet_IP_Manual_NVE41313_02.pdf
PDF
Discovering st32
ย 
PDF
IBM Flex System Interoperability Guide
PDF
I2C bus specification version 2.1
PDF
thesis_SaurabhPanda
PDF
Manual completo ARM
PDF
OpenWRT manual
ย 
PDF
USB OTG
PDF
Emf2102 ib _lecom-a-b-li aif module__v2-0__en
PDF
IBM Flex System Interoperability Guide
PDF
Ap51 xx reference_guide
MFR4310.pdf
Motorola solutions wing 4.4 ap7131 n access point product reference guide (pa...
Motorola solutions wing 4.4 ap7131 n access point product reference guide (pa...
SPI Concepts.pdf
Emf2192 ib _ethercat aif module__v3-1__en
Bx310x Product Specification
RF Management Applications Using ZigBee Networks
Ff wiring
Motorola solutions wing 4.4 ap51xx access point product reference guide (part...
ATV320_Modbus_TCP_EtherNet_IP_Manual_NVE41313_02.pdf
Discovering st32
ย 
IBM Flex System Interoperability Guide
I2C bus specification version 2.1
thesis_SaurabhPanda
Manual completo ARM
OpenWRT manual
ย 
USB OTG
Emf2102 ib _lecom-a-b-li aif module__v2-0__en
IBM Flex System Interoperability Guide
Ap51 xx reference_guide
Ad

More from ๋ด‰์กฐ ๊น€ (20)

PDF
์ฐฝ์˜ยท์œตํ•ฉยท๋ฌธ์ œํ•ด๊ฒฐ์„ ๋ฐฐ์šฐ๋Š” ๋ฉ”์ด์ปค ํ™œ๋™ ๋ฆฌ์ŠคํŠธ
PDF
Softboxcoding brand name
PDF
Weather station performance sharing
PDF
Aircleaner 20190616 - ๋ฏธ์„ธ๋จผ์ง€ ๊ณต๊ธฐ์ฒญ์ •๊ธฐ ๋ฉ”์ด์ปคํ™œ๋™ ์ œ์•ˆ์„œ
PDF
Softbox coding - raspberrypi3 b+ 2019 Lecture File
PDF
Sw education and maker
PDF
์†Œํ”„ํŠธ๋ฐ•์Šค ๋ผ์ฆˆ๋ฒ ๋ฆฌํŒŒ์ด ๊ต์œกํ‚คํŠธ ๊ฐœ๋ฐœํ™˜๊ฒฝ ์„ค์ •
PDF
Expansion of maker culture and promotion of maker activity
PDF
2018๋…„ ๋”ฐ๋ณต๊ณต๋™์ฒด ํ™œ๋™ ๊ณต์œ  - ๊ณผ์ฒœ ๋””์ง€ํ„ธ ์ฐฝ์ž‘์ง‘๋‹จ
PDF
๊ฐ•์‚ฌ๋ฃŒ ์›์ฒœ์ง•์ˆ˜ ๊ด€๋ จ ์„ค๋ช…์ž๋ฃŒ
PDF
Softbox review and quickstartguide-20180926
PDF
๋””์ง€ํ„ธ์ฐฝ์ž‘์ง‘๋‹จ ํ™œ๋™ ์†Œ๊ฐœ๋ฌธ์„œ
PDF
Softbox arduino software education, softbox ์†Œํ”„ํŠธ๋ฐ•์Šค ์ œํ’ˆ์†Œ๊ฐœ์„œ
PDF
Stuffed animals 20180605
PDF
20180329 reco computer for maker
PDF
2018 donga marathon training schedule
PDF
2017 marathob trainning schedule
PDF
Marathon safe guide
PDF
์‚ฌ๋ฌผ์ธํ„ฐ๋„ท์„œ๋น„์Šค์™€ ํด๋ผ์šฐ๋“œ
PDF
4์ฐจ ์‚ฐ์—…ํ˜๋ช…๊ณผ io t 20170919
์ฐฝ์˜ยท์œตํ•ฉยท๋ฌธ์ œํ•ด๊ฒฐ์„ ๋ฐฐ์šฐ๋Š” ๋ฉ”์ด์ปค ํ™œ๋™ ๋ฆฌ์ŠคํŠธ
Softboxcoding brand name
Weather station performance sharing
Aircleaner 20190616 - ๋ฏธ์„ธ๋จผ์ง€ ๊ณต๊ธฐ์ฒญ์ •๊ธฐ ๋ฉ”์ด์ปคํ™œ๋™ ์ œ์•ˆ์„œ
Softbox coding - raspberrypi3 b+ 2019 Lecture File
Sw education and maker
์†Œํ”„ํŠธ๋ฐ•์Šค ๋ผ์ฆˆ๋ฒ ๋ฆฌํŒŒ์ด ๊ต์œกํ‚คํŠธ ๊ฐœ๋ฐœํ™˜๊ฒฝ ์„ค์ •
Expansion of maker culture and promotion of maker activity
2018๋…„ ๋”ฐ๋ณต๊ณต๋™์ฒด ํ™œ๋™ ๊ณต์œ  - ๊ณผ์ฒœ ๋””์ง€ํ„ธ ์ฐฝ์ž‘์ง‘๋‹จ
๊ฐ•์‚ฌ๋ฃŒ ์›์ฒœ์ง•์ˆ˜ ๊ด€๋ จ ์„ค๋ช…์ž๋ฃŒ
Softbox review and quickstartguide-20180926
๋””์ง€ํ„ธ์ฐฝ์ž‘์ง‘๋‹จ ํ™œ๋™ ์†Œ๊ฐœ๋ฌธ์„œ
Softbox arduino software education, softbox ์†Œํ”„ํŠธ๋ฐ•์Šค ์ œํ’ˆ์†Œ๊ฐœ์„œ
Stuffed animals 20180605
20180329 reco computer for maker
2018 donga marathon training schedule
2017 marathob trainning schedule
Marathon safe guide
์‚ฌ๋ฌผ์ธํ„ฐ๋„ท์„œ๋น„์Šค์™€ ํด๋ผ์šฐ๋“œ
4์ฐจ ์‚ฐ์—…ํ˜๋ช…๊ณผ io t 20170919

Recently uploaded (20)

PPTX
02fdgfhfhfhghghhhhhhhhhhhhhhhhhhhhh.pptx
PPT
Hypersensitivity Namisha1111111111-WPS.ppt
PPTX
code of ethics.pptxdvhwbssssSAssscasascc
PDF
How NGOs Save Costs with Affordable IT Rentals
PPTX
Lecture-3-Computer-programming for BS InfoTech
PPTX
sdn_based_controller_for_mobile_network_traffic_management1.pptx
PPTX
quadraticequations-111211090004-phpapp02.pptx
PPTX
5. MEASURE OF INTERIOR AND EXTERIOR- MATATAG CURRICULUM.pptx
PPTX
Wireless and Mobile Backhaul Market.pptx
PPTX
Embedded for Artificial Intelligence 1.pptx
PDF
Layer23-Switch.com The Cisco Catalyst 9300 Series is Ciscoโ€™s flagship stackab...
PPTX
Presentacion compuuuuuuuuuuuuuuuuuuuuuuu
PPTX
Embeded System for Artificial intelligence 2.pptx
PPTX
Syllabus Computer Six class curriculum s
PPTX
Computers and mobile device: Evaluating options for home and work
PPTX
KVL KCL ppt electrical electronics eee tiet
PPTX
Lecture 3b C Library _ ESP32.pptxjfjfjffkkfkfk
PPTX
Entre CHtzyshshshshshshshzhhzzhhz 4MSt.pptx
PPTX
Operating System Processes_Scheduler OSS
PPTX
PROGRAMMING-QUARTER-2-PYTHON.pptxnsnsndn
02fdgfhfhfhghghhhhhhhhhhhhhhhhhhhhh.pptx
Hypersensitivity Namisha1111111111-WPS.ppt
code of ethics.pptxdvhwbssssSAssscasascc
How NGOs Save Costs with Affordable IT Rentals
Lecture-3-Computer-programming for BS InfoTech
sdn_based_controller_for_mobile_network_traffic_management1.pptx
quadraticequations-111211090004-phpapp02.pptx
5. MEASURE OF INTERIOR AND EXTERIOR- MATATAG CURRICULUM.pptx
Wireless and Mobile Backhaul Market.pptx
Embedded for Artificial Intelligence 1.pptx
Layer23-Switch.com The Cisco Catalyst 9300 Series is Ciscoโ€™s flagship stackab...
Presentacion compuuuuuuuuuuuuuuuuuuuuuuu
Embeded System for Artificial intelligence 2.pptx
Syllabus Computer Six class curriculum s
Computers and mobile device: Evaluating options for home and work
KVL KCL ppt electrical electronics eee tiet
Lecture 3b C Library _ ESP32.pptxjfjfjffkkfkfk
Entre CHtzyshshshshshshshzhhzzhhz 4MSt.pptx
Operating System Processes_Scheduler OSS
PROGRAMMING-QUARTER-2-PYTHON.pptxnsnsndn

Wireless m-bus-quick-start-guide

  • 1. Wireless M-Bus Suite and Silabs speci๏ฌc documetation Quick Start Guide January 17, 2014
  • 2. page 2 Document History 1.00 2013-10-11 First release mr 1.01 2013-11-11 Setup chapter updated mr 1.02 2013-11-14 Note in chapter โ€™Firmwareโ€™ added mr 1.03 2014-01-17 Added chapter 4.1.4 ar Table 1: Document History Quick Start Guide Version 1.02
  • 3. 1 INTRODUCTION page 3 1 Introduction This document is a hardware and software guide for Silabs devices and the Wireless M-Bus Stack from Steinbeis Transfer Center Embedded Design and Networking [STZEDN] and describes the installation of Wireless M-Bus devices to test, to evaluate and to con๏ฌgure with the Wireless M-Bus Suite. The guide contains the following chapters: โ€ข Chapter 5.1: System Requirements This chapter speci๏ฌes the system requirements for the PC to use the Wireless M-Bus Suite for 32-Bit and 64-Bit operating systems. โ€ข Chapter 5.2: COM Port Settings This chapter contains the required settings to connect the target hardware to the PC. โ€ข Chapter 4: Hardware Setup and Firmware Installation This chapter describes the hardware setup, de๏ฌnes performance and peripheral information and speci๏ฌes dif- ferent ways to upload the Wireless M-Bus Stack from STZEDN for each Silabs microcontroller family. โ€ข Chapter 5: Wireless M-Bus Suite Quick Start Guide The Wireless M-Bus Suite quick start guide leads the user step by step through the included demo con๏ฌguration to setup a Wireless M-Bus network in a fast and easy way. The Wireless M-Bus Suite from STZEDN is a computer program to test, to evaluate and to con๏ฌgure Wire- less M-Bus devices running the Wireless M-Bus Stack. It contains mechanisms to build up a Wireless M-Bus network. It provides interfaces to control the different device types of the Wireless M-Bus Stack - collector, meter and protocol monitor (Wireless M-Bus sniffer). The Wireless M-Bus Suite is designed to handle different network con๏ฌgurations. Con๏ฌgurations can easily be changed, updated or stored. Furthermore it is capable to run Wireless M-Bus devices with different parameters and settings (e.g. security, device addresses, uni- or bidirectional). The Wireless M-Bus Suite uses a serial interface to communicate with the Wireless M-Bus devices and is able to upload a new ๏ฌrmware image to a Wireless M-Bus device. โ€ข Chapter 6: Wireless M-Bus Protocol Monitor The Wireless M-Bus Protocol Monitor is an integrated application in the Wireless M-Bus Suite. It is a Wireless M-Bus Sniffer and can be used to monitor Wireless M-Bus packets. Besides meter and collector con๏ฌgura- tions, the Wireless M-Bus Stack from STZEDN contains con๏ฌgurations is capable of Wireless M-Bus Sniffer con๏ฌgurations. โ€ข Chapter 7: Demonstration Application This chapter presents the demonstration application of the Wireless M-Bus Stack with a sample experimenter Quick Start Guide Version 1.02
  • 4. 1 INTRODUCTION page 4 board. Furthermore, it de๏ฌnes the nomenclature, speci๏ฌes the different delivery packages of the Wireless M-Bus Stack and shows how to use the Wireless M-Bus Stack with and without the Wireless M-Bus Suite. Table 2 lists the supported Transceivers from Silabs, as well as the supported Starter Kits. SI4461 SI4463 EFM32LG890 X X Table 2: Supported Transceivers and Starter Kits Quick Start Guide Version 1.02
  • 5. CONTENTS page 5 Contents 1 Introduction 3 2 Wireless M-Bus Basics 11 2.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 2.2 Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 2.2.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 2.2.2 Communication Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 2.2.3 Unidirectional vs. Bidirectional Communication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 3 The STZEDN Protocol Stack 15 3.1 Wireless M-Bus Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 3.2 Wireless M-Bus Protocol Stack Deliveries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 3.2.1 Demonstration Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 3.2.2 Wireless M-Bus Stack as Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 3.3 Con๏ฌguration of the Wireless M-Bus Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 3.4 Memory Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 3.4.1 Internal data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 3.4.2 Volatile memory model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 3.4.3 Non-volatile memory model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 3.4.3.1 Data storage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 3.4.3.2 Non-volatile memory management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 3.5 Encryption Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 3.6 Sleep modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 3.7 Wireless M-Bus Channels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 4 Setup 23 4.1 Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 4.1.1 Supported Radio Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 4.1.2 Hardware requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 4.1.3 Wireless M-Bus Hardware Platform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 4.1.3.1 EFM32LG-STK3600 Leopard Gecko Starter Kit . . . . . . . . . . . . . . . . . . . . . . . . . 24 4.1.3.2 MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 4.1.3.3 Connection between Leopard Gecko MCU and EZRadioPRO transceiver . . . . . . . . . 26 4.1.3.4 EZRadioPRO RF Pico Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 4.1.4 Required hardware resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 4.2 Firmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 4.2.1 Firmware Installation with Simplicity Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 4.2.2 Install Firmware with IAR compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Quick Start Guide Version 1.02
  • 6. CONTENTS page 6 5 Wireless M-Bus Suite 34 5.1 System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 5.2 COM Port Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 5.3 Loading the demo project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 5.4 Collector short description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 5.5 Meter short description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 5.6 Using the Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 5.6.1 Mode selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 5.6.2 Console . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 5.7 Perform a ping test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 5.8 Using the transmission tests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 5.9 Wireless M-Bus Protocol Monitor Quick Start Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 6 Wireless M-Bus Protocol Monitor 54 6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 6.2 Wireless M-BUS protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 6.3 Running the protocol monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 6.4 Packet View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 6.5 CSV View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 6.6 Statistics View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 6.7 Timeline View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 6.8 Details View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 6.9 Filter View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 6.10 No warranty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 7 Demonstration Application 61 7.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 7.2 The Wireless M-Bus Stack Nomenclature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 7.2.1 Pre-compiled Firmware Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 7.2.1.1 Wireless M-Bus Stack Firmware Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 7.2.2 Wireless M-Bus Stack Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 7.2.3 IAR Projects and Con๏ฌgurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 7.2.3.1 Library Build IAR Workbench Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 7.2.3.2 Library Usage IAR Workbench Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 7.2.3.3 Source Code IAR Workbench Project with serial interface disabled . . . . . . . . . . . . 64 7.2.3.4 Source Code IAR Workbench Project with serial interface enabled . . . . . . . . . . . . . 65 7.3 The Demonstration Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 7.3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 7.3.2 Demonstration Application without Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . 66 Quick Start Guide Version 1.02
  • 7. CONTENTS page 7 7.3.3 Demonstration Application with Wireless M-Bus Suite . . . . . . . . . . . . . . . . . . . . . . . . . . 67 7.4 Download Binary Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 7.5 The Wireless M-Bus Stack as Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 7.5.1 Build Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 7.5.2 Use Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 7.6 The Wireless M-Bus Stack as Source Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 8 Contact information 70 References 71 Quick Start Guide Version 1.02
  • 8. LIST OF TABLES page 8 List of Tables 1 Document History . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 2 Supported Transceivers and Starter Kits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 3 Operating Modes of Wireless M-Bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 4 Operating Modes of Wireless M-Bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 5 Compatibility matrix for Wireless M-Bus operating modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 6 Available Wireless M-Bus Protocol Stack Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 7 Available Wireless M-Bus memory models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 8 Available Types and Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 9 Internal data of a Wireless M-Bus meter device. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 10 API functions, which case a non-volatile write access imediately. . . . . . . . . . . . . . . . . . . . . . . . . 19 11 Encryption Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 12 Available channels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 13 Supported Transceivers and RF Pico Boards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 14 Hardware requirements for a meter / collector device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 15 Pin compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 16 Hardware Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 17 Memory consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 18 โ€™Smart Meterโ€™ Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 19 Console View Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 20 List of Wireles M-Bus ๏ฌelds. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 21 Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles without a serial interface and without Wire- less M-Bus Suite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 22 Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles with a serial interface and with Wireless M-Bus Suite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 23 Nomenclature of the Wireless M-Bus Stack library ๏ฌles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 24 Con๏ฌguration Names of the Library Build porject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 25 Con๏ฌguration Names of the Library Usage porject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 26 Con๏ฌguration Names of the Debug porject with serial interface disabled . . . . . . . . . . . . . . . . . . . 64 27 Con๏ฌguration Names of the Debug porject with serial interface enabled . . . . . . . . . . . . . . . . . . . 65 28 Wireless M-Bus Stack Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Quick Start Guide Version 1.02
  • 9. LIST OF FIGURES page 9 List of Figures 1 Bidirectional Communication with a request after the reception of a periodical meter packet. Example for mode S2. (Supported by the following modes: T2, S2, C2 and N2) . . . . . . . . . . . . . . . . . . . . 14 2 Wireless M-Bus Protocol Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 3 Non-volatile memory work ๏ฌ‚ow. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 4 List of frequencies used by Wireless M-Bus mode S, T and C . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 5 List of frequencies used by Wireless M-Bus mode N . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 6 The 32bit W-MBUS Hardware Platform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 7 EFM32LGSTK3600 hardware layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 8 Breakout pads and expansion header . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 9 EXP Header Pins on Leopard Gecko Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 10 MSC-RFP2EFM Adapter Board connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 11 EXP header pins on MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 12 RF Pico Board Pins on MSC-RFP2EFM Adapter Board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 13 RF Pico Board Front Side . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 14 Simplicity Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 15 Select "energyAwareCommander" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 16 Select the connected board . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 17 Select "Flash" . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 18 Flash the selected ๏ฌrmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 19 Download . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 20 Workbench con๏ฌguration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 21 Open project options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 22 Driver selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 23 Standard COM port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 24 Virtual COM port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 25 Start -up dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 26 Collector and Meter device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 27 Collector editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 28 Meter connected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 29 Meter disconnected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 30 Meter without collector address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 31 Meter addresses duplicate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 32 COM Port selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 33 Select โ€™Smart Meterโ€™ meter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 34 โ€™Data Collectorโ€™ programmed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 35 โ€™Smart Meterโ€™ Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 36 โ€™Smart Meterโ€™ programmed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Quick Start Guide Version 1.02
  • 10. LIST OF FIGURES page 10 37 Mode selection boxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 38 Collector C and Meter T . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 39 Mode Nb example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 40 Console View . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 41 Console with serial text output enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 42 Write con๏ฌg to device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 43 Start ping test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 44 Ping test failed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 45 Ping test ok . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 46 โ€™Start wireless M-Bus demoโ€™ button โ€™Data Collectorโ€™ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 47 โ€™Start wireless M-Bus demoโ€™ button โ€™Smart Meterโ€™ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 48 โ€™Data Collectorโ€™ Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 49 Send data test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 50 Open the โ€™Wireless M-Bus Protocol Monitorโ€™ wizard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 51 Select the serial connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 52 Select the protocol monitor device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 53 Select the protocol monitor device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 54 Wireless M-Bus Protocol Monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 55 Example of a Wireless M-Bus packet. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 56 Starting and stopping the wireless M-Bus protocol monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 57 Packet View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 58 CSV View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 59 Statistic View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 60 Timeline View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 61 Detail View. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 62 De๏ฌning a ๏ฌlter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 63 De๏ฌning several rules. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 64 Demonstration Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Quick Start Guide Version 1.02
  • 11. 2 WIRELESS M-BUS BASICS page 11 2 Wireless M-Bus Basics 2.1 Introduction The Metering Bus (or in short "M-Bus ") is a ๏ฌeld bus specialized for transmission of metering data from gas, electricity, heat, water or other meters to a data collector. It is described by European Norm (EN 13757), which includes the speci๏ฌcation of wired and Wireless M-Bus. The speci๏ฌcation is divided into ๏ฌve parts: โ€ข EN 13757-1 ([1]): Communication systems for meters and remote reading of meters - Part 1: Data exchange The ๏ฌrst part describes the basic communication between the meters and a central data collector. It provides an overview of the communication system. โ€ข EN 13757-2 ([2]): Communication systems for meters and remote reading of meters - Part 2: Physical and link layer The second part includes the speci๏ฌcation of the physical data transmission using wired connections. It also includes the description of the protocol to transmit the data. โ€ข EN 13757-3 ([3]): Communication systems for meters and remote reading of meters - Part 3: Dedicated application layer The third part describes a standardized application protocol to enable multivendor capability. So devices of different manufacturers may be combined in one system. โ€ข EN 13757-4 ([4]): Communication systems for meters and remote reading of meters - Part 4: Wireless meter readout (Radio me- ter reading for operation in the 868 MHz to 870 MHz SRD band) This part speci๏ฌes the wireless communication of M-Bus and is the main source document for this implemen- tation. It includes the Physical and the Data Link Layer for wireless devices. It corresponds to speci๏ฌcation EN 13757-2 for wired communication. โ€ข EN 13757-5 ([5]): Communication systems for meters and remote reading of meters - Part 5: Relaying This last part includes different proposals for relaying data frames to overcome the range problem between remote meters and data collectors. The sixth part of this norm relates only to wired busses and is disregarded in this document. All parts of EN 13757 are compliant to the European Norm EN 870-5 [6]. Quick Start Guide Version 1.02
  • 12. 2 WIRELESS M-BUS BASICS page 12 2.2 Protocol Stack 2.2.1 Introduction M-Bus is compatible to the international ISO/OSI-model, but only the layers 1, 2 and 7 are implemented. Layer 7 Application Layer (EN 13757-3) Layer 2 Data Link Layer (EN 13757-2 or EN 13757-4) Layer 1 Physical Layer (EN 13757-2 or EN 13757-4) Table 3: Operating Modes of Wireless M-Bus Up to now, the application layer implements all other protocol layers required for a speci๏ฌc appliance. Especially if routing is required according to [5], it is implemented in the application layer. The reduced modularity leads to compact implementations running on very small devices with minimum computing resources. But the lack of modularity certainly is one of the reasons why standardized routing protocols are currently not available for Wireless M-Bus. The M-Bus favours asymmetric network topologies with low-cost or low-power metering devices on the one side and data collectors or gateways with higher performance on the other side. Currently, only point-to-point or star network topologies can be supported. Mesh or multi-hop topologies are not possible. This chapter describes the settings for implementations of the data collector and the metering devices to setup a network in star topology. 2.2.2 Communication Modes Dependly on the application there are various combinations of communication modes for data collectors and metering devices. These settings de๏ฌne the communication ๏ฌ‚ow and the con๏ฌguration of the radio channel. Table 4 lists available communication modes. Mode Communication Description S1 Unidirectional In the stationary mode, the metering devices send their data several times a day. In this mode, the data collector may save power as the metering devices send a wakeup signal before transmitting their data. S2 Bidirectional Bidirectional version of S1. T1 Unidirectional In the Frequent Transmit mode, the metering devices periodically send their data to collectors in range. The interval is con๏ฌgurable in terms of several seconds or minutes. T2 Bidirectional Bidirectional version of T1. The data collector may request dedicated data from the metering devices. C1 Unidirectional "Compact Mode" mode. This mode is similar to mode T but it allows for transmis- sion of more data within the same energy budget and with the same duty cycle. It is suitable for walk-by and/or drive-by readout. The common reception of mode T and mode C frames with a single receiver is possible. C2 Bidirectional Bidirectional version of C1. The data collector may request dedicated data from the metering devices. Table 4: Operating Modes of Wireless M-Bus Table 5 lists the combinations of the communication modes of meters and data collectors. Quick Start Guide Version 1.02
  • 13. 2 WIRELESS M-BUS BASICS page 13 In T2 mode, the communication settings for the two data directions are different. Due to different requirements, both communication devices have to support fast switching of communication speed, coding scheme, and frequency. Meter Deviceโ€™s channels Data Collector channels S1, S2 T1, T2 C1, C2 Collector Deviceโ€™s Tx radio settings (Freq., data rate, modula- tion) S1, S2 X 868,30 MHz 32.768 kcps Manchester enc. T1, T2 X 868,30 MHz 32.768 kcps Manchester enc. C1, C2 X 868,30 MHz 32.768 kcps Manchester enc. C1, C2 X 869,525 MHz 50 kcps NRZ enc. MeteringDeviceโ€™s Txradiosettings (Freq.,datarate,modulation) 868,30MHz 32.768kcps Manchesterencoding 868,95MHz 100kcps 3-out-of-6encoding 868,95MHz 100kcps NRZencoding Table 5: Compatibility matrix for Wireless M-Bus operating modes Table 5 shows that although the T- and S-modes cannot be combined, a T2 data collector may not well coexist with a parallel S-mode communication int its vicinity. Table 5 also shows that the C-mode supports the common reception of mode T and mode C frames with a single receiver. 2.2.3 Unidirectional vs. Bidirectional Communication If unidirectional communication is used, data will be sent from the metering device to the data collector only. This enables simple transmitters as metering devices while the data collector only needs to receive. Because listen-before- talk (LBT) and dynamic network con๏ฌguration are not possible, it is recommended to use the unidirectional modes for small and simple constellations with little network load. In case of bidirectional communication, the collector device can request data from the meter device. This is for example the case in S2, T2, C2 and N2 mode. In this modes, a bidirectional communication will only be established if further data or commands need to be exchanged (cf. Fig. 1). Figure 1 shows a typical communication ๏ฌ‚ow. Quick Start Guide Version 1.02
  • 14. 2 WIRELESS M-BUS BASICS page 14 Figure 1: Bidirectional Communication with a request after the reception of a periodical meter packet. Example for mode S2. (Supported by the following modes: T2, S2, C2 and N2) Quick Start Guide Version 1.02
  • 15. 3 THE STZEDN PROTOCOL STACK page 15 3 The STZEDN Protocol Stack 3.1 Wireless M-Bus Protocol Stack The Wireless M-Bus Stack from STZEDN is a fully Wireless M-Bus complicant protocol stack, including OMS v.3.0.1 [7]. It implements the functionality described in EN-13757 ([1], [2], [3], [4], [5]). Refer to ๏ฌgure 2 for a graphical overview. Figure 2: Wireless M-Bus Protocol Stack The Wireless M-Bus protocol stack from STZEDN basically consists of four different parts: โ€ข Wireless M-Bus Stack: The Wireless M-Bus Stack part of the protocol stack contains all Wireless M-Bus functionality. โ€ข Hardware drivers: This part of the protocol stack contains all low level drivers to control the microcontroller unit, such as com- munication interfaces, memory resources and pheripheral units. โ€ข Utility Module: This part of the protocol stack contains mechanisms and functions which the stack uses to forward information through the protocol layers, to report runtime information, to handle time intervals and clocks, to manage meterlists and to execute software updates. Quick Start Guide Version 1.02
  • 16. 3 THE STZEDN PROTOCOL STACK page 16 โ€ข Con๏ฌguration interfaces: The con๏ฌguration interfaces are used to setup basic parameters of the target, such as location of the commu- nication settings or input interrupt sources. STZEDN offers different packages of the Wireless M-Bus protocol stack. All packages support full Wireless M-Bus functionality. Refer to table 6 for an overview. To ๏ฌnd the most suitable Wireless M-Bus version for the desired application, please contact STZEDN (refer to chapter 8). Layer Basic Extended Extended serial Full Application Layer x x x Extended Data Link Layer x x x x Data Link Layer x x x x Physical Layer x x x x RF Driver x x x x MCU Driver x x x x Serial Driver x x Bootloader support x Table 6: Available Wireless M-Bus Protocol Stack Packages Table 7 lists the different memory models of the stack. The memory model speci๏ฌes where the Wireless M-Bus Stack saves internal data and meterlists. Package Volatile memory Non-volatile memory Basic x x Extended x x Extended serial x x Full x x Table 7: Available Wireless M-Bus memory models Please contact STZEDN for information about currently supported microcontrollers and transceivers. Adaptions of the Wireless M-Bus protocol stack are possible upon request as well as driver developments for microcontrollers and transceivers. Please refer to chapter 8 for contact information. 3.2 Wireless M-Bus Protocol Stack Deliveries 3.2.1 Demonstration Applications Demonstration applications for development boards were delivered as binary ๏ฌles. Please note, that the demon- stration application contain the full Wireless M-Bus Stack from STZEDN. The Wireless M-Bus Suite can be used to study, test and evaluate the wmbus demonstration application and Wireless M-Bus, e.g. bidirectional communica- tion between a Wireless M-Bus collector and a Wireless M-Bus meter device. Furthermore, Wireless M-Bus Suite can download the binary ๏ฌles to development boards to switch between Wireless M-Bus device types and Wireless M-Bus modes. Please contact STZEDN for information about supported development boards. The Wireless M-Bus Suite also Quick Start Guide Version 1.02
  • 17. 3 THE STZEDN PROTOCOL STACK page 17 supports Wireless M-Bus sniffer applications for all Wireless M-Bus channels, including decryption and encryption of data. 3.2.2 Wireless M-Bus Stack as Library STZEDN delivers the Wireless M-Bus Stack for the Wireless M-Bus devices types and Wireless M-Bus modes in li- braries. Refer to table 8 for an overview. Please contact STZEDN for information about supported integrated de- velopment environments. Refer to chapter 8 for contact information. The customer is able to develop application using the Wireless M-Bus Stack libraries. For a fast and easy development, the Wireless M-Bus Stack comes with application code example for a collector and a meter device. Mode Meter Device Collector Device S1 x S2 x x T1 x T2 x x C1 x C2 x x N1 x N2 x x Table 8: Available Types and Modes Please note, that Wireless M-Bus sniffer con๏ฌgrations are only delivered as binaries. 3.3 Con๏ฌguration of the Wireless M-Bus Stack STZEDN delivers the Wireless M-Bus protocol stack in fully con๏ฌgured libraries for different device types and modes (refer to table 8). Depending on the target hardware, the Wireless M-Bus Stack supports several communication interfaces, to enable customized hardware designs. Target con๏ฌguration ๏ฌle: stzedn_target_con๏ฌg.h The target con๏ฌguration ๏ฌle contains de๏ฌnitions about pin and port de๏ฌnitions of the communication interfaces. This includes e.g. the SPI and UART communication, as well as GPIO input pin de๏ฌnitions. Please note, that the number of con๏ฌguration parameters for the hardware drivers depends on the target hardware. Refer to the hardware speci๏ฌc con๏ฌguration guide. 3.4 Memory Models Quick Start Guide Version 1.02
  • 18. 3 THE STZEDN PROTOCOL STACK page 18 3.4.1 Internal data Table 9 lists the internal data of the Wireless M-Bus Stack, which is effected by the choice of the memory model. Description Meter Collector Device status x x RF channel x x Frequency offset x x Serial baud rate x x Meter Wireless M-Bus address x x Collector Wireless M-Bus address x Periodical transmission interval x Device speci๏ฌc encryption key x x General encryption key x x Wireless M-Bus standard speci๏ฌc data x x Meterlist x Table 9: Internal data of a Wireless M-Bus meter device. 3.4.2 Volatile memory model The Wireless M-Bus Stack saves all internal vairables as well as the meterlist in volatile memory. More precisely, in the random access memory (RAM). Thus, all data which changes at runtime is lost after a reset of the device. Refer to table 9 for a list of parameters which are effected. 3.4.3 Non-volatile memory model 3.4.3.1 Data storage The non-volatile memory model stores the data listed in table 9 in the non-volatile memory. The Wireless M-Bus Stack does not specify which kind of non-volatile memory must be used. E.g. FLASH, EEPROM or FRAM. In general, the Wireless M-Bus Stack buffers most parameters in volatile memory. It synchronizes the volatile memory with the non-volatile memory at speci๏ฌc points in time. A complete synchronization of the data in table 9 takes place at the following actions/events: โ€ข During initialization of the Wireless M-Bus Stack. โ€ข A forced synchronization, initiated by user application. โ€ข When the Wireless M-Bus Stack goes to sleep mode, initiated by user application. However, some data cannot be buffered in volatile memory. Thus, some API function calls cause a write access to non- volatile memory immediately - API functions which cause changes of meterlist entries. Thus, this effects only Wireless M-Bus collector devices. Furthermore, these functions do not initiate a complete synchronization, but apply only the changes to the non-volatile memory which is described by the API function. Refer to table 10 for a corresponding list of API functions. Quick Start Guide Version 1.02
  • 19. 3 THE STZEDN PROTOCOL STACK page 19 API stzedn_apl_meterAdd stzedn_apl_meterRemove stzedn_apl_meterSetRfAdapter stzedn_apl_meterSetKey Table 10: API functions, which case a non-volatile write access imediately. Another direct non-volatile memory write access takes place, when a Wireless M-Bus collector device calls the event stzedn_apl_evt_newMeter, if the return value is set to TRUE. In this case, a new meter which is currently not in the meterlist will be added to the meterlist. 3.4.3.2 Non-volatile memory management Figure 3 shows the basic work๏ฌ‚ow of the Wireless M-Bus Stack regarding the memory management. After the start-up of the device and the initialization of the Wireless M-Bus Stack, the function stzedn_apl_start function must be called with appropriate parameters. The Wireless M-Bus Stack then synchronizes with the non-volatile memory. Synchronization at stzedn_apl_start : In this function, the Wireless M-Bus Stack ๏ฌrst checks, if the non- volatile memory contains valid information. If the non-volatile memory contains no valid information, the Wireless M-Bus Stack uses the parameters from the stzedn_apl_start function to initialize the device and stores the parameters afterwards into the non-volatile memory. If the information is valid, the parameters in the start function stzedn_apl_start were omitted and all parameters were loaded from the non-volatile memory. In this case, the Wireless M-Bus Stack also omits the optional static meterlist and loads the one in the non-volatile memory, even if the list is empty (only for collector). After calling this function, the Wireless M-Bus Stack is ready for operation. Synchronization at stzedn_apl_sleep : When the Wireless M-Bus Stack is set into sleep mode, all internal parameters from table 9 were stored into non-volatile memory. If the function returns success, the user application is allowed to set the microcontroller into a hardware sleep mode. Synchronization at stzedn_apl_wake : This function must be called to run the Wireless M-Bus Stack after a sleep mode. The stack synchronizes the buffered parameters in the volatile memory with the parameters in the non-volatile memory. Synchronization at meterlist write/change operations: When the user changes the meter entries (add, change, remove), the Wireless M-Bus Stack writes the changes immediately into the non-volatile memory. The reason for this is that the meterlist entries were not buffered in the volatile memory. Synchronization at meter installation mode: When a collector detects a new meter, it is possible to add the meter into the meterlist of the collector. The Wireless M-Bus Stack ๏ฌres the event stzedn_apl_evt_newMeter and the user application can decide, if the collector should add the meter into the own meterlist. In case the collector adds the meter into the meterlist, the stack writes the meter parameters into the non-volatile memory immediately. Quick Start Guide Version 1.02
  • 20. 3 THE STZEDN PROTOCOL STACK page 20 In all other cases, there is no non-volatile memory write access. Figure 3: Non-volatile memory work ๏ฌ‚ow. 3.5 Encryption Modes Refer to table 11 for the supported encryption modes of the Wireless M-Bus protocol stack. The only mandatory encryption mode de๏ฌned in OMS v.3.0.1 is mode 5. Mode Description 0 No encryption. 1 AES Counter Mode (AES-CTR). 5 AES Cipher Block Chaining Mode (AES-CBC) with dynamic initialization vector. Table 11: Encryption Modes Quick Start Guide Version 1.02
  • 21. 3 THE STZEDN PROTOCOL STACK page 21 3.6 Sleep modes The stack provides several sleep modes, which can be used to save energy, while the stack is not busy. โ€ข Sleep It is assumed that the mcu will enter a lpm state in which the RAM content will be kept. The radio will be set to power down mode. โ€ข Deep sleep It is assumed that the mcu will enter a lpm state in which the RAM content will not be kept. The radio will be set to power down mode. 3.7 Wireless M-Bus Channels The modes of Wireless M-Bus are using different channels. Table 12 lists all available channels. Depending on the deviceโ€™s mode, only a subset of this table can be accessed. Using channels that are not supported result in an error message at compilation of the ๏ฌrmware. Mode Frequency N1a, N2a (Meter Device and Data Collector) 169.406 MHz N1b, N2b (Meter Device and Data Collector) 169.418 MHz N1c, N2c (Meter Device and Data Collector) 169.431 MHz N1d, N2d (Meter Device and Data Collector) 169.443 MHz N1e, N2e (Meter Device and Data Collector) 169.456 MHz N1f, N2f (Meter Device and Data Collector) 169.468 MHz N2g (Meter Device and Data Collector) 169.437 MHz T2 (Data Collector TX, Meter Device RX) 868.30 MHz T1, T2 (Meter Device TX, Data Collector RX) 868.95 MHz S1, S2 (Meter Device and Data Collector) 868.30 MHz C2 (Data Collector TX, Meter Device RX) 869.525 MHz C1, C2 (Meter Device TX, Data Collector RX) 868.95 MHz Table 12: Available channels Quick Start Guide Version 1.02
  • 22. 3 THE STZEDN PROTOCOL STACK page 22 Figure 4: List of frequencies used by Wireless M-Bus mode S, T and C Figure 5: List of frequencies used by Wireless M-Bus mode N Quick Start Guide Version 1.02
  • 23. 4 SETUP page 23 4 Setup 4.1 Hardware 4.1.1 Supported Radio Types The following EZRadioPRO radio ICs are supported by the STZEDN W-MBUS Protocol Stack: 1. Si4461 Transceiver 2. Si4463 Transceiver The transceivers are delivered on RF Pico Boards. The radio module contains the radio IC, the corresponding match- ing network and the SMA connector matched to 50โ„ฆ. Part Number Board Description 4461-PCE14D868 868 MHz matching, Transceiver, 14dBm output power, Direct tied antenna connection 4463-PSQ20D169 169 MHz matching, Transceiver, 20dBm output power, Direct tied antenna connection Table 13: Supported Transceivers and RF Pico Boards 4.1.2 Hardware requirements The following devices are needed to build either a complete W-MBUS capable data collector or meter device. Description Part Number MCU EFM32LG-STK3600 Leopard Gecko Starter Kit RF Adapter Board MSC-RFP2EFM RF Pico Board 4461-PCE14D868 / 4463-PSQ20D169 Antenna 868MHz / 169MHz Table 14: Hardware requirements for a meter / collector device 4.1.3 Wireless M-Bus Hardware Platform The W-MBUS Hardware Platform is a demo, evaluation and development platform for EZRadioPRO radio ICs. It consists of a Leopard Gecko Starter Kit, an RF Pico Adapter Board and an interchangeable RF Pico Board. Quick Start Guide Version 1.02
  • 24. 4 SETUP page 24 Figure 6: The 32bit W-MBUS Hardware Platform 4.1.3.1 EFM32LG-STK3600 Leopard Gecko Starter Kit Figure 7: EFM32LGSTK3600 hardware layout Many of the EFM32โ€™s pins are routed out to "breakout pads" at the top and bottom edges of the kit. A 2.54mm pitch pin header can be soldered in for easy access to these pins. On the right hand side of the board an angled 20 pin expansion header is provided to allow connection of peripherals or plugin boards. The connecter contains a number of I/O pins that can be used with most of the EFM32 Leopard Geckoโ€™s features. Additionally, the VMCU, 3V3 and 5V power rails are also exported. Quick Start Guide Version 1.02
  • 25. 4 SETUP page 25 Figure 8: Breakout pads and expansion header Figure 9: EXP Header Pins on Leopard Gecko Module 4.1.3.2 MSC-RFP2EFM Adapter Board The adapter module makes it possible that the EFM32 Leopard Gecko MCU can be connected to the EZRadioPRO radio IC easily. On the left hand side of the board an angled 20 pin expansion header is provided to allow connection of EFM32 Leopard Gecko module. The same expansion header can be found on the right hand side. The digital signals of the radio (SCLK, MISO, MOSI, NSEL, SCLK, VRF, GND and RF_GPIOs) can be accessed on test pins at the top right side of the board. Four SMA connectors can be soldered on the bottom side for measurement purposes. The RF Pico Board can be connected in the middle of the adapter board. By default, the radio is powered through the VMCU pin. If the leopard gecko module is powered by a battery, the supply voltage must be provided to the radio through the external power source pin. The current consumption of the radio can be measured separately from the leopard gecko module on current measurement pin. Quick Start Guide Version 1.02
  • 26. 4 SETUP page 26 Figure 10: MSC-RFP2EFM Adapter Board connections Figure 11: EXP header pins on MSC-RFP2EFM Adapter Board Figure 12: RF Pico Board Pins on MSC-RFP2EFM Adapter Board 4.1.3.3 Connection between Leopard Gecko MCU and EZRadioPRO transceiver The following table shows which MCU and radio pins are required to be connected for the operation of the stack. Quick Start Guide Version 1.02
  • 27. 4 SETUP page 27 Si446x transceiver EFM32LG990F256 RF_SDN PC3 RF_GPIO_0 PC41 RF_GPIO_1 PC51 MOSI PD0 MISO PD1 RF_NSEL PD3 SCLK PD2 Table 15: Pin compatibility 4.1.3.4 EZRadioPRO RF Pico Board Figure 13: RF Pico Board Front Side The RF Pico Board is a radio module that contains an EZRadioPRO radio IC, a matching network and an SMA connector on the top side. These components apart from the antenna connector are covered by a metal shield for noise reduction. The digital signals of the radio (SCLK, SDI, SDO, NSEL, SCL, SDA, VDD and GND) can be accessed on test points at the edge of the board. The boards also have a factory loaded board identi๏ฌcation memory (EBID) on the bottom side that contains data that describes the board properties. Via the uni๏ฌed RF Pico connector pair on the bottom side of the board, any RF Pico board can be connected to the RF Pico Adapter Board. 4.1.4 Required hardware resources The following table shows the hardware resources that are required from the MCU. 1 Note that RG0=RG1=0โ„ฆ resistors must be soldered on the adapter board so that RF_GPIO_0 and RF_GPIO_1 will be available for the MCU. RF_GPIO_2 and RF_GPIO_3 are not used by the stack. Quick Start Guide Version 1.02
  • 28. 4 SETUP page 28 Function Resources MCU SPEED 28MHz SPI Bus Speed 8MHz Used Timer TIMER_1 SPI Interface USART_1_Location_1 USART Interface USART_0_Location_2 Flash for Collector informations 0x3E800-0x40000 Collector Flash for Meter informations 0x3E800-0x3F8FF Meter Used RF GPIOs of radio RF_GPIO_0, RF_GPIO_1 Table 16: Hardware Requirements The following table shows the memory consumptions of the different con๏ฌgurations for collectors and meters. Con๏ฌgurations Read-only code memory Read-write code memory Read-only data memory Read-write data memory Collector C2 with serial 47272 288 1000 6135 Collector C2 with apl 32204 288 760 4787 Collector T2 with serial 45328 288 960 6103 Collector T2 with apl 30264 288 720 4755 Collector S2 with serial 45156 288 708 6103 Collector S2 with apl 30088 288 468 4755 Collector N2 with serial 45260 288 972 6139 Collector N2 with apl 30196 288 732 4791 Meter C2 with serial 43472 288 716 6124 Meter C2 with apl 29300 288 472 4766 Meter T2 with serial 41900 288 716 6124 Meter T2 with apl 27660 288 472 4766 Meter S2 with serial 41732 288 676 6124 Meter S2 with apl 27492 288 432 4766 Meter N2 with serial 41988 288 940 6128 Meter N2 with apl 27748 288 696 4770 Table 17: Memory consumption 4.2 Firmware This section describes how to setup the ๏ฌrmware of the EFM32LG-STK3600 in use with the Wireless M-Bus Suite. Please note, that if you want to set up the enclosed demo network with the quick start for Wireless M-Bus Suite in chapter 5, you have to con๏ฌgure at least two devices: one with the collector and one with the meter ๏ฌrmware. The EFM32LG-STK3600 ๏ฌrmware can either be provided as binary2 (โ€™*.binโ€™๏ฌle) or as source code that is compiled and ๏ฌ‚ashed using IAR compiler. Please check, if a valid serial ๏ฌrmware is available on your boards. You can do this with Wireless M-Bus Suite with a ping test. If there is no ๏ฌrmware available, refer to chapter 4.2.1 for ๏ฌrmware installation using Simpl. Studio or refer to chapter 4.2.2 for installation using IAR IDE. . 2 Note that these binaries are SERIAL related and the location in our ๏ฌle hierarchy is at the location of ...WMBUS ToolsFirmwareSerial binaries Quick Start Guide Version 1.02
  • 29. 4 SETUP page 29 4.2.1 Firmware Installation with Simplicity Studio To install a ๏ฌrmware using Simplicity Studio the following steps must be performed. 1. Connect the mini USB port of the target board to your PC using a mini USB cable (J-Link interface) 2. Connect the micro USB port of the target board to your PC using a micro USB cable (serial interface). 3. Open the Simplicity Studio software (Studio software [8]). Figure 14: Simplicity Studio 4. Select "energyAwareCommander" Quick Start Guide Version 1.02
  • 30. 4 SETUP page 30 Figure 15: Select "energyAwareCommander" 5. The energyAwareCommander application will start. 6. Select the connected J-Link-Decvice and push the "Connect" button. Figure 16: Select the connected board 7. Select option "Flash". Quick Start Guide Version 1.02
  • 31. 4 SETUP page 31 Figure 17: Select "Flash" 8. Choose a "*.bin" ๏ฌle and push the button "Flash EFM32". Figure 18: Flash the selected ๏ฌrmware 9. Wait until the J-Link-Device is programmed successfully. Quick Start Guide Version 1.02
  • 32. 4 SETUP page 32 Figure 19: Download 10. To program additional devices, repeat the steps as described above. Make sure to upload the appropriate ๏ฌrmware for each device. 11. Now your boards are ready to run the application. 4.2.2 Install Firmware with IAR compiler 1. Connect the mini USB port of the target board to your PC using a mini USB cable (J-Link interface). 2. Connect the micro USB port of the target board to your PC using a micro USB cable (serial interface). 3. Open the project ๏ฌle (*.eww) with the IAR ARM compiler. 4. There are different con๏ฌgurations available in the workspace window: One for the meter device and one for the collector device with the different supported modes. Refer to ๏ฌgure 20 for the selection. Figure 20: Workbench con๏ฌguration 5. Select a workspace con๏ฌguration. 6. Before debugging, please check, if the โ€™Debuggerโ€™ is selected in the project options. Right-click on the project and select โ€™Optionsโ€™. Quick Start Guide Version 1.02
  • 33. 4 SETUP page 33 Figure 21: Open project options 7. Switch to the tab "Debugger" and verify that the "J-Link/.." option is selected. Figure 22: Driver selection 8. Now you can download and debug the source code. 9. To program additional devices, repeat the steps as described above. Make sure to upload the appropriate ๏ฌrmware for each device. Quick Start Guide Version 1.02
  • 34. 5 WIRELESS M-BUS SUITE page 34 5 Wireless M-Bus Suite 5.1 System Requirements The Wireless M-Bus Suite is available for 32-Bit and 64-Bit Win XP/WinVista/Win 7 operating systems. The tool detects the version of the installed java runtime environment and noti๏ฌes the user if a newer version is available. It requires the user to download at the of๏ฌcial java homepage (www.java.com). Recommended minimum system requirements are: โ€ข 512 MB RAM for Win XP and 1 GB RAM for Win Vista / Win 7 โ€ข 1 GHz CPU โ€ข 100 MB free hard disk space โ€ข Serial interface or USB-to-Serial connector Before installing Wireless M-Bus Suite, please check if your operating system is 32-Bit or 64-Bit: โ€ข WindowsX P : Open system information: please select Start->Run. Input โ€™winmsd.exeโ€™ and press โ€™enterโ€™. Select โ€™System Summaryโ€™. Check the โ€™System Typeโ€™ parameter: if the value is X86 โˆ’ basedPC, it is a 32-Bit Windows XP, if the value is X64 โˆ’ basedPC, it is a 64-Bit Windows XP. โ€ข WindowsVista/7 : Please go to Start->System control->System. The operating system settings can be found under the parameter โ€™System Typeโ€™. Please make sure to run the correct installer for your system type. 5.2 COM Port Settings This chapter describes how to get information about the com pot settings on Windows operating systems. Go to โ€™Start->System control->System->Hardware->Device managerโ€™ and check the โ€™COM and LPTโ€™ connections. Refer to ๏ฌgure 23 and 24 for an example COM port con๏ฌguration in a device manager of a PC. In the following, the numbers in angle brackets were used to refer to the red numbers in ๏ฌgure 23 and 24. Please expand the node <1> โ€™Ports(COM & LTP)โ€™. Based on physical connection, there are two types of COM ports to distinguish: โ€ข Physical COM port of the PC <2> (serial interface, usually COM1) โ€ข Virtual COM ports In case of a USB connection, the PC will assign a virtual COM port to the USB interface as shown by <3> in ๏ฌgure 24, COM10. Please note, that the COM port number assignement can vary. If you are not sure which COM port was assigned to your USB connection (and your device), open the โ€™Device Managerโ€™, unplug the USB cable. Please wait three seconds and plug in the USB cable again. The โ€™Device Managerโ€™ and the available COM ports of the PC updates automatically and new devices will be added to the COM port list. Quick Start Guide Version 1.02
  • 35. 5 WIRELESS M-BUS SUITE page 35 Please note, that connections declared with โ€™LPTโ€™ are no COM ports and cannot be used for a serial communication. Figure 23: Standard COM port Figure 24: Virtual COM port This chapter demonstrates how to start a basic Wireless M-Bus network with the Wireless M-Bus Suite. Wireless M- Bus Suite comes with a demonstration network project. The project settings are stored in con๏ฌguration ๏ฌles (*.xml). This quick start guide uses the demonstration project to show the basic concepts of the Wireless M-Bus Suite. The provided demo con๏ฌguration ๏ฌle includes one collector and one meter device, which communicate via Wireless M- Bus. Please note that you need to have at least two compatible evaluation boards with a valid application ๏ฌrmware. You will need one board with the collector and one board with the meter ๏ฌrmware to use the demo application. The ๏ฌrst step is to connect the boards to your pc and to power them on. The following chapters of the quick start guide can be read independently. Chapters 5.3 to 5.5 provide information, how to load the demonstration project as well as basic information, which are used for collector and meter devices. Chapters 5.7 and 5.8 specify how to perform transmission tests. However, it is recommend to read all chapters in order of appearance. Quick Start Guide Version 1.02
  • 36. 5 WIRELESS M-BUS SUITE page 36 5.3 Loading the demo project The demo project is integrated in the Wireless M-Bus Suite and can be opened after starting the Wireless M-Bus Suite. Please perform the following steps: 1. Start the Wireless M-Bus Suite. 2. A โ€™Welcomeโ€™ page will be displayed. Press โ€™Watch the tutorialโ€™ to open a video tutorial for the Wireless M-Bus Suite. 3. Press โ€™Open the demo Projectโ€™. 4. This loads the โ€™wmbs_demo.xmlโ€™ ๏ฌle from the Wireless M-Bus Suite installation folder. Figure 25: Start -up dialog 5. Now you can see the โ€™Data Collectorโ€™ and the โ€™Smart Meterโ€™ in the con๏ฌguration suite tree. In ๏ฌgure 26, the correspondig items are framed in red. Quick Start Guide Version 1.02
  • 37. 5 WIRELESS M-BUS SUITE page 37 Figure 26: Collector and Meter device Now the โ€™wmbs_demo.xmlโ€™ is loaded. In the con๏ฌguration suite tree, the โ€™Smart Meterโ€™ is located in the subtree of the โ€™Data Collectorโ€™. This means, that the โ€™Smart Meterโ€™ is assigned to the Wireless M-Bus network of the โ€™Data Collectorโ€™. 5.4 Collector short description The collector parameters can be displayed by double clicking on the โ€™Data Collectorโ€™ in the navigation tree. By default, it has a device address and an encryption key. There are several options in the โ€™Collector con๏ฌgurationโ€™ window, which are grouped in different sections. These sections (e.g. โ€™Collector operationsโ€™ or โ€™Collector detailsโ€™) can be expanded individually (refer to ๏ฌgure 27 - red framed window in the โ€™Collectors operationsโ€™ section). The red framed window in the section โ€™Collectors meter listโ€™ in ๏ฌgure 27 shows the meter devices, which are associated with this collector. In this case it is the โ€™Smart Meterโ€™ device. Quick Start Guide Version 1.02
  • 38. 5 WIRELESS M-BUS SUITE page 38 Figure 27: Collector editor If the โ€™Smart Meterโ€™ device is selected in the red framed window, the corresponding parameters such as device address etc. are displayed. It has a unique device address, an encryption key and the address of the collector device. Note that the collector device address must be consistent with the parameters of the โ€™Data Collectorโ€™ device. Otherwise no communication will be possible. The status of the con๏ฌguration of the โ€™Smart Meterโ€™ meter and the โ€™Data Collectorโ€™ will be displayed with the icon of the โ€™Smart Meterโ€™ in the navigation tree. A well de๏ฌned connection is displayed with the icon in ๏ฌgure 28, otherwise ๏ฌgure 29 noti๏ฌes the user that the meter is not connected. Figure 30 appears, if a meter has no collector address registered or the collector has no address con๏ฌgured. If two meters within the Wireless M-Bus network have the same device addresses, ๏ฌgure 31 is shown. Figure 28: Meter connected Figure 29: Meter disconnected Quick Start Guide Version 1.02
  • 39. 5 WIRELESS M-BUS SUITE page 39 Figure 30: Meter without collector address Figure 31: Meter addresses duplicate To start the Wireless M-Bus network with the default settings, please press โ€™Start wireless M-Bus demoโ€™ and select the COM port related to the โ€™Data Collectorโ€™ device. Figure 32: COM Port selection Now press โ€™Nextโ€™ and select the meters which shall be used together with the collector board and press โ€™Finishโ€™. Figure 33: Select โ€™Smart Meterโ€™ meter After this, settings are stored in the data collectorโ€™s ๏ฌ‚ash memory. If the device was programmed correctly, the following dialog is shown. Quick Start Guide Version 1.02
  • 40. 5 WIRELESS M-BUS SUITE page 40 Figure 34: โ€™Data Collectorโ€™ programmed 5.5 Meter short description You can view the meter parameters by double clicking on the โ€™Smart Meterโ€™ in the navigation tree. The โ€™Smart Meterโ€™ editor is shown in the following ๏ฌgure. There are several options in the โ€™Meter con๏ฌgurationโ€™ window, which are grouped in different sections. These sections (e.g. โ€™Meter operationsโ€™ or โ€™Meter detailsโ€™) can be expanded individually. Figure 35: โ€™Smart Meterโ€™ Window Table 18 lists the parameters of the โ€™Smart Meterโ€™: Quick Start Guide Version 1.02
  • 41. 5 WIRELESS M-BUS SUITE page 41 Parameter Purpose Device address Address of the โ€™Smart Meterโ€™. Collector address Address of the โ€™Data Collectorโ€™, to which the โ€™Smart Meterโ€™ sends data. Encryption key The key encrypts the Wireless M-Bus wireless telegrams. Binding information This checkbox sets the โ€™Smart Meterโ€™ to the connected state. Time interval The time interval [ms] of periodical data. Table 18: โ€™Smart Meterโ€™ Parameters The โ€™Smart Meterโ€™ meter will send messages in the con๏ฌgured time interval. The โ€™Set binding informationโ€™ checkbox is used to set manual connections. Please refer to the manual of the Wireless M-Bus Suite for detailed information regarding this attribute. To start the network using the default settings, please press โ€™Start wireless M-Bus demoโ€™, select the COM port related to the โ€™Smart Meterโ€™ device. (refer to ๏ฌgure 32). Then press โ€™Finishโ€™ and the device will be programmed. If the device was programmed correctly, the following dialog is shown. Figure 36: โ€™Smart Meterโ€™ programmed In the demo project, the โ€™Smart Meterโ€™ sends a default packet to the collector every 10 seconds. 5.6 Using the Wireless M-Bus Suite This chapter describes speci๏ฌc device con๏ฌgurations and special functions of the Wireless M-Bus Suite. 5.6.1 Mode selection The โ€™Data Collectorโ€™ and the โ€™Smart Meterโ€™ window includes a โ€™Modeโ€™ selection box. The Wireless M-Bus mode can be selected here. The selection of the mode is necessary only in case of mode C or mode N. The following picture shows the mode selection boxes. Quick Start Guide Version 1.02
  • 42. 5 WIRELESS M-BUS SUITE page 42 Figure 37: Mode selection boxes The selection box can be ignored for modes S and T, as well as for a mode C meter device. If a C collector shall be used with a T meter, please set the meter to mode T ( as shown in ๏ฌgure 38). The reason is that the collector needs the information of the supported channels of the meter. Otherwise the collector will only be able to receive packets of the meter (RX), but is not able to send packets to the meter (TX). Figure 38: Collector C and Meter T Quick Start Guide Version 1.02
  • 43. 5 WIRELESS M-BUS SUITE page 43 For using the device in mode N the selection box must be used to select and con๏ฌgure the channel. The ๏ฌgure 39 shows an example for the mode Nb. Figure 39: Mode Nb example 5.6.2 Console The Console View displays the serrial communication ๏ฌ‚ow. Figure 40: Console View The commands available in the Console View are listed below. Quick Start Guide Version 1.02
  • 44. 5 WIRELESS M-BUS SUITE page 44 Command Name Description Clear Console Clears the currently active console. Display Selected Console Opens a listing of currently opened con- soles and allows to select the one to dis- play. Open Console Opens a new console of the selected type. Pin Console Pins the current console to remain on top of all other consoles. Scroll Lock Changes if scroll lock should be enabled or not in the current console. Text on/off Enables/Disables the serial text output. Table 19: Console View Commands The โ€™Text on/offโ€™ button enables or disables the text output for the serial commands (see ๏ฌgure 41). Figure 41: Console with serial text output enabled 5.7 Perform a ping test This chapter describes how to send a ping message to a device using the Wireless M-Bus Suite. A ping is a simple message over the UART interface which is used to verify if a ๏ฌrmware is available on the connected board. If your board responds to the ping request, a ๏ฌrmware is currently being executed. To send a ping message to your board, perform the following steps: Quick Start Guide Version 1.02
  • 45. 5 WIRELESS M-BUS SUITE page 45 1. Make sure that your device is connected to your PC properly. 2. Load the demo project as described in chapter 5.3. 3. Double click on the โ€™Data Collectorโ€™ device in the device tree. Press on the red framed button โ€™Write con๏ฌg to deviceโ€™ or โ€™Start wireless M-Bus demoโ€™ (refer ๏ฌgure 42). Figure 42: Write con๏ฌg to device 4. The wizard shown in ๏ฌgure 43 pops up. Con๏ฌgure the COM port settings to the correct COM port. Then press โ€™Start ping testโ€™. Figure 43: Start ping test Quick Start Guide Version 1.02
  • 46. 5 WIRELESS M-BUS SUITE page 46 The Wireless M-Bus Suite now tries to send a ping message to the device. If the connection settings are con๏ฌgured correctly and the ping test fails, the device does not execute a ๏ฌrmware and dialog 44 will pop up. In this case you have to load a ๏ฌrmware on your device, before you can perform the next steps in chapters 5.4 to 5.8. Figure 44: Ping test failed If the ping test is successful, the console window will show the communication of the ping request and the response of the board. Refer to ๏ฌgure 45. If the ping test is successful, you can stop the ping test with the โ€™Stop ping testโ€™ button. Figure 45: Ping test ok 5.8 Using the transmission tests Perform the following steps for the โ€™Data Collectorโ€™ collector: 1. Open Wireless M-Bus Suite 2. Load the demo project as described in chapter 5.3. 3. Open the โ€™Data Collectorโ€™ device by double clicking on the icon in the navigation tree. 4. Press โ€™Start wireless M-Bus demoโ€™ and select the COM port of the collector device. Quick Start Guide Version 1.02
  • 47. 5 WIRELESS M-BUS SUITE page 47 Figure 46: โ€™Start wireless M-Bus demoโ€™ button โ€™Data Collectorโ€™ 5. Press โ€™Nextโ€™ and set the checkbox for the โ€™Smart Meterโ€™ meter. (refer to ๏ฌgure 33) 6. Open the โ€™Smart Meterโ€™ device by double clicking on the icon in the navigation tree. 7. Press โ€™Start wireless M-Bus demoโ€™ and select the COM port of the meter device. Quick Start Guide Version 1.02
  • 48. 5 WIRELESS M-BUS SUITE page 48 Figure 47: โ€™Start wireless M-Bus demoโ€™ button โ€™Smart Meterโ€™ 8. Press โ€™Finishโ€™. The meter device will now send every time interval a message to the collector. Make sure that the โ€™Connection statusโ€™ is correct. The โ€™Data Collectorโ€™device will receive the data which is sent by the โ€™Smart Meterโ€™ meter. The RSSI value is displayed in a diagram, shown in ๏ฌgure 48. Quick Start Guide Version 1.02
  • 49. 5 WIRELESS M-BUS SUITE page 49 Figure 48: โ€™Data Collectorโ€™ Window You can also send a string from the โ€™Smart Meterโ€™ meter to the โ€™Data Collectorโ€™ collector. Input a message in the text ๏ฌeld and press โ€™Send dataโ€™. The โ€™Data Collectorโ€™will receive and display this message as shown in ๏ฌgure 49. Quick Start Guide Version 1.02
  • 50. 5 WIRELESS M-BUS SUITE page 50 Figure 49: Send data test Another test which you can perform is the โ€™RF-Testโ€™. Con๏ฌgure the transmission delay and press โ€™Run RF-Testโ€™ on the โ€™Smart Meterโ€™. The โ€™Smart Meterโ€™ will send a standard message to the โ€™Data Collectorโ€™ periodically. You can now use the Wireless M-Bus Suite to view the โ€™Smart Meterโ€™ which is sending data, and the โ€™Data Collectorโ€™, which is receiving data. This demonstration Wireless M-Bus network represents a star-network in an area with different device roles. Generally, the collector device is not intended to send custom data to a meter device. Quick Start Guide Version 1.02
  • 51. 5 WIRELESS M-BUS SUITE page 51 5.9 Wireless M-Bus Protocol Monitor Quick Start Guide The wireless M-Bus protocol monitor is a application to monitor wireless networks. It provides a full-featured web based capture monitor system. This document covers instructions for the use of wireless M-Bus protocol monitor. Please make sure to read the instructions carefully. If open questions remain after reading this manual, please contact STZEDN for support. Requirements: (a) The Wireless M-Bus device which contains the protocol monitor ๏ฌrmware. (b) A valid connection of the Wireless M-Bus device to the PC. (c) Wireless M-Bus Suite. Perform the following steps to start the wireless M-Bus protocol monitor: (1) Open Wireless M-Bus Suite. (2) Select โ€™Connect to protocol monitorโ€™ or โ€™Protocol Monitorโ€™ (refere to ๏ฌgure 50). Figure 50: Open the โ€™Wireless M-Bus Protocol Monitorโ€™ wizard (3) Choose the serial connection and press โ€™Nextโ€™. (See ๏ฌgure 51.) Quick Start Guide Version 1.02
  • 52. 5 WIRELESS M-BUS SUITE page 52 Figure 51: Select the serial connection (4) Select the protocol monitor device and press โ€™Nextโ€™ as shown in ๏ฌgure 52. Figure 52: Select the protocol monitor device (5) Select the mode and press โ€™Finishโ€™ as shown in ๏ฌgure 53. Figure 53: Select the protocol monitor device Quick Start Guide Version 1.02
  • 53. 5 WIRELESS M-BUS SUITE page 53 (6) Now the wireless M-Bus protocol monitor window will be opend. (7) To start capturing packets click on the green arrow at the top of the screen as shown in ๏ฌgure 54. Now all packets are captured from the protocol monitor device. If there are already some packets in the device buffer they are read, too. Figure 54: Wireless M-Bus Protocol Monitor For more informations read chapter 6. Quick Start Guide Version 1.02
  • 54. 6 WIRELESS M-BUS PROTOCOL MONITOR page 54 6 Wireless M-Bus Protocol Monitor 6.1 Introduction This document covers instructions for the use of wireless M-Bus protocol monitor. The ๏ฌrst chapter contains the speci๏ฌcations of the wireless M-Bus protocol monitor. A quick start guide follows, that describes in short terms how to get the protocol monitor into operation for the ๏ฌrst time. In the third part, the web interface, being the main user interface, is described. Especially focussing on the different views of captured data. 6.2 Wireless M-BUS protocol A Wireless M-Bus packet consists of several blocks. The ๏ฌrst block contains 12 bytes, the following blocks may contain up to 16 bytes. For each block, a 16 bit wide checksum of the current block is transmitted (2 bytes). Name Size (Byte) Description Length (L) 1 Number of packet bytes excluding the length ๏ฌeld and all CRCs. Type (C) 1 Packet type. Manufacturer Id (M) 2 ID of the manufacturer, according to DLMS. Type (A) 6 Address of the meter device. Checksum (CRC) 2 Checksum of the current block. Application Type (CI) 1 Type ๏ฌeld of the application layer. (Application Layer) x Data of the application layer Table 20: List of Wireles M-Bus ๏ฌelds. Figure 55: Example of a Wireless M-Bus packet. This document assumes that the reader is familiar with the Wireless M-Bus speci๏ฌcation, according to EN 13757 [9] and its application layer extensions of Open Metering System (OMS) [10] and the Dutch Smart Meter Requirements (DSMR). Otherwise, please contact STZEDN [11] for further documentation or training. Quick Start Guide Version 1.02
  • 55. 6 WIRELESS M-BUS PROTOCOL MONITOR page 55 6.3 Running the protocol monitor Figure 56: Starting and stopping the wireless M-Bus protocol monitor To start capturing packets click on the start button of the button bar at the top of the screen. Now all packets from the protocol monitor device are captured. If there are already some packets in the protocol monitor buffer they are read, too. To stop snif๏ฌng click on the stop button. This only stops receiving the packets of the browser application, the pro- tocol monitor device continues to capture all packets. This allows to run several instances of the protocol monitor application on several hosts. To start snif๏ฌng again click on the start button. To clear the screen click on the clear button. This action removes all cached packets of the browser application. 6.4 Packet View Figure 57: Packet View. In the packet view all received packets are shown from top to bottom as they are received over the air. New packets are appended at the bottom of the list, while the list scrolls up automatically over the time. Quick Start Guide Version 1.02
  • 56. 6 WIRELESS M-BUS PROTOCOL MONITOR page 56 One line represents one packet. Different blocks delimit the various ๏ฌelds of the protocol such as header and data sections. The ๏ฌrst four ๏ฌelds, however, contain data created by the protocol monitor: โ€ข Timestamp: This value contains the time the telegram was received by the protocol monitor device. The timestamp is calculated relatively to the current time of the web browser. A relative time stamp is being received by the protocol monitor device. โ€ข RSSI and LQI: These values describe the link quality of the received telegram. Read chapter 6.8 to get further information. Protocol sections not active for the selected packet are hidden. Each ๏ฌeld of the packet has two rows: โ€ข The name of the protocol section. โ€ข The data of the protocol section in hexadecimal notation. 6.5 CSV View Figure 58: CSV View. The delimiter character, which separates the ๏ฌelds is set by default to a semicolon โ€™;โ€™. However, you can enter a different character the input text ๏ฌeld "Delimiter". To change this ๏ฌeld enter your desired delimiter and press set. The delimiters are changed immediately. Quick Start Guide Version 1.02
  • 57. 6 WIRELESS M-BUS PROTOCOL MONITOR page 57 6.6 Statistics View Figure 59: Statistic View. The statistics view is used to group packets. Packets with the same ๏ฌeld values can be set up as statistic to get the overall count of the number of packets. To create a group select the ๏ฌeld of the drop down list in the header row and click on "Add group". Now all packets are grouped by this ๏ฌeld. To add further groups repeat this step. To remove a grouping ๏ฌeld, click on the red x behind the ๏ฌeld value of "Grouped by" line. The grouped packets are shown as tree view. If several groups are chosen, click on the [+] in front of the group name to display the subgroups of the current group. For faster opening or closing all groups click on the button "Expand all" or "Collapse all". The statistics view works independently of the other views. If all packets of the views cleared by pressing the clear button, the packets in the statistic are kept. Click on the button "Clear statistic" to clear the packets from the statistic view. 6.7 Timeline View Figure 60: Timeline View. Quick Start Guide Version 1.02
  • 58. 6 WIRELESS M-BUS PROTOCOL MONITOR page 58 Additionally to the main view, a second section provides additional information about the radio activity. In the timeline view, all received packets are displayed by ports and addresses. In the ๏ฌrst lines the activities on the ports are shown. The ports may represent different radio settings for the internal modules. Each coloured box marks an activity on the port. The next lines show the received packets categorised by their address. Selecting a packet in the timeline automatically selects it in the main window as well and vice versa. 6.8 Details View Figure 61: Detail View. The details view expands the protocol sections with further details as listed in the table or packet views. Additional protocol speci๏ฌc information are listed here for the currently selected packet. To display the details of a speci๏ฌc packet in the detail view, select any packet in either the packet view (chapter 6.4) or the time line view (chapter 6.7). The same packet will be selected across all views and its extended information in the detail view can be inspected. Quick Start Guide Version 1.02
  • 59. 6 WIRELESS M-BUS PROTOCOL MONITOR page 59 Moving the mouse over a speci๏ฌc packet highlights the packet in the different views without selection. For selection and packet detail investigation, left-clicking is necessary. 6.9 Filter View The wireless M-Bus protocol monitor allows to de๏ฌne ๏ฌlter rules to concentrate on packets of interest. E.g., it is possible to hide all packets of a special device. For de๏ฌning the ๏ฌlter rules open the tab "Filter". By default, one dummy ๏ฌlter is displayed. For each ๏ฌlter, the following options can be set: โ€ข The ๏ฌeld, to which the rule applies. โ€ข The logic operation the value is compared to (==, !=, >, <, >=, <=). โ€ข The value, which has to be used for comparison. Figure 62: De๏ฌning a ๏ฌlter. To set a ๏ฌlter press the button "Enable". The icon at the top of the screen is then switched to green. The rules are applied to all views and all received packets. If new packets are detected, they are stored to the local packet memory, but they will be only displayed, if they meet the ๏ฌlter rules. Consequently if the ๏ฌlter is disabled, older packets, which were ๏ฌltered out, appear then. If several rules shall be de๏ฌned, press "+" at the top of the ๏ฌlter tab. A further box to speci๏ฌy rules is opened. To combine multiple rules, select the desired operation next to the set-button: โ€ข AND: To display a packet, all rules have to be true. โ€ข OR: At least one rule has to be true to display the packet. Quick Start Guide Version 1.02
  • 60. 6 WIRELESS M-BUS PROTOCOL MONITOR page 60 Figure 63: De๏ฌning several rules. To remove a rule, select it by left-clicking and press the remove button "-". After a rule is changed, the button "Enable" has to be pressed to update the views. For disabling all ๏ฌlters, click "Disable". The icon at the top of the screen is then switched to red. 6.10 No warranty The wireless M-Bus protocol monitor is provided โ€œas isโ€ and use of it is at userโ€™s risk. STZEDN expressly disclaims all warranties, representations of conditions of any kind, express or implied or statutory, including but not limited to, any warranty of merchantable quality or ๏ฌtness for a particular purpose and any warranty that the protocol monitor is delivered free of any third party claims by way of infringement or otherwise. STZEDN does not warrant nor make any condition or representations that the functions contained in the protocol monitor will meet the requirements of the customer, that the operation of the protocol monitor will be uninterrupted nor error free that defects in the protocol monitor will be corrected. Further, STZEDN does not warrant or make any conditions or representations regarding the use or the results of the use of the protocol monitor in terms of its correctness, accuracy, reliability or otherwise. No oral or written information or advice given by STZEDN or others shall create a warranty, condition or representation or in any way extend the scope of the โ€œas is" provision of the protocol monitor. Quick Start Guide Version 1.02
  • 61. 7 DEMONSTRATION APPLICATION page 61 7 Demonstration Application 7.1 Introduction The following chapters specify the nomenclature and the usage of the different Wireless M-Bus Stack resources. Chapter 7.3 is a description of the demonstration application in general. Furthermore, chapters 7.4 to 7.6 show how the demonstration application can be downloaded to the EFM Starter Kit to run the application. Please note, that in this chaper โ€™deviceโ€™ and โ€™boardโ€™ are used as synonyms for the EFM Starter Kit. The Wireless M-Bus Stack from STZEDN is delivered in different assamblies: โ€ข Pre-compiled binary ๏ฌles. โ€ข Pre-compiled library sources which can be used with the IAR Workbench. โ€ข Source code IAR Workbench project. 7.2 The Wireless M-Bus Stack Nomenclature This chapter describes the nomenclature of the Wireless M-Bus Stack resources from STZEDN. 7.2.1 Pre-compiled Firmware Files 7.2.1.1 Wireless M-Bus Stack Firmware Files In general, the Wireless M-Bus Stack ๏ฌrmwares without a serial interface and without Wireless M-Bus Suite are made up of โ€ข the pre๏ฌx โ€™demoโ€™, โ€ข the name of the development board, โ€ข the corresponding transceiver, โ€ข the device type, โ€ข and the Wireless M-Bus mode. Feel free to change the names of the ๏ฌrmware ๏ฌles. These ๏ฌrmware ๏ฌles are generated by the project in chapter 7.2.3.2. Quick Start Guide Version 1.02
  • 62. 7 DEMONSTRATION APPLICATION page 62 Name Transceiver Type Mode File Name EFM32LG990 SI446X Collector c2 demo_efm32lg990_si446x_collector_c2.bin EFM32LG990 SI446X Collector n2 demo_efm32lg990_si446x_collector_n2.bin EFM32LG990 SI446X Collector s2 demo_efm32lg990_si446x_collector_s2.bin EFM32LG990 SI446X Collector t2 demo_efm32lg990_si446x_collector_t2.bin EFM32LG990 SI446X Meter c2 demo_efm32lg990_si446x_meter_c2.bin EFM32LG990 SI446X Meter n2 demo_efm32lg990_si446x_meter_n2.bin EFM32LG990 SI446X Meter s2 demo_efm32lg990_si446x_meter_s2.bin EFM32LG990 SI446X Meter t2 demo_efm32lg990_si446x_meter_t2.bin Table 21: Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles without a serial interface and without Wireless M-Bus Suite. In general, the Wireless M-Bus Stack ๏ฌrmwares with a serial interface and with Wireless M-Bus Suite are made up of โ€ข the pre๏ฌx โ€™serialโ€™, โ€ข the name of the development board, โ€ข the corresponding transceiver, โ€ข the device type, โ€ข and the Wireless M-Bus mode. Feel free to change the names of the ๏ฌrmware ๏ฌles. These ๏ฌrmware ๏ฌles are generated by the project in chapter 7.2.3.4. Please note, that all serial Wireless M-Bus Stack ๏ฌrmwares use 115200 baud. Name Transceiver Type Mode File Name EFM32LG990 SI446X Collector c2 serial_efm32lg990_si446x_collector_c2.bin EFM32LG990 SI446X Collector n2 serial_efm32lg990_si446x_collector_n2.bin EFM32LG990 SI446X Collector s2 serial_efm32lg990_si446x_collector_s2.bin EFM32LG990 SI446X Collector t2 serial_efm32lg990_si446x_collector_t2.bin EFM32LG990 SI446X Meter c2 serial_efm32lg990_si446x_meter_c2.bin EFM32LG990 SI446X Meter n2 serial_efm32lg990_si446x_meter_n2.bin EFM32LG990 SI446X Meter s2 serial_efm32lg990_si446x_meter_s2.bin EFM32LG990 SI446X Meter t2 serial_efm32lg990_si446x_meter_t2.bin Table 22: Nomenclature of the Wireless M-Bus Stack ๏ฌrmware ๏ฌles with a serial interface and with Wireless M-Bus Suite. 7.2.2 Wireless M-Bus Stack Libraries In general, the library ๏ฌle names are made up of โ€ข the name of the development board, โ€ข the corresponding transceiver, Quick Start Guide Version 1.02
  • 63. 7 DEMONSTRATION APPLICATION page 63 โ€ข the device type, โ€ข and the Wireless M-Bus mode. Name Transceiver Type Mode Type EFM32LG990 SI446X Collector c2 EFM32LG990_SI446X_Collector_C2.a EFM32LG990 SI446X Collector n2 EFM32LG990_SI446X_Collector_N2.a EFM32LG990 SI446X Collector s2 EFM32LG990_SI446X_Collector_S2.a EFM32LG990 SI446X Collector t2 EFM32LG990_SI446X_Collector_T2.a EFM32LG990 SI446X Meter c2 EFM32LG990_SI446X_Meter_C2.a EFM32LG990 SI446X Meter n2 EFM32LG990_SI446X_Meter_N2.a EFM32LG990 SI446X Meter s2 EFM32LG990_SI446X_Meter_S2.a EFM32LG990 SI446X Meter t2 EFM32LG990_SI446X_Meter_T2.a Table 23: Nomenclature of the Wireless M-Bus Stack library ๏ฌles 7.2.3 IAR Projects and Con๏ฌgurations It is possible to open all IAR projects with the project ๏ฌle: Project Name: Complete_efm32lg990_si446x.eww 7.2.3.1 Library Build IAR Workbench Project The library build project produces the Wireless M-Bus Stack libraries for the different Wireless M-Bus network devices and the different Wireless M-Bus modes. The project contains all con๏ฌgurations with the type and mode correspond- ing settings listed in table 24. Project Name: Lib_Build_efm32lg990_si446x.ewp Type Mode Con๏ฌguration Name Collector c2 Lib_Build_EFM32LG990_SI446X_Collector_C2 Collector n2 Lib_Build_EFM32LG990_SI446X_Collector_N2 Collector s2 Lib_Build_EFM32LG990_SI446X_Collector_S2 Collector t2 Lib_Build_EFM32LG990_SI446X_Collector_T2 Meter c2 Lib_Build_EFM32LG990_SI446X_Meter_C2 Meter n2 Lib_Build_EFM32LG990_SI446X_Meter_N2 Meter s2 Lib_Build_EFM32LG990_SI446X_Meter_S2 Meter t2 Lib_Build_EFM32LG990_SI446X_Meter_T2 Table 24: Con๏ฌguration Names of the Library Build porject 7.2.3.2 Library Usage IAR Workbench Project The library usage project includes the Wireless M-Bus Stack libraries. The customer can use this project to program own applications based on the Wireless M-Bus Stack libraries. A sample main ๏ฌle for the meter and the collector device is included in the project to quickly setup a wireless communication. The project contains all con๏ฌgurations with the type and mode corresponding settings listed in table 25. Quick Start Guide Version 1.02
  • 64. 7 DEMONSTRATION APPLICATION page 64 Project Name: Lib_Use_efm32lg990_si446x.ewp Collector Main File: app_aplmain_collector.c Meter Main File: app_aplmain_meter.c Con๏ฌguration File: app_aplstzedn_wmbus_global.h Type Mode Con๏ฌguration Name Collector c2 Lib_Use_EFM32LG990_SI446X_Collector_C2 Collector n2 Lib_Use_EFM32LG990_SI446X_Collector_N2 Collector s2 Lib_Use_EFM32LG990_SI446X_Collector_S2 Collector t2 Lib_Use_EFM32LG990_SI446X_Collector_T2 Meter c2 Lib_Use_EFM32LG990_SI446X_Meter_C2 Meter n2 Lib_Use_EFM32LG990_SI446X_Meter_N2 Meter s2 Lib_Use_EFM32LG990_SI446X_Meter_S2 Meter t2 Lib_Use_EFM32LG990_SI446X_Meter_T2 Table 25: Con๏ฌguration Names of the Library Usage porject 7.2.3.3 Source Code IAR Workbench Project with serial interface disabled The source code project contains all source ๏ฌles from the Wireless M-Bus Stack. A sample main ๏ฌle for the meter and the collector device is included in the project to quickly setup a wireless communication. The project contains all con๏ฌgurations with the type and mode corresponding settings listed in table 26. Project Name: Debug_Demo_efm32lg990_si446x.ewp Collector Main File: app_aplmain_collector.c Meter Main File: app_aplmain_meter.c Con๏ฌguration File: app_aplstzedn_wmbus_global.h Type Mode Con๏ฌguration Name Collector c2 Debug_Demo_EFM32LG990_SI446X_Collector_C2 Collector n2 Debug_Demo_EFM32LG990_SI446X_Collector_N2 Collector s2 Debug_Demo_EFM32LG990_SI446X_Collector_S2 Collector t2 Debug_Demo_EFM32LG990_SI446X_Collector_T2 Meter c2 Debug_Demo_EFM32LG990_SI446X_Meter_C2 Meter n2 Debug_Demo_EFM32LG990_SI446X_Meter_N2 Meter s2 Debug_Demo_EFM32LG990_SI446X_Meter_S2 Meter t2 Debug_Demo_EFM32LG990_SI446X_Meter_T2 Table 26: Con๏ฌguration Names of the Debug porject with serial interface disabled Quick Start Guide Version 1.02
  • 65. 7 DEMONSTRATION APPLICATION page 65 7.2.3.4 Source Code IAR Workbench Project with serial interface enabled The source code project contains all source ๏ฌles from the Wireless M-Bus Stack. A sample main ๏ฌle for the meter and the collector device is included in the project to quickly setup a wireless communication. The project contains all con๏ฌgurations with the type and mode corresponding settings listed in table 27. Please note, that there is one shared main ๏ฌle for the collector and meter. Project Name: Debug_Serial_efm32lg990_si446x.ewp Collector Main File: app_serialstzedn_app_serial.c Meter Main File: app_serialstzedn_app_serial.c Con๏ฌguration File: app_serialstzedn_wmbus_global.h Type Mode Con๏ฌguration Name Collector c2 Debug_Serial_EFM32LG990_SI446X_Collector_C2 Collector n2 Debug_Serial_EFM32LG990_SI446X_Collector_N2 Collector s2 Debug_Serial_EFM32LG990_SI446X_Collector_S2 Collector t2 Debug_Serial_EFM32LG990_SI446X_Collector_T2 Meter c2 Debug_Serial_EFM32LG990_SI446X_Meter_C2 Meter n2 Debug_Serial_EFM32LG990_SI446X_Meter_N2 Meter s2 Debug_Serial_EFM32LG990_SI446X_Meter_S2 Meter t2 Debug_Serial_EFM32LG990_SI446X_Meter_T2 Table 27: Con๏ฌguration Names of the Debug porject with serial interface enabled Please note, that all serial Wireless M-Bus Stack con๏ฌgurations use 115200 baud. 7.3 The Demonstration Application 7.3.1 Introduction The demonstration application builds up a wireless network with two network devices - a collector and a meter device. Thus, the application needs two EFM Starter Kits. Figure 64 shows the basic setup. The ๏ฌrst step is to download the collector and the meter ๏ฌrmware to the EFM Starter Kits. Refer to chapters 7.4 to 7.6 to get detailed information about how to download a ๏ฌrmware to the boards. Quick Start Guide Version 1.02
  • 66. 7 DEMONSTRATION APPLICATION page 66 Figure 64: Demonstration Application There are two different setups to run the demonstration application. One setup runs without the Wireless M-Bus Suite (refer to chapter 7.3.2) and one setup with it (refer to chapter 7.3.3) 1 . The Wireless M-Bus Stack ๏ฌrmware differs for the two setups. Please make sure to se- lect the correct ๏ฌrmware ๏ฌles. Refer to chapter 7.2 for details about the nomenclature of the ๏ฌrmware ๏ฌles or IAR projects. 7.3.2 Demonstration Application without Wireless M-Bus Suite In this setup, the demonstration application works without the optional serial interface and thus, without Wireless M-Bus Suite. The following Wireless M-Bus Stack ๏ฌrmware ๏ฌles or projects are applicable: โ€ข The pre-compiled Wireless M-Bus Stack ๏ฌrmware ๏ฌles in chapter 7.2.1, table 21. Refer to chapter 4.2.1 for details about downloading a binary ๏ฌrmware ๏ฌle to a EFM Starter Kit. โ€ข The IAR Workbench project in chapter 7.2.3.2 or the project in chapter 7.2.3.3. Refer to chapter 4.2.2 for details about downloading an IAR Workbench Project to a EFM Starter Kit. If the demonstration application is installed on both boards, the meter device starts sending sample data packets to the collector device. 1 It is recommended to use the USB interface as power supply. If the EFM Starter Kits are powered with batteries, the display may not work correctly. Quick Start Guide Version 1.02
  • 67. 7 DEMONSTRATION APPLICATION page 67 7.3.3 Demonstration Application with Wireless M-Bus Suite The Wireless M-Bus Suite (refer to chapter 5) can be used to control the demonstration application on both boards via the serial interface. In the Wireless M-Bus demonstration application without Wireless M-Bus Suite, the meter device sends a telegram to the collector device in a de๏ฌned time interval. Please note, that the serial demonstration application is limited in the number of supported meter devices. There are many advantages and extensions for the demonstration application, which allow fast and easy wireless communications, if Wireless M-Bus Suite is used: โ€ข Perform an RF-Test. โ€ข Set serveral user telegrams and send them from the meter to the collector device. โ€ข Perform a bidirectional communication. โ€ข Communication with and without encryption. โ€ข Access to internal parameters of the devices. E.g. in case of a collector device the โ€™Received Signal Strength Indicationโ€™ value is displayed for a speci๏ฌc meter. โ€ข Access to the serial console. Thus, all commands from the serial speci๏ฌcation from STZEDN can be send to the devices. โ€ข Create fast and easily own Wireless M-Bus con๏ฌgurations. โ€ข Wireless M-Bus Suite supports Wireless M-Bus Stack sniffer (refer to chapters 5.9 and 6 ). โ€ข Wireless M-Bus Suite includes an AES encryption and decryption tool. โ€ข Download binary ๏ฌrmware ๏ฌles to the EFM Starter Kits, to switch or update applications, if a bootloader is available. The following Wireless M-Bus Stack ๏ฌrmware ๏ฌles or projects are applicable: โ€ข The pre-compiled Wireless M-Bus Stack ๏ฌrmware ๏ฌles in chapter 7.2.1, table 22. Refer to chapter 4.2.1 for details about downloading a binary ๏ฌrmware ๏ฌle to a EFM Starter Kit. โ€ข The IAR Workbench project in chapter 4.2.1. Refer to chapter 4.2.2 for details about downloading an IAR Workbench Project to a EFM Starter Kit. 7.4 Download Binary Files This chapter describes how to prepare the the demonstration application of the Wireless M-Bus Stack from STZEDN with a pre-compiled ๏ฌrmware, delivered as a โ€™*.binโ€™ binary ๏ฌle. To start the demonstration application, the Wireless M-Bus Stack ๏ฌrmware must be downloaded to the EFM Starter Kits. The ๏ฌrmware ๏ฌles in chapter 7.2.1, table 21 and table 22, are applicable. To upload the ๏ฌrmware, please perform the steps in chapter 4.2.1. Quick Start Guide Version 1.02
  • 68. 7 DEMONSTRATION APPLICATION page 68 Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kits. 7.5 The Wireless M-Bus Stack as Library This chapter describes the usage of the Wireless M-Bus Stack as library. Regarding the libraries, there are two IAR Workbench projects available. The project in chapter 7.2.3.1 builds the Wireless M-Bus Stack libraries. The project in chapter 7.2.3.2 uses the libraries to setup an application project. If you want to build the libraries, go to chapter 7.5.1. If the libraries should be built, please refer to chapter 7.5.2. Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kit. Refer to chapter 4.2.2 for more detailed information about uploading an IAR Workbench project to the EFM Starter Kits. 7.5.1 Build Libraries The corresponding IAR Workbench project is the โ€™lib_buildโ€™ project in chapter 7.2.3.1. The purpose of the project is only to build Wireless M-Bus Stack libraries. Thus, there are no main ๏ฌles necessary. The project contains all precon๏ฌgured con๏ฌguration for the different Wireless M-Bus types and modes. Refer to table 23 in chapter 7.2.2 for detailed information about the nomenclature of the library ๏ฌles. Please note, that the serial interface is disabled in all project con๏ฌgurations. 7.5.2 Use Libraries The corresponding IAR Workbench project is the โ€™lib_useโ€™ project in chapter 7.2.3.2. The purpose of this project is to use the Wireless M-Bus Stack libraries to develop applications. For a fast and easy development, the project contains sample main ๏ฌles for the meter and the collector device which implement the demonstration application. The user can change and extend these ๏ฌles for own applications. The project contains precon๏ฌgured con๏ฌgurations for all supported Wireless M-Bus types and modes. Please make sure to include the correct library ๏ฌle for the intended Wireless M-Bus type and mode. Please note that the serial interface is disabled in all project con๏ฌgurations. 7.6 The Wireless M-Bus Stack as Source Code The corresponding IAR Workbench projects are described in chapter 7.2.3.3 and chapter 7.2.3.4. In the ๏ฌrst project, the serial interface is enabled. In the second project, the serial interface is disabled. However, these projects support full access to every source ๏ฌle at each communication layer of the Wireless M-Bus Stack from STZEDN. Thus, the user is able to change e.g. the availibility of the serial interface. Quick Start Guide Version 1.02
  • 69. 7 DEMONSTRATION APPLICATION page 69 Please note, that changes in the source code can have major impact on the prin- ciple of operation of the Wireless M-Bus Stack. Please perform changes on the source code only, if you are completly con๏ฌdent about the impacts. There is no support from STZEDN to projects with changed source code (The only exception to this restriction are the main application ๏ฌles and the con๏ฌguration header ๏ฌle, stzedn_wmbus_global.h). Please make sure, that the following requirements are ful๏ฌlled: Number Description 1 The function stzedn_tmr_tick() must be called 2000 times per second. 2 The microcontroller main clock must be fast enough to ensured that the timings in the bidirectional communication can be hold. Table 28: Wireless M-Bus Stack Requirements Please refer to chapter 7.3 for a description of the demonstration application on the EFM Starter Kit. Refer to chapter 4.2.2 to get detailed information about uploading an IAR Workbench project to the EFM Starter Kits. Quick Start Guide Version 1.02
  • 70. 8 CONTACT INFORMATION page 70 8 Contact information In case of questions, requests for quotations or ideas for further improvements, please contact: Steinbeis Transfer Center for Embedded Design and Networking (STZEDN) Poststrasse 35 D-79423 Heitersheim Germany Tel: +49 7634-6949-340 Fax: +49 7634-5049-886 Url: http://www.stzedn.de/smart-metering.html E-mail: metering@stzedn.de Quick Start Guide Version 1.02
  • 71. REFERENCES page 71 References [1] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 1: Data exchange; English version EN 13757-1, 2002. [2] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 2: Physical and link layer; English version EN 137572, 2004. [3] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 3: Dedicated application layer; English version EN 137573, 2004. [4] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 4: Wireless meter readout (Radio meter reading for operation in the 868 MHz to 870 MHz SRD band); German version EN 137574, 2005. [5] โ€œCommunication systems for meters and remote reading of meters.โ€ Part 5: Wireless Relaying; English version prEN 13757-5, 2009. [6] โ€œTelecontrol equipment and systems.โ€ Part 5: Transmission protocols; EN 870-5, 2002. [7] โ€œOpen metering system speci๏ฌcation - volume 2: Primary communication.โ€ http://www.oms- group.org/download/OMS-Spec_Vol2_Primary_v301.pdf, 2011. [8] S. Labs, โ€œSimplicity studio homepage, "http://www.energymicro.com/software/simplicity-studio".โ€ [9] โ€œEuropean committee for standardization.โ€ [Online; accessed 15-December-2011] http://www.cen.eu. [10] โ€œOms-group.โ€ [Online; accessed 15-December-2011] http://www.oms-group.org. [11] โ€œSteinbeis transfer center for embedded design and networking.โ€ [Online; accessed 15-December-2011] http://www.stzedn.de. Quick Start Guide Version 1.02