A Wireless Billboard Channel over Digital Video Broadcasting-Handheld Platform

By

Zhanlin Ji

B. Eng, Beijing Institute of Technology M.Eng, Dublin City University M.Sc, Beijing University of Posts and Telecommunications

A doctoral thesis submitted in partial fulfilment of the requirement for the award of Doctor of Philosophy at the University of Limerick

Supervisors Dr. Ivan Ganchev, Dr. Máirtín O'Droma Telecommunications Research Centre Department of Electronic & Computer Engineering University of Limerick

A Wireless Billboard Channel over Digital Video Broadcasting-Handheld Platform

Zhanlin Ji, B. Eng, M.Eng, M.Sc The research work was carried under supervision and direction of Dr. Ivan Ganchev, Dr. Máirtín O'Droma University of Limerick

Declaration

This thesis is presented in partial fulfilment of the requirements for a PhD.

It is entirely my own work and has not been submitted to any other University or higher education institution, or for any other academic award in this University. Where use has been made of the work of other people it has been fully acknowledged and fully referenced.

Signed: Date: Zhanlin Ji

Student ID: 0622052

ii

A Wireless Billboard Channel over Digital Video Broadcasting-Handheld Platform

Zhanlin Ji, B. Eng, M.Eng, M.Sc The research work was carried under supervision and direction of Dr. Ivan Ganchev, Dr. Máirtín O'Droma University of Limerick

Abstract

Wireless Billboard Channels (WBCs) are a proposal for novel broadcast advertisement channel which will be integral to realising the Consumer-centric Business Model (CBM) within the new emerging Ubiquitous Consumer Wireless World (UCWW), their primary goal of facilitating the service of Advertisement, Discovery and Association (ADA) of wireless access networks and teleservices in the UCWW. In the principal research presented in this thesis the author has investigated the conceptualisation, design, implementation and testing of a WBC established over a Digital Video Broadcasting – Handheld (DVB-H) platform. The thesis addresses how realising this goal the following objectives were successfully achieved in the research work and are described in the thesis:  The creation of a foundational WBC infrastructure.  The elaboration of a WBC framework, interface and protocol architecture.  The development of a fully operational WBC system prototype.  The investigation and implementation of suitable WBC carrier technologies. The WBC system proposed and designed has been developed along three architectural layers – physical, link and service layers. In designing the service layer, to achieve an extensible, flexible, configurable and maintainable system, the WBC Service Provider (WBC-SP) and Mobile User (MU)’s software architecture has been proposed. A number of intelligent algorithms have been developed for advertisement’s collecting, clustering, scheduling, indexing, discovery and association in Multi-Agents System (MAS) environment. A new WBC Advertisements Delivery Protocol (ADP) has been designed and developed for delivering advertisement over unidirectional WBCs to MU simultaneously. In the link layer, and specifically dictated by DVB-H link layer conditions, a novel cross-layer Multi-Protocol Encapsulation - Forward Error Correction (MPE-FEC) coding and decoding schemes were proposed for improving reliability. Realising the DVB-H physical layer was achieved through a specially constructed laboratory testbed infrastructure, using a DVB-H physical layer simulator. Besides the design and implementation of this layered, distributed, intelligent, and heterogeneous WBCs system, the research work included the proofing and refining of aspects of the designs. Also carried out was the operational testing, performance evaluation and scalability evaluation of the core WBCs elements. WBC carrier technologies other than DVB-H were also explored, e.g. Terrestrial- Digital Multimedia Broadcasting (T-DMB). The work has yielded over 20 internationally published research papers to date, including one in the IEEE Transactions on Consumer Electronics and two in EURASIP Journal on Wireless Communications and Networking.

iii

ACKNOWLEDGEMENTS

I would like to express my sincere thanks to my supervisors Dr. Ivan Ganchev and Dr. Máirtín O'Droma for all their guidance, patience, support and advice. I could not have asked for any more.

Thanks go to the following for their financial support:  Telecommunications Research Centre, University of Limerick.  Science Foundation Ireland (SFI) Basic Research Grant (Ref. No 04/BR/E0082).  SFI Equipment Call 2007 for the funding of a DVB-H “All-in-One” Testbed (Ref. No. 04/BR/E0082/EC07).  University of Limerick (UL) ‘seed’ Funding Programme 2008 for purchasing the POD-1100 DVB-H demodulator.  The Embark Initiative, who fund this research through the Irish Research Council for Science, Engineering and Technology (IRCSET) postgraduate Research Scholarship Scheme.

Special thanks also to my wife Xiuli Quan and my daughter Hongyu Ji, for encouraging me in all stages of this work.

iv Table of Contents

TABLE OF CONTENTS

Author’s Declaration ...... ii Abstract ...... iii Acknowledgements ...... iv Table of Contents ...... v List of Figures ...... viii List of Tables ...... xi List of Abbreviations ...... xii Chapter 1. Introduction ...... 1 1.1. Research Objectives ...... 2 1.2. The Novel Contributions of the Research ...... 4 1.3. Literature Survey ...... 4 1.4. The Structure of the Thesis ...... 5 1.5. Publications Arising from This Work ...... 6 1.6. Conclusion ...... 6 Chapter 2. Wireless Billboard Channels: Motivation and Concepts ...... 7 2.1. Introduction ...... 7 2.2. Ubiquitous Consumer Wireless World (UCWW) ...... 7 2.2.1. Always Best Connected and best Served (ABC&S) ...... 8 2.2.2. Consumer-centric Business Model (CBM) ...... 8 2.3. Wireless Billboard Channels (WBCs) ...... 10 2.3.1. Motivation ...... 10 2.3.2. WBC Service Discovery Protocols ...... 11 2.3.3. WBC Concept and Characteristics ...... 13 2.3.4. WBC Service Discovery Model ...... 15 2.4. Conclusion ...... 21 Chapter 3. WBC System Architecture ...... 22 3.1. Introduction ...... 22 3.2. System Architecture ...... 23 3.3. WBC Service Layer ...... 25 3.3.1. WBC Service Description Model ...... 25 3.3.2. WBC Application Enabler Sub-Layer ...... 27 3.3.3. WBC Service Enabler Sub-Layer ...... 38 3.4. WBC Link Layer ...... 39 3.4.1. Time Slicing ...... 40 3.4.2. MPE-FEC Frame ...... 42 3.4.3. Link Layer PDU Encapsulation ...... 42 3.4.4. Software and Hardware Solutions ...... 44 3.5. WBC Physical Layer ...... 44 3.5.1. Software and Hardware Solutions ...... 46 3.5.2. Wireless Fading Channels ...... 46 3.5.3. Other Carriers ...... 46 3.6. Conclusion ...... 47 Chapter 4. WBC service layer – WBC-SP side’s Design and Implementation ...... 48 4.1. Introduction ...... 48 4.2. Design and Implementation of SDs Encoder ...... 48 4.3. Architectural Design of Application Enabler Sub-Layer ...... 51 4.3.1. Design of Service Discovery and Maintenance Tier ...... 53 4.3.2. Design of Application Tier ...... 55 4.3.3. Design of MAS Container Tier ...... 66 4.4. Implementation of Application Enabler Sub-Layer ...... 67 4.4.1. Implementation of Service Discovery and Maintenance Tier ...... 67

v Table of Contents

4.4.1. Implementation of User Interface (UI) ...... 71 4.4.2. Implementation of Application Tier ...... 75 4.4.3. Implementation of MAS Container Tier ...... 75 4.5. Design and Implementation of Advertisements Delivery Protocol (ADP) ...... 78 4.5.1. WBC-ADP Encoding and Decoding ...... 79 4.5.2. ADP Message Format ...... 80 4.5.3. ADP Implementation ...... 81 4.6. Conclusion ...... 84 Chapter 5. WBC Service Layer - User Side’s Design and Implementation ...... 86 5.1. Introduction ...... 86 5.2. Design and Implementation of SDs Decoder ...... 86 5.3. Architecture Design of Application Enabler Sub-Layer on User Side ...... 86 5.4. Design and Implementation of iWBC Content Provider ...... 89 5.4.1. iWBC Light-weight HTTP Container ...... 89 5.4.2. iWBC Content Manager ...... 90 5.5. iWBC UIs Design and Implementation ...... 93 5.5.1. Architecture ...... 93 5.5.2. iWBC JADE ...... 93 5.5.3. iWBC Client Profiles ...... 96 5.5.4. iWBC-UI Packages Structure ...... 97 5.5.5. iWBC-JSE UI Implementation ...... 99 5.5.6. iWBC-MIDP UI Implementation ...... 101 5.5.7. iWBC-Android UI Implementation ...... 104 5.6. Conclusion ...... 108 Chapter 6. ‘WBC over DVB-H’ Link layer Design and Implementation ...... 109 6.1. Introduction ...... 109 6.2. Software Design and Implementation ...... 109 6.2.1. Encapsulating and Encoding Schemes ...... 109 6.2.2. Decapsulating and Decoding Schemes ...... 111 6.3. Hardware Testbed’s Design and Implementation ...... 113 6.3.1. WBC-SP Side ...... 114 6.3.2. User Side ...... 117 6.4. Conclusion ...... 121 Chapter 7. ‘WBC over DVB-H’ Physical layer Design and Implementation ...... 122 7.1. Introduction ...... 122 7.2. Software Design and Implementation ...... 122 7.2.1. Transmitter ...... 123 7.2.2. Channel ...... 125 7.2.3. Receiver...... 126 7.3. Hardware Design and Implementation ...... 126 7.3.1. WBC-SP Side ...... 127 7.3.2. User Side ...... 128 7.4. Conclusion ...... 130 Chapter 8. ‘WBC over DVB-H’ Performance Evaluation and Results ...... 131 8.1. Introduction ...... 131 8.2. 2SRL Model for Physical Layer Simulation ...... 131 8.2.1. Two-State Run Length Model (2SRL) ...... 132 8.2.2. 2SRL Parameters in 'WBC over DVB-H' Chi-Square Central (Rayleigh) Fading Channel ...... 134 8.2.3. 2SRL Implementation ...... 138 8.3. Physical Layer Evaluation ...... 139 8.3.1. AWGN Channel ...... 139 8.3.2. Rayleigh Fading Channel ...... 140 8.4. Link Layer Evaluation ...... 142 8.4.1. IP Packet Error Rate (IPER) and Segment Error Rate (SER) ...... 142 8.4.2. ‘WBC over DVB-H’ Overhead Efficiency ...... 147 8.5. Service Layer Evaluation ...... 151

vi Table of Contents

8.5.1. Tuning Time ...... 151 8.5.2. Access Time ...... 152 8.6. Conclusion ...... 153 Chapter 9. Conclusions ...... 154 9.1. Introduction ...... 154 9.2. Main Research Goal Achieved ...... 154 9.2.1. On WBC Service Layer ...... 154 9.2.2. On WBC Link Layer ...... 154 9.2.3. On WBC physical Layer ...... 155 9.3. Conclusion ...... 155 9.4. Future Work ...... 162 Reference ...... 165 Appendix A An Example of SD on WBC: Structure, Encoding and Decoding ...... 179 A.1. Introduction ...... 179 A.2. ASN.1 Notation ...... 179 A.3. SD’s POJO ...... 181 A.4. Software Architecture for Encoding and Decoding ...... 185 A.4.1 SD Encoding Design on WBC-SP Node ...... 185 A.4.2 SD Decoding Design on MU Node ...... 186 A.5. Conclusion ...... 187 Appendix B Broadcast Disks ...... 188 B.1. Introduction ...... 188 B.2. Algorithm ...... 188 B.3. Proof of Formula 4.1 ...... 189 B.4. Conclusion ...... 189 Appendix Wireless Billboard Channels over T-DMB ...... 190 C.1. Introduction ...... 190 C.2. T-DMB Transmission Frame ...... 191 C.2. 'WBC over T-DMB' IPDC Mode ...... 191 C.3. Software Testbed Design ...... 192 C.3.1 Transmitter ...... 193 C.3.1.1 Source ...... 193 C.3.1.2 Encoder and Interleaver ...... 193 C.3.1.3 Modulator ...... 194 C.3.2 Receiver ...... 194 C.4. Results ...... 195 C.5. Conclusion ...... 197 Appendix D Project Development Environment ...... 198 D.1. Introduction ...... 198 D.2. WBC Service Layer – SP Side Software Environment ...... 198 D.2.1 WBC-SP Enterprise Distributed Application ...... 198 D.2.2 WBC-SP Portal Application ...... 199 D.2.3 ADP Application ...... 199 D.3. WBC Service Layer – User Side Software Environment ...... 201 D.3.1 iWBC Content Provider ...... 201 D.3.2 Receiver ...... 201 D.3.2.1 iWBC-JSE ...... 201 D.3.2.2 iWBC-MIDP ...... 202 D.3.2.3 iWBC-Android ...... 203 D.4. ‘WBC over DVB-H’ Link Layer and Physical Layer Software Environment ...... 203 D.5. Conclusion ...... 204 Appendix E Zhanlin Ji’s List of Relevant Publications ...... 205

vii List of Figures

LIST OF FIGURES

Figure 2.1: An Example of Heterogeneous Networking Wireless World ...... 8 Figure 2.2: An Example of CBM-based UCWW Environment ...... 10 Figure 2.3: Model Used by: (a) Jini, SLP, Salutation and (b) WBC [1] ...... 13 Figure 2.4: The WBCs Hierarchy ...... 14 Figure 2.5: Generic Service Classification [97] ...... 16 Figure 3.1: The WBC Layered Model ...... 22 Figure 3.2: The WBC System Infrastructure ...... 24 Figure 3.3: The WBC Service Layer Model ...... 25 Figure 3.4: The Java Technology’s Editions ...... 28 Figure 3.5: The JAVA EE Environment ...... 29 Figure 3.6: The Light-weight Design of the iWBC Content Provider ...... 32 Figure 3.7: The GWT Client HTML and JavaScript Generating Steps ...... 32 Figure 3.8: The Android Software Stack [41] ...... 33 Figure 3.9: The MIDP Architecture...... 35 Figure 3.10: The JADE Architecture ...... 36 Figure 3.11: The ReteOO System ...... 38 Figure 3.12: The Conceptual Scheme of the 'WBC over DVB-H' Link Layer ...... 40 Figure 3.13: The Use of Time-Slicing for 'WBC over DVB-H' ...... 41 Figure 3.14: The 'WBC over DVB-H' Link Layer PDU Encapsulation ...... 43 Figure 3.15: The Functional Block Diagram of the ‘WBC over DVB-H’ Physical Layer [70] ...... 45 Figure 4.1: The ASN.1-PER Encoding/Decoding of SDs ...... 49 Figure 4.2: The Class Diagram of AWBCTSASMS and WBCTSSMS ...... 50 Figure 4.3: The Class Diagram of Encoding_TSASMS ...... 51 Figure 4.4: The WBC Application Enabler Sub-Layer's (WBC-SP Side) Architecture ...... 52 Figure 4.5: The Architecture of the Presentation Sub-Tier (WBC-SP Side) ...... 54 Figure 4.6: The Business Delegate Concept of the Business Sub-Tier ...... 55 Figure 4.7: The WBC Rule-based Expert System ...... 56 Figure 4.8: The Hot WBC segments Scheduling Algorithm for Example 2 ...... 63 Figure 4.9: The Cold WBC segments Scheduling Model for Example 2 ...... 64 Figure 4.10: The Final WBC segment Broadcasting Sequence for Example 2 ...... 64 Figure 4.11: The Generic Format of the WBC Broadcasting Cycle ...... 65 Figure 4.12: The JVM Invoking the ADP API for IPDC ...... 66 Figure 4.13: The Personal Profile Agent's Model ...... 67 Figure 4.14: A Use Case View of the Service Discovery and Maintenance Tier (WBC-SP Side) ...... 69 Figure 4.15: The UML Diagrams of (a) BaseDaoHibernate; (b) BaseManager; (c) BaseAction...... 70 Figure 4.16: The UI Java Class Dependencies UML Diagram ...... 71 Figure 4.17: The WBC-SP UI Portal. (a) Server Starter; (b) Login; (c) User Profile; (d) SDs List; (e) SDs Information; (f) Scheduling...... 74 Figure 4.18: The Interface Design at the Application Tier ...... 75 Figure 4.19: The UML Diagram of Drools Main Recommendation Classes ...... 76 Figure 4.20: The UML Diagram of MAS and Java EE Main Communication Classes ...... 76 Figure 4.21: The WBC-SP MAS Portal: (a) Start Jade Tab; (b) WBC Jade Panel...... 77 Figure 4.22: The ADP Building Block Structure ...... 78 Figure 4.23: A Graphical Representation of the RS Encoding/Decoding Process ...... 78 Figure 4.24: The ADP/UDP/IP PDU Format ...... 80 Figure 4.25: The ADP Sender’s/Receiver's Finite State Machine ...... 81 Figure 4.26: The WBC JNI-ADP UML Class Diagram ...... 82 Figure 4.27: The WBC-SP MAS Portal: ADP Broadcaster...... 83

List of Figures

Figure 4.28: Performance Comparison of ADP, Flute (TZI), and FCast (INRIA)...... 83 Figure 5.1: The Class Diagram of Decoding_TSASMS ...... 87 Figure 5.2: The WBC Application Enabler Sub-Layer’s (User Side) Architecture ...... 87 Figure 5.3: The iWBC WPAN in the MU Domain ...... 88 Figure 5.4: The UML Diagram of the iWBC HTTP Container’s Main Classes ...... 89 Figure 5.5: The UI of the iWBC HTTP Container ...... 90 Figure 5.6: The UML Diagram of the iWBC Content Manager’s Model ...... 91 Figure 5.7: The Main Java Classes of the iWBC Content Manager’s Controller ...... 92 Figure 5.8: The iWBC-UI Architecture ...... 93 Figure 5.9: The JADE Architecture of the iWBC Mobile Application ...... 94 Figure 5.10: The UML Diagram of the PAA, Request, Response and MessageManager ...... 95 Figure 5.11: The iWBC-UI Java Packages Dependencies UML Diagram ...... 97 Figure 5.12: The Time-sequence UML Diagram of the MU Interaction with the iWBC Content Provider (Agent-Online Mode) ...... 98 Figure 5.13: The UML Diagram of iWBC-JSE UI Application’s Main Classes ...... 99 Figure 5.14: The iWBC-JSE UI: (a) AD Manager; (b) Category Manager...... 101 Figure 5.15: The iWBC-MIDP UI Java Packages Dependencies UML Diagram ...... 102 Figure 5.16: The iWBC-MIDP UI (Sony Ericsson W900) ...... 103 Figure 5.17: The Lifecycle of FavoriteView Activity ...... 104 Figure 5.18: The Initial Task of the iWBC-Android UI UML Diagram ...... 105 Figure 5.19: The UML Diagrams of iWBC-Android Activities ...... 106 Figure 5.20: The iWBC-Android UI ...... 107 Figure 5.21: The iWBC WPAN Setup and Operation ...... 107 Figure 6.1: The ‘WBC over DVB-H’ CSIT Table ...... 110 Figure 6.2: The ‘WBC over DVB-H’ Link Layer Encapsulator’s and Encoder's Functional Models ...... 110 Figure 6.3: The WBC Cross-layer Smart Decoding ...... 113 Figure 6.4: The 'WBC over DVB-H' Link Layer Decoder's Functional Model ...... 114 Figure 6.5: The DVB-H Link Layer Testbed Equipment: (a) IP Encapsulator and Encoder (IPE-10); (b) IP Decapsulator and Decoder (POD-1100); (c) Monitor and Analyzer (GOLDENEAGLE)...... 115 Figure 6.6: The DVB-H Link Layer Portal: (a) IP Address; (b) IPE-Output; (c) DVB-H Physical Parameters; (d) Channels; (e) Sessions; (f) Session Definition; (g) IP Sessions; (h) Traffic and Signalling Monitoring...... 117 Figure 6.7: The WBC Channel Discovery Sequence Example ...... 118 Figure 6.8: GOLDENEAGLE DVB-H MPEG Real-time Monitor and Analyzer ...... 119 Figure 6.9: The Link Layer UML Diagrams of the POD-1100 Receiver ...... 120 Figure 6.10: The ‘WBC over DVB-H’ Link-Layer Monitoring Application UI ...... 121 Figure 7.1: The 'WBC over DVB-H' Matlab Physical Layer Testbed...... 122 Figure 7.2: The Audemat DVB-H Transmitter (EMAA) ...... 126 Figure 7.3: The DVB-H Physical-Layer Portal Application: (a) Transmitter Configuration; (b) Modulator Parameters...... 127 Figure 7.4: GOLDENEAGLE DVB-H RF Signal Real-time Monitor ...... 128 Figure 7.5: The Physical Layer UML Diagrams of POD-1100 Receiver ...... 129 Figure 7.6: The ‘WBC over DVB-H’ Physical-Layer Monitoring Application’s UI ...... 130 Figure 8.1: (a) The 2SMM; (b) The 2SRL...... 132 Figure 8.2: The Observed Probability Distributions of Good Runs and Bad Runs in DVB-H: (a) SNR=12 dB; (b) SNR=15 dB. [PHY Parameters: 16-QAM, CR= 1/2, 4K OFDM, GI=1/4]...... 133 Figure 8.3: The 2SRL Functional Model ...... 139 Figure 8.4: The Discrete Time Scatter Plot Scope: (a) SNR=16 dB, (b) SNR=5 dB...... 139 Figure 8.5: The Byte Error Rate and TSPER in the ‘WBC over DVB-H’ AWGN Channel . 140 Figure 8.6: The 'WBC over DVB-H' Physical Layer's TSPER ...... 141 Figure 8.7: The Comparison of the Link Layer Decoding Schemes Based on (a) IPER and (b) SER Analytical Results ...... 145 Figure 8.8: The AWGN Simulation Result: (a) IPER; (b) SER...... 145

Figure 8.9: The IPER/SER Simulation Result for ‘WBC over DVB-H’: (a) fD

ix List of Figures

=10Hz; (b) fD =40Hz; (c) fD =80Hz...... 146 Figure 8.10: The Overhead Efficiency (at IP Layer) versus the IP Packet Length for the AWGN and Rayleigh Fading Channel ...... 148 Figure 8.11: The Overhead Efficiency for Different IP Packet Lengths with SSE Decoding

Scheme: (a) fD =10Hz; (b) fD =80Hz...... 151 Figure 8.12: The Mean WBC segment Access Time for Different Access Patterns ( ) ...... 152 Figure A.1: The SD's Encoding Time-Sequence UML diagram ...... 185 Figure A.2: The SD's Decoding Time-Sequence UML Diagram ...... 186 Figure B.1: Deriving a Broadcast Disk Algorithm ...... 189 Figure C.1: The Structure of the T-DMB Transmission Frame ...... 191 Figure C.2: The New 'WBC over T-DMB' IPDC Mode vs. Standard T-DMB Stream Mode and Packet Mode ...... 192 Figure C.3: The 'WBC over T-DMB' Matlab PHY Testbed ...... 193 Figure C.4: The IPER in Packet Mode and IPDC Mode. (a) Doppler Frequency= 10Hz; (b) Doppler Frequency = 80Hz ...... 196 Figure D.1: The WBC-SP Enterprise Distributed Application Environment ...... 198 Figure D.2: The WBC-SP Enterprise Distributed Application Structure ...... 199 Figure D.3: The WBC-SP Portal Application Environment ...... 199 Figure D.4: The ADP DLL Design Environment ...... 200 Figure D.5: The ADP Java Invoking DLL Design Environment ...... 200 Figure D.6: The WBC-MU Content Provider Development Environment ...... 201 Figure D.7: The iWBC-JSE Development Environment ...... 202 Figure D.8: The iWBC-MIDP Development Environment ...... 202 Figure D.9: The iWBC-Android Development Environment ...... 203 Figure D.10: The Link Layer and Physical Layer Development Environment on User Side204

x List of Tables

LIST OF TABLES

Table 2.1: Examples of Teleservices [1] ...... 18 Table 2.2: Examples of ANCS ...... 20 Table 3.1: WBC Nodes and Elements ...... 24 Table 3.2: SD Sizes in Different Formal Languages Formatting ...... 26 Table 3.3: The ASN.1 Basic Types and Structure Types Used in WBCs ...... 26 Table 3.4: The TS Packet’s Header Structure ...... 45 Table 4.1: The General WBC System Parameters ...... 58 Table 4.2: An Example of SD Broadcating Frequency Generating Scheme ...... 61 Table 4.3: The Main IDEs/APIs/Frameworks at the WBC Application Enabler Sub-Layer... 68 Table 4.4: The ADP, Flute, and FCast Comparison ...... 84 Table 5.1: The iWBC User Profile's General Description ...... 96 Table 7.1: The Parameters of DVB-H Transmission Modes ...... 123 Table 7.2: Fading Channel Parameters ...... 126 Table 8.1: DVB-H Physical Layer Matlab Testbed Parameters ...... 139

Table 8.2: 2SRL Parameters for fD =10 and  t =5 ...... 141

Table 8.3: 2SRL Parameters for fD =10 and  =16...... 142 Table 8.4: Theoretical Analysis Parameters ...... 142 Table 8.5: The Byte Error Rate for Different Decoding Schemes (Analytical Results) ...... 149 Table 8.6: The SNR (in dB) for AWGN Channel Simulation ...... 149 Table 8.7: The SNR (in dB) for Rayleigh Channel Simulation: ...... 150 Table C.1: The Characteristics of the T-DMB Transmission Frame ...... 192

List of Abbreviations

LIST OF ABBREVIATIONS

2SMM Two-State Markov Model 2SRL Two-State Run Length Model Third-Party Authentication, Authorisation and Accounting Service 3P-AAA-SPs Providers 4G Fourth Generation AAA Authentication, Authorisation and Accounting AAITS AN Affiliated IP Teleservices ABC&S Always Best Connected and Best Served ABNF Augmented Backus-Naur Form ACL Agent Communication Language ADA Advertisement, Discovery and Association ADP Advertisements Delivery Protocol ADT Application Data Table AJAX Asynchronous JavaScript and XML ALC Asynchronous Layered Coding AMS Agent Management System AN Access Network ANCS Access Networks' Communication Service ANP Access Network Provider AOP Aspect-Oriented Programming API Application Programming Interface ARQ Automatic Repeat-reQuest ASN.1 Abstract Syntax Notation One AWGN Additive White Gaussian Noise BB Building Block BDI Belief-Desire-Intention BSC Binary Symmetric Channel C/S Client/Server CBM Consumer-centric Business Model CBR Constant Bit Rate CC Congestion Control CC / PP Composite Capability / Preference Profiles CDC Connected Device Configuration CDF Cumulative Distribution Function CFT Curve Fitting Techniques CIM Consumer Identity Module CLDC Connected Limited Device Configuration CP Cyclical Prefix CRC Cyclic Redundancy Check

List of Abbreviations

CRUD Create, Read, Update and Delete CSIT Correct Segment Index Table DA Directory Agent DAB Digital Audio Broadcasting DAO Data Access Object DDV Dialog Data Validation DDX Dialog Data Exchange DF Directory Facilitator DRM Digital Radio Mondiale DTD Document Type Definition DVB-H Digital Video Broadcasting - Handheld DVB-T Digital Video Broadcasting - Terrestrial EIT Erasure Info Table EJB3 Enterprise JavaBean version 3 ETSI European Telecommunications Standards Institute FCAST File multiCasting FDD Feature Driven Development FDT File Delivery Table FEC Forward Error Correction FFT Fast Fourier Transform FIFO First-In-First-Out FIPA Foundation of Intelligent Physical Agents FLUTE File Delivery over Unidirectional Transport FSMM Finite-State Markov Model GPS Global Positioning System GWT HTML Hyper Text Markup Language HTTP Hypertext Transfer Protocol HTTPS Hypertext Transfer Protocol Secure I/O Input/Output ICC Incoming Call Connection ICS Internet Connection Service IDE Integrated Development Environment IDFT Inverse Discrete Fourier Transform IETF Internet Engineering Task Force IITS Independent IP Teleservice IoC Inversion of Control IPDC IP Datacasting IPER IP Packet Error Rate IPv6 Internet Protocol version 6 IRCSET Irish Research Council for Science, Engineering & Technology ISAPI Microsoft Internet Server Application Programming Interface International Telecommunications Union - Telecommunications ITU-T Standardization Sector

xiii List of Abbreviations

JADE Java Agent Development Framework JAR Java Archive Java EE Java Enterprise Edition Java ME Java Micro Edition Java SE Java Standard Edition JDBC Java Database Connectivity JMS Java Message Service JNI Java Native Interface JPA Java Persistence API JSON JavaScript Object Notation JSP Java Server Page KVM (Java) K Virtual Machine LCR Level Crossing Rate LCT Layered Coding Transport LLC Logical Link Control MAC Medium Access Control MAcWiN Multi-Access Wireless Network MAS Multi-Agent System MC Message Channel MFC Microsoft Foundation Classes MFER MPE-FEC Error Rate MIDP Mobile Information Device Profile MPE Multi-Protocol Encapsulation MPE-FEC Multi-Protocol Encapsulation - Forward Error Correction MT Mobile Terminal MTU Maximum Transmission Unit MU Mobile User MVC Model-View-Controller NGN Next Generation Network NIT Network Information Table NITS Non-IP Teleservices NORM NACK Oriented Reliable Multicast OFDM Orthogonal Frequency-Division Multiplexing OHA Open Handset Alliance OO Object Oriented OR Mapping Object-Relation Mapping P2P Peer-to-Peer PAA Personal Assistance Agent PAT Program Association Table PDA Personal Digital Assistant PDF Probability Density Function PDU Protocol Data Unit PED Packet Erasure Decoding PER Packed Encoding Rules

xiv List of Abbreviations

PI Protocol Instantiation PID Packet Identifier PMT Program Map Table POJO Plain Old Java Object PPC Pocket PC PSD Power Spectral Density PSP Personal Software Process QAM Quadrature Amplitude Modulation QoS Quality of Service QPSK Quadrature Phase-Shift Keying RDF Resource Description Framework RF Radio Frequency RMI Remote Method Invocation RMT Reliable Multicast Transmission RS Reed-Solomon RSDT RS Data Table SA Service Agent SBM Subscriber-based Business Model SD Service Description SDK Software Development Toolkit SE Section Erasure SER Segment Error Rate SFI Science Foundation Ireland SI/PSI Service Information/Program Specific Information SLP Service Location Protocol SNR Signal - to - Noise Ratio SP Service Provider SSDP Simple Service Discovery Protocol SSE Smart Section Erasure STSE Smart Transport Stream Erasure TDD Test Driven Development T-DMB Terrestrial - Digital Multimedia Broadcasting TEI Transport Error Indicator TPS Transmission Parameter Signalling TRC Telecommunications Research Centre TS Transport Stream TSE Transport Stream Erasure TSP Teleservice Provider TSPER TS Packet Error Rate UA User Agent UCWW Ubiquitous Consumer Wireless World UFANP User Foreign Access Network Provider UHANP User Home Access Network Provider UHF Ultra High Frequency

xv List of Abbreviations

UI User Interface UML Unified Modeling Language UMPC Ultra-Mobile PC UMTS Universal Mobile Telecommunications System UPnP Universal Plug and Play URL Uniform Resource Locator VASP Value Added Service Provider WBC Wireless Billboard Channel WBCC WBC Centre WBC-SP WBC Service Provider WiMax Worldwide Interoperability for Microwave Access WLAN Wireless Local Area Network WMAN Wireless Metropolitan Area Network WPAN Wireless Personal Area Network XML Extensible Markup Language xSP Service Provider

xvi Chapter 1. Introduction

CHAPTER 1. INTRODUCTION

This thesis investigates the conceptualisation, design, implementation, testing and performance evaluation of a Wireless Billboard Channel (WBC) established over a Digital Video Broadcast - Handheld (DVB-H) platform [1-15].

WBCs are novel infrastructural components of the Ubiquitous Consumer Wireless World (UCWW) [16-18], which shall be a new wireless communications operating environment five to fifteen years hence. UCWW is particularly matched to maximizing the efficient and economic use of the massive, and ever-growing, range of wireless communication interfaces and services, both Access Networks (ANs)' communications services and teleservices [14]. It is particularly in harmony with realizing the user-driven Always Best Connected and best Served (ABC&S) [19-23] communication paradigm. In it the consumer mobile user - identified by a personal, network-independent and location-independent, Internet Protocol version 6 (IPv6) address [24] - is not constrained to any particular AN Provider (ANP) and may use any available service through any available AN, and pay for the use of services through a trusted Third-Party Authentication, Authorisation and Accounting Service Provider (3P-AAA-SP) [25]. The consumer-user is free to choose what is 'best' for them, i.e. the service and AN that they consider best matches their needs at any time or place. The concept of UCWW has emanated from the Telecommunications Research Centre (TRC) in the University of Limerick and has already attracted significant international attention with its dissemination in international journals and conferences, including keynote speaking invitations to the Director of the TRC to address the topic in future wireless world vision sessions at international conferences.

In the UCWW maximizing consumer wireless transactions, and not subscriber contracts, is the business driver for service providers. The newly conceived WBC infrastructural component of the UCWW aims to satisfy this requirement in this environment by facilitating the wireless service providers to 'push' advertisements and information about their wireless service offerings to potential consumers. Taking into

1 Chapter 1. Introduction consideration the potentially large number of wireless services already available - and this is set to grow exponentially -, efficient and easy-to-implement mechanisms for wireless services' advertisement and novel solutions for the above tasks are needed, i.e. for facilitating the services’ Advertisement, Discovery and Association (ADA) [1, 2].

In this research work, besides further development of the essentials of the general WBC concept, the WBC infrastructure and framework were also developed. This includes WBC server operations, structures and procedures for WBC-advertisers interactions and Mobile Users (MUs) obtaining services interactions, especially wireless access services as a result of obtaining the requisite information through a WBC. Conceptual work through to testbed implementation has been undertaken.

This research work was initiated as part of the Science Foundation Ireland (SFI) Basic Research Grant project “Protocol Foundations for ABC&S Paradigm Realisation in future Fourth Generation (4G) Wireless Communication Networks (Ref. No. 04/BR/E0082)” undertaken by the TRC in University of Limerick and later supported by the Irish Research Council for Science, Engineering & Technology (IRCSET). The work described in this thesis represents the author’s contribution to the research effort.

1.1. Research Objectives

The goal of the research project was to design and develop a fully operational WBC system prototype. The main objectives of this research were as follows:

 To study state-of-the-art of the WBC applications requirements.  To propose a WBC (three-layered) model.  To run and test the final WBC system on a real-time hardware testbed and pure software simulator testbed. In the service layer:  To investigate the WBC Service Description (SD) model, structure [2], and description languages.  To gain knowledge of Abstract Syntax Notation (ASN.1) language and to develop the ASN.1's Packed Encoding Rules (ASN.1-PER) encoder and decoder [26, 27].  To gain knowledge of Java programming, including [28], Tomcat [29], Swing programming [30], Struts2 [31], [32], Enterprise JavaBean

2 Chapter 1. Introduction

version 3 (EJB3) [31], Spring [33], Ant [34], XDoclet [35], Log4J [36], Servlet, DB4O [37], MySQL [38], i18n [39], portal Application Programming Interfaces (APIs), Java Micro Edition (Java ME) [40], Android [41, 42], Google Web Toolkit (GWT) [43], etc. The above knowledge was used in developing an enterprise portal application on the WBC Service Provider (WBC-SP) side, and a light-weight personal mobile application on the user side.  To gain knowledge of Multi-Agent Systems (MAS) and Rule-Engine for the Java Platform, e.g., Java Agent Development Framework (JADE) [44, 45], JESS [46] and Drools [47], for intelligent SDs collecting, clustering, scheduling, indexing, broadcasting, discovery and association processing [3].  To design a WBC Advertisements Delivery Protocol (WBC-ADP) [4] in order to enable IP datacasting (IPDC) [48-52] in unidirectional WBC.  To gain knowledge of Java Native Interface (JNI) component to invoke C++ function from Java APIs [53].  To evaluate the WBC Mobile Terminal (MT) access time and tuning time. In the link layer:  To gain knowledge of DVB-H [54-62] link layer technologies, and develop and use a novel Multi-Protocol Encapsulation - Forward Error Correction (MPE-FEC) cross-layer smart decoding, where the MPE-FEC interacts with the ADP protocol for improving the decoding efficiency.  To investigate the optimal IP packet length and overhead efficiency for use in a 'WBC over DVB-H' system in a fading-channel conditions.  To study a DVB-H compatible link layer for Digital Audio Broadcasting (DAB)/ Terrestrial-Digital Multimedia Broadcasting (T-DMB) [63-69] system. In the physical layer:  To gain knowledge of Matlab communication toolbox, and design the DVB-H software simulation testbed [70]. Additionally, to study the DAB/T-DMB software testbed design.  To propose a Two-State Run Length Model (2SRL) to simulate the Transport Stream (TS) output behaviour (good/bad TS packet output) for the ‘WBC over DVB-H’ physical layer [71].

3 Chapter 1. Introduction

1.2. The Novel Contributions of the Research

The novel contributions of this research project can be described as follows:

The research work has investigated, designed and implemented a fully operational WBC system prototype. The core project work was done along three strands: (a) the WBC service layer; (b) the WBC link layer and (c) WBC physical layer.

WBCs are point-to-multipoint, simplex, unidirectional and narrowband channels. This research work proposes new WBC server operations, structures and procedures for WBC-advertisers interactions in an extensible and distributable system; intelligent ADA schemes design; efficient MU profiles design and light-weight mobile application implementation; new smart link layer decoder design; efficient DVB-H software implementation; and WBC software and hardware testbed development and testing. The results of the performance evaluation of the testbed demonstrate that the WBC system prototype runs in a flexible, maintainable, and extensible way.

1.3. Literature Survey

A significant number of literature resources relevant to and studied throughout the course of this research is presented in the references section. Presented in this section are the primary references of significant interest to the research studied and presented in this thesis.

 UCWW and 4G generic system and service integration architecture [1, 2, 16-19, 22-25, 73, 74, 76, 78-84, 87, 89].  MAS and Rule-Engine system [42, 44, 45, 47, 116, 117, 142].  Data organization and access in asymmetric communication environments [95, 119, 140, 141].  Java Enterprise Edition (JAVA EE) platform [28, 31, 34, 35, 39, 40, 53, 91, 103-105, 146-149].  JAVA ME and Android software design [40-42, 154, 155].  DVB-H/DAB system and IPDC techniques [48-52, 54-65, 67, 69, 70, 72, 124-126, 156, 158, 167, 173].  Finite-state Markov model (FSMM) for Rayleigh fading channels [8, 71, 129-133].

4 Chapter 1. Introduction

1.4. The Structure of the Thesis

Chapter 2 describes the motivation and concepts of WBCs. An overview of the UCWW and ABC&S concepts is included in this chapter. In the wireless services discovery model section, the structure of SD is introduced.

Chapter 3 introduces the WBC system layered model. The WBC service layer is a software layer with a common structure for all WBC nodes and is independent of the carrier technology. On the contrary, the WBC link layer and physical layer are hardware dependent layers and thus may have different structures depending on the carrier technology used. The DVB-H is selected as a carrier for the WBC prototype implementation.

Chapter 4 presents the design and implementation of the WBC service layer on the WBC-SP side. A number of developed intelligent algorithms are described for SDs collecting, clustering, scheduling, indexing and broadcasting. A new ADP protocol is proposed for WBC segments IPDC in the unidirectional broadcasting channel.

Chapter 5 presents the design and implementation of the WBC service layer on the user side. A novel personal mobile application, together with profiles, is designed for discovery and association operation.

Chapter 6 describes the design and implementation of the ‘WBC over DVB-H’ link layer. A cross-layer smart decoding scheme was proposed based on the Section Erasure (SE) and TS Erasure (TSE) algorithms [55, 72]. During the implementation, a pure software testbed is developed for performance evaluation, and a hardware real-time testbed is developed for demonstration.

Chapter 7 explains the design and implementation of the ‘WBC over DVB-H’ physical layer. Similarly to Chapter 6, during implementation two testbeds are built – one in software and another in hardware.

Chapter 8 discusses the results of the performance evaluation of the ‘WBC over DVB-H’ system. A 2SRL model is proposed for representing the physical layer and for performance evaluation with emphasis on the physical layer, link layer, and service layer.

Chapter 9 concludes the thesis. The research achievements and future work directions are discussed.

5 Chapter 1. Introduction

1.5. Publications Arising from This Work

A total of 25 technical papers have been published (to be published) during the course of this research work. Among them are four journal papers, one book chapter and others are conference papers. The list of publications in Appendix E shows this in more detail.

1.6. Conclusion

This chapter has introduced the research work, which is presented further in the thesis in great detail. It has covered the project objectives, the novel research contributions, and the thesis structure.

6 Chapter 2. Wireless Billboard Channels Motivation and Concepts

CHAPTER 2. WIRELESS BILLBOARD CHANNELS: MOTIVATION AND CONCEPTS

2.1. Introduction

WBCs [1-15] used for wireless service ADA are fundamental to the Consumer-centric Business Model (CBM), which is integral to the UCWW evolution [16, 17]. The aim of the CBM is to enable MUs to be ABC&S in UCWW, i.e. to use the best service1 anytime, anywhere, and anyhow through the best available wireless connection.

In the CBM, the user role is changed from a subscriber to a consumer, i.e. the user can select any available teleservice through the best AN. Taking into account the large number of services available to users/consumers in the UCWW, an efficient and flexible mechanism is needed for: (i) Service Providers (xSPs2) to advertise their services, (ii) consumers to discover their favourite services and updates, (iii) Mobile Terminals (MTs) to associate with ANs and teleservices.

2.2. Ubiquitous Consumer Wireless World (UCWW)

The UCWW is the University of Limerick’s version of the wireless Next Generation Network (NGN) proposal [16]. The NGN is based on an IP infrastructure and encompasses all existing mobile and fixed wireless networks, providing wireless services which are independent of any transport-related technologies, both terrestrial and satellite, and will be deployed over the next 5–10 years [17, 73-84]. From the MU viewpoint, the MTs (NGN terminals) can be reconfigured to use many different access technologies to discover and associate with ‘best’ services, thus giving rise to the concept of an ABC&S paradigm [19, 21-23, 78]. Figure 2.1 shows an example of a heterogeneous networking wireless world.

1 The term ‘services’ is used here to mean both access networks’ communications services and Teleservices. 2 xSP is an encompassing acronym for both Access Network Providers and Teleservice Providers.

7 Chapter 2. Wireless Billboard Channels Motivation and Concepts

Figure 2.1: An Example of Heterogeneous Networking Wireless World

2.2.1. Always Best Connected and best Served (ABC&S)

For a MU to be ABC&S means that the MU is not only always connected through ‘best’ access network but also connected via the ‘best’ available MT to the ‘best’ wireless services [19, 23]. The MU should define the profiles that specify the parameters (e.g. cost/ Quality of Service (QoS) [85]) determining what "best" means in any particular scenario. For instance, the MU may want to use the cheapest available voice-call service at home with a pocket PC (PPC) and would rather use a high-performance voice-call service on a small mobile phone in the office; or the MU may like a high-quality online music service on an Ultra-Mobile PC (UMPC) but with a price lower than one cent per min, etc. Also, when the MU moves out from one AN to another AN, or changes from one MT to another MT, a vertical or horizontal handover decision making scheme should run on the user side to keep the connection between MTs and ANs [86]. As a result, the ABC&S needs not only technical solutions, but also business solutions for MUs and SPs. The CBM is a novel techno-business concept for the ABC&S realization [78].

2.2.2. Consumer-centric Business Model (CBM)

The NGN is one of the most popular research topics in today’s wireless world. The NGN’s state-of-the-art business model is a Subscriber-based Business Model (SBM).

8 Chapter 2. Wireless Billboard Channels Motivation and Concepts

In the SBM, the MU is a subscriber (customer) to a User Home ANP (UHANP). All other ANPs are User Foreign ANPs (UFANPs) [78]. To access the resource of a UFANP, a business agreement should be in place between UHANP and UFANP, resulting in a roaming charge being billed by the UHANP when MUs use the services of the UFANP. This leads to the SBM not being considered ideal in supporting the ABC&S [21].

Dissimilar to other studies [73, 76, 79-81, 83], the UCWW is based on a new generic CBM for the NGN as a new evolution on the legacy SBM [16]. In CBM-UCWW, the consumer MU – identified by a smart Consumer Identity Module (CIM) card – with at least one personal IP address – is the centric of the model. The MU’s address is location independent and device-independent, not constrained to any particular ANP. With the novel CBM solution, the MU can benefit from receiving a detailed monthly bill, simplicity of use, enjoyment of their favourite services, and SPs. Similarly, ANPs can benefit from single business agreements, simplicity and the fact that it is easier for new market entrants to succeed. This enables a realization of a truly consumer-oriented, user-friendly and user-driven ABC&S wireless communication environment.

The main actors in the CBM are the following [78]:

 Consumer-User: The ABC&S consumer equipped with a MT, which automatically selects his/her ‘best’ wireless services offered by ANPs/TSPs [21].  Access Network Providers (ANPs): The service providers who provide ANs' Communication Services (ANCSs) for all consumer-users [16].  Teleservice Providers (TSPs): The service providers who provide an independent service, directly or in-directly through Value Added Service Providers (VASPs) [14].  Value Added Service Providers (VASPs): The Incoming Call Connection SPs (ICC-SPs) and the WBC-SPs belong to the category of VASPs [87].  WBC Service Providers (WBC-SPs): The wireless billboard channel service providers used by TSPs and ANPs [1].

9 Chapter 2. Wireless Billboard Channels Motivation and Concepts

 Third-Party Authentication, Authorisation and Accounting Service Providers (3P-AAA-SPs): The third-party providers for Authentication, Authorization and Accounting (AAA) services for all actors in UCWW [88].  ICC Service Providers (ICC-SPs): The providers of an ICC service for consumers [89]. Figure 2.2 shows an example of a CBM-based UCWW environment. In this example, MU seamlessly performs vertical handover between Universal Mobile Telecommunications System (UMTS), 802.11b and Worldwide Interoperability for Microwave Access (WiMax) ANs.

TeleServiceTeleservice UMTS ProvidersProviders Access Network 1 Access Access Network Network 3 2

802.11b WiMax WBC

Figure 2.2: An Example of CBM-based UCWW Environment

The WBCs are the main topic in this research.

2.3. Wireless Billboard Channels (WBCs)

2.3.1. Motivation

In UCWW, MUs need to continually receive updates of the wireless services’ advertisements in order to discover and associate with the ‘best’ wireless services. This ADA of wireless services (including ANCSs and teleservices) is a key aspect of the UCWW as MUs/MTs need to discover all services available/deployed in a given area/location. There is potential for wireless services in UCWW being sold to users on a consumer basis, transaction by transaction, rather than through a long-term subscriber contract as at present. Many TSPs and ANPs competing for consumer

10 Chapter 2. Wireless Billboard Channels Motivation and Concepts business will seek new dynamic ways to advertise their services to potential customers [25]. The demand for an efficient and easy mechanism for wireless services ADA adapted to the MT capabilities, MU preference and location, is clearly foreseen [1, 11].

2.3.2. WBC Service Discovery Protocols

Service discovery allows MTs to automatically find all available services. For example, if a MU wants to call his/her friend when they have arrived in a new location, then the service discovery scheme enables his/her MTs to automatically discover the ‘best’ voice call service available there based on his/her personal profile, as well as the attributes of the service, e.g., price, QoS, etc. A number of well-established service discovery protocols exists as listed here [1]:

 Jini: Developed by SUN, it is based on Java . It is a next generation networking technology that provides building blocks for a distributed system [90]. Comparing with client-server architecture [91], a register is the centre of Jini and it allows clients in the corresponding community to lookup services. Also, Jini uses Java’s Remote Method Invocation (RMI) to move code around the distribution system [39]. Clients communicate with services by means of proxy – a Java object provides an interface and method to enable the user to invoke and execute the service. The main functions in Jini include: register, lookup, notify, getServiceId, getEntryClasses, getServiceTypes, etc .  Service Location Protocol (SLP): This is an IP-based framework which allows the client to discover the existing network services in enterprise networks, proposed by the Internet Engineering Task Force (IETF) [92]. There are three agents in SLP: User Agent (UA) - an entity used to locate the required services; Service Agent (SA) - an entity that provides the location of services; and Directory Agent (DA) - an entity that acts as a register centre for services. The main functions in SLP include: SLPReg, SLPDeReg, SLPFindSrvs, SLPFindAttrs, SLPFindSrvTypes, etc.  Salutation: This is a network independent architecture for service discovery which was proposed by the Salutation consortium [93]. It provides a standard method for devices to advertise their capabilities which they offer to other

11 Chapter 2. Wireless Billboard Channels Motivation and Concepts

devices. There are three fundamental components: functional units - used for defining a service; salutation managers - similar to the lookup service in Jini, these service brokers help clients find the needed services and allow services to register their availability; and transport managers - similar to lookup servers in Jini. The main functions in Salutation include: slmRegisterCapabilities, slmUnregisterCapabilities, slmSearchCapability, slmQueryCapability, etc.  Universal Plug and Play (UPnP): This is an architecture for service advertisement and discovery proposed by Microsoft [93, 94]. It is based on the concept of ‘plug and play’, which is used to simplify the process of installing hardware components on PCs. Unlike Jini, there is no code movement in UPnP, and it is device-centric (a device can dynamically join a network, obtain an IP address, advertise its services, discover the presence and capabilities of other services or leave a network automatically). UPnP uses Extensible Markup Language (XML) to describe device and service capability and uses the Simple Service Discovery Protocol (SSDP) for service discovery. For example, a device (advertiser) multicasts a message (SSDP:alive) advertising its services to control points (discover), and the control point multicasts a search message (SSDP:discover) to the network, resulting in the Uniform Resource Locator (URL) of the XML file being received by the control point. From the above four protocols, the UPnP is used by devices to advertise services directly to each other, making it less relevant to the WBC-SP concept. On the contrary, the Jini, SLP and Salutation relay on a register centre. Their basic service discovery model is shown in Figure 2.3 (a). The message flow sequence [2] is:

1. xSPs register their services with the register centre;

2. The MU sends a request to the centre querying the desired service;

3. The register centre sends the service information to the MU;

4. The MU uses the service.

The wireless communication environment comprises two channels – a downlink channel and an uplink channel. Comparatively, the downlink channel communication capacity, i.e., from server to MUs, is much greater than the upstream communication capacity, i.e., from MUs to server. This is called an asymmetric communication environment [95]. With the increasing popularity of portable MTs in UCWW, the

12 Chapter 2. Wireless Billboard Channels Motivation and Concepts request and reply mechanisms, i.e., Jini, SLP and Salutation are not efficient for WBCs. A broadcasting scheme was proposed in [1] that is independent of the client population, where the streaming of service advertisements is available simultaneously to a large number of clients. With this push-based WBC data delivery system, the wireless bandwidth is efficiently used. The MTs only passively listen to the channel thus consuming less battery power. The push-based WBCs services discovery model is shown in Figure 2.3 (b). The message flow sequence is [1]:

1. The xSPs register their SDs with a WBC-SP's central registry using some external methods, e.g. via a web portal;

2. The WBC-SP broadcasts all SDs repeatedly on a WBC (service advertisement);

3. The MU/MT tunes to WBC and listens to broadcasts to receive desired SDs (service discovery);

4. The MU/MT associates with chosen service provider to use the 'best' services it has discovered (association).

1. Join 1. Join Register xSPs xSPs WBC-SP Centre 3. Receive 2. 4. Use 2. Lookup 4. Use Broadcasting

MUs MUs

(a) (b) Figure 2.3: Model Used by: (a) Jini, SLP, Salutation and (b) WBC [1]

2.3.3. WBC Concept and Characteristics

The approach proposed to facilitate ADA in UCWW is WBC. It is a channel that broadcasts wireless services information to MUs. With WBCs, MUs can discover new services or updates of favourite services advertised by xSPs. WBCs are a point-to- multipoint, simplex, narrowband and unidirectional channels, which are solely used for wireless services’ advertisement purposes.

The main WBC characteristics stated in [1] are briefly described below:

13 Chapter 2. Wireless Billboard Channels Motivation and Concepts

 Simplex and Broadcast: Wireless SDs are periodically broadcast over WBC using a 'push' mode by the WBC-SP, i.e. MTs only listen to the channel and never send out any requests. Compared with the alternative "pull" mode, the simple WBC "push" mode consumes less battery power and also improves WBC bandwidth utilization. By using a standardized SD format, the xSPs would compete with each other for MUs.  Limited Bandwidth: Since the WBCs are independent of any ANs, the bandwidth-spectrum allocation would become a significant issue. The limited bandwidth property increases the chances of WBC becoming an international standard of UCWW.  Maximum WBC Coverage Area: To enable ABC&S, the MTs should have the ability to tune into a WBC and discover the needed services anywhere and at anytime. The mobility of MTs must not affect the ability to receive advertisements of services.  Different Areas Operating Different Versions of WBCs: Different-size areas may run different versions of WBC by means of different carrier technologies, e.g. international, national, and local WBCs (Figure 2.4).

International WBC

National WBC National WBC

Local WBC

Local WBC Local WBC

Local WBC

Local WBC

WBC-SP Center

WBC Broadcasting Servers

Figure 2.4: The WBCs Hierarchy

 Operated by Non-ANP SPs: To ensure fair competition on broadcasting service advertisements, the WBC-SP should be provided by non-ANP SPs.

14 Chapter 2. Wireless Billboard Channels Motivation and Concepts

With this property, the WBC-SP needs to define a number of algorithms which enable the wireless service advertisements’ broadcasting frequency to follow the MU’s access pattern.

2.3.4. WBC Service Discovery Model

To describe the wireless service advertisement, a SD format was defined for storing and exchanging the service’s ADA information in WBCs. A SD consists of a number of fields, such as a service type, scope list, length, composite capability / preference profiles (CC/PP) [96], QoS and attribute list. The full SD format is as follows [1, 2, 14]:

ServiceDescription ::= SEQUENCE { serviceType Service-Type, length Length, scopeList ScopeList, ccpp CCPP, qos QoS, attrList ServiceTemplate. } The serviceType is a field that indicates the basic function performed by the service which allows the SDs of similar services to be grouped together to generate a WBC segment. The serviceType contains four subfields: the division specifies whether the service belongs to TS or ANCS; the category specifies the category that the service falls into; the type specifies the actual type of the service; and the version specifies the version of the SD which is defined by WBC-SP.

The length field indicates the length of the SD in bytes (B). The WBC-SP uses this field to generate a WBC segment from SDs, and MTs use this field to extract SDs from the WBC segment.

The scopeList, ccpp and qos act as filters of a SD. The scopeList is a list of one or more scopes. With this, MUs can define the scopes parameter in user profiles, and only pay attention to SDs which belong to the defined scopes. For instance, some news services only allow access for subscribing MUs, and some services only allow access for emergency service employees. The ccpp field is used for identification of the required minimum terminal hardware and software configuration. For instance,

15 Chapter 2. Wireless Billboard Channels Motivation and Concepts

300|64|200|18 represents terminal CPU frequency, memory size, screen resolution, and software configuration respectively [14]. If for instance a terminal has 32MB memory, this SD will be ignored even though the user might be interested in this service. The qos is an integer value to indicate a certain level performance of a SD. Some MUs may only be interested in high QoS services.

The attrList field is the main field of a SD, which carries the ADA information. Each service type has its own attribute template. The templates are defined by a global WBC authority. When a new service type is released, the WBC-SP will update the template library and broadcast it to MTs. With the defined standard SD attribute templates, the xSPs, WBC-SP and MTs can share the same library thus improving the efficiency of the software development process.

ANCS and teleservice are two divisions of wireless services [1, 2]. Teleservice is the actual service available to MUs, and ANCS is provided by the physical ANs used to get access to the teleservice. In practice, some ANPs may only provide ANCSs, or both ANCS and teleservice. Some TSPs may allow the services to be accessed via more than one ANP. Figure 2.5 shows the generic service classification used [97].

MUs

Mobile Users Internet Access Connection Networking Services Services (ANS) (ICS) ANCSs

Independent IP AN Affiliated NON-IP Teleservices IP Teleservices Teleservices Teleservices (IITS) (AAITS) (NITS)

Figure 2.5: Generic Service Classification [97]

Subsection 2.3.4.1 and 2.3.4.2 provide details of teleservices and ANCSs respectively.

2.3.4.1. Teleservices

There are three divisions of teleservices [1]:

1) Independent IP Teleservice (IITS).

An IITS is not affiliated with any ANP. It can be accessed using any Internet connection. MTs may select the 'best' Internet Connection Services (ICSs) based on

16 Chapter 2. Wireless Billboard Channels Motivation and Concepts

MUs' profiles. For example, an Internet video call service may need an ICS with high date rate, while a news service will work fine over an ICS with lower QoS. To use IITS, MUs may have to pay twice, once for the IITS and once for the ANP who provides the ICS.

2) AN Affiliated IP Teleservices (AAITS).

The AAITS is affiliated with one or more ANPs. The MTs do not need to select the ICS and directly use the 'best' ANP which provides the AAITS. The cost of AAITS includes the ANs thus the MUs only needs to pay once.

3) Non-IP Teleservices (NITS).

Considering there is some time until the all-IP UCWW becomes a reality, some legacy systems are still in use, such as voice call services (UMTS, GSM, CDMA) and messaging services. The SD of NITS should carry all ANs parameters so that MTs can know how to access it. Like AAITS, MUs only need to pay for NITS once.

For future UCWW, a set of service types are included in each division, and each service type belongs to one of a number of categories. Based on the International International Telecommunications Union - Telecommunications Standardization Sector (ITU-T) NGN Release 1 Service Classification [98], the possible TS categories are described below [1]:

 Communication Services: Incoming call; Voicemail; Call diversion; Voice call; Video call; Conference call; Multimedia interactive communication service, etc.  Information Services: News; Weather; Sport; Finance, etc.  Message Services: Email; Fax; messaging; Chat Online; Forum; SMS, etc.  Entertainment Services: DVB-H; Terrestrial Digital Multimedia Broadcasting (T-DMB); Games; Music; Other Entertainment, etc.  Education Services: e-learning, etc.  M-Commerce Services: shopping; banking; booking; ticketing; marketing; etc.  Location-Based Services: Advertising; Bus Information; Restaurant; Cinema; City guide; etc.  Other Services: Web browsing; File transfer; Address Books; etc.

17 Chapter 2. Wireless Billboard Channels Motivation and Concepts

The attribute template of teleservices should include name, cost, software, text, URL, and supported AN lists. The general format for the teleservices attribute is the following [15]:

AttributeTemplate ::= SEQUENCE { name Name, cost Cost, software SoftwareInfo, text Text, url URL, feature Features, divisionSpecific CHOICE { requrements Requirements, supportedANList SEQUENCE of AccessNetworkID, } } Table 2.1 shows some examples of teleservices and their division, category, type and description.

Table 2.1: Examples of Teleservices [1]

Division Category Type Description

IITS Communication Voice Call A voice call service based on VoIP to a particular number / username / IP address.

IITS Information News A news service that includes local, national and international news, breaking news, story news, etc. The MT will receive the MU’s favorite news specified in his/her profiles. IITS Information Stock A stock ticker service allows the MU to receive Ticker information and price of his/her favorite stock.

IITS M-Commerce Airline An airline ticket service allows the MU to Ticket receive his/her favorite airline ticket information, including price, provider, data, etc. AAITS Entertainment Online An online music service which allows MUs to Music download his/her favorite songs.

NITS Communication Voice Call A voice call service offered by UMTS / GSM / CDMA networks.

NITS Messaging SMS/MMS A SMS/MMS service offered by UMTS / GSM / CDMA networks.

18 Chapter 2. Wireless Billboard Channels Motivation and Concepts

2.3.4.2. ANs' Communication Services (ANCS)

There are two divisions of ANCS [1]:

1) Internet Connection Service (ICS).

The ICS is a service that provides an Internet connection for MTs. The SD for ICS should include the data rate and QoS level, as well as information about which SPs are providing it so that the MTs may know how to access it [97]. The ICS may be offered by an ANP or a SP who has a business agreement with ANPs.

Possible categories for ICS could be based on the IntServ service classes [97, 99]:

 Best Effort: ICSs that give no assurance about delay or packet loss.  Guaranteed Services: ICSs that offer guarantees that QoS parameters such as delay will not exceed certain values, provided the sender stays within an agreed traffic specification.  Controlled Load: ICSs that tightly approximate the behavior visible to applications receiving best-effort service under unloaded conditions, once again provided the sender stays within a traffic specification. The attributes template of ICS should include name, category, connection QoS parameters, cost, and supported ANs list [1]:

AttributeTemplate ::= SEQUENCE { name ICSName, category ServiceClass, connectionParams QoSParameters, cost ICSCost, supportedANList SEQUENCE of AccessNetID } 2) Access Networking Service (ANS).

An ANS provides physical attributes connection (link) for using all other services - IITS, AAITS or NITS. Based on the type of the radio technology used by the AN, the following ANS categories could be distinguished:

 Cellular Service: The cellular ANP includes UMTS, GSM, GPRS, CDMA, etc. The coverage area is large.

19 Chapter 2. Wireless Billboard Channels Motivation and Concepts

 Wireless Metropolitan Area Network (WMAN) Service: The WMAN ANP includes WiMax (802.16), Korean Wi-Bro, etc. The coverage area is large.  Wireless Local Area Network (WLAN) Service: The WLAN ANP includes Wi-Fi (802.11), HIPERMAN, etc. The coverage area is of middle size.  Wireless Personal Area Network (WPAN) Service: The WPAN includes Bluetooth, Zigbee, wireless USB, etc. The coverage area is small.  Multi-access Wireless Networks (MAcWiN) Service: The MAcWiN provides more than one access technology to a unified network. The attribute of AN should include name, type, identifier and access point information [1]:

AttributeTemplate ::= SEQUENCE { name ANName, type ANType, identifier ANID, accessPointInfo SEQUENCE OF AccessPoints } Table 2.2 shows some example of ANCS with Division, Category, Type and Description.

Table 2.2: Examples of ANCS

Division Category Type Description

ICS Basic Email This service type provides basic Internet connection functions. ICS Real-time Voice This service type provides high QoS Internet connection functions. ANS High Data Rate File This service type provides high data rate Download Internet connection functions. ANS Cellular UMTS This service type describes UMTS ANS.

ANS WMAN WiMax This service type describes WiMax ANS.

ANS WLAN WiFi This service type describes WiFi ANS.

ANS WPAN Bluetooth This service type describes Bluetooth ANS.

ANS MAcWiN UMTS-WiFi This service type describes UMTS-WiFi ANS.

20 Chapter 2. Wireless Billboard Channels Motivation and Concepts

2.4. Conclusion

This chapter has provided an insight into the UCWW and an overview of the motivation and the concepts of WBCs. An introduction to UCWW, ABC&S and CBM was given, which is necessary to comprehend WBCs as a fundamental part of UCWW. A description of the service discovery protocols, WBC characteristics, WBC service discovery model, as well as the details of ANCSs and teleservices have been presented.

We believe that the future consumer-centric wireless communication environment should behave according to the push mode in which an ANP or a TSP takes care of preparing connections and services, and proposes them to the mobile user. In this proactive mode of operation, the only user intervention is to choose the 'best' possible connection for each needed 'best' service.

21 Chapter 3. WBC System Architecture

CHAPTER 3. WBC SYSTEM ARCHITECTURE

3.1. Introduction

In Chapter 2, the WBC is defined as a narrow, unidirectional and point to multi-point broadcasting channel. On the WBC-SP side, the WBC-SP pushes service advertisements to a large number of MTs simultaneously; on the user side, to choose the "best" service, each MT filters the broadcast SDs using the user discovery profile, MT's CC/PP and the user location.

The WBC system is developed with three layers: physical layer, link layer and application layer, as shown in Figure 3.1.

WBC-SP Node MU Node Broadcasting Receiver Service Layer Service Layer

Broadcasting Receiver Link Layer Link Layer WBC Broadcasting Receiver Physical Layer Physical Layer

Figure 3.1: The WBC Layered Model

The physical layer encompasses a transmitter in the WBC-SP node and a receiver in the MU node. The link layer is concerned with frame processing issues, such as forward error control, multiprotocol encapsulation, etc. The service layer contains the service discovery model, and data collection, clustering, scheduling, indexing, broadcasting, discovery and association schemes, etc. The link layer and physical layer are hardware-dependent layers and thus may have different structures depending on the carrier technology used (e.g. DAB, T-DMB, DVB-H, etc). The service layer is a software layer with a common structure for all WBC nodes and being independent of the carrier technology [14].

The WBC layered model provides:

22 Chapter 3. WBC System Architecture

 Scalability and extensibility: The WBC system can be scaled and extended both horizontally (i.e. adding a new business rule at any layer does not require to change anything else in this layer) and vertically (e.g. the service layer can be migrated or updated easily).  Configurability, maintainability and security: Maintaining the system's configuration parameters and security roles in the WBC system is easy. Different layers may define different rules for end users with different levels of security policy.  Layered distribution: The layers' components on the WBC-SP side can be implemented/deployed on different machines and areas with different IP addresses. Thus the WBC system is a distributed system.

3.2. System Architecture

The WBC system architecture is depicted in Figure 3.2.

On the WBC-SP side, various xSPs submit/publish SDs of their services (along with the price they want to pay for the advertisements) to the WBC-SP over the Internet through its web portal. To reduce the user terminals' access time3 and tuning time4, a number of intelligent algorithms - running on the WBC Centre (WBCC) server - for SD collecting, clustering, scheduling, indexing and broadcasting were developed [3]. Finally, the WBC-ADP server produces ADP message that are encapsulated into UDP/IP datagrams for sending them over a backbone network to various types of WBC transmitters, which broadcast these to MTs.

On the user side, when a MU turns on her/his MT, the WBC Radio Frequency (RF) signal is being received. After demodulation of it at the physical layer and decapsulation and decoding at the link layer, the IP packets are sent to the service layer, where WBC-ADP reconstructs the WBC segments from the IP/UDP datagrams. Finally MT records the ‘favourite’ SDs to a database based on information stored in the user profiles.

Table 3.1 lists the main elements of the WBC-SP, xSPs and MUs.

3 Access time: The total amount of time from the moment when a mobile terminal first tunes in the WBC channel, until that the terminal receives the needed data. 4 Tuning time: The time that a mobile terminal keeps active mode for listening to the WBC and receiving the needed data.

23 Chapter 3. WBC System Architecture

2 Shared Knowledge Blackboard Rule Engine Ontology Database DVB-H 1

Collecting Clustering Scheduling Indexing DVB-S Agent Agent Agent Agent xSP1 WBCC Server Backbone DAB xSP2 Internet 4 xSP3 WBC-ADP Server MBMS

Broadcast … API 101010

101010 Source WBC-ADP/ALC Protocols 010101 Symbols UDP 3 010101 101010101010 xSPn 010101010101 010101 FEC IP/IPsec 101010101010 010101010101 010101 Symbols

100110 Header 010101 Segment / 001101 Source WBC-ADP UDP/IP Broadcasting Blocks Encoding Packet Packet Agent Symbols Database

Figure 3.2: The WBC System Infrastructure

Table 3.1: WBC Nodes and Elements

Node Element Description

WBC-SP/ Portal This provides interfaces to: (i) the WBC-SP administrator - for xSP application defining the WBC parameters; (ii) the xSPs - for submitting their SDs to WBCC. WBC-SP Data These are used for SDs' collection, clustering, scheduling, and organization indexing with WBC rules for data organization, prior to schemes broadcasting of the SDs. WBC-SP WBCC A server used for running the WBC portal application and providing a Multi-Agent System (MAS) runtime environment. WBC-SP Transmitter The equipment used to convert the IP packets into RF signals for broadcasting over WBC to MUs. WBC-SP/ MAS A self-organized system consisting of a number of agents, which MUs communicate to each other in order to solve a particular problem. WBC-SP/ Rule engine A rules-based and facts-based pattern matching tool used for MUs separation of the business logic from data. WBC-SP/ WBC-ADP An API for converting the WBC segments into IP packets on the MUs WBC-SP side and vice versa on the MU side. MUs Receiver The equipment used to receive, demodulate, decode the WBC RF signal, and generate the IP packets. MUs WBC receiver Running on MTs, this could be a Mobile Information Device application Profile (MIDP) Midlet application [40], a Connected Device Configuration (CDC) Xlet application [40], a Google Android application, a GWT application, etc. MUs User Profiles These help the WBC user application discover and associate with the 'best' SDs.

24 Chapter 3. WBC System Architecture

3.3. WBC Service Layer

The WBC service layer is concerned with the WBC service description model and service advertisement data collecting, clustering, scheduling, indexing and broadcasting on the WBC-SP node; and service discovery and association (at application enabler sub-layer) and IPDC over ADP (at service enabler sub-layer) on the MU node. Figure 3.3 illustrates the high-level view of the WBC service layer model.

SDs Collecting, Clustering, Scheduling, Indexing Discovery Association Application Enabler JSR 272 (Broadcast API) Sub-layer

WBC-ADP

WBC-ADP/ALC Protocols Service UDP Enabler Sub-layer IP/IPSEC

Figure 3.3: The WBC Service Layer Model

3.3.1. WBC Service Description Model

SDs are basic elements in WBC. Several formal languages could be used for abstract description of SDs, namely the augmented Backus-Naur form (ABNF [100]), the ASN.1-PER [27], the Document Type Definition - eXtensible Markup Language (DTD-XML [35]), etc. Compared with ABNF and DTD-XML, ASN.1 stores and transmits using compressed octets steam instead of plain text. Table 3.2 compares the sizes of SDs when encoded with ABNF, ASN.1, or DTD-XML. Since using as little bandwidth as possible is one of the WBC’s desired properties and because ASN.1 provides the smallest SD size, it has been chosen for the SD encoding as it is the most efficient one among the considered formal languages.

ASN.1 is a standard notation language used to describe data in telecommunication protocols. It is a powerful and flexible language that is independent of the software or hardware systems. With its ability to describe, encode and decode telecommunication protocols’ data structures, the ASN.1 has been used for a wide range of applications, such as email, telephony network management, IP-based voice and video services, etc [26, 27].

25 Chapter 3. WBC System Architecture

Table 3.2: SD Sizes in Different Formal Languages Formatting

SD Category ASN.1PER ABNF textual DTD-XML encoding [bytes] encoding [bytes] encoding [bytes] Bluetooth 61 189 293

SMS 91 274 449

News 123 343 601

Music album 153 459 758

Voice call 188 583 921

UMTS/Wi-Fi 220 682 1078

The formal standards of ASN.1 are published by the ITU-T, and the specification of basic notation was defined in ITU-T Rex X.680 [27]. The main notations in WBCs include basic types and structure types which are shown in Table 3.3.

Table 3.3: The ASN.1 Basic Types and Structure Types Used in WBCs

Division Type Name Description

Basic INTEGER Specifies an integer value. The value can be anyone or constrained, for example, INTEGER (1..10). Type BOOLEAN Specifies a Boolean value. The value is “true” or “false”.

BIT STRING Specifies a string of bit. The bit string can be assigned with name and length, for example, BIT STRING (a, b, c, d)(SIZE(4)). OCTET STRING Specifies a string of Octet. The Octet string can be assigned with a length, for example, OCTET STRING (SIZE(4)). IA5STRING Specifies an ASCII character. The length can be anyone or constrained, for example, IA5STRING(SIZE(1..10)). ENUMERATED Specifies a list of values that a field can take. The values should be formatted with the same type. Structure SEQUENCE Specifies a list of fields with different types. Type SEQUENCE OF Specifies a list of fields with the same type. The length can be constrained, for example, SEQUENCE (SIZE(1..4) OF aType. CHOICE Specifies a field that can be one of a number of types.

The ASN.1 includes a number of encoding rules for converting the notation into unambiguous byte stream. These include [101]:

 Basic encoding rules;

26 Chapter 3. WBC System Architecture

 Canonical encoding rules;  Distinguished encoding rules;  General string encoding rules;  Packed encoding rules (PER);  XML encoding rules; The PER was selected to encode a SD to byte stream. Compared with the other encoding rules, the PER uses minimum of bits to encode fields [101], which is appropriate for narrowband WBC. There are two variants in PER - aligned and unaligned. The unaligned version is selected for WBC as it does not encode fields on octet (byte) boundaries thus using less space. ASN.1-PER can work under a range of programming languages, including Java, C++, C or COBOL.

3.3.2. WBC Application Enabler Sub-Layer

Considering that the WBC is narrowband and that MTs are limited in power, on the WBC-SP node, all SDs need to be well organized to reduce the MT access time and tuning time. On the MT node, discovery and association schemes working with user personal profiles are used to enable the user to easily obtain information about the "best" wireless service(s) needed.

To enable the ADA processing to run in an efficient way, a heterogeneous software architecture combining an enterprise application environment and agent execution environment was proposed for facilitating the SDs' collection, clustering, scheduling, indexing, broadcasting, discovery and association [102].

The applications running at the WBC application enabler sub-layer are: on the WBC-SP node - an enterprise application with an enterprise MAS environment; on the MU node – an iWBC server with a light-weight MAS environment and iWBC receiver application.

Java is the ideal technology for the development of the WBC application enabler sub-layer because it provides solutions for a wide range of networks, computers and devices. With its versatility, efficiency, portability, and security properties, Java is running on 4.5 billion devices, and there are more than 6.5 million Java developers which are active within the Java dedicated community [103]. The Java technology is structured into four editions: Java Enterprise Edition (EE) [91], Java Standard Edition

27 Chapter 3. WBC System Architecture

(Java SE) [103], Java Micro Edition (ME) [40], and , as shown in Figure 3.4.

Figure 3.4: The Java Technology’s Editions

3.3.2.1. WBC-SP Node Enterprise Application

On the WBC-SP node, there are two types of actors - the xSP and the WBC-SP. The goal of the xSP is to submit his/her SDs to the WBC-SP server for broadcasting. The goal of the WBC-SP is to manage those SDs in an efficient way. An enterprise application needs to be developed on the WBC-SP node for running the WBC advertising business tasks.

Java EE is a widely used platform for developing enterprise applications. It is a standard used to provide functionality for deployment and management of an application running on an application server. It is well suited to developing the WBC-SP application.

28 Chapter 3. WBC System Architecture

Java EE includes a number of APIs and components specifications. The APIs include Java Database Connectivity (JDBC), Remote Method Invocation (RMI), e-mail, Java Message Service (JMS), web services, XML, etc. The components include Enterprise JavaBean version 3 (EJB3), Servlet, Connectors, Portlet, Java Server Page (JSP), Web Service, etc [91, 103-105]. Those technologies enable developers to build large-scale, distributed applications and to focus on business logic instead of integration and other tasks.

Figure 3.5 shows the Java EE environment.

Java EE Server

Web Browser Servlet JSP Page

Web Container Application Database Client

Application Client Enterprise Enterprise Container Bean Bean Client Machine EJB Container

Figure 3.5: The JAVA EE Environment

The core elements in the Java EE environment include [91]:

 Client Machine. It includes three types: (i) Web client consists of two parts. One is a dynamic web page generated by the web container and formatted with a markup language, such as XML, Hyper Text Markup Language (HTML), etc. Another is a web browser used to open the web page; (ii) Applet client is a small client application installed into the web browser. It is written in Java. To run the , the client side needs to install the ; (iii) Application client is an application that runs on the client machine. The application can directly access the EJB container or web container. Before running the application client, the user needs to download and install the WBC-SP application and Java runtime environment. The communication protocol between client machines and the WBC-SP server can be Hypertext Transfer Protocol (HTTP), HTTP Secure (HTTPS), RMI, etc.

29 Chapter 3. WBC System Architecture

 Web Container. It manages the JSP pages and Servlet components of the WBC-SP application. The JSP and Servlet maintain the client’s requests and responses [39]. Considering the web container part of Java EE is mainly working on low-level infrastructure and is heavily dependent on configuration, to develop a maintainable WBC-SP application and reduce the complexity, a light-weight application framework needs to be designed for developing the WBC-SP applications in a consistent manner. The framework should support the following components: enterprise services to Plain Old Java Objects (POJOs) [39], Inversion of Control (IoC) container [91], Aspect-Oriented Programming (AOP) framework [39], transaction management, Model-View-Controller (MVC) web framework [106], Java Message Service (JMS), Java Management Extensions (JMX) [35], Portlet, and a reasonable way to invoke a EJB3 service, MAS agents, and rule engine APIs.  EJB container. It manages the EJBs of the WBC-SP application. The EJB should run on Java EE EJB3 application server, such as JBOSS [107], Sun GlassFish [108], IBM Websphere [109], Weblogic [110], etc. EJBs in the WBC-SP application provide distributed support, e.g., ASN.1-PER encoder EJB should run on a dedicated encoder server, and the SDs template EJB should run on an international WBC-SP node, etc. There are three types of EJBs supported in Java EE: session bean, entity bean, and message driven bean [91].

3.3.2.2. MU Node Portable Application

The MT types may include a cell phone, Personal Digital Assistant (PDA), Ultra-Mobile PC (UMPC), laptop, etc. Those MTs may be organized in a WPAN based on Bluetooth, Zigbee, Z-wave, Wi-Fi, etc. The MU node portable application is named as iWBC application. As some MTs may not support the WBC carrier technique and because other mobile applications may also need to access the WBC mobile application to query SD’s information, the MU node’s portable iWBC is implemented with two parts – a light-weight iWBC content provider and a MT receiver’s User Interface (UI), such as the Google iWBC GWT UI, the Google iWBC Android UI, the Java ME iWBC MIDP UI, etc.

30 Chapter 3. WBC System Architecture

3.3.2.2.1. Light-weight iWBC Content Provider

In the personal mobile application’s background, a light-weight iWBC content provider runs on a light-weight HTTP container, which maintains SDs and personal profiles, enables the iWBC content provider to migrate from one MT to another, and makes it accessible to all other applications. The iWBC content provider is the core of the personal mobile application. It can run on a laptop, a UMPC or a PDA. There are a number of open-source HTTP containers available on the Internet, such as the Apache Tomcat, Sun GlassFish, etc [91]. These containers, however, are too heavy for installation, running and maintenance. Therefore, a light-weight HTTP container is required. The Java SE is a widely used platform for deploying portable applications. It is well suited for the development of the iWBC content provider.

The iWBC content provider has been developed in two parts:

 iWBC HTTP Container. It provides an environment to process HTTP requests and responses which are similar to the Microsoft Internet Server Application Programming Interface (ISAPI) web server [111]. In the iWBC HTTP container, each incoming request or outgoing response should ultimately be encapsulated by a HttpExchange object and processed by a specific instance of a class that implements the iWBCHandle interface.  iWBC Content Manager. It runs on the iWBC HTTP container acting as the server side in the personal mobile application. The main elements of the iWBC content provider include: Data Access Object (DAO) APIs and service handle APIs. To improve performance and remain light-weight, the DAO APIs in the persistence layer (Figure 3.6) should support an Object Oriented (OO) database instead of a relational database to avoid the heavy Object-Relation (OR) mapping operation. The OO database, such as DB4O [37], denotes one line of code database, which can save 90% of the cost for persistence development and can run up to 44 times faster than the relational database. The service handle APIs include SDs receiving services, SDs add/delete/modify/search services, profiles services, etc. Also, the iWBC content provider can work with the light-weight MAS. Figure 3.6 shows the light-weight design of the iWBC content provider.

31 Chapter 3. WBC System Architecture

iWBC APP 《Service Layer》 POJO & Business Logic Manager OO Database Receiver 《Presentation Layer》 《Persistence Layer》 UI DAO

Figure 3.6: The Light-weight Design of the iWBC Content Provider

3.3.2.2.2. iWBC-JSE UI

From the viewpoint of the MU, the iWBC-JSE UI is a browser version of the UI, and from the viewpoint of the iWBC content provider, it is a UI to manage all business services. As Asynchronous JavaScript and XML (AJAX) [112] is widely used for creating client-side web applications or rich Java applications, to provide a better user experience, the AJAX was selected to develop the iWBC-JSE UI. With AJAX, the dataset being transferred between server and client is the JavaScript Object Notation (JSON) object [113], which is fast as there are no page load events [43]. The Google Web Toolkit (GWT) is a front-end AJAX developing toolkit allowing developers to quickly build client side application with pure Java language [114]. The edit-refresh-view development cycle makes the implementation of iWBC JSE-UI easy. Also, the GWT provides lots of rich UI components, integrates JUnit and is easy to mix with any environment. Figure 3.7 shows the GWT client HTML and JavaScript generating steps.

JavaScript Client Java Code GWT Compiler HTML

Figure 3.7: The GWT Client HTML and JavaScript Generating Steps

3.3.2.2.3. iWBC-Android UI

The Google Android is an open-source software platform [41], which includes a small Linux operating system, a middleware and a number of APIs. It becomes part of the Open Handset Alliance (OHA). The first Android mobile G1 was released in the US

32 Chapter 3. WBC System Architecture and UK in 2008. The Android software architecture (stack) is shown in Figure 3.8 and described in more detail below.

Application Layer

Native Apps Third-Party Developer iWBC (Contacts, Maps, Browser, etc.) Apps Apps Receiver

Application Framework

Location-Based Content Window Activity Package Services Providers Manager Manager Manager

Resource Telephony P2P/IM Notifications Views Manager

Libraries

Graphics Media SSL & WebKit Android (OpenGL, SGL, FreeType) Libraries

Surface Libc SQLite Manager Virtual Machine

Linux Kernel

Hardware Drivers Power Process Memory (USB, Display, Bluetooth, etc.) Management Management Management

Figure 3.8: The Android Software Stack [41]

 Linux kernel: The Android mobile operating system runs on the Linux kernel version 2.6 for handling the hardware drivers, memory management, process management, power management, etc.  Libraries: These are C/C++ core libraries running on the top of the kernel, mainly including Libc, SSL & Webkit, media, graphics, SQLite libraries.  Android run-time: It is the engine that powers Android WBC UI applications. The run-time includes the core Java libraries and the Dalvik virtual machine, which relies on the Linux kernel ensuring that a device can run multiple instances efficiently.  Application Framework: It provides the classes used to create Android applications.  Application Layer: The Android iWBC receiver application runs at this layer, which should be developed based on the available classes of the application framework.

33 Chapter 3. WBC System Architecture

The Android Software Development Toolkit (SDK) includes everything for the designer to develop, test, debug and complete application. The WBC Android receiver mainly includes five components:

 Activities, which present UI Forms in the application. Each activity can be invoked from the other applications;  Services, which act as invisible workers to finish the business logic of the WBC application. Like the activities, the services run in the main thread of the application;  Broadcast receivers, which are components for receiving and reacting to broadcast announcements. The number of broadcast receivers can be multiple, and receivers can start an activity or notify the user to pay attention. Receivers should extend from the BroadcastReceiver base class;  Android content providers, which are used to manage and share WBC DB4O databases and enable other applications to access the WBC receiver database.  Intents - the activities, services, and broadcast receivers can become active through intent messages. A number of pieces of information are used to describe the message, such as action, data and category attributes.

3.3.2.2.4. iWBC-MIDP UI

To run the WBC client application on low-end MTs with limited capabilities, among all the current technologies the Java ME is the best solution for a wide range of small devices, such as mobile phones, PDAs, TV set-top boxes, printers, etc. Java ME on handsets is supported by all major phone vendors [40]. Java ME uses configuration to define a Java run-time environment for devices. There are two types of configurations applied based on memory and screen size: (i) Connected Device Configuration (CDC) – which needs 512 kilobytes of memory to run a Java application; (ii) Connected Limited Device Configuration (CLDC) – which only needs 128 kilobytes of memory to run a Java application [39]. The CLDC Java platform is suitable for developing the low-end WBC client application.

To address the MT’s capabilities, on the top of CLDC, a Mobile Information Device Profile (MIDP) extends from CLDC core libraries for providing UI APIs, input and event handling mechanism, persistent storage solution, network connectivity, etc. The extensions take into consideration the screen size and memory limitations of MTs.

34 Chapter 3. WBC System Architecture

The MIDP and CLDC are closely tied to the Java K Virtual Machine (KVM) which translates the Java class files into machine code for execution. The KVM runs on the top of the host operating system and considers the resource limited MTs for meeting the CLDC specification. The KVM itself only requires 80 kilobytes of memory. Figure 3.9 shows the MIDP architecture.

MIDP

CLDC Core Libraries

K Virtual Machine (KVM)

Host Operating System

Figure 3.9: The MIDP Architecture

The MIDP application derives from a MIDlet class. MIDlet is a Java application framework for controlling the application’s life cycle, i.e., loading, activing, pausing, and destroying the application. The methods include startApp(), pauseApp(), and destroyApp(). The Sun Java Wireless Toolkit is an efficient and quick toolbox for developing the MIDP application [115].

3.3.2.3. Multi-Agent System (MAS)

The MAS is an environment composed of a number of interacting intelligent agents which work together to solve a particular problem. The agent is the basic element in the MAS with the following properties recommended by the Foundation of Intelligent Physical Agents (FIPA) [44]:

 Mobility: An agent can migrate from one environment to another. It can suspend the execution, save the status, move to another machine and resume the execution later.  Communication: Agents can communicate with each other by mean of the Agent Communication Language (ACL), using messages such as inform, request, agree, understand, etc. A content language is defined in the ACL for knowledge exchange. It includes actions, objects, and propositions. The ontology is used in the content language for describing a subject domain.

35 Chapter 3. WBC System Architecture

 Coordination: The agents should work together to complete a particular job, such as SDs collecting, clustering, scheduling, or indexing. There are four main structures in the coordination: commitments, convention, social conventions, and local reasoning.  Negotiation: To achieve the goals of each agent, the negotiation is the process used for agents’ joint decision. The Java Agent Development Framework (JADE) is a FIPA specification compatible open-source software framework fully implemented in Java [44, 116]. It is suitable to act as a MAS middleware for facilitating the ADA processing in the WBC system. The WBC-SP node should include SDs collecting, clustering, scheduling, indexing and broadcasting agents. The WBC-MU node should include a discovery agent, association agent and Personal Assistance Agent (PAA). The JADE mainly consists of three parts: a runtime environment for execution of agents, a library for agents development, and a graphical tool for agents monitoring. Figure 3.10 shows the JADE architecture and it’s compatibility with Java EE, Java SE, and Java ME/Android environment.

Figure 3.10: The JADE Architecture

The agent platform is the kernel of the MAS. It contains a number of active containers. The main container must always be active: all other containers need to register with it. The main container provides Agent Management System (AMS), Directory Facilitator

36 Chapter 3. WBC System Architecture

(DF), and message transport services [117]. In JADE, each agent lives in a container, which can dynamically discover other agents and communicate in peer-to-peer mode.

Considering the WBC system is built with heterogeneous architecture, the MAS should support all versions of the Java environment. The JADE-LEAP (JADE powered by LEAP [118]) is selected for developing the uniform WBC-JADE light-weight MAS system. Four main packages are included in WBC-JADE:

 jade.core - all agents should extend from the Agent Java class. To design a light-weight MAS, only two Behaviours - OneShotBehaviour and CyclicBehaviour are supported in WBC-JADE;  jade.lang.acl - provides ACL support with FIPA standard specifications;  jade.content - the WBC ontologies and content languages are supported in this package;  jade.domain - provides agent life-cycle management. The AMS and DF agents are included in this package.

3.3.2.4. Java Rule Engine

Different areas may apply different business logics. For instance, on the WBC-SP node, a small country may broadcast SDs in a flat mode, whereas a big country may broadcast SDs in a skew mode. In addition, the collecting, clustering, scheduling, indexing rules for different areas may be different. On the MU node, the MU’s profiles may be dynamically changed, and different MTs have different profiles. To be able to dynamically change the business logic and efficiently manage the WBC system, the Java rule engine API was selected for controlling the business's behaviours [47]. Other benefits of using this Java rule engine in the WBC system are the separation of the business logic from the system implementation and lack of necessity of changing the source code when the business logic is updated.

The Drools - an open-source pure Java rule engine platform developed by JBOSS and enhanced by implementing the Rete algorithm for OO systems with the forward chaining excitation method - is suited to act as the rule engine API in the WBC system [47]. There are four components in Drools: facts (SDs, profiles, WBC segments, etc) asserted into the working memory; rules stored in production memory; pattern matcher used for deciding which rules are true for facts assertion; and agenda,

37 Chapter 3. WBC System Architecture which is a tool to manage the execution order by a conflict resolution strategy. Figure 3.11 shows the ReteOO system.

Inference Engine (ReteOO)

Production Pattern Working Memory Matcher Memory

(rules) (facts)

Agenda

Figure 3.11: The ReteOO System

The main methods in Drools include:

 Get URL for the DRL file (contain rules) with RecipeFinder.class.getResource ("*.java.drl");  Create RuleBase with RuleBaseLoader.loadFromUrl(url);  Create a working memory with ruleBase.newWorkingMemory();  Assert facts with workingMemory.assertObject(Java Object);  Create search results object with new SearchResults();  Set application data with workingMemory.setApplicationData("Results", new ArrayList());  Rules firing with workingMemory.fireAllRules();

3.3.3. WBC Service Enabler Sub-Layer

The WBC application sub-layer outputs WBC segments (each WBC segment is a small equal-size byte file which as described in the next chapter) [3]. Considering the "all-IP" networking as one of the visionary goals for the Next Generation Networks (NGN), the MTs should be able to receive all wireless service advertisements delivered from xSPs over an IP-based backbone. To enable the IP datacasting (IPDC) processing and provide reliability in the WBC service layer, a unidirectional protocol to convert WBC segments into IP packets with a redundancy Forward Error Correction (FEC) scheme should be developed.

38 Chapter 3. WBC System Architecture

The Reliable Multicast Transmission (RMT) IETF working group [119-122] has published a set of standards for one-to-many multicasting, in terms of Building Blocks (BBs) and Protocol Instantiations (PIs) [120]. BBs are the basic components which can plug/unplug into/from PI. Four BBs have been specified: Layered Coding Transport (LCT) BB, FEC BB, Congestion Control (CC) BB, and authentication BB. Two types of PIs have been designed: Asynchronous Layered Coding (ALC) [120] relying on FEC and NACK Oriented Reliable Multicast (NORM) relying on Automatic Repeat-reQuest (ARQ). Several reliable and unidirectional packet-level file casting protocols have been developed recently, such as File multicasting (FCAST) [121] and File Delivery over Unidirectional Transport (FLUTE) [122], published by the IETF working group and planete-bcast team respectively. The common features of these protocols include:

 Built on Asynchronous Layered Coding (ALC) standard protocols;  Files broadcasting with extra data, i.e., File Delivery Table (FDT) in Flute and Meta-data in FCAST;  Push and on demand modes support;  IPv4 and IPv6 support;  Complexity of the file WBC segment algorithm;  Various FEC algorithms supported [123];  CC support; One of the desired properties for the WBC is that it should use as little bandwidth as possible. However in addition to being complex, the above protocols use extra XML/meta-data and produce large overhead. The CC BB and authentication BB make these protocols complex. That’s why they are not suitable for the narrowband WBC. For above reason, a simplex and efficient Advertisements Delivery Protocol (ADP) was developed, as explained later in section 4.5.

3.4. WBC Link Layer

In this thesis, the DVB-H is selected as the WBC carrier as discussed in section 3.5. The WBC link layer acts as an interface between the service layer and the physical layer for converting the IP packets into TS packets and vice versa. A conceptual scheme of the ‘WBC over DVB-H’ link layer is shown in Figure 3.12.

39 Chapter 3. WBC System Architecture

MPEG-2 TV Service MPEG-2 TV Service MPEG-2 TV Service TS MPEG-2 TV Service MUX DVB-T Modulator

WBC DVB-H RF Segments in IP IP-Encapsulator MPE- Time Transmitter MPE FEC Slicing

Channel

RF Receiver DVB-H TS IP-Decapsulator DVB-T WBC Time MPE- Demodulator MPE Slicing FEC Segments in IP

Figure 3.12: The Conceptual Scheme of the 'WBC over DVB-H' Link Layer

In 2004, the European Telecommunications Standards Institute (ETSI) ratified the standard of DVB-H by adding a link layer on top of the Digital Video Broadcasting Terrestrial (DVB-T) standard [5, 54, 124], which layer takes into account the specific properties of typical portable MTs, such as limited battery-life, various signal environments, propagation loss of indoor reception, limited antenna gain, poor weather conditions, etc. To enable IPDC function [49-52], two new features were introduced into the DVB-H link layer, namely the time-slicing and MPE-FEC. These two features are defined in the ETSI EN 301-192 specification [125]. The implementation guidelines are defined in the ETSI TR 102-377 specification [126].

3.4.1. Time Slicing

In DVB-T, all channels are multiplexed by means of an Orthogonal Frequency Division Multiplexing (OFDM) technique and broadcast in parallel. To receive data from a channel, MTs need to stay in active mode all the time, with no allowance made for the need to conserve battery power in the mobile unit. Responding to the normal MT requirement of efficient use of battery energy –maximizing battery inter-charge life–, a time-slicing mechanism is used in DVB-H for arranging the data broadcasting in a burst mode. Figure 3.13 shows non time-sliced DVB-T streams multiplexing with time-sliced DVB-H data streams.

40 Chapter 3. WBC System Architecture

Figure 3.13: The Use of Time-Slicing for 'WBC over DVB-H'

With this mechanism MT remains most of the time in a sleep mode and becomes active only when a target burst is broadcast on air. A target burst is one likely to contain service description data of interest to the mobile user, as determined by his/her profile stored on the MT. The off-time between each burst is denoted by ETSI as Ot (seconds) and the relative minimum time to the beginning of the next burst from the start of the present MPE (or MPE-FEC) section being received is delta-t [126]. To successfully receive a data burst, the MT should become active a little bit before the scheduled arrival of the target burst. This is to allow for variation in the actual arrival time from the scheduled arrival time due to the delta-t jitter D j (10ms by default) and the synchronization-time St (250ms by default) [126].

The ‘WBC over DVB-H’ Protocol Data Unit (PDU) encapsulation example is presented in Figure 3.14.

The WBC burst duration is defined in [126] as:

Bs Bd  , (3.1) Br  1 overhead where Bs is the burst size (bits), Br is the burst bit rate (bits per second), and overhead is the overhead fraction resulting from the TS packet and section headers.

By comparison with a Constant Bit Rate (CBR) channel, the power saving when employing the time-slicing mechanism could be calculated as in [126]:

41 Chapter 3. WBC System Architecture

BdtS0.75  D jC b1  overhead  1 , (3.2) Bs where Cb denotes the constant bit rate (bits per second).

3.4.2. MPE-FEC Frame

The MPE-FEC frame is the core PDU at the link layer. MPE-FEC was introduced into DVB-H to compensate for the performance degradations due to wireless fading channels [60]. It is constructed as a table consisting of 255 columns and a number of rows (256, 512, 768, or 1024 [8]). Each cell in the table contains one byte. The 255 columns are divided into two parts: from 1st to 191st - an Application Data Table (ADT), and from 192nd to 255th – a Reed-Solomon Data Table (RSDT). The IP packets are installed into the ADT column-wise, one by one. A Reed-Solomon (RS) code is used on each row of ADT for improving the link layer error protection. Some parity columns are punctured to achieve different MPE-FEC code rates. Usually one DVB-H burst contains only one MPE-FEC frame. Each DVB-H burst carries a number of WBC segments [10].

3.4.3. Link Layer PDU Encapsulation

The MPE-FEC is built at the Logical Link Control (LLC) sub-layer of the DVB-H link layer. At the Medium Access Control (MAC) sub-layer of the sender, each IP packet in the ADT and each column of the RSDT are extracted for adding a MAC overhead, i.e., 12B MPE/FEC header and 4B Cyclic Redundancy Check (CRC)-32 trailer. The resultant MPE/FEC data units are WBC segmented into MPEG-2 TS packets for broadcasting over the channel. Each TS packet consists of 4B header and 184B payload, and is encoded at the physical layer by using an RS(204, 188) code for further error protection. The ‘WBC over DVB-H’ PDU encapsulation example is presented in Figure 3.14. In this example, the average SD size is 180B, the WBC segment length is 3808B, the ADP message length is 507B, and the IPv4 datagram length is 535B. A 8B Correct Segment Index Table (CSIT) is used for improving receiver’s reliability as described in Chapter 6.2.

42 Chapter 3. WBC System Architecture

WBC Segment (3992B)

Application SD21 Index SD2 SD3 Enabler SD1 ... Sublayer ...

Source Source FEC FEC symbol 1 ... symbol 8 symbol 1 symbol 2 10 ADP messages (x 507B) Service 8B ADP Data (1) ... 8B ADP Data (10) ... Enabler Sublayer 8B UDP Data ... 10 UDP datagrams (x 515B)

20B IP Data ... 10 IPv4 datagrams (x 535B) WBC Service Layer WBC Link Layer

Application Data Table (191) RS Data Table (64) 1IP Section 191 16FEC Section 4

RS (255,191) gram Parity bytes carried in section 1 section in carried bytes Parity 2 section in carried bytes Parity Parity bytesin last FECsection gram First punctured RScolumn Last punctured RS column gram gram No of Rows (512) No of Rows Padding 180th IP data- IP 180th

LLC data-1st IP Sublayer 2nd IP data-

3rd IP data- IP 3rd ...... CSIT

MPE-FEC frame

180 MPE datagrams 12B IP datagram (or parity section) CRC-32 ... MAC (x 551B) Sublayer 540 MPEG-2 TS 4B 184B 4B 184B 4B 184B ... TS packet 1 TS packet 2 TS packet 3 packets (x 188B) WBC Physical Layer Burst ()B Duration d Off-Time ()Ot

Burst PHY Burst ()B Bit Rate Size s ()Br

Constant Bit Rate ()C b

18 WBC segments

Figure 3.14: The 'WBC over DVB-H' Link Layer PDU Encapsulation

43 Chapter 3. WBC System Architecture

3.4.4. Software and Hardware Solutions

For performance analysis, the WBC link layer has been emulated in software, such as C++, Matlab, etc. For proof-of-concept testbed demonstration, the ‘WBC over DVB-H’ link layer has been implemented in hardware. The UDCast [127], a professional company providing IP broadcast solutions for DVB-H, has been selected as the DVB-H link layer encapsulator equipment provider. The TeamCast [128], a manufacturing company for DVB-H receivers, has been selected as the DVB-H link layer decapsulator equipment provider.

3.5. WBC Physical Layer

The WBC broadcast channels will be simplex and relatively narrowband [1]. Several types of carriers at different geographic coverage regimes are envisaged: local (e.g., based on Worldwide Interoperability for Microwave Access (WiMax), Digital Audio Broadcasting (DAB), or DVB-H in L-Band), regional (e.g., based on DVB-H in Ultra High Frequency (UHF)), national (e.g., based on Digital Radio Mondiale (DRM), DAB or DVB-H), and global (e.g., based on Satellite DVB, or Satellite DAB) [1]. The spectrum resources required will not be significant which should help the process of seeking agreed spectrum allocations. Among the above carriers’ techniques, the DVB-H, which its support for IP datacasting and flexibility on national/regional/local coverage, has the potential to be exploited effectively in creating a WBC system.

The physical layer of DVB-H is based on the DVB-T standard and three new features as guided in [70, 126]:

 Transmission Parameter Signalling (TPS) - used to enhance and speed up the service discovery;  4K mode - offers an additional trade-off between the single-frequency network cell size and mobile reception performance;  In-depth symbol interleaving - increases the flexibility of symbol interleaving thus improving robustness in mobile environments and impulse noise conditions. From the viewpoint of the top layer (link layer), the 'WBC over DVB-H' physical layer is envisaged as a binary symmetric noise fading channel.

44 Chapter 3. WBC System Architecture

The ‘WBC over DVB-H’ physical layer employs the OFDM technique (Figure 3.15). In addition, an RS(n,k) code algorithm (n=204, k=188), a convolution algorithm and a number of interleaving schemes are included in the standard for error protection at this layer.

Mux TS Adaptation Outer Outer Inner Mux Energy Coder Interleaver Coder Dispersal Inner (Bit) Splitter Interleaver Mux Adaptation Outer Outer Inner Energy Coder Interleaver Coder Dispersal

Inner Guard Frame To (Symbol) Mapper OFDM Interval D/A Front End Adaptation Aerial Interleaver Insertion

Includes new 4K Pilot and Pilot positions Addition of Change for interleaver and TPS are same as 4K FFT different guard TPS control of Signals 'first half' of interval sizes for interleaver depth 8K pilot 4K mode positions Figure 3.15: The Functional Block Diagram of the ‘WBC over DVB-H’ Physical Layer [70]

The multiplexer (MUX) in the DVB-H physical layer provides ability for different datacast network operators to share the same broadcasting channel. This enables WBC-SP broadcasting in flexible mode, i.e., to use a narrow dedicated channel for broadcasting or sharing with other channels. The MUX input are fixed-size 188-byte TS packets. The TS packet’s header structure is shown in Table 3.4.

Table 3.4: The TS Packet’s Header Structure

Field Name Size (bits) Description

Synchronization byte 8 Fixed value of 0x47.

TS error indicator 1 To let link layer finding the TS packet error.

Payload unit start 1 Sets the payload start.

Priority 1 ‘1’ means higher-priority TS packet.

PID 13 Packet identifier.

Scrambling control 2 Contains scrambling controlling information.

Adaptation field 2 Contains the adaptation value. control Continuity counter 4 Incremented for each packet in one PID.

45 Chapter 3. WBC System Architecture

The DVB-H system uses an OFDM frame to transmit the signal. Each OFDM frame consists of 68 OFDM symbols. Four OFDM frames constitute a super OFDM frame [58]. An OFDM symbol consists of a number of carriers, composed of a payload and guard interval.

3.5.1. Software and Hardware Solutions

Similarly to the link layer, for performance analysis the WBC physical layer has been emulated in software, whereas for proof-of-concept testbed demonstration, this layer has been implemented in hardware. The UDCast and TeamCast are selected as the DVB-H physical layer equipment providers.

3.5.2. Wireless Fading Channels

Previous studies have shown that errors in wireless channels appear in bursts mode due to multipath propagation [8, 71, 129-133]. In [132], a FSMM to represent Rayleigh fading channels in non-interleaving coding systems is introduced. In [55], a finite-state run length model for simulating the TS packet error behaviour in a multipath channel environment is presented, but the model’s parameters are obtained by unbiased estimators. In [71], a 2SRL for analyzing the throughput in fading channels is proposed. However, the details of the fading channel and the manner of obtaining the parameters of the model are not explained. Despite the fact that the Rayleigh fading channel with a central chi-square distribution is well known as a flexible model that provides a definable number of degrees of freedom to experimental fading channel measurements for outdoor environments [134], there are very few studies for 2SRL over a central chi-square distribution Rayleigh channel. To evaluate the overhead efficiency, WBC segment access time and tuning time in a ‘WBC over DVB-H’ system, a 2SRL model for simulating the TS packets outputting behaviour built on an interleaving block system with the received signal envelope having a central chi-square distribution has been implemented, as described in section 8.2.

3.5.3. Other Carriers

The T-DMB has also been studied as a WBC carrier, as shown in Appendix C.

46 Chapter 3. WBC System Architecture

3.6. Conclusion

This chapter has provided an insight into the WBC system and presented an overview of the WBC three-layer architecture.

In the service layer of the WBC-SP node, an intelligent enterprise application working with a MAS and rule engine for facilitating SDs collecting, clustering, scheduling and broadcasting should be developed with Java EE. On the MUs node, a portable personal mobile application which includes a light-weight intelligent iWBC content provider, a iWBC-JSE UI, a iWBC-MIDP UI and an iWBC-Android UI working with light-weight MAS for facilitating SDs discovery and association should be developed with Java SE, Java ME and Android, respectively. Finally, a simplex and efficient ADP to enable the IPDC processing and provide reliability in the WBC service layer should be developed.

In the link layer, different aspects of the ‘WBC over DVB-H’ system have been discussed. An overview of the time slicing, MPE-FEC frame, and PDU encapsulation has been given. The possible hardware and software solutions have been presented.

In the physical layer, an overview of the DVB-H standard, which is well suited as a WBC carrier, has been presented. The possible software and hardware solutions have been discussed. The need of developing a 2SRL model for simulating the TS packets outputting behaviour has been justified.

Details of the design and implementation of each layer of the ‘WBC over DVB-H’ system are presented in the following four chapters starting with the top layer.

47 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

CHAPTER 4. WBC SERVICE LAYER – WBC-SP SIDE’S DESIGN AND IMPLEMENTATION

4.1. Introduction

This chapter describes the design and implementation of the WBC service layer on the WBC-SP side for facilitating the wireless service advertisement processing, i.e., SDs’ collecting, clustering, scheduling, indexing and broadcasting. The potential techniques for formatting the SDs and the implementating the WBC service layer have been stated in Chapter 3. The SDs are described by the ASN.1 notation language and encoded to octet streams by an ANS.1-PER encoder. The WBC service layer on the SP side includes two sub-layers. At the application enabler sub-layer, a heterogeneous software architecture which combines a Java EE environment and an agent execution environment has been developed for facilitating the wireless service advertisements (Figure 3.2 part 1). At the service enabler sub-layer, an ADP protocol has been developed for encapsulating the WBC segments into IP packets (Figure 3.2 part 2). Besides supporting the IPDC functioning, improving the data access efficiency (i.e., reducing the access time and tuning time) is another goal when developing the service layer of the WBC-SP side.

4.2. Design and Implementation of SDs Encoder

The ITU-T ASN.1 [27, 101] is well known as a reliable description language that uses compactable rules for representing, encoding and decoding data in telecommunications protocols. It is closely tied to the Java programming language [135]. An example of a

SD’s ASN.1 template (TSASMS) for the WBC teleservice SMS is shown below [15].

SampleTSASMS DEFINITIONS IMPLICIT TAGS ::= BEGIN IMPORTS WBCTSSMS FROM WBC; SampleTSASMS ::= SEQUENCE { service-Type Service-Type, ccpp CCPP, length SDLength OPTIONAL,

48 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

attributes Attributes } Service-Type ::= SEQUENCE { Division OCTET STRING(SIZE(1..16)), category OCTET STRING(SIZE(1..16)), type OCTET STRING(SIZE(1..16)), version OCTET STRING(SIZE(1..16)) } CCPP ::= CHOICE{ defaultCCPP [0] SEQUENCE OF CCPPProperty, notDefaultCCPP [1] SEQUENCE OF CCPPProperty } Attributes ::= WBCTSSMS END To integrate the ASN.1-PER scheme into the WBC service layer, all SD templates were compiled into Java classes with an ASN.1 Java compiler (Figure 4.1).

SD Templates with ASN.1

Common APIs Dictionary

ASN.1 Compiler For Java

3P-AAA APIs POJOs Java Classes

Advertiser Parameter I/O (SP) Values SD Java ASN.1 Encoder/Decoder PER Octets Object

Figure 4.1: The ASN.1-PER Encoding/Decoding of SDs

There are several important APIs in the ASN.1-PER encoder/decoder:

 SD POJOs: All SD’s parameters are carried by the SD plain old Java objects (POJOs). An example of a SD's Java class diagram (AWBCTSASMS) and an attribute Java class diagram (WBCTSASMS) for the WBC teleservice SMS is shown in Figure 4.2.  Dictionary: The dictionary decodes values transmitted on the WBC into names represented by those values. For instance, a service type with the value "0x5002004001" might represent a "StockTicker".  3P-AAA APIs: These APIs help WBC-SP to obtain the SD's usage data from a third-party authentication, authorization and accounting (3P-AAA) server.  Common APIs: To improve the software development efficiency, a number of basic WBC ASN.1 APIs were implemented, such as, fast_print, log, SDtoByte, Hexprint, etc.

49 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

Service_Type CCPP -c_typeinfo: SequenceInfo = new SequenceInfo( ) +defaultCCPP_chosen: int = 1 +notDefaultCCPP_chosen: int = 2 <>+Service_Type() -c_typeinfo: ChoiceInfo = new ChoiceInfo() <>+Service_Type(division, category, type, version) +initComponents() <>+CCPP() +createInstance(index: int): AbstractData +createCCPPWithDefaultCCPP(defaultCCPP): CCPP +getDivision(): OctetString +hasDefaultCCPP(): boolean +setDivision(division: OctetString) +setDefaultCCPP(defaultCCPP: DefaultCCPP) +getCategory(): OctetString +createCCPPWithNotDefaultCCPP(notDefaultCCPP): CCPP +setCategory(category: OctetString) +hasNotDefaultCCPP(): boolean +getType(): OctetString +setNotDefaultCCPP(notDefaultCCPP: NotDefaultCCPP) +setType(type: OctetString) +createInstance(chosen: int): AbstractData +getVersion(): OctetString +getTypeInfo(): TypeInfo +setVersion(version: OctetString) +getStaticTypeInfo(): TypeInfo +getTypeInfo(): TypeInfo +getStaticTypeInfo(): TypeInfo

AWBCTSASMS -c_typeinfo: SequenceInfo = new SequenceInfo() <>+AWBCTSASMS() <>+AWBCTSASMS(service_Type: Service_Type, ccpp: CCPP, length: SDLength, attributes: Attributes) <>+AWBCTSASMS(service_Type: Service_Type, ccpp: CCPP, attributes: Attributes) +initComponents() +createInstance(index: int): AbstractData +getService_Type(): Service_Type +setService_Type(service_Type: Service_Type) +getCcpp(): CCPP +setCcpp(ccpp: CCPP) +getLength(): SDLength +setLength(length: SDLength) +hasLength(): boolean +deleteLength() +getAttributes(): Attributes +setAttributes(attributes: Attributes) +getTypeInfo(): TypeInfo +getStaticTypeInfo(): TypeInfo +isPDU(): boolean

SDLength Attributes CCPPProperty -c_typeinfo: IntegerInfo -c_typeinfo: SequenceInfo -c_typeinfo: VectorInfo <>+Attributes() <>+SDLength() <>+CCPPProperty() <>+SDLength(value: short) +getTypeInfo(): TypeInfo <>+CCPPProperty(value: byte) +getStaticTypeInfo(): TypeInfo <>+SDLength(value: int) +getTypeInfo(): TypeInfo <>+SDLength(value: long) +getStaticTypeInfo(): TypeInfo +getTypeInfo(): TypeInfo +getStaticTypeInfo(): TypeInfo WBCTSASMS

WBCTSSMS -c_typeinfo: SequenceInfo = new SequenceInfo() <>+WBCTSSMS() <>+WBCTSSMS(name, features, cost, supportedANs, advertiserText, advertiserURL) <>+WBCTSSMS(name, features, cost, supportedANs) +initComponents() +createInstance(index: int): AbstractData +getName(): IA5String +setName(name: IA5String) +getFeatures(): SMSFeatures +setFeatures(features: SMSFeatures) +getCost(): CallCost +setCost(cost: CallCost) +getSupportedANs(): SupportedANs +setSupportedANs(supportedANs: SupportedANs) +getAdvertiserText(): IA5String +setAdvertiserText(advertiserText: IA5String) +hasAdvertiserText(): boolean +deleteAdvertiserText() +getAdvertiserURL(): IA5String +setAdvertiserURL(advertiserURL: IA5String) +hasAdvertiserURL(): boolean +deleteAdvertiserURL() +getTypeInfo(): TypeInfo +getStaticTypeInfo(): TypeInfo

Figure 4.2: The Class Diagram of AWBCTSASMS and WBCTSSMS

50 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

The ASN.1-PER encoder depends on the Java classes used for encoding a Java SD object into PER octets. The Encoding_TSASMS class diagram is shown in Figure 4.3.

SampleTSASMS

+valueWBCTSASTS: wbcts.wbctsasms.AWBCTSASMS = init_valueWBCTSASTS() -init_valueWBCTSASTS(): wbcts.wbctsasms.AWBCTSASMS

Encoding_TSASMS

~write: int = 0

~toHstring(value: byte): String ~bytetostring(bytearray: byte): String +Wbcts.initialize() +new_Wbcts(): ASN1Project +Wbcts.getPERAlignedCoder() +new_SampleTSASMS(): SampleTSASMS +encode(SampleTSASMS.valueWBCTSASTS, sink: ByteArrayOutputStream) +sink_toByteArray(): byte[]

Figure 4.3: The Class Diagram of Encoding_TSASMS

The output bytes of a sample SD are as follows:

80640047 00481039 38000100 3401C8C3 78626F77 01027C01 2BC40401 55699360 03000330 74717865 30777564 6C30716A 796A0035 0003306F 63726930 65776971 307A6F63 68403200 03306869 70663062 6B656730 67676D65 84383601 03306971 69783064 6B667930 63747367 01050182 313204C0 010F8476 6D366F4C 4D9C3A90 03265003 227727A0 046F747A 74046772 6F63 4.3. Architectural Design of Application Enabler Sub-Layer

The WBC service layer's architecture is built on three tiers (Figure 4.4):

1) Service discovery and maintenance tier.

As stated in Chapter 3, the Java EE is an effective, hardware-independent platform for building enterprise applications. It is well suited for building the service layer application on the WBC-SP side. There are two actors in this tier: xSPs, who submit their SDs to the WBC content database in a competitive way via the WBC-SP web portal; and WBC-SP, who maintains the roles and databases, and defines the WBC broadcasting parameters, etc.

2) Application tier.

To simplify the system design and enable the system decoupling [106], this tier is implemented as an expert system for maintaining the business logic and WBC algorithms. A set of APIs, such as common APIs, ontology APIs, SD’s processing APIs, intelligent rule-engine APIs, etc, are shared with the other two tiers.

51 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

3) MAS container tier.

This tier is an agent run-time environment for facilitating the SDs' collection, clustering, scheduling, indexing, and broadcasting. A shared blackboard 5 and gateway agent are used for agent's communication and tier's communication, respectively.

A Message Channel (MC) is shared by the three tiers as shown in Figure 4.4.

Java SE Client Application

WEB Application WBC WEB MVC IoC Container WEB Service Context

Remote / Local Service Builder

Business Logic Local/Remote Portlet API WBC AOP APIs POJO APIs (JSR-168)

O/R Mapping Mail DAO

Service Discovery and Maintenance Tier

Server Application Shared WBC Rule Common Collecting APIs Ontology Engine APIs Clustering APIs APIs DB MC Broadcasting Rule Scheduling APIs APIs Engine ADP APIs APIs Indexing APIs Application Tier

Gateway Agent Main WBC Yellow Page Shared Container Services Blackboard PAA

...... Collecting Clustering Scheduling Indexing Container Container Container Container

MAS Container Tier

Figure 4.4: The WBC Application Enabler Sub-Layer's (WBC-SP Side) Architecture

This three-tier’ architecture provides the following benefits:

5 Blackboard - A basic element in expert systems and multiple agent systems, serving as sharing data structure during the execution cycle.

52 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

 Extensibility: Any addition or modification of a WBC functionality does not impact the system existing functionality as the architecture is component-based, which allows the WBC designer to separate the roles in the WBC application. For example, the Java SE client application handles presentation, the service discovery and maintenance tier handles routing, the application tier handles algorithms, and the MAS container tier handles the agents running environment.  Maintainability: Maintaining the system performance and correcting the flaws in the existing WBC functionality do not impact the others components.  Flexibility: Changing an existing function, moving to another environment, or adding a new function to the architecture are supported with great level of flexibility.  Efficiency: Implementing the system with the OO design makes the system extensible and effective.  Distributed model: The architecture offers a multi-tiered distributed enterprise application model. Different components/tiers can run in different servers; for example, the ASN.1 encoder EJB runs in a PER server, the authorization EJB runs in an AAA server, etc.

4.3.1. Design of Service Discovery and Maintenance Tier

This tier provides a scalable, Internet-based enterprise application on the WBC-SP node. It consists of three sub-tiers: a presentation sub-tier acting as an interface between the actors (WBC-SP, xSPs) and the system; a business logic sub-tier, which follows the delegate design pattern to decouple the business logics and codes [136], and exposes simpler interfaces for other sub-tiers/tiers; and a persistence sub-tier concerned with the storing/retrieving of POJOs into/from databases, i.e. SD database, xSP database, WBC system parameters' database, broadcasting database, WBC-SP intelligent rules' database, etc.

4.3.1.1. Presentation Sub-Tier

In accessing the WBC system, either a local mode (HTML/Applet) or remote mode (web service) could be used to process the requests/responses. A personalized

53 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation interface was defined by the personal business roles and a history via the WBC-SP web portal. A set of design patterns is used at this sub-tier: an MVC module that works with the business delegate module for communication with the business sub-tier via a remote/local service builder; an IoC pattern (dependency injection) that minimizes dependencies of the other sub-tiers, uses a factory class for creating and assembling objects with configuration files (maintained by a web application context component) [39], and improves system testability and loose-coupling property (i.e., a “mock” object can be injected into the WBC test environment for replacing a “live” service [35]; an AOP interceptor pattern that works on top of the IoC to facilitate modularization of crosscutting concerns (i.e., to enable encapsulation of functionality that affects multiple classes in separate units [35]). All advice methods and pointcuts are represented by reconfigurable XML files to monitor and manage the system easily [33]. Figure 4.5 depicts the structure of the presentation sub-tier.

Business Sublayer

WBC Business Delegate

WBC AOP Interceptors

WBC IoC Container

WBC MVC Actions

Security Filter / Portal Pages

RemoteRemote HTMLHTML ... ClientClient

Figure 4.5: The Architecture of the Presentation Sub-Tier (WBC-SP Side)

4.3.1.2. Business Logic Sub-Tier

Facades and delegates [106] are the key design patterns used at this sub-tier. By hiding complex business APIs and exposing a simpler interface [13], the business services are decoupled from distributed clients and agents. Moreover, the maintenance cost can be reduced due to the fact that the business rules are redefined by modifying the business delegates XML files. There are four types of business delegates located at this sub-tier: a GUI business delegate, a WBC agent business delegate, a Java Message Service (JMS)/Database business delegate, and a WBC data organizing business delegate. For example, the GUI business delegate can cache data and user

54 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation requests, ask for a JMS feedback from the WBC system, interact with the persistence sub-tier and other sub-tiers/tiers to manage the persistence data and other WBC services, display the result to client forms or web services, etc.

With this concept of business delegates (Figure 4.6), the overall WBC system development and testing is much more efficient.

WBC Agent Business Delegate

GUI Business Business JMS/Database Delegate Sublayer Business Delegate

WBC Data Organizing Business Delegate

Figure 4.6: The Business Delegate Concept of the Business Sub-Tier

4.3.1.3. Persistence Sub-Tier

There are three main components located at this sub-tier: a mail component concerned with xSPs and WBC-SP; a O/R mapping component used for conversion between Java objects and a relational database; and a DAO component used to abstract and encapsulate all accesses with different data source, such as relational database, XML, Resource Description Framework (RDF) data [137], OO database. All SD PER streams are carried by Java POJOs and serialized to an OO database. The xSP roles, 3P-AAA and other information are serialized to relational databases.

4.3.2. Design of Application Tier

The core WBC algorithms are located in this tier. They include the WBC ontology, the expert system, and the WBC intelligent schemes for SDs' collection, clustering, scheduling, indexing, and broadcasting.

4.3.2.1. WBC Ontology

For uniform design of the WBC system, an ontology technique is used to describe concepts and their relationships [138]. All ontologies use Java objects. The design

55 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation pattern of ontologies follows the singleton design pattern [139] to enable the sharing of the same object among the three tiers. Two ontology types are used: data source ontology and task ontology. Each ontology scheme is built up with the following structure (Figure 4.7):

 Vocabulary – used to identify the name of a variable in an ontology Java class;

 Concept – expressions with Java POJOs that indicate entity dataset, such as a SD, WBC segment, xSP, index, broadcasting history, etc;

 Predicate – used to define the relationship between the elements of a concept. For instance, the predicative (belong to (SD: name abc_voice_call ) (WBC segment: ID 123)) states that the abc_voice_call belongs to WBC segment 123;

 Action – includes collecting, clustering, scheduling, indexing, and broadcasting actions.

4.3.2.2. WBC Expert System

To achieve a loose-coupling system and enable WBC data organizing algorithms to run in an intelligent way, a rule-based expert system (knowledge-based system) runs at the intelligent application tier for facilitating the data broadcasting (Figure 4.7). The key advantage of using a rule-based expert system is that the business solutions could be managed easily, e.g. with the data and logic separated solution, the end user can change the rules (very simular to a natural language) without having to recompile the source code [46, 47].

Data Provider, WBC-SP Agents e.g. xSP, MU.

Agent Call

Pattern Matcher Vocabulary, Concept, Working Memory WBC Rule List Predicate and Action schemes

Conflict Resolution Extended Task Data Source Strategy Dictionary & Ontology Ontology Ontology Agenda Fire Rule Select Rule Rule Found to Fire No Rule Found ...... Collecting Clustering SD Segment Execution Exit Engine

Figure 4.7: The WBC Rule-based Expert System

56 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

There are two basic elements in the WBC rule-based expert system: facts (all the ontologies act as shadow-facts asserted into the working memory) and rules (different area and different time may cause different rules to run) [47]. There are a number of rules on the WBC-SP side: the collecting rule defines the broadcasting frequency of each SD based on the user demand for this service and advertisement fees paid by the service provider; the clustering rule clusters SDs with category type, frequency, CC/PP, QoS, scope list etc, and defines the properties of WBC segments; the scheduling rule locates the position of each WBC segment in the broadcasting sequence; the indexing rule generates index-WBC segments; and the broadcasting rule determines the broadcasting time for each final sequence.

When a behaviour of an agent tries to finish a task, an ACL [44] message is sent to the rule-based expert system and is asserted into the working memory. Then the pattern matcher is called to decide which rules should be fired. The matched rules act as a conflict set and are resolved into an agenda (a conflict resolution strategy is used for managing the rules execution order [47]). Finally, the execution engine fires the agenda-selected rules, modifies or retracts facts from the working memory, and executes other functions.

4.3.2.3. WBC Algorithms

Considering the fact that in the next ten years, the lifetime of battery is expected to increase by only 20%, the use of efficient power saving schemes is a key element in WBC. In [95] a broadcast disk algorithm was introduced for reducing the access time, and in [140, 141] an (1,M) indexing algorithm was proposed for reducing the tuning time. However, with these algorithms, the unpopular SDs will be broadcast too many times; thus these are not suitable for WBC. Our solution includes four important SD organization schemes for collecting, clustering, scheduling, and indexing, respectively [3].

A SD is the smallest logical unit in WBC. SDs are grouped into fixed-size WBC segments for broadcasting over the WBC. Each WBC segment is made up of a number of SDs with same type, which facilitates the SD filtering, caching, comparing and selecting the favorite SDs by MTs. Considering the fact that the client access pattern for SDs does not follow the uniform distribution [95], to optimize the access

57 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation time, the WBC segment / SDs broadcasting times should follow the client access pattern [3].

The protocol used by MT to access a particular n-th WBC segment is as follows [3]:

1) Tune in WBC and wait for the next inner-index WBC segment. 2) Read the position of the next inter-index. 3) Tune out and wait for the next inter-index. 4) Tune in, read the inter-index data and determine the position of the needed n-th data WBC segment. 5) Tune out and wait for the n-th data WBC segment. 6) Tune in again and read the n-th data WBC segment. 7) Tune out. Table 4.1 lists the notations used further in this section.

Table 4.1: The General WBC System Parameters

Parameter Description

M Total number of distinct WBC segments in a broadcasting cycle.

N Total number of data WBC segments in a broadcasting cycle.

Broadcasting frequency of n-th WBC segment (1  nM ), i.e. the number of Fn instances of n-th WBC segment in a broadcasting cycle.

Ig,n Inter-arrival gaps for n-th WBC segment, 11 gFn .

pn Current access probability of n-th WBC segment.

Tn Expected value of access time for n-th WBC segment.

T Expected value of mean WBC segment access time.

n Expected value of tuning time for n-th WBC segment.

Two types of indexes are used in the WBC broadcasting cycle: an inter-index used for WBC segments in order to reduce the tuning time ( ); and an inner-index used for SDs in order to reduce the access time (T).

The minimization of Tn and n are the key goals in WBCs.

Expected value of mean WBC segment access time (T):

Tn can be calculated as shown in Appendix B:

58 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

2 11FIngIgn, 1 ,nFi TIIx 1 . ngsx101 z0 ,,ns gn(4.1) NN2 2

It is stated in [3] that Tn is minimal when the inter-arrival gaps between all consecutive instances of WBC segment n in a broadcasting cycle are equal, i.e. if for each 12gFn :

 N  IIgn,1, g n I n   , (4.2)  Fn  Then:

2 Fn NN Min() Tn  , (4.3) 22NFnn F

Now, assuming that all pn are independent, for T we have:

M pNn M T  , where FN . n1  n 1 n (4.4) 2Fn

The minimum value of T is reached, when for every independent Fn :

MMp NpN 0 (nn ) ... ( ). nn1122FF FnFn1 M

pN12 pN pM N 22... 2 (4.5) 22FF12 2 FM F F n j ,1,.where  i j M ppnj M F  Fj N n j1  p MM n ppj j jj11 (4.6) Np F n n M p  j1 j From (4.4) and (4.6), we can obtain the minimum value of T:

M p MMM j1 j 1 Min() T p p p nnj111nnj (4.7) 2 p 2 n This Min(T) is reached when equalities (4.2) hold. Expected value of tuning time for n-th WBC segment: If data indexing is not used, then [3]

 nn T (4.8) If data indexing is used,

59 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

n = Probe wait+ Inner-index reading time + Inter-index reading time + WBC segment downloading time (4.9)  0.5111 3.5 WBC segment timeslots. In practice, due to the properties of SDs, it is difficult to achieve the equalities (4.2) due to collisions6. In [3], efficient WBC collecting, clustering, and scheduling schemes have been proposed to approach the optimal access time.

4.3.2.3.1. Collecting Scheme

This scheme is used to collect SDs from service providers and generate SD broadcasting frequencies. This thesis only focuses on the SD broadcasting frequency scheme. In a broadcasting cycle, the SD broadcasting frequency f is obtained as: i

 fij(udcost) i  i (4.10) where 0 i  Af and 0,,,1    j . If (calculated f i ) > A, then the value of fi is set to A. If (calculated fi ) < 0, then the value of fi is set to 0.

The parameter udi (user demand) indicates the current popularity of SDi among the users (i.e., the number of user requests for service i); its value is supplied by an independent third-party monitoring infrastructure, which gathers statistics from users about their use of different services. The parameter costi reflects the cost of SDi advertisement paid by its service provider to the WBC-SP; its value is supplied by an online price-competition system run by the WBC-SP. The coefficient  is used to delete cold SDs from the broadcasting cycle (e.g. if SDi has been broadcast in 1/ consecutive cycles, and there have been no ‘user demand’ or ‘cost paid’, then fi is set to 0, and this SD is deleted from the next broadcasting cycle). The coefficient  j is a specific coefficient for servicecategory j . Parameter A is defined by the WBC-SP as the maximum value of times that a SD may appear in a broadcasting cycle. The initial value of fi for a newly published SDi is set to B (usually B = 2).

Example 1: The broadcasting frequencies for four SDs (of same category) in five broadcasting cycles are shown in Table 4.2. Let     0.05 ,   0.25 ,  1,

A  3 , B  2 ,   7/4. Assume that SDB is released in cycle 66. For cycle 70,

6 A collision occurs if two (or more) WBC segments have the same user access probability.

60 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

fa  4.25 >A, so fa is set to 3. On the other hand fb  0 in cycle 70, because there were no ‘user demand’ or ‘cost paid’ for SDb in 1/  = 4 cycles.

Table 4.2: An Example of SD Broadcating Frequency Generating Scheme

66 67 68 69 70 Cycle No. SD User demand / cost / fi a 20/30/2 20/30/2 30/30/2 40/40/3 40/50/3 b 0/0/1 0/0/1 0/0/1 0/0/1 0/0/0 c 100/0/3 70/0/3 60/0/3 40/0/2 40/50/3 d 0/30/1 0/30/1 10/20/1 10/10/1 20/20/1

4.3.2.3.2. Clustering Scheme

The clustering scheme is used to install the SDs into WBC segments in an optimal way so as to reduce the user access time and tuning time. Only SDs in the same category are inserted into each WBC segment, and in addition the SDs are ordered from ‘hottest’ to ‘coldest’ based on their broadcasting frequency f . To generate a reasonable SD sequence, a set of intelligent decision rules apply, such as the CCPP rule, QoS rule, scopeList rule, and arbitrary rule. Using these rules, a cluster agent asserts the SDs into the working memory and uses the “salience” conflict resolution strategy to decide which rule should be “fired” [142]. The following is an example of the wbcarbitrary rule:

rule wbcarbitrary salience 10 when SD( f ==$ f && CCPP ==$CCPP && QoS == $QoS && scopeList == $ scopeList ) then SD sequence. end

The cluster agent executes the following algorithm:

for j=1 to  Cluster SDs in category j by using an expert system. Insert SDs into WBC segments.

4.3.2.3.3. Scheduling Scheme

After generating the WBC segments, the next step is to apply a reasonable scheduling scheme for reducing the access time. From the user’s viewpoint, the access time could be divided into: (i) particular-WBC segment access time Tn , and (ii)

61 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

particular-category access time  j . In this section, hot segments scheduling and cold segments scheduling algorithms are proposed for reducing these two access times.

As previously discussed, to minimize the WBC segment access time, in the WBC non-uniform broadcasting scheme the hot WBC segments are broadcast more frequently so as to reflect the client access pattern. If the WBC segment inter-arrival gaps are equal, the WBC segment access time is minimal. The WBC segment broadcasting frequencies n   MnF )1( and the values of M and N are supplied by the clustering scheme. In this thesis we propose a modification of the broadcast disks algorithm [95], where the hot WBC segments (1)F  are inserted into final sequence n  (by a scheduling agent) in a novel way [3]:

for n=1 to M

when Fn 1

then for j = 0 to Fn

wF 1/ 2*(N mod n )

  Segmentn with scheduling rules w w+(N - N mod FFnn ) /

FFnn1, j j 1 end n=n+1 end end

Using the above algorithm, the hot WBC segments are inserted into  uniformly. Scheduling rules are used for solving the collision problems. The difference from the broadcast disks algorithm is the relative spin speed, i.e. in [95] it makes no sense to have two broadcast disks with relative speed 11:5. On the contrary, our algorithm does not depend on the relative speed. Moreover the intelligent scheduling agent inserts automatically all hot WBC segments into  in a manner corresponding to the user access pattern and the WBC segments inter-arrival gaps approach equality.

Example 2: Figure 4.8 depicts an example of the hot WBC segments scheduling algorithms, in which FA =4, FB =3, FC =2, Fothers =1, MN11, 17. There are three categories in total. Category1 includes WBC segments A, D, E, F. Category2 includes

WBC segment B. Category3 includes WBC segments C, G, H, I, J, K. With the hot WBC segments scheduling algorithm, the hot WBC segments A, B, C are inserted into

62 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation the scheduling cache with hot WBC segments rules ensuring equality for WBC segments inter-arrival gaps.

Segments: Hot A B C D E F G H I J K Cold

Scheduling cache: Aa Bb Cc Aa Bb Aa Cc Bb Aa Figure 4.8: The Hot WBC segments Scheduling Algorithm for Example 2

The next step is to insert the cold WBC segments (1Fn  ). Different from [95, 140, 141], we propose a new criterion – the mean category access time ( ). Reducing  is also an important goal in WBC. To minimize the value of  , the inter-arrival gaps C qj,

(inter-arrival gaps for j-th category) should be (almost) equal within each Category j . To achieve this, we propose an intelligent Cold WBC segments Scheduling algorithm executed by the scheduling agent as follows:

Step 0: Determine the number of minor cycles (  Min() j  where j is the total number of

WBC segments of category j in a broadcasting cycle) and the length of a minor cycle

LNk  / ; generate  disks, and Diskj  Segmentn , where Fn 1 ,

Segmentnj category . Step 1: Set the spin speed SS of Disk as SS  Length() Disk . j j j j Step 2: Write the available WBC segment places ( i ) within each minor cycle i to the blackboard (the blackboard pattern acts as a knowledge container in the WBC MAS). Step 3: Spin all disks at their own speed. for i=0 to  -1

Extract the first i WBC segments appearing on the top of each disk (if not enough free space, give priority to faster disks).

Insert (in order) those i WBC segments into the minor cycle i . end Step 4: Insert the unscheduled WBC segments into the tail of the scheduling cache.

In example 2, 1  7 , 2  3 , 3  7()3;Min j  LNk  /5; SS1  3 ,

SS2  0 , SS3  5 ; 1  2,  2  3 ,  3 1. After executing the cold WBC segments scheduling algorithm the WBC segment order in the scheduling cache will be (G,D),(H,E,I),(J),(K,F) as shown in Figure 4.10. To avoid the Bus Stop Paradox [95], the scheduling agent changes the WBC segment order to (D,G),(E,H,I),(J),(K,F). The final sequence  is shown in Figure 4.10.

63 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

Disk 1 E (for cold segments D of category 1) F Blackboard Scheduling Agent H (Rule Decision Disk 3 I Maker) (for cold segments G of category 3) J i K

Scheduling cache G D Aa Bb Cc H Aa E Bb I Aa J Cc Bb Aa K F 1st minor cycle 2nd minor cycle 3rd minor cycle    1 2 3 Figure 4.9: The Cold WBC segments Scheduling Model for Example 2

 D G Aa Bb Cc E Aa H Bb I Aa J Cc Bb Aa K F

Figure 4.10: The Final WBC segment Broadcasting Sequence for Example 2

If the current access probability for WBC segment i ( pi ) and current access probability for category j (  ) follow the same distribution as the final broadcasting distribution, j then T  5.5 and   2.2 .

4.3.2.3.4. Indexing Scheme

In this subsection we describe the WBC indexing scheme which allows the MT to save the battery power by staying in a sleeping mode and only tuning in when the desired data (the user is interested in) is broadcast on the billboard channel. The indexing algorithms developed in the past [140] only consider flat broadcasting; some also distinguish index WBC segments from data WBC segments completely. Our indexing scheme includes WBC segment inner-index and WBC segment inter-index.

Inner-Index:

The WBC segment inner-index is a full index for the inter-index and a WBC segment, which is saved in the WBC segment’s header and has the following ASN.1 structure:

AWBC segmentIndex ::= SEQUENCE { service-Type Service-Type, seg_totalSDNumber INTEGER, seg_totalSDSize INTEGER,

64 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

WBC segmentValueTag OCTET STRING(SIZE(1)), ccpp OCTET STRING OPTIONAL, indexSD SEQUENCE of IndexSD } Inter-Index:

The inter-index is an index tree which indexes all data WBC segments and saves index data in separate fixed-size WBC segments. The inter-indexing is used for reducing the WBC segment access time and category access time. Taking into account the fact that the size of interleaved data in the WBC indexing tree is small, we adopt the (1, M ) indexing algorithm [140] as the most efficient for the inter-indexing. It means that the inter-index WBC segment is broadcast M times during a broadcasting cycle (Figure 4.11). The ASN.1 structure of the inter-index follows:

AIndexTree ::= SEQUENCE { totalWBC segmentNumber INTEGER, totalIndexNumber INTEGER, currentInexNumber INTEGER, serviceType SEQUENCE of ServiceType }

4.3.2.3.5. Final WBC segment Broadcasting Sequence

After adding the inner-index to each WBC segment and adding the inter-index to  , the final  is generated as shown in Figure 4.11. IndexM Header Index2 Index1 Seg n Seg n Seg Seg N Seg 1 Inter- Inter- Inter- Seg 2 ...... ……………

. . . Inner- Index SD1 SD2 ......

. . .

Figure 4.11: The Generic Format of the WBC Broadcasting Cycle

4.3.2.4. IP Datacasting

Considering that the ADP protocol was implemented in C++ (based on IETF RFC3695 standard [123], the only open source Reed-Solomon FEC codec was

65 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation developed by Luigi Rizzo in C++. Also, the Java programming language is not efficient on byte level processing, thus C++ is used for implementation the ADP protocol), to invoke the ADP C++ library in Java EE environment, a Java Native Interface (JNI [53]) – ADP middleware was developed which acts as a bridge between the Java environment and C++ environment (Figure 4.12).

Load ADP DLL Library ADP C++ .dll Javah C++ .h C++ .h C++ Compiler

Javac C++ Code: JNIEXPORT JNICALL Java Code: java_broadcast(){..} loadLibrary (dll) native ADP(); Static broadcast(){...} JNIEnv->CallMethod broadcast

JNI Create JNIEnv->getMethodID broadcast Java VM JNIEnv->FindClass JNIEnv *

Figure 4.12: The JVM Invoking the ADP API for IPDC

4.3.3. Design of MAS Container Tier

To build a heterogeneous distributed system on the WBC-SP side and improve the terminal mobility, a goal-oriented, flexible, reactive, and communicative MAS runs in this tier to deal with wireless services’ ADA processing. Based on the Foundation of Intelligent Physical Agents (FIPA) framework [116], the MAS job is to provide Agent Management System (AMS) and Directory Facilitator (DF) services, ‘yellow pages’ service, message transport service, etc. Each running instance of MAS is called a container with a set of agents. All WBC agents (i.e. the collecting agent, clustering agent, scheduling agent, indexing agent, and broadcasting agent) use ACL messages for communication with each other. A content manager performs conversion operations between the ACL byte stream and ACL ontology Java object. With this communication mechanism, the MAS tier runs in a Peer-to-Peer (P2P) mode. A blackboard is used for sharing the information and common static objects. To communicate with other tiers, a gateway agent is used to receive/send messages via the shared message channel. All agents besides the personal profile agent are logic-based agents that work with the knowledge-based system. The personal profile agent is a Belief-Desire-Intention (BDI)

66 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation agent [143], whose actions depend on the user history records, plans, beliefs/desires, and intentions. Figure 4.13 depicts the model of the personal profile agent.

Personal Profile Agent Gateway Knowledge Expert Agent System

Input (perception) History Record Rule Engine

Ontologies Desires

Plans Rule Lists Goals User Profile Intentions History Database Output (action)

Figure 4.13: The Personal Profile Agent's Model 4.4. Implementation of Application Enabler Sub-Layer

The design and developing the WBC application enabler sub-layer follow the Personal Software Process (PSP) methodology [144]. An experience repository database is used to store all development experiences. Test Driven Development (TDD) [145] and Feature Driven Development (FDD) [146] methods were selected when designing this PSP project. With these two methodologies, the three-tier heterogeneous WBC application enabler sub-layer’s architecture is plotted into a set of unit functional modules (features), such as a login module, SDs uploading module, SDs organizing module, history-log viewer module, IPDC module, etc. For each unit module, from bottom tier to top tier, Unified Modeling Language (UML) [146, 147] diagrams following the corresponding interface were first designed. Then the interface was fully implemented and a unit testing was performed.

The WBC application enabler sub-layer is built with a number of open-source Integrated Development Environments (IDEs)/APIs/frameworks as shown in Table 4.3. The benefits of using these open-source software include public collaboration, not bounding to a single development company, auditability, flexibility and freedom.

4.4.1. Implementation of Service Discovery and Maintenance Tier

To design and implmenent the service discovery and maintenance tier quickly and efficiently, a project skeleton as well as a number of build/test/deploy schemes was

67 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation first developed based on the open-source IDEs/APIs/frameworks as shown in Table 4.3. To describe the requirements for analysis, design, implementation and documentation, a use case diagram was first being designed as shown in Figure 4.14.

Table 4.3: The Main IDEs/APIs/Frameworks at the WBC Application Enabler Sub-Layer

IDEs/APIs/ Descriptions Frameworks Eclipse [28] An open-source Java IDE platform (http://www.eclipse.org).

A high-performance, embeddable, open-source OO database DB4O [37] (http://www.db4o.com).

MySQL [38] A popular open-source relational database (http://www.mysql.com).

A simple framework to write repeatable tests for Java classes JUnit [148] (http://www.junit.org).

Mock [35] A Java object behaviour simulation tool (http://ant.apache.org).

ANT [34] A Java building tool (http://ant.apache.org).

A software project management and comprehension tool Maven [35] (http://maven.apache.org). An object/relational persistence and query service mapping framework Hibernate [32] (https://www.hibernate.org). A high performance and full text Java search engine (https:// Lucene [149] lucene.apache.org).

XDoclet [35] A Java code generation engine (https://xdoclet.sourceforge.net).

XWork [39] A Java IoC container (https://www.opensymphony.com/xwork).

Spring [39] An AOP framework (http://www.springsource.org).

JBoss [35] A Java EE container (https:// www.jboss.org).

A semantic web framework API for reading and writing CC/PP RDF files Jena [150] (http://jena.sourceforge.net).

For each unit module, the main design and implementation steps were follows:

Step 1: Create the corresponding POJO (aentity) and add Java Persistence API’s (JPA) annotations. The toString(), equals() and hashCode() methods should be implemented. Then run the command mvn test-compile hibernate3:hbm2ddl to create the aentity database table. Step 2: Create the aentity’s DAO bean aentityDao for database’s Create, Read, Update and Delete (CRUD) operations. Configure the aentityDao with the class

68 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

org.wbc.dao.hibernate.GenericDaoHibernate in the context file wbcContext.xml. Once the aentityDao is being defined, add the setter method with parameter of GenericDao in order to use this bean as a dependency of the object. Step 3: Create the aentityManager to act as a service facade to aentityDao. Configure the aentityManager with the class org.wbc.service.impl.GenericManagerImpl in the context file wbcContext.xml. Similarly to step 2, add the setter method with parameter of GenericManager in order to use this bean as a dependency of the object. Step 4: Create the web tier using xwork. Implement an aentity action to process the request and response operations.

Register& Login Actions Persistence Operations

SD Form Uploading Actions ASN.1 PER Encoder

SDs List & Search Actions Other Services

User Business Service Manager SD Cluster, Schedule, Rule Engine and Index Actions

Shared Blackboard Broadcast Action

Message Channel System Configuration WBC Agents Action

WBC Services Others Actions

Figure 4.14: A Use Case View of the Service Discovery and Maintenance Tier (WBC-SP Side)

To update and modify the whole system easily, the Java interface and extends design pattern were used for developing the service discovery and maintenance tier. Figure 4.15 shows the UML class diagram of the main interfaces (Dao, Manager, Action) and implementations (BaseDaoHibernate, BaseManager, BaseAction) at the persistence, business logic and presentation sub-tier, respectively.

69 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

Dao

BaseDaoHibernate

#log: Log = LogFactory.getLog(getClass())

+saveObject(o: Object) +getObject(clazz: Class, id: Serializable): Object +getObjects(clazz: Class): List +removeObject(clazz: Class, id: Serializable)

LookupDaoHibernate PersonDaoHibernate RoleDaoHibernate ...DaoHibernate ...

+getRoles(): List +getPersons(person: Person): List +getRoles(role: Role): List +get...(...: ...): List +getPerson(id: Long): Person +getRole(roleId: Long): Role +get...(id: Long): ... +savePerson(person: Person) +getRoleByName(rolename: String): Role +save...(...: ...) +removePerson(id: Long) +saveRole(role: Role) +remove...(id: Long) +removeRole(rolename: String)

(a)

Manager

BaseManager #log: Log = LogFactory.getLog(getClass()) #dao: Dao = null +setDao(dao: Dao) +getObject(clazz: Class, id: Serializable): Object +getObjects(clazz: Class): List +removeObject(clazz: Class, id: Serializable) +saveObject(o: Object)

PersonManagerImpl LookupManagerImpl RoleManagerImpl ...ManagerImpl ... -dao: LookupDao -dao: PersonDao -dao: RoleDao -dao: ...Dao

+setLookupDao(dao: LookupDao) +setPersonDao(dao: PersonDao) +setRoleDao(dao: RoleDao) +set...Dao(dao: ...Dao) +getAllRoles(): List +getPersons(person: Person): List +getRoles(role: Role): List +get...(...): List +getPerson(id: String): Person +getRole(rolename: String): Role +get...(id: String): ... +savePerson(person: Person) +saveRole(role: Role) +save...(...: ...) +removePerson(id: String) +removeRole(rolename: String) +remove...(id: String)

(b)

Action

BaseAction

#log: Log = LogFactory.getLog(getClass()) -defaultLong: Long = null +getBean(name: String): Object #convert(o: Object): Object #convertLists(o: Object): Object +getMessages(request: HttpServletRequest): ActionMessages -getActionMethodWithMapping(request: HttpServletRequest, mapping: ActionMapping): String #getActionMethod(request: HttpServletRequest, prepend: String): String +execute(mapping: ActionMapping, form: ActionForm, request: HttpServletRequest, response: HttpServletResponse): ActionForward #getActionForm(mapping: ActionMapping, request: HttpServletRequest): ActionForm +getConfiguration(): Map #removeFormBean(mapping: ActionMapping, request: HttpServletRequest) #updateFormBean(mapping: ActionMapping, request: HttpServletRequest, form: ActionForm)

SignupAction PersonsAction ReloadAction UploadAction ...

+execute(...): ActionForward +cancel(...): ActionForward +execute(...): ActionForward +execute(...): ActionForward +delete(...): ActionForward ~toHstring(value: byte): String +edit(...): ActionForward ~bytetostring(bytearray: byte): String +save(...): ActionForward +search(...): ActionForward +unspecified(...): ActionForward

(c) Figure 4.15: The UML Diagrams of (a) BaseDaoHibernate; (b) BaseManager; (c) BaseAction.

70 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

4.4.1. Implementation of User Interface (UI)

The WBC-SP UI of the service discovery and maintenance tier was implemented as a Java desktop portal application. It integrates several applications, such as a MAS application, WBC portal initial application, WBC web viewer application, and WBC broadcasting application. The WBC-SP UI application provides the environment variables for running native libraries and executable files, i.e., a URL based application, C++ application, Applet, Java EE container, etc. Figure 4.16 shows the UI Java class dependencies UML diagram.

DataA rriveListener

Segment_Broadcaster WBC_Jade_Loader WBC_Container_Loader UI_Pa ne ls

DataArriveEvent

Figure 4.16: The UI Java Class Dependencies UML Diagram

There are two parameters in the DataArriveEvent - the string data and the Java source object. The DataArriveListener listens to the arrived events and notifies the relevant application processing about the event. Figure 4.17 shows the main UI panels of the service discovery and maintenance tier.

The portal UI includes four tabs: (i) the MAS tab maintains the WBC-JADE environment, (ii) the portal tab is used for starting/stopping the Java EE distributed environment, and recording log-information of the system, (iii) the WBC APP tab is the entrance to the WBC-portal (it mainly includes the WBC SD collecting, clustering, scheduling, indexing and broadcasting section; in addition the link layer’s and physical layer's parameters can be defined by the corresponding Portlet in a remote mode), (iv) the send tab is a remote control panel used to control the ADP server to broadcast WBC segments/SDs in a carousel way.

71 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

(a)

(b)

72 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

(c)

(d)

73 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

(e)

(f)

Figure 4.17: The WBC-SP UI Portal. (a) Server Starter; (b) Login; (c) User Profile; (d) SDs List; (e) SDs Information; (f) Scheduling.

74 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

4.4.2. Implementation of Application Tier

To achieve a loose-coupling system and enable WBC advertise-processing to run in an intelligent way, the WBC APIs, rule engine and database are integrated in this tier. Considering that the programming to an interface is the key principle of reusable object-oriented design [33, 35, 39, 134], all APIs of the application tier are extract interfaces to other tiers. Figure 4.18 shows the interface design of the application tier.

LuceneIndexer LuceneSearcher Cache DBManager RulesLoader WBCAlgorithms ...

WBCIndexer WBCSearcher WBCCache WBCDBManager WBCRulesLoader aWBCAlgorithms WBC...

+index() +search() +addObject() +getId() +RulesLoader() +collector() +unindex() +getObject() +findAll() +readRule() +cluster() +removeObject() +getById() +getWorkingMemory() +scheduler() +size() +remove() +getRecomendList() +indexer() +removeExpiredObject() +save() +setRecomendList() +broadcaster()

Figure 4.18: The Interface Design at the Application Tier

A rule-based expert system operates at this tier for facilitating the data broadcasting on the WBC-SP node. As stated in section 3.3, the Drools was selected as the rule engine in WBC. All the .drl configuration files are stored in a database, which can be accessed and updated via the portal application.

Figure 4.19 shows the UML diagram of the Drools main recommendation classes. The RecomendCmd class implements the interface recommend and gets the recommended SDs via a sort interface. With this interface design pattern, when a new rule is applied to the system, the system does not need to recompiled thus ensuring loose-coupling.

4.4.3. Implementation of MAS Container Tier

The WBC-JADE is a light-weight MAS. The UI of WBC-JADE has been redesigned based on JADE (the popup UI in Figure 4.21b). In addition to the WBC collecting agents, clustering agents, scheduling agents, indexing agents, broadcasting agents and PAA, a gateway agent, message channel and blackboard were also developed. Figure 4.20 depicts the diagram of the main UML classes for MAS communication with the Java EE environment. The MyGateWayAgent verifies the received blackboard object

75 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation and forwards it to the proper agent, and vice versa; the DirectoryServlet links the MAS to the Java EE environment; the Interaction exchanges HTTP requests and responses between the DirectoryServlet and ProxyAgent; the Synchronizer synchronizes the blackboard between the DirectoryServlet and ProxyAgent; and the ProxyAgent accepts objects through the communication channel and provides behaviours that deal with requests.

recommend

-instance

RecomendCmD AdvertClient +accountDao: AccountDao -ctxName: String = "./configuration/wbcContext.xml" +adDao: ADDao -ctx: ApplicationContext +rulesLoader: RulesLoader -instance: AdvertClient +logger: Log = LogFactory.getLog("Recomend") <>+AdvertClient() +init(): void +getInstance(): AdvertClient +getAccountDao(): AccountDao +getBean(beanName: String): Object +setAccountDao(accountDao: AccountDao): void -initSpringContext() +execute(): void +main(args: String) +getRulesLoader(): RulesLoader +setRulesLoader(rulesLoader: RulesLoader): void +getAdDao(): ADDao +setAdDao(adDao: ADDao): void

sort

SortByPrice SortByQoS SortByUsedTimes ....

+compare(ad1: AD, ad2: AD): int +compare(ad1: AD, ad2: AD): int +compare(ad1: AD, ad2: AD): int

Figure 4.19: The UML Diagram of Drools Main Recommendation Classes

ProxyAgent Synchronizer Interaction -Started: boolean = false -theRequest: HttpServletRequest = null +setup() -theResponse: HttpServletResponse = null +takeDown() ~waitOn() -theResponseChangeFlag: boolean = false ~Started() <>+Interaction(p_Request: HttpServletRequest, p_Response: HttpServletResponse) ~getResponse(): HttpServletResponse ~waitChangedResponse() ~getRequest(): HttpServletRequest ~setResponseChanged()

DirectoryServlet -theProxyAgent: AgentController = null

-SyncInit() +init() +doGet(p_Request: HttpServletRequest, p_Response: HttpServletResponse)

MyGateWayAgent ~board: BlackBoardBean = null

#processCommand(obj: java.lang.Object) +setup()

BroadcastingAgent ClusterAgent SchedulingAgent IndexingAgent PAAAgent ...... ~seed: long = System.currentTimeMillis() #setup() #setup() ~language: Codec #setup() #takeDown() #takeDown() #setup() ~ontology: Ontology #takeDown() #takeDown() -requestNumber: int = 0

#setup() #takeDown()

Figure 4.20: The UML Diagram of MAS and Java EE Main Communication Classes

The UI MAS portal is depicted in Figure 4.21.

76 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

(a)

(b)

Figure 4.21: The WBC-SP MAS Portal: (a) Start Jade Tab; (b) WBC Jade Panel.

77 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

4.5. Design and Implementation of Advertisements Delivery Protocol (ADP)

The core ADP includes Building Blocks (BBs) and Protocol Instantiation (PI). Two modified BBs – LCT [120] and FEC [123] – and one modified Asynchronous Layered Coding (ALC) PI were developed for ADP. Figure 4.22 depicts the ADP building block structure.

WBC-ADP

ADP/ALC PI

ADP/LCT ADP/FEC BB BB

Figure 4.22: The ADP Building Block Structure

From the viewpoint of the top layer (application enabler sub-layer), the WBC is envisaged as a packet erasure channel, i.e., a packet either arrives or is lost. As the WBC segment is small in size, based on previous studies [119, 123], the one-dimensional small-block RS codes are particularly well suited for ADP due to their characteristics, e.g. good performance in correcting wireless burst errors, no “coupon collector problem”, etc [151].

Figure 4.23 shows an example of the Packet Erasure Decoding (PED) process. A 8-kB WBC segment is first plotted into 8 equal-size source symbols, which are then encoded by a RS (n,k) algorithm [123] (n=10 is the number of encoding symbols per WBC segment; k=8 is the number of source symbols per WBC segment). This way the receiver can recover a WBC segment from any 8 (out of 10) encoding symbols received without errors.

Sender Receiver 1 1 1 2 2 1 2 3 X 2 3 4 4 3 Recovered Source 4 5 4 5 Source Symbols 5 6 6 5 WBC Symbols 6 7 7 6

7 8 X ADP RS FEC Decoder 7 ADP RS FEC Encoder FEC RS ADP 8 FEC 1 FEC 1 8

k=8 FEC 2 FEC 2 k=8 8kB n=10 n=10 8kB WBC WBC Segment Segment Figure 4.23: A Graphical Representation of the RS Encoding/Decoding Process

78 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

4.5.1. WBC-ADP Encoding and Decoding

The WBC-ADP message generation and subsequent encapsulation into UDP/IP datagrams are sketched in Figure 3.2 (part 3). There are two types of encoding symbols: source symbols and FEC symbols. The number of source symbols is kL/ , where L is the source blocks’ length and  is the encoding symbols’ length. Each ADP message only contains one encoding symbol consisting of  elements (bytes). Each element is characterized by the following irreducible polynomial:

px() x8432 x x x 1 (4.11) Let x denotes the vector of each i-th element of the source symbols, y denotes the i i vector of each i-th element of the encoding symbols, X is the vector of source symbols, andY - the vector of encoding symbols, i.e.:

xiiiiiiik { ,1 , ,2 , ,3 , ,4 , ,5 ,...  , } (4.12)

ypi { iiiii,1 , ,2 , ,3 , ,4 , ,5 ,...  iki , , ,1 ,...,p ink ,  } (4.13)

X  {xxxxx12345 , , , , ,... x } (4.14)

Yyyyyyy {,12345 , , , ,...} (4.15) A (n*k) generator systematic matrix G (a Vandermonde matrix) [11] is used for the encoding:

yii Gx where 1  i  (4.16) The following algorithm is used to build G:

1) Tp lj , where 0 lk, 0  jn , and p is a primitive lj, (4.17) element of the finite field GF( 28 ). 1 lm 2) Aplm,   , where 0 mk. (4.18) 3) GAT . (4.19) During the decoding process at the mobile terminal, to recover X from any k of the

' received encoding symbols (denoted as Y ), xi is obtained from the inverted matrix of the corresponding matrix G' (the corresponding rows of matrix G) multiplied by

' yi :

'1' xii ()Gy . (4.20)

79 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

4.5.2. ADP Message Format

The format of the ADP message is shown in Figure 4.24. The total size of the ADP/LCT header is only 8 bytes. Compared with the standard LCT (44 bytes [122]) and FCAST (60 bytes [121]) header, the ADP/LCT is more efficient both in terms of the overhead and complexity.

0151631 IP_V IP_Hl IP_Tos IP_Len IP_Id Flag IP_Off IP_Ttl IP_Proto IP_Sum IP Source Address IP Destination Address Source Port Number Destination Port Number UDP Length UDP Checksum VTAD L b r ESI TOI_Index TOI Cycle_l Next-Full-Index-Segment

Encoding ==Symbol

IPv4 Header UDP Header ADP Header

Figure 4.24: The ADP/UDP/IP PDU Format

The ADP header is formatted with ASN.1 as follows:

ADP Pkt ::= SEQUENCE { V BIT STRING(SIZE(4)), // WBC broadcasting cycle version (New in WBC). D BIT STRING(SIZE(1)), // WBC segment Type (New in WBC). A BIT STRING(SIZE(1)), // Close Session Flag (Same to ALC).

80 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

T BIT STRING(SIZE(2)), // Encoding Symbol Length (Same to ALC). L BIT STRING(SIZE(4)), //WBC segment size (New in WBC). b BIT STRING(SIZE(1)), // 0 is data symbol (New in WBC). r BIT STRING(SIZE(3)), // Reserved (Same to ALC). ESI BIT STRING(SIZE(8)), // Encoding symbol ID (Same to ALC). TOI_Index OCTET STRING (SIZE(1)), // Index number (Same to ALC). TOI OCTET STRING (SIZE(2)), // WBC segment ID (New in WBC). Cycle_l BIT STRING(SIZE(4)), // Mini cycle length (New in WBC). Next-Full-Index-WBC-segment-Object BIT STRING(SIZE(12 ) (New in WBC)) }

4.5.3. ADP Implementation

The WBC-ADP protocol is implemented in C++ on a Linux platform [152]. To enable the ADP to run in an efficient way, a multi-thread scheme (running under a Finite State Machine, Figure 4.25) was designed for optimizing the business logic of the sending/receiving process. In addition, to facilitate the protocol running on handheld MTs, the minimization of the memory consumption and maximization of the FEC encoding/decoding speed are both targeted when designing the ADP.

Send_Pkts Init

New_Seg No_ Pkt close Ready Send Start Finish End

State_NIL

Send_Reset

Recv_Pkts Init K_Pkt_Recv New_Seg close Ready Recv Start Finish End

State_NIL

Recv_Reset

Figure 4.25: The ADP Sender’s/Receiver's Finite State Machine

As stated in section 4.3.2.4, a JNI – ADP middleware need to be developed to invoke the C++ library of ADP at the application enabler sub-layer. Figure 4.26 shows the JNI-ADP Java UML class diagram.

81 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

wbc_JNI_ADP adpsend

~id: int = 0 +wbc_open(mode: String): int ~port: int = 2324 +wbc_close(id: int): int ~ttl: int = 5 +wbc_abort(id: int): int ~verbose: int = -1 +wbc_wait_event(id: int, event: int): int ~m: wbc_JNI_ADP +wbc_send(id: int, data: byte, len: int): int ~fd: FileInputStream = null +wbc_recv(id: int, data: byte, len: int): int ~addr: InetAddress = null +wbc_ctl_STATS(id: int, stats: int): int +wbc_ctl_PORT(id: int, port: int): int +main(args: String) +wbc_ctl_ADDR(id: int, addr: String): int ~send() +wbc_ctl_VERBOSITY(id: int, verbosity: int): int ~pa rse _comma ndline () +wbc_ctl_TTL(id: int, ttl: int): int ~usage(args: String) +wbc_ctl_DEBUG(id: int): int +wbc_ctl_MOREABOUT(id: int): int +wbc_ctl_SINGLE_LAYER(id: int, layer: int): int +wbc_ctl_DEMUX_LABEL(id: int, label: int): int +wbc_ctl_NETIF(id: int, netif: int): int +wbc_ctl_LOOPBACK(id: int, loopback: int): int +wbc_ctl_SET_NEXT_TOI(id: int, toi: int): int adprecv +wbc_ctl_TX_PROFILE(id: int, profile: int): int +wbc_ctl_DATAGRAM_SIZE(id: int, size: int): int ~id: int = 0 +wbc_ctl_TX_RATE(id: int, rate: int): int ~port: int = 8080 +wbc_ctl_FEC_RATIO(id: int, ratio: float): int ~ttl: int = 5 +wbc_ctl_NB_OF_TX(id: int, nb: int): int ~verbose: int = 3 +wbc_ctl_KEEP_DATA(id: int): int ~m: wbc_JNI_ADP +wbc_ctl_PUSH_DATA(id: int): int ~fd: FileOutputStream = null +wbc_ctl_RESET_TRANSMISSIONS(id: int): int ~addr: InetAddress = null +wbc_ctl_SCHED(id: int, sched: int): int +wbc_ctl_OBJ_SCHED(id: int, sched: int): int +main(args: String) +wbc_ctl_SET_FEC_CODE(id: int, code: int): int ~recv() +wbc_ctl_SRC_ADDR(id: int, addr: int): int ~pa rse_commandline () +wbc_ctl_SP_CYCLE(id: int, cycle: int): int ~usage(args: String) +wbc_ctl_PKT_TIMEOUT(id: int, timeout: int): int

Figure 4.26: The WBC JNI-ADP UML Class Diagram

With JNI-ADP, the ADP parameters can be defined via WBC-SP’s UI portal (Figure 4.27), e.g. fec_ratio (r), encoding symbol length (t), source block length (k), sequence number (esi), encoding symbols interleaving mode (m), etc. Following this software design approach, the flexibility of the whole system is improved significantly. To compare the performance of ADP, Flute, and FCast, two metrics - encoding speed and decoding speed – were selected and measured on a (1.0-GHz Via C7M processor and 512M RAM) UMPC with Linux OS. The WBC segment size was set to 8 Kbytes, and the noise in the channel followed a uniform distribution with 5% packets error. Figure 4.28 compares the encoding and decoding speeds (in packets/s) of ADP, Flute (TZI, C++ implementation), and FCast (INRIA, C implementation) with different fec_ratio and k. The results show that the ADP encoding/decoding speed is higher than that of Flute and FCast. This is due to the fact that the ADP header is smaller (i.e. deliberately shorten) and the ADP protocol does not generate extra documents, such as FDT (Flute) or XML meta-data (FCast).

82 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

Figure 4.27: The WBC-SP MAS Portal: ADP Broadcaster.

7000 4500 ADP ADP Flute 6000 4000 Flute FCast FCast 3500 5000 (a) k=8,Encoding (b) k=8,Decoding 3000

4000 2500

3000 2000 Packet/s Packet/s 1500 2000 1000 1000 500

0 0 1.25 1.5 1.75 1.25 1.5 1.75 FEC Ratio FEC Ratio

3500 2500 ADP ADP Flute Flute 3000 FCast FCast 2000 (c) k=16,Encoding 2500 (d) k=16,Decoding

1500 2000

1500 Packet/s Packet/s 1000

1000 500 500

0 0 1.25 1.5 1.75 1.25 1.5 1.75 FEC Ratio FEC Ratio

Figure 4.28: Performance Comparison of ADP, Flute (TZI), and FCast (INRIA).

83 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

Full comparison between the ADP, Flute, and FCast is presented in Table 4.4.

Table 4.4: The ADP, Flute, and FCast Comparison

Features ADP Flute FCast

Standard No Yes Yes

FEC Supported Only RS Any Any

Congestion Control No Yes Yes

Push or Pull Push only Yes Yes

File Properties ASN.1 XML FDT Meta-Data

Header Size 8 bytes 44 bytes 60 bytes

Redundancy Control Yes (QoS) No No

Large File Support No Yes Yes

File WBC No Yes Yes segmentation

4.6. Conclusion

This chapter has presented the design and implementation of the WBC service layer on the WBC-SP side. Starting with a brief introduction of SDs encoder implementation, the chapter then delves further into the design and implementation of the application enabler sub-layer and service enabler sub-layer.

On the WBC-SP side, the application enabler sub-layer was implemented with three tiers: a service discovery and maintenance tier acting as a client-server distributed system for data collection and organization, an intelligent application tier holding all business logic and common APIs, and a multi-agent system tier maintaining the agents' lifecycle and supplying message transport services. A message channel, blackboard and gateway agent are shared by all three tiers thus enabling advertisement processing in an efficient way. A number of open-source IDEs/APIs/frameworks were used for this sub-layer implementation to build a flexible and efficient broadcasting system. Java SE/Java EE is the main technique used to implement this sub-layer.

84 Chapter 4. WBC Service Layer – WBC-SP side’s Design and Implementation

The service enabler sub-layer runs the ADP protocol. It is implemented in C++, can be invoked from the application enabler sub-layer, and acts as a bridge between the service layer and link layer of WBC to provide an IPDC functionality.

85 Chapter 5. WBC Service Layer - User side Design and Implementation

CHAPTER 5. WBC SERVICE LAYER - USER SIDE’S DESIGN AND IMPLEMENTATION

5.1. Introduction

This chapter describes the design and implementation of the WBC service layer on the user side used for facilitating the wireless services discovery and association. The potential techniques for decoding the SDs and implementing the WBC service layer on the user side have been stated in Chapter 3. The SDs are decoded by an ASN.1 PER decoder and described by Java objects. Similarly to the WBC-SP side, the WBC service layer on the user side includes two sub-layers. At the application enabler sub-layer, a portable software architecture combining a Java SE environment and a light-weight agent execution environment has been developed for discovering the wireless service advertisements. In addition, three different types of client applications have been developed: a Java SE terminal application for management of service advertisements, a Java ME and an Android terminal applications for association with services. At the service enabler sub-layer, an ADP receiver decapsulates the WBC segments from the received IP packets as explained in Section 4.5.

5.2. Design and Implementation of SDs Decoder

The ASN.1-PER decoder depends on the Java classes used for decoding the PER octets into Java SD object, which was shown in Figure 4.1. A demo of the Decoding_TSASMS (an teleservice SMS SD) class diagram is shown in Figure 5.1.

5.3. Architecture Design of Application Enabler Sub-Layer on User Side

To achieve a portable and efficient structure on the user side, similarly to the WBC-SP side, the application enabler sub-layer is built with three tiers (Figure 5.2).

86 Chapter 5. WBC Service Layer - User side Design and Implementation

SampleTSASMS +valueWBCTSASTS: wbcts.wbctsasms.AWBCTSASMS = init_valueWBCTSASTS() -init_valueWBCTSASTS(): wbcts.wbctsasms.AWBCTSASMS

Decoding_TSASMS ~write: int = 0 ~toHstring(value: byte): String ~bytetostring(bytearray: byte): String +Wbcts.initialize() +new_Wbcts(): ASN1Project +Wbcts.getPERAlignedCoder() +newAWBCTSASMS(): AWBCTSASMS +decode(source: ByteArrayInputStream, decodedData: AWBCTSASMS) +save(decodedData)

Figure 5.1: The Class Diagram of Decoding_TSASMS

MIDP / Android / Java Application

WBC MU Model-View-Controller

Local Service Builder

Business Logic APIs Local POJO APIs

Data Access Object Service Discovery and Maintenance Tier Message Channel

Shared Rule Common WBC ADP Ontology Engine APIs Algorithms APIs DB APIs APIs Application Tier

Gateway Agent Main MU Container Shared Blackboard

SDs DVB-H iWBC Dispatcher Personal Monitor Agent Agent Agent Agent Assistance Agent Agent iWBC Content Provider iWBC-UI MAS Container Tier

Figure 5.2: The WBC Application Enabler Sub-Layer’s (User Side) Architecture

87 Chapter 5. WBC Service Layer - User side Design and Implementation

Comparing with the architecture on the WBC-SP side, the architecture on the receiver side is light-weight. In the service discovery and maintenance tier, it still includes three sub-tiers but with less number of components. The client UI component includes MIDP, Android and GWT Java applications. In the application tier, the WBC wireless service advertisement APIs are changed to discovery and association APIs. In the MAS container tier, the wireless service advertisement agents are divided into two groups: (i) the SDs agent, DVB-H agent, iWBC agent, and dispatcher agent that run in a iWBC content provider for discovering and processing the SDs; (ii) the personal assistance agent (PAA) and monitor agent that run in a iWBC UI to facilitate the association with discovered services/providers [153].

As the design of the application tier and the MAS tier on the user side is quite similar to the WBC-SP side, this chapter is mainly focused on the service discovery and maintenance tier design and implementation. It includes the iWBC content provider’s and iWBC UI’s design and implementation.

Figure 5.3 shows the high-level view of the iWBC WPAN in the MU domain.

MU domain WBC-SP xSPs domain domain

iWBC Broadcasting WBC WPAN station Not-Enabled MT C WB ds on ice A Serv

iWBC WPAN IP Packets WBC xSPs Enabled MT SDs

iWBC WPAN WBC Portal

Figure 5.3: The iWBC WPAN in the MU Domain

The iWBC content provider is the core element in the personal iWBC mobile application. It receives service advertisements from the WBC channel and forwards these to the corresponding UI or other MTs which do not support the carrier technology/standard used for WBC.

88 Chapter 5. WBC Service Layer - User side Design and Implementation

5.4. Design and Implementation of iWBC Content Provider

To run the iWBC content provider on portable MTs, such as PPC, UMPC, laptop, etc, an iWBC light-weight HTTP container has been designed and implemented to act as a container for processing the HTTP requests and responses. An iWBC content manager runs on the HTTP container and communicates with the MAS to receive/manage wireless advertisements.

5.4.1. iWBC Light-weight HTTP Container

The iWBC light-weight HTTP container listens to the incoming TCP connections from MTs and processes the requests with the associated Handler objects (listed in the configuration file httpserver.ini). Each line in httpserver.ini contains a URI path, such as, “/dvbhservice,adserver.handlers.DVBHService”, which represents the DVB-H service handler. A createContext function is used for mapping a handler to a service in the container. The UML diagram of the light-weight HTTP container’s main Java classes is shown in Figure 5.4.

HTTP Container -httpServer: HttpServer Handler -address: InetSocketAddress <>+Server(port: int) +star t() +stop() DefaultHandler +reboot() +createContext(alias: String, handler: Handler): HttpContext +handle(exchange: HttpExchange)

wbc_http.ini Boot -t: Thread -port: int -server: HTTP Container = null <>+Boot(port: int) +main(args: String) +r un() +exit()

Figure 5.4: The UML Diagram of the iWBC HTTP Container’s Main Classes

Figure 5.5 shows the UI of the iWBC HTTP container.

89 Chapter 5. WBC Service Layer - User side Design and Implementation

Figure 5.5: The UI of the iWBC HTTP Container

5.4.2. iWBC Content Manager

The design of the iWBC content manager follows the light-weight MVC architecture. The model represents the Java objects (such as SDs, user, category, etc) that the iWBC content manager/client operate on. The view presents the client UI to the user. The controller defines how the iWBC content manager interacts with the business logic of the service discovery and maintenance tier to build the model and display it in the view.

5.4.2.1. Model

The iWBC content manager model includes five classes: AD, Division, Category, Type, and User. The UML diagram (Figure 5.6) illustrates the structure of these Java classes. The AD holds SD information and the User holds the MU personal information. The Java code for these classes is simple. The main functions include the get, set, toJSON, and toByte methods.

5.4.2.2. View

The view of the iWBC content manager includes three types: iWBC-JSE, iWBC-MIDP, and iWBC-Android. Different views have different software structures. The task is to present an efficient and easy-to-use UIs to MUs.

90 Chapter 5. WBC Service Layer - User side Design and Implementation

AD Division -serialVersionUID: long = -1000512304568031904L -id: String -id: String -name: String -name: String -typeId: String -type: String <>+Division() -division: String +getId(): String -category: String +setId(id: String) -version: String +getName(): String -CCPP: int +setName(name: String) -rank: int +getTypeId(): String -subscriptions: int +setTypeId(typeId: String) -advertiserText: String +toJSON(): JSONObject -advertiserURL: String -QoS: String -latitude: double -longitude: double -content: String -_length: String Category -_aattr: byte[*] -id: String <>+AD() -name: String +getId(): String -divisionId: String +setId(id: String) -isdefault: Boolean +getName(): String <>+Category() +setName(name: String) +isDefault(): boolean +getType(): String +setDefault(defaultValue: boolean) +setType(type: String) +getDivisionId(): String +getDivision(): String +setDivisionId(divisionId: String) +setDivision(division: String) +getId(): String +getCategory(): String +setId(id: String) +setCategory(category: String) +getName(): String +getVersion(): String +setName(name: String) +setVersion(version: String) +toJSON(): JSONObject +getCCPP(): int +toBytes(): byte +setCCPP(ccpp: int) +getRank(): int +setRank(rank: int) +getSubscriptions(): int Type +setSubscriptions(subscriptions: int) +getAdvertiserText(): String -id: String +setAdvertiserText(advertiserText: String) -name: String +getAdvertiserURL(): String +setAdvertiserURL(advertiserURL: String) <>+Type() +getQoS(): String <>+Type(id: String, name: String) +setQoS(qoS: String) +getId(): String +getLatitude(): double +setId(id: String) +setLatitude(latitude: double) +getName(): String +getLongitude(): double +setName(name: String) +setLongitude(longitude: double) +toJSON(): JSONObject +toString(): String +getLength(): String +setLength(length: String) User +setAattr(aattr: byte) -serialVersionUID: long = 3669596700547817684L +getAattr(): byte -id: String +getContent(): String +... +setContent(Content: String) +toJSON(): JSONObject +setCcpp(ccpp: int) +toBytes(): byte +...()

Figure 5.6: The UML Diagram of the iWBC Content Manager’s Model

5.4.2.3. Controller

The iWBC content manager’s controller is used for: receiving IP packets from the WBC, rebuilding the WBC segments, decoding SDs to Java objects, and saving the Java objects to the database; dispatching the message to MTs when new SDs (of MU’s interest) are coming; and handling the httpExchange objects from views. Unlike

91 Chapter 5. WBC Service Layer - User side Design and Implementation the traditional Client/Server (C/S) architectures, the interactions within the model are performed by agents in the iWBC solution. A RequestBuilder method is used by agents for creating httpExchange objects. The main Java classes of the controller are illustrated in Figure 5.7.

AgentManager <>+agents: MapClass?>,T2->Agent> +register(clazz: Class?>, agent: Agent): void +unregister(clazz: Class?>): void +getAgentAgent>(clazz: ClassT>): T +sendMessage(clazz: Class?>, msg: ACLMessage): void

SDsAgent DVBHAgent DispatcherAgent iWBCAgent ... -serialVersionUID -serialVersionUID +serialVersionUID +serialVersionUID +serialVersionUID #setup() #setup() #setup() #setup() #setup() #takeDown() #takeDown() #takeDown() #takeDown() #takeDown()

SDsBehaviour DVBHBehaviour DispatcherBehaviour iWBCBehaviour ...Behaviour -serialVersionUID -serialVersionUID +serialVersionUID +serialVersionUID +serialVersionUID +action() +action() +action() +action() +action() +done(): boolean +done(): boolean +done(): boolean +done(): boolean +done(): boolean()

MyGateWayAgent Response Requests +serialVersionUID +BlackBoardBean +newMessageSerializable>(msg: ACLMessage, clazz: ClassT>, object: T): ACLMessage +RequestBuilder() +action() +done(): boolean

SDsService DVBHService DispatcherService iWBCService ...Service

+handle(...) +handle(...) +handle(...) +handle(...) +handle(...)

Figure 5.7: The Main Java Classes of the iWBC Content Manager’s Controller

To achieve a light-weight architecture, the iWBC HTTP container is implemented with a Java handler instead of a Java EE Servlet. This way the MyGatewayAgent on the receiver side becomes light-weight and does not depend on the proxyAgent. An agent behavior is implemented in the following manner: during the request processing, an agent receives the request objects, sets them on the BlackBoardBean, and then sends the bean to the MyGatewayAgent; during the response processing, the MyGatewayAgent receives the results, sets them on the BlackBoardBean, and then sends the bean to the corresponding agent(s). To achieve a light-weight system, all agents on the MU side are managed by the Java class AgentManager instead of the yellow page service of the Java agent development framework (JADE).

92 Chapter 5. WBC Service Layer - User side Design and Implementation

5.5. iWBC UIs Design and Implementation

Different MTs may have different iWBC-UI installed, such as: iWBC-MIDP, iWBC-CDC, iWBC-JSE, iWBC-Android, iWBC-iPhone, etc. This thesis focuses on the design and implementation of the iWBC-JSE, iWBC-MIDP, and iWBC-Android. It runs on UMPC/PC, PPC, resource limited MT, respectively.

5.5.1. Architecture

The iWBC-UI components include: a view, a client PAA, a monitor agent, a message manager, a business logic, and a Java object persistence tier which includes a configuration file, database (DB), POJO, and Token, as shown in Figure 5.8.

UI Client PAA

Query

Stack Monitor (MIDP) Agent

Message Manager & Business Logic

Token Configure DB POJO (MIDP)

iWBC-Client Figure 5.8: The iWBC-UI Architecture

The iWBC-UI can work in two modes: (i) agent-online mode – the DB synchronization with the iWBC content provider is done by the advertisements monitor agent; all user operations are handled by PAA; (ii) agent-offline mode - the advertisements monitor agent and PAA are blocked; all user operations are handled by the message manager and business logic. The former mode is used with WBC not-enabled MTs, whereas the latter is for WBC-enabled MTs.

5.5.2. iWBC JADE

To support JADE operation in wireless environments, two JADE add-ons have been made available on the JADE website [117] – the JADE-LEAP and the JADE Android. The JADE-LEAP splits in three versions [45]: JADE-MIDP, JADE-PJava, and JADE-J2SE. Different versions need different Java Archive (JAR) library support; In

93 Chapter 5. WBC Service Layer - User side Design and Implementation

JADE-Android [42], to access the Android device resources, two complex JADE Android APIs - jade.android.MicroRuntimeService (the Android JADE run time environment) and jade.android.JadeGateway (the entry point in the JADE system) - should be instantiated. Each Android activity should implement the JadeGateway's connect and onConnected functions to communicate with the JADE environment. In the case of multiple activities, this mechanism may cause instability of the Android application (due to reconnection with the JadeGateway agent).

As the iWBC client application does not need direct access to the local MT resources, a hardware-independent uniform JADE-iWBC design has been elaborated based on JADE-LEAP. It can work on the iWBC-client using the same JAR library and does not use a MANIFEST configuration file. To achieve a light-weight architecture of the iWBC client, the JADE-iWBC only supports the Mediator mode [118], i.e., the JADE container is WBC segmented into a front-end (running on the MTs) and a back-end (running in the iWBC content provider). Figure 5.9 shows the JADE architecture of the iWBC mobile application.

Figure 5.9: The JADE Architecture of the iWBC Mobile Application

To unify the iWBC client design, a HTTP-like request /response mechanism (Figure 5.10) together with a compact Java object serialization APIs has been developed. The iWBC.iWBCAgent class is the most important class. Other agents should extend from this class by only overriding the iwbcrequest method. The iWBCAgent acts as a gateway between the UI and the iWBC content provider.

The main steps in developing and using an agent on the iWBC UI side are:

 Create an agent, which extends the iWBCAgent; add the agent's behaviours; override the iwbcrequest method (in the latter, an ACL message is generated

94 Chapter 5. WBC Service Layer - User side Design and Implementation

and sent to JADE MAS; the request object is inserted as a content parameter in the ACL message);  Develop the corresponding iWBC UI Form object (a Form is a UI screen that contains a number of items, such as images, text fields, choice groups, etc); in the commandAction method, build the request object and invoke the agent's iwbcrequest method;  The created agent receives messages from JADE and invokes the onResult method in the iWBC UI Form object;  The iWBC UI Form object de-serializes the received ACL message to a POJO, refreshes the UI Form and runs the corresponding persistence operations.

Request Response MessageManager -agent: String -content: String -listeners: Hashtable = new Hashtable() -content: String -data: byte[*] -data: ISyncObject +regListener(clazz: Class, listener: MessageListener) -params: Hashtable <>+Response(content, data) +unRegListener(clazz: Class, listener: MessageListener) +getContent(): String +unRegListener(clazz: Class) <>+Request(agent, content, data) +getData(): byte +sendMessage(msg: Object) +getAgent(): String +getContent(): String +getData(): ISyncObject +setParam(name: String, value: String) +getParams(): Hashtable

-INST

PAA -INST: PAA -requests: Hashtable = new Hashtable() -results: Hashtable = new Hashtable() MessageListener -autoId: int = 0

#setup() #takeDown() +iwbcrequest(request: Request, listener: IResultListener) IResultListener

Figure 5.10: The UML Diagram of the PAA, Request, Response and MessageManager

The two important agents in the iWBC-UI are: the PAA and monitor agent. The client PAA consists of multiple generic behaviours, such as searcher behaviour, profiles behaviour, category behaviour, updater behaviour, etc. In contrast, the monitor agent only contains one cyclicBehavior. This latter agent discovers the ‘interesting’ SDs (as per the user profile) when the iWBC content provider receives new SDs from the WBC channel and sends a MSGCategoryUpdate message to the message manager for home page ADlistByCategory view repainting and local database updating.

Two novel interface components have been designed for iWBC-UI (Figure 5.10): (i) IResultListener (located in the JADE package) with an operation onresult; it is declared as an agent but implemented in the corresponding Form; (ii) MessageListener (located

95 Chapter 5. WBC Service Layer - User side Design and Implementation in the message package) with an operation handle; like IResultListener, it is registered and declared in the MessageManager but implemented in the corresponding Form. This design pattern makes the iWBC-UI source code clear, and easy to implement and test.

5.5.3. iWBC Client Profiles

To achieve personalized service discovery and association, the user may define different roles for different MTs. For example, the user may use a limited capabilities cell phone for voice call service, and a UMPC with acceptable display resolution for high data rate eLearning services. The PAA runs on each MT for intelligent management of MT identification, device CC/PP [14] profile, and user profiles (Table 5.1).

Table 5.1: The iWBC User Profile's General Description

Module Contents

Identification/ Contains personal information, including user name, sex, age, position, Authentication address, credit card information, username, password, etc (all security Profile protected). CC/PP Location Contains MT location, defined by means of a Global Positioning System Profile (GPS). Contains favorite advertisement categories; acts (together with user IA profile Advertisement and CC/PP location profile) as a receiving advertisements filter for MTs to Profile save power and database space. Contains user preferences for ‘best’ services. E.g. the cheapest available Discovery service to call family members but a high-performance service to call business Profile partners, or specifying a price lower than 1c/ min for high-quality online music service, etc. Association Used by the user/terminal to associate with the ‘best’ access network and/or Profile the "best" teleservice at any given moment. Used for defining how to sort and list the SDs in screen-limited MTs. Initially, Rules PAA will generate a set of rules when the MT is first initialized with the Profile user’s personal information; the user and PAA can update the rules at any time later. Contains user operating behaviors recorded by PAA. The history SD’s History information is stored in the slots of the history POJO in a First-In-First-Out Profile (FIFO) manner.

96 Chapter 5. WBC Service Layer - User side Design and Implementation

In practice, the user profiles may change frequently with regard to the user personal information, interests, rules, and history. To maintain the user profiles in a dynamic way, the profiles are built with POJO instead of RDF. PAA loads profiles from a database when MT is switched on, then asserts the profiles into the working memory as profile facts, serializes the profiles objects to the database, and synchronizes all MT's profiles within the user's WPAN when any of them is being modified.

5.5.4. iWBC-UI Java Packages Structure

The iWBC-UI application development environment has been realized with Eclipse, Java ME SDK 3.0, GWT, Android 1.5. Figure 5.11 depicts the iWBC-UI Java packages dependencies diagram.

DB Sync JADE Message MessageManager DAO Request Response ISyncObject +User() +regListener() +Profiles() +unregListener() +Favorites() iWBCAgent +sendMessage() +Histroy() SD MySDs User +setup() IResultListener +takeDown() MessageListener +iWBCRequest()

JSE UI MIDP UI Andorid UI

Figure 5.11: The iWBC-UI Java Packages Dependencies UML Diagram

Several Java packages are used in this application as explained below:

 DAO package - this includes database O/R mapping tools. The agent interactions in agent-offline mode of iWBC-UI depend on the local DAO operation.  Sync package - a POJO package mainly including SDs, mySDs and user class. Each POJO class needs to implement the ISyncObject interface supporting the Java object serialization and un-serialization;  Message package - an event listener model supported package. The listener runs on the Form and receives broadcast notifications from the message manager;

97 Chapter 5. WBC Service Layer - User side Design and Implementation

 JADE package - an uniform iWBC-UI agent building package. Figure 5.10 shows the UML diagram of PAA. The PAA class follows the singleton design pattern [106]. A private static INST:PAA attribute is created when the PAA is initialized;  UI package - an UI Forms generating package. Different iWBC-UIs have different structure. Figure 5.12 depicts the iWBC client time-sequence UML diagram of the mobile user’s interaction with the iWBC content provider in agent-online mode [153].

Figure 5.12: The Time-sequence UML Diagram of the MU Interaction with the iWBC Content Provider (Agent-Online Mode)

98 Chapter 5. WBC Service Layer - User side Design and Implementation

5.5.5. iWBC-JSE UI Implementation

In order for iWBC-JSE UI to maintain the iWBC content provider, as stated in Chapter 3.3.2.2, a GWT AJAX web application together with an iWBC ADP receiver has been integrated into the Java desktop portal application framework (Section 4.4.1) acting as the UI.

The GWT web-based application is written in pure Java language [43]. It is easy to compile and generate the optimized JavaScript codes. This is an efficient way to build the AJAX application in comparison with the manually written one. In the iWBC-JSE UI, the main Java classes include ADManager, CategoryManager, MyApplication, etc, as shown in Figure 5.13.

CategoryListBox TypeListBox DivisionListBox

-value: String -value: String -value: String -index: int = 0 -index: int = 0 -index: int = 0 -noneText: String -handler: ChangeHandler -handler: ChangeHandler -noneText: String -noneText: String <>+CategoryListBox() +setDivisionId(divisionId: String) <>+TypeListBox(inHandler: ChangeHandler) <>+DivisionListBox(inHandler: ChangeHandler) +setSelectedValue(value: String) +setSelectedIndex(index: int) +setTypeId(id: String) +setSelectedIndex(index: int) +setSelectedValue(value: String) +setSelectedValue(value: String) +getSelectedValue(): String +getSelectedValue(): String +setSelectedIndex(index: int) +getSelectedText(): String +getSelectedText(): String +getSelectedValue(): String +getSelectedText(): String

ADManager -table: FlexTable -typeListBox: TypeListBox MyApplication -divisionListBox: DivisionListBox -queryText: TextBox +onModuleLoad() -categoryListBox: CategoryListBox -pageLabel: Label -ads: List = new ArrayList() -maxCount: int = 25 -pageIndex: int = 0 CategoryManager -totalCount: int = -1 -columnHandler: ColumnListener = new ColumnListener() -tree: Tree -orderArg: String = "" -dPanel: DeckPanel

<>+ADManager() <>+CategoryManager() +getArgs(): String +changeState() +refreshTable() +refreshTree(tree: Tree) +setADtoTable(index: int, ad: AD) +refreshTreeItem(item: TreeItem)

CategoryEditDialog TypeEditDialog DivisionEditDialog

ADEditDialog -handler: SubmitHandler -handler: SubmitHandler -handler: SubmitHandler -isNew: boolean -isNew: boolean -isNew: boolean -ad: AD -division: Division -type: Type -division: Division -handler: SubmitHandler -category: Category -type: Type -isNew: boolean <>+TypeEditDialog(...) <>+CategoryEditDialog(...) <>+DivisionEditDialog(...) <>+ADEditDialog(...)

Figure 5.13: The UML Diagram of iWBC-JSE UI Application’s Main Classes

The MyApplication is the EntryPoint of the GWT application. An onModuleLoad method initiates a DockPanel widget and adds it to the RootPanel widget to implement the layout of the application. A number of child panels, such as ADManager and CategoryManager, were added to the DockPanel to build the function tabs (Figure

99 Chapter 5. WBC Service Layer - User side Design and Implementation

5.14).

With the designed GWT Java classes, the Java command used for generating and deploying the HTML JavaScript code is shown below:

@java -Xmx256M -cp "%~dp0\src;%~dp0\bin;%~dp0\..\lib\gwt\gwt-user.jar;%~dp0\..\lib\gwt\gwt-dev-windows.jar;%~dp0\.. \lib\gwt\gwt-maps.jar" com.google.gwt.dev.GWTCompiler -out "%~dp0\..\AdServer\web\gwt" %* com.mycompany.MyApplication

Figure 5.14 shows the iWBC-JSE UI application.

(a)

100 Chapter 5. WBC Service Layer - User side Design and Implementation

(b)

Figure 5.14: The iWBC-JSE UI: (a) AD Manager; (b) Category Manager.

5.5.6. iWBC-MIDP UI Implementation

The iWBC-MIDP runs on a Java-enabled cell phone or an embedded small device which supports the MIDP specification [40, 154]. The core Java package of MIDP UI is shown in Figure 5.15. The ItemContent and BaseForm are the main classes in this package. Each Form should implement the onCreateItem method in ItemContent class for UI Forms generation. To design an efficient MIDP application, another two sub- packages were provided as follows:

101 Chapter 5. WBC Service Layer - User side Design and Implementation

 Control package - the UI screen header and ADlistByCategory view (the fast navigator view in the main UI) paints package.  Input/Output (IO) package - the basic package for serialization and un-serialization operations. The Token class is the main class in this package which includes three important attributes: data, offset and length with Java type byte, integer, and integer respectively.

JSE UI IO Token BaseForm +TokenOutputStream() +TokenInputStream()

... SearchForm SDInfoForm MainForm ConfigForm FavoriteCategoryForm

Control TabBar

ItemContent ADListByCategoryView

AD_Item

... HistoryContent HomeContent FavoriteContent _Tab

Figure 5.15: The iWBC-MIDP UI Java Packages Dependencies UML Diagram

There are two problems in designing the iWBC-MIDP UI: the Form scheduling problem and the Form container problem. Java ME does not provide solutions for these problems.

In Java ME, when the MIDP UI changes from Form 1 to Form 2, Form 1 is destroyed directly. When the user comes back to Form 1, Form 1 needs to be repainted. This is considered inefficient for the iWBC-MIDP application design. To solve this problem, a BaseForm class has been designed by extending the Form object and adding a Vector stack object. A Form can be appended to or popped from the stack.

In the MIDP UI design, if one screen includes several Forms (e.g., header Form, body Form, bottom Form), the different UIs use the same header Form and same bottom Form. In Java ME, if the UI is changed to another one, all Forms on the screen need to be repainted. To improve efficiency, an indexOf method has been implemented in the

102 Chapter 5. WBC Service Layer - User side Design and Implementation

BaseForm class to record the position of each Form, so when the UI changes, only the new Form needs to be repainted and inserted into the current UI.

The iWBC-MIDP UI (Sony Ericsson mobile phone W900, Figure 5.16) includes four tabs: (i) the home tab contains a search box and the ADlistByCategory view (the SD list in each favorite category can dynamically change when new ‘interesting’ SDs arrive at the iWBC content provider), (ii) the favorite tab stores user’s ‘best’ SDs, (iii) the history tab records the user’s history (a list of accessed/read SDs), (iv) the configuration tab is used by the user to define profiles, update the software, etc.

Figure 5.16: The iWBC-MIDP UI (Sony Ericsson W900)

103 Chapter 5. WBC Service Layer - User side Design and Implementation

5.5.7. iWBC-Android UI Implementation

Comparing with the MIDP specification, the Android abstracts the hardware better and does not use the Java ME SDK [155], i.e., the code does not have to be device- specific. The Android software stack has been explained in Chapter 3.3.2. The Form in Android is named as Activities. Each activity is independent of the others and runs on a single Java thread. Figure 5.17 shows the lifecycle of FavoriteView activity. The FavoriteView activity starts when it comes to the top of the activity stack, and then focuses on the user’s actions. It will be stopped when the view is completely obscured by another activity.

FavoriteActivity starts

onCreate()

User navigates back to the activity onStart() onRestart()

Activity is running Process is killed The Activity comes to the foreground

History Activity comes in front of the Activity, The activity is no longer visible

onStop()

OnDestroy()

FavoriteActivity is shut down

Figure 5.17: The Lifecycle of FavoriteView Activity

The entrance of iWBC-Android is BrowserActivity. Figure 5.18 shows the BrowserActivity and it’s initTask Java classes UML diagrams.

104 Chapter 5. WBC Service Layer - User side Design and Implementation

In the constructor of BrowserActivity, three initial tasks, i.e., Db4oInitTask, UserInitTask and RegInitTask, are added to a Java List vector as global information for the iWBC-Android environment. The Config and R resource Java classes are the parameters of the iWBC-Android.

The kernel of iWBC-Android UI is the Activity design. Figure 5.19 shows the main iWBC-Android Activities.

BrowserActivity

+mHandler: Handler +max: int +pb: ProgressBar +flag: boolean Activity +initTasks: ListInitTask>

<>+BrowserActivity() +onCreate(savedInstanceState: Bundle): void +switchToNextActivity(): void

InitTask

Db4oInitTask RegInitTask UserInitTask

+onInit(context: Context) +onInit(context: Context) +onInit(context: Context)

Config R +Host: String = "218.12.76.242" <>+array +Port: String = "1099" <>+attr +Container: String = "Android" <>+drawable +AGENT_CATEGORY: String = "Category" <>+id +AGENT_ADQUERY: String = "ADQuery" <>+layout +DIVISION_IDS: String = "100,101,201,202,200,203,204,205" <>+string +HOME_SHOW_ADS: int = 5 +HISTORY_MAX: int = 20 +SEARCH_PAGE_SIZE: int = 20 +APP_TITLE: String = "AD v1.0"

Figure 5.18: The Initial Task of the iWBC-Android UI UML Diagram

Similarly to iWBC-MIDP, the iWBC-Android UI also includes four tabs: the home tab, a favorite tab, a history tab and a configuration tab, as shown in Figure 5.20.

105 Chapter 5. WBC Service Layer - User side Design and Implementation

LoginView RegisterView -userNameSpinner: Spinner -userNameText: EditText -passwordText: EditText -passwordText: EditText -loginButton: Button -registerButton: Button -registerButton: Button -access: UserAccess -access: UserAccess -userChangeListener: MessageListener = new MessageListener(){} +onCreate(savedInstanceState: Bundle) +onCreate(savedInstanceState: Bundle) +onDestroy()

MainView

+onCreate(savedInstanceState: Bundle) +onDestroy()

MainViewContent FavoriteView OptionView HistoryView -button_search: Button -lv: ListView -option_favorite: Button -lv: ListView -edittext_search: EditText -listener: MessageListener -option_profile: Button -listener: MessageListener -elv: ExpandableListView -option_system: Button -mHandler: Handler #onCreate(savedInstanceState: Bundle) -option_help: Button #onCreate(...) -adpater: ExpandableListAdapter #onDestroy() -option_update: Button #onDestroy() -msgFavoriteChangeListener: MessageListener <>+OptionView() +onCreate(savedInstanceState: Bundle) +onCreate(...) +onClick(v: View) -setChildrenOnClickListener() +onItemClick(...) +onClick(v: View) +getGenericView(): TextView +onChildClick(...): boolean

SearchResultListView ItemInfo HomeFavoriteView ProfileView -textView_title: TextView -titleView: TextView -button_save: ImageButton -spinner_ccpp: Spinner -bunPerv: Button -categoryView: TextView -button_refresh: ImageButton -spinner_sort: Spinner -bunNext: Button -contentView: EditText -lv: ListView -button_save: ImageButton -txtPage: TextView -urlView: TextView -categorys: Category[*] -button_location: Button -lv: ListView -rankView: TextView -mHandler: Handler -pageIndex: int = 0 -ccppView: TextView +onCreate(...) -lastCount: int = -1 -versionView: TextView <>+HomeFavoriteView() -retrieveWidget() -query: String -addFavorite: ImageButton +onCreate(...) -save() -ads: AD[*] -ad: AD +onDestroy() +onClick(v: View) -mHandler: Handler -handler: Handler -retrieveWidget() -saveStatus() <>+SearchResultListView() +onCreate(savedInstanceState: Bundle) +onClick(v: View) +onCreate(savedInstanceState: Bundle) -reload() -load(query: String) -retrieveWidget() -getAdapter(): Adapter +onItemClick(...)

Figure 5.19: The UML Diagrams of iWBC-Android Activities

106 Chapter 5. WBC Service Layer - User side Design and Implementation

Figure 5.20: The iWBC-Android UI

Figures 5.21 shows the iWBC WPAN setup and operation. The iWBC content provider (installed on a laptop) receives SDs by means of a DVB-H POD-1100 USB receiver and forwards these over WPAN to the WBC un-enabled Android Google mobile phone, which selects and associates with the ‘best’ chosen services as per the user profile. Other components include a GWT viewer and a Sun Java wireless toolkit for MIDP emulator.

Figure 5.21: The iWBC WPAN Setup and Operation

107 Chapter 5. WBC Service Layer - User side Design and Implementation

5.6. Conclusion

On the user side, considering that the design of the application tier and MAS tier in the service enabler sub-layer and the design of the ADP protocol in the application enabler sub-layer are similar to those on the WBC-SP side, this chapter has mainly presented the design and implementation of the service discovery and maintenance tier of the WBC service layer on the user side.

The design and implementation of an iWBC content provider acting as a light-weight server for receiving SDs from the WBC, and of iWBC-JSE, iWBC-MIDP and iWBC-Andorid user interfaces (UIs) for service discovery and association have been presented and explained.

The iWBC content provider runs on an iWBC light-weight HTTP container and provides a number of handlers together with the MAS to process client requests. Considering that different MTs may have different UI design, the DAO, POJOs, message manager, profiles and client side split-agents used in the iWBC-UI design have followed the uniform design and implementation. The details of the design and implementation of iWBC-JSE, iWBC-MIDP, iWBC-Android UIs have been provided. Using the peer-to-peer JADE communication and light-weight HTTP container, the iWBC-JSE, iWBC-MIDP and iWBC-Android can dynamically update SDs information from the iWBC content provider as directed by the user profiles.

108 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

CHAPTER 6. ‘WBC OVER DVB-H’ LINK LAYER DESIGN AND IMPLEMENTATION

6.1. Introduction

This chapter outlines the ‘WBC over DVB-H’ link layer design and implementation. As stated in Chapter 3.4, the link layer acts as a bridge between the service layer and the physical layer, and the DVB-H is selected as a WBC carrier. To evaluate the system performance and demonstrate real-time operation, the link layer testbed has been implemented in software and hardware, respectively. In the pure software testbed implementation, two new cross-layer decapsulating and decoding algorithms have been proposed. In the hardware testbed implementation, efficient DVB-H link- layer broadcaster and receiver have been designed and implemented.

6.2. Software Design and Implementation

6.2.1. Encapsulating and Encoding Schemes

On the WBC-SP side, the IP packets are cached at the Logical Link Control (LLC) sub-layer. When the number of IP packets in the cache becomes sufficient to fill up the ADT, the IP packets are encapsulated into the ADT column-wise, one by one. With the ADT table, the MPE-FEC frame and corresponding TS packets sequence are generated. Comparing with the DVB-H standard, an additional smart 8B Correct WBC segment Index Table (CSIT), Figure 6.1, is inserted at the end of the last WBC segment padding area to help the decoder operate in an efficient way [10]. The CSIT consists of the following 8 bytes: the header indicates the start of CSIT; Burst number is the serial number of the WBC data burst; w denotes the number of WBC segments in a MPE-FEC frame; k as the number of source symbols in each WBC segment; n as the number of encoding symbols (IP packets) in each WBC segment; x as the number of MPE-FEC column(s) occupied by each IP packet; two FEC bytes of the CSIT.

109 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

1 Header 2 Burst Number 3 x 4 w 5 n 6 k 7 FEC Byte 1 8 FEC Byte 2

Figure 6.1: The ‘WBC over DVB-H’ CSIT Table The encapsulator’s and encoder’s functional models are depicted in Figure 6.2.

IP packets

Build MPE-FEC frame, generate CSIT table and insert it at the end of IP section of MPE-FEC frame

FinishInstall IP packets to the MPE- Finish LLC SubLayer FEC frame. Add RS parity data.

Extract first/next IP packet from Extract each RS column from IP section of MPE-FEC frame, FEC section, insert MPE header insert MPE header and CRC-32 and CRC-32 trailer, and put trailer, and put resultant MPE resultant MPE packet in cache. packet in cache.

Done for all IP NO NO Done for all RS packets? columns?

YES Build TS packets and put them YES into TS buffer table (when becoming full, signal this event to the physical layer)

NO Done for all waiting WBC segments?

YES MAC SubLayer END

Figure 6.2: The ‘WBC over DVB-H’ Link Layer Encapsulator’s and Encoder's Functional Models

110 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

6.2.2. Decapsulating and Decoding Schemes

6.2.2.1. Section Erasure (SE) and Transport Stream Erasure (TSE)

Compared with the encapsulating and encoding schemes, the decapsulating and decoding schemes are opened for end users' design and implementation. In [72, 126], a SE decoding scheme is suggested for use at the Media Access Control (MAC) sub-layer. The MPE packet is first decapsulated from the received TS packets and a CRC-32 error-detection algorithm verifies it. If no errors are detected, the MPE packet is marked as "reliable"; otherwise it is marked as "unreliable". Then the IP packet is decapsulated from the MPE packet. The IP packet together with the CRC verification result is sent up to the LLC sub-layer, where the IP packet is inserted in the relevant column(s) of the MPE-FEC frame. The corresponding column of Erasure Info Table (EIT), Figure 6.3, is filled with "0" or "1", i.e. "0s" for "reliable" packets and "1s" for "unreliable" ones. When the MPE-FEC frame is full, the decoding algorithm checks the number of "1s" in the MPE section and the number of "0s" in the FEC section of EIT. If for every row, the number of "1s" is smaller than the number of "0s", then the MPE-FEC frame can be decoded with the RS(255,191) code; otherwise the MPE-FEC frame should be marked as error-prone frame.

In WBC, the error protection of service advertisement is an important issue since even a single bit error may cause discarding of a full burst-data/WBC segment [10]. The SE decoding scheme, however, is not efficient since the MPE-FEC frame may be marked as error-prone even if some parts of it are error-free. In [55, 72, 156], a TSE decoding scheme and two hierarchical erasure-plus-error RS decoding schemes were proposed in the link layer to improve reliability. The hierarchical decoding schemes in [72] leads to complex hardware design of the ‘WBC over DVB-H’ link layer and thus is not suitable for direct use in WBC.

The TSE scheme is proposed as follow. At the MAC sub-layer, the TSE MPE/FEC section decoding does not depend on the CRC scheme, but uses a bit indicator - transport_error_indicator (TEI) located in the TS header - to identify whether the TS packet can or cannot be decoded with the RS(204,188) at the physical layer. TEI = 0 means a decoding success, whereas TEI=1 means a decoding failure (packet_IDentifier (PID) failure or payload failure). At the LLC sub-layer, the

111 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation corresponding TS packet position of EIT is filled with “0” or “1”, and the decoding scheme is the same as in the SE. Because the TS payload is smaller than the IP packet, the performance of the TSE scheme is better than the SE scheme [72].

6.2.2.2. WBC Cross-layer Smart Section Erasure (SSE) and Smart Transport Stream Erasure (STSE)

Being not designed for WBC with their specific characteristics in mind, the erasure decoding schemes are not efficient for direct use in WBC. As one DVB-H burst (MPE-FEC frame) usually contains several WBC segments, one byte error in the MPE-FEC frame may cause discarding of the whole burst dataset. To improve the error protection in WBC, a CSIT used by the ADP for cross-layer decoding was developed. Based on the SE and TSE, the WBC cross-layer smart decoding schemes plot into Smart SE (SSE) and Smart TSE (STSE) [10, 12]. The decapsulation process of the SSE and STSE is the same to that of the SE and TSE, respectively. Both use the same decoding process as shown bellow:

 Step 1: Try to decode each row j of the MPE-FEC frame. If decoding fails, mark the un-decoded row (grey colour in Figure 6.3) and go to step 2. Step 2: Initialize the CSIT (Figure 6.1). Execute the following algorithm: for i=1 to w if there are “1s” in corresponding EIT columns, then a) extract i*x*n IP packets from MPE-FEC frame, and b) decode with ADP in packet erasure mode. if WBC segment is decoded successfully, then a) encode the recovered WBC segment into IP datagram with ADP packet erasure scheme, and b) fix the corresponding MPE-FEC cells and EIT table. c) try to run the RS algorithm on MPE-FEC frame. end if end if i = i+1 end for.

if EIT contains errors, for i=1 to w if IP(good)

112 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

Compared with SE and TSE decoding schemes, WBC cross-layer smart decoding schemes provide extra reliability. On the other hand, due to WBC smart decoding work with ADP protocol, the time complexity is increased from O(k l x) to O(k (n-k+l+l x)) , where l is the number of lost packets. This is acceptable because it is only an additive increase.

Figure 6.3 shows an example of the WBC cross-layer smart decoding, where k=8, n=10, and the number of MPE-FEC rows is 512.

Figure 6.3: The WBC Cross-layer Smart Decoding The decoder’s functional model is depicted in Figure 6.4.

6.3. Hardware Testbed’s Design and Implementation

The hardware testbed of the ‘WBC over DVB-H’ link layer is shown in Figure 6.5. This include: (i) on the WBC-SP side - a UDCast [127] IPE-10 fully DVB-H supporting IP encapsulator and encoder (Figure 6.5a); (ii) on the user side - a TeamCast [128] POD-1100 receiver (Figure 6.5b) acting as an IP decapsulator and

113 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation decoder and a UDCast GOLDENEAGLE (Figure 6.5c) acting as a monitor and analyser.

MAC Sublayer TS packets

Store TS packet in TS buffer table

Create empty MPE-FEC frame, LLC Sublayer EIT based on CSIT

Generate MPE/FEC section, extract MPE/FEC section payload, update MPE-FEC, EIT with MU pre- defined decapsulating algorithm.

NO MPE-FEC frame fully built?

YES MPE-FEC, EIT building process finished

Decode MPE- FEC frame with NO Done for all TS MU pre-defined packets? algorithm YES

END

WBC Service IP packets Layer

ADP PED

Figure 6.4: The 'WBC over DVB-H' Link Layer Decoder's Functional Model

6.3.1. WBC-SP Side

For efficient control of the IPE-10 parameters, the IPE-10 web application has been integrated into the WBC-SP portal application. Thus the WBC-SP may remotely control the link-layer parameters. The main steps in setting up the link layer parameters are the following:

114 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

 Step 1: Define the IP address, mask, Maximum Transmission Unit (MTU) as shown in Figure 6.6a;

(a) (b)

(c)

Figure 6.5: The DVB-H Link Layer Testbed Equipment: (a) IP Encapsulator and Encoder (IPE-10); (b) IP Decapsulator and Decoder (POD-1100); (c) Monitor and Analyzer (GOLDENEAGLE).  Step 2: Configure the IP encapsulator’s output parameters, including output bitrate, DVB Service Information/Program Specific Information (SI/PSI) signalling table [51]and adaptive queue (Figure 6.6b).  Step 3: Configure the DVB frequency and cell parameters (same as in the physical layer), Figure 6.6c.  Step 4: Create DVB-H channels. Configure each channel period and all needed time-sliced channels with the following parameters: channel bitrate, burst duration, program number, program ID, etc. These parameters are used to generate the SI/PSI tables (Figure 6.6d).  Step 5: Create sessions, as shown in Figure 6.6e.  Step 6: Define the session’s parameters, including title, PID, guaranteed bitrate, priority, estimated packet size, etc (Figure 6.6f).

115 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

 Step 7: As each session may include a number of IP streams, define the IPv4 source address and IPv4 destination address for each stream (Figure 6.6g).  Step 8: Monitor traffic and signalling as shown in Figure 6.6h.

(a) (b)

(c) (d)

(e) (f)

116 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

(g) (h)

Figure 6.6: The DVB-H Link Layer Portal: (a) IP Address; (b) IPE-Output; (c) DVB-H Physical Parameters; (d) Channels; (e) Sessions; (f) Session Definition; (g) IP Sessions; (h) Traffic and Signalling Monitoring.

6.3.2. User Side

The user side of the link layer consists of a POD-1100 receiver and GOLDENEAGLE monitor and analyzer. UDcast provides software and hardware implementation for the monitor, whereas TeamCast only provides Dibcom hardware (OEM) implementation [157] and the software implementation is open for the developers.

6.3.2.1. WBC Channel Discovery Sequence

At the link layer of MU node, the discovery of the WBC broadcasting channel follows these steps:

 Step 1: Enter the Program Association Table (PAT) on PID 0, look for the programmer number 0, and find the network PID equal to 16;  Step 2: Read the Network Information Table (NIT) on PID 16, look for the linkage_type 0x0B, find the service ID equal to 62555;  Step 3: Re-read PAT on PID 0, look at the programmer number at service ID 62555, find the program PID equal to 32;  Step 4: Read the Program Map Table (PMT) on PID 32, look for PID that has data_broadcast id equal to 62555, find the elementary PID equal to 33;  Step 5: Read the INT on PID 33, show the IP address 192.168.1.4 and service ID 5141, and component tag equal to 1;

117 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

 Step 6: Re-read the PAT on PID 0, look for the program number 5141, find the program map PID equal to 130;  Step 7: Read the PMT on PID 130, look for the program number 5141 and component tag 1, find the elementary PID equal to 61;  Step 8: MPE is on PID 61. Figure 6.7 shows the diagram of this example.

NIT:PID 16 -DVB Global Network Parameters PAT:PID 0 Start (One per DVB Network) -Iinkage_type 0x0b:62555 Prog 0→Network PID 16 here -Cell 1::Modulation Parameters : Prog 62555→PID 32 -Cell2 Modulation Parameters (One per DCO) Prog 5141→PID 130

Prog Y→PID PY INT:PID 33 WBC IP#<192.168.1.4>→ Service ID(Program): 5141 PMT:PID 130 PMT:PID 32 Component Tag:1 : PMT PID PY 1→ PID 61 <0x0B:62555> → CT1 PID S3 CT2→ PID S2 INT→PID 33 IP#→ Service ID(Program):X Component Tag:CT2

Stream 1: IP#→ Stream 3: Stream 2: PID S1 Service ID(Program):Y PID S3 PID S2 Session Component Tag:CT1 Session IP# Session IP# IP#<225.1.1.1>

Figure 6.7: The WBC Channel Discovery Sequence Example

6.3.2.2. GOLDENEAGLE Monitor and Analyzer

The GOLDENEAGLE DVB-H monitor and analyzer equipment is a wireless monitoring system which offers a number of functions such as audio/video streaming and recording, scanning, real-time signal monitoring, analyzing, etc (Figure 6.8).

6.3.2.3. TeamCast POD-1100 Receiver

The TeamCast POD 1100 receiver’s hardware is implemented by the DiBcom's DIB7000 chipset – the world’s first DVB-H chipset [158]. The software implementation of the POD-1100 includes the link layer and physical layer. In this chapter, the link layer of the ‘WBC over DVB-H’ receiver part is designed and implemented by means of the Microsoft Foundation Classes (MFC) [159] application framework.

118 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

Figure 6.8: GOLDENEAGLE DVB-H MPEG Real-time Monitor and Analyzer Figure 6.9 shows the link-layer UML diagrams of the POD-1100 receiver (the program entrance is WBC_over_DVBH_link_layer_App). The application includes one dialog WBC_over_DVBH_link_layer and a number of C++ Structs [160]. The main functions of the dialog are explained below:  WBC_over_DVBH_link_layer - used to initialize the dialog components with default values;  DoDataExchange - used to exchange and validate dialog data through the Dialog Data Exchange (DDX) and Dialog Data Validation (DDV) routines. DDX/DDV is designed to initialize the controls in a dialog box and gather/validate data input from/to the user;  BEGIN_MESSAGE_MAP - message handlers used to handle intermediate classes;  OnInitDialog – used to initialize the dialog between the WBC_over_DVBH_link_layer and DVB-H driver. The main Structs used in the application include:

 wbcDibInterfContext - a global context that enables the application to connect with the Dibcom-7000 driver;  wbcAddPidInfo - a communication structure for adding a PID (MPE data, SI/PSI or TS filter) to the application;

119 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation

 wbcDelPidInfo - a communication structure for stopping a PID (MPE data, SI/PSI or RAW TS filter) from the application;  wbcPidDataMonitoring – used to get a PID's total data in bytes;  wbcPIDTargets - a targets filter type of wbcAddPidInfo /wbcDelPidInfo;  wbcGetSection - used to get the section information of a PID;  wbcDVBHMonitoring - used to get the DVB-H monitor data from the Dibcom-7000 hardware.

WBC_over_DVBH_link_layer_App

<>-WBC_over_DVBH_link_layer_App() +InitInstance(): BOOL <>-DECLARE_MESSAGE_MAP()

WBC_over_DVBH_link_layer <> wbcPIDTargets <> #m_hIcon: HICON wbcDibInterfContext +m_comRow s: CComboBox +T ARGET _MPE +m_dPID: UINT +T ARGET _S IPS I +pDevice: void +m_bStreamWithFEC: BOOL +TARGET_SIPSI_NO_CRC +m_lPIDS : CListBox +TARGET_RAW_TS +tsChannelNumber: UCHAR +isMonitor: BOOL +isHMonitor: BOOL +m_pContext: sDibInterfContext <> <> +m_cmbCurPid: CComboBox wbcGetSection wbcAddPidInfo +m_dUncor_packets: double +m_dT otalT ables: ULONG +flow : _s Flow +pid: US HORT +m_dErrorTables: ULONG +pid: US HORT +PIDTarget: ePIDTarget +m_dUncorrectedTables: ULONG +s ection: UCHAR +ts Cha nnelNum be r : UC HA R +m_sErrorTables_p: CString +S pecific: _s S pecific +m_sUncorrectedTables_p: CString +m_dTotalTables_last: ULONG <> +m_dErrorTables_last: ULONG wbcDVBHMonitoring +m_dUncorrectedTables_last: ULONG +pid: US HORT <> +m_sErrorTable_last_p: CString +ulT otalT ables : ULONG wbcDelPidInfo +m_sUncrrectedTables_last_p: CString +m_progErrorTables: CProgressCtrl +ulErrorTablesBeforeFec: ULONG +pid: US HORT +m_progUncorrectedTables: CProgressCtrl +ulErrorTablesAfterFec: ULONG +tsChannelNumber: UCHAR +m_dPadding: ULONG +ulT otalPacketDa ta: ULONG +m_progPadding: CProgressCtrl +ulErrorPacketDataBeforeFec: ULONG +m_dPuncturing: ULONG +ulErrorPacketDataAfterFec: ULONG +m_progPuncturing: CProgressCtrl +MPEPadding: UCHAR +m_qLastMonitors: std::vector +MPEPuncturing: UCHAR +m_dT otalIPData: ULONG +uiTableSize: USHORT <> +us De lta T _S tr ea m : US HORT <>-WBC_over_DVBH_link_layer(pParent: CWnd) wbcPidDataMonitoring +usDeltaT_Detected: USHORT #DoDataExchange(pDX: CDataExchange): void +usBurst_Stream: USHORT +pid: US HORT #OnInitDialog(): BOOL +us Bur s t_De tecte d: US HORT +totalBytes : ULONG #OnSysCommand(nID: UINT, lParam: LPARAM): void +usPowerUpTime: USHORT #OnPaint(): void +Debug_Value_1: ULONG #OnQueryDragIcon(): HCURSOR +Debug_Value_2: ULONG <>-DECLARE_MESSAGE_MAP() +tsChannelId: UCHAR +OnClose(): void +OnBnClickedButtonAddPid(): void +OnBnClickedButtonRemovePid(): void +OnLbnSelchangeListPids(): void +OnCbnSelchangeComboCurPid(): void

Figure 6.9: The Link Layer UML Diagrams of the POD-1100 Receiver

Figure 6.10 shows the UI of the link-layer monitoring application. In this example, after selecting the PID value of 61 and the number of MPE-FEC rows of 1024, the user clicks on the ‘Add PID’ button. Then, in the ‘WBC over DVB-H’ monitoring area, the

120 Chapter 6. ‘WBC over DVB-H’ Link Layer Design and Implementation total MPE-FEC tables, total IP data (in bytes), padding and puncturing information are dynamically shown.

WBC over DVB-H Receiver

WBC Physical Layer WBC Link Layer WBC Service Layer

2009 TELECOMMUNICATIONS RESEARCH CENTRE, UNIVERSITY OF LIMERICK

WBC over DVB-H Link Settings

DATA PID (decimal) 61 61(1024rows) Add PID Rows 1024

Stream with FEC Remove PID

WBC over DVB-H Link Layer Monitoring

61

Table Total MPE-FEC Tables Padding RX Error Tables Uncorrected Tables Service Layer-ADP Puncturing

Total IP Data

Figure 6.10: The ‘WBC over DVB-H’ Link-Layer Monitoring Application UI

6.4. Conclusion

This chapter has described the design and implementation of the ‘WBC over DVB-H’ link layer. For the performance evaluation discussed in Chapter 8, a software simulation testbed for encapsulation, encoding, decapsulation and decoding has been proposed. Based on the previous studies, a Smart Section Erasure (SSE) and Smart Transport Stream Erasure (STSE) have been developed to achieve reliable reception in the mobile terminal. To develop a fully operational WBC prototype with a real-time hardware testbed, an UDCast encapsulator and encoder, TeamCast POD-1100 receiver, and UDCast GOLDENEAGLE monitor and analyser have been selected to build the ‘WBC over DVB-H’ link layer. In addition, a Visual C++ based POD-1100 link-layer receiver application has been developed.

121 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

CHAPTER 7. ‘WBC OVER DVB-H’ PHYSICAL LAYER DESIGN AND IMPLEMENTATION

7.1. Introduction

This chapter describes the ‘WBC over DVB-H’ physical layer design and implementation. Similarly to Chapter 6, for the purpose of performance evaluation, the ‘WBC over DVB-H’ physical layer has been implemented by means of a software simulation testbed. For real-time demonstration purposes, the physical layer has been implemented by means of a hardware testbed.

7.2. Software Design and Implementation

Based on the DVB-T ETSI-EN-300-744 standard [70], the ‘WBC over DVB-H’ physical-layer simulator has been designed and implemented with all necessary features by means of Matlab [161, 162] as illustrated in Figure 7.1 [11, 15].

Rate 1/2 Convolutional DVB-H DVB-H (204 ,188 ) Shortened Punctured OFDM Random Interleaver Inner 16 -QAM RS Encoder Convolutional Transmitter Integer I=12 Interleaver Mapper Code

Integer to Bit Rayleigh Converter Fading

BER Tx Error Rate ------Rx Calculation Total Errors Total Bits AWGN Integer to Bit Converter TS PER Convolutional DVB-H DVB-H Channel (204 ,188 ) Shortened Viterbi OFDM Deinterleaver Inner 16 -QAM Estimator RS Decoder Decoder Receiver I=12 Deinterleaver Demapper &Equalizer

Figure 7.1: The 'WBC over DVB-H' Matlab Physical Layer Testbed Based on the number of carriers in one OFDM symbol, a DVB-H system may operate in three transmission modes, i.e., 2K mode, 4K mode, and 8K mode. Table 7.1 lists the parameters of those models.

Similarly to other communication systems, the ‘WBC over DVB-H’ simulator consists of three elements: a transmitter, a channel, and a receiver.

122 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

Table 7.1: The Parameters of DVB-H Transmission Modes

OFDM Parameters 2K 4K 8K

Number of carriers (Fast Fourier 2048 4096 8192

Transform (FFT) Size) ( NFFT ) 1705 3409 6817 Number of modulated carriers ( N K )

1512 3024 6048 Number of useful carriers ( Nused )

Duration of an OFDM symbol (in μs) 224 448 896

(TU ) Carriers spacing (in kHz) 4464 2232 1116

Maximum distance coverage (in km) 17 33 67

Number of OFDM symbols per OFDM 68 68 68

frame ( NOFDM )

7.2.1. Transmitter

The transmitter part of the simulator is used to generate the signal to be sent in the channel. Before sending it, the source data has to be encoded, interleaved, and modulated.

7.2.1.1. Source

As described in the DVB standard [70], the data being transmitted should be randomized. To simplify the design, a binary source data file is first generated. The source data file contains a number of blocks, each of which includes Nts K-symbol message words (TS packet) carried by an ODFM frame. The Nts is equal to:

NSRTts  U (1 cpN %) OFDM / BWK / (7.1) where SR is the WBC data broadcasting source rate, cp% is the cyclical prefix ratio, BW is the DVB-H system bandwidth, and K is the TS packet length.

Once the Nts K-symbol message words are generated, the number of bytes to send to the RS encoder is equal to:

SNKpacket ts  . (7.2)

123 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

7.2.1.2. Encoders and Interleavers

In the outer RS encoder module, for every Nts K-symbol message word, a Galois field array is created and then encoded using an (N,K) RS encoder. The output is Nts N-symbol codewords (N = 204).

In the outer interleaver module, the above codewords are first reshaped to a 1 by

NNts  array. The array is then permuted with shift registers Irow  12 and register length-step N  204 /12 17 . slope In the convolutional coder module, the above output is encoded by a binary convolutional encoder with constraint length of 7 (poly2trellis(7,[177 133]). The output is punctured by corresponding convolutional code rate CR (1/2, 2/3, 3/4, 5/6, or 7/8).

In the inner interleaving module, the above output is first padded to NCRN/  bits. Then an inner interleaving algorithm is executed as follows: used OFDM

 Demultiplexering: for every NCRNused /  OFDM bits, the stream is demultiplexed into L sub-streams ( L is the modulation level, e.g., 2 - for m m Quadrature Phase-Shift Keying (QPSK), 4 - for 16 Quadrature Amplitude Modulation (QAM), and 6 - for 64 QAM, respectively). It includes a hierarchical algorithm and a non-hierarchical algorithm [70];  Bit interleaving: each sub-stream undergoes different bit interleaving algorithm. There are six bit interleaving algorithms [70]. In each of them, the bit interleaver works with a 126-bit block and the process is repeated 12, 24,

48 times (Nused /126) for 2K, 4K, 8K mode, respectively;  Symbol interleaving: the symbol interleaving algorithm maps bit words into

the Nused active carriers. The input bit interleaving vector is denoted as

Yyyyy''''' ( , , ... ) . The output interleaver vector Yyyyy (,,... ) 012Nused  1 01 2Nused  1 is defined in [70] as:

' ' (7.3) yyH()qq for even symbol; yyqHq () for odd symbol, where H(q) is the DVB-T permutation function.

124 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

7.2.1.3. Modulator

The output from the symbol interleaver section is modulated using either QPSK, 16-QAM or 64-QAM constellations. It includes symbol mapping and power normalization modules. After merging the pilot and NULL sub-carrier, the output is sent to an Inverse Discrete Fourier Transform (IDFT) algorithm to transform the signal from the frequency domain into the time domain. At the end, a cyclical prefix (CP) is added to the output and an OFDM frame is generated ready for broadcasting over the channel.

7.2.2. Channel

The Matlab communication blocksets Additive White Gaussian Noise (AWGN) and Rayleigh channels were selected as channel modules, which can be implemented with the Matlab awgn and rayleighchan functions as follows:

 OFDM_Out =awgn(OFDM_in,SNR): adds white Gaussian noise to the input OFDM_in. In the DVB-T physical layer simulation testbed, the OFDM_in is a complex array, so that the AWGN function adds a complex noise;  OFDM_Out = filter(ray_ch, OFDM_out): filters the OFDM_Out with a Rayleigh filter. The ray_ch is a multiple path fading channel object. It is generated by the Rayleigh channel function rayleighchan(1/SymbolRate, Doppler, Delay_vec, Power_vec), where Doppler is the maximum Doppler shift in Hz, Delay_vec is the path delays vector in seconds, Power_vec is the average path gains vector in dB, and SymbolRate is the sample time of the input signal in seconds. The values of Delay_vec and Power_vec used in this testbed are listed in Table 7.2. The testbed follows the COST 207 TU6 model in typical urban reception conditions [163], which is commonly used for wireless broadcasting simulations. The SymbolRate in DVB-H can be obtained as:

BW N (7.3) symbolRate  FFT . NK

125 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

Table 7.2: Fading Channel Parameters

Path Number Delay(μs) Power (dB) 1 0.0 -3 2 0.2 0 3 0.5 -2 4 1.6 -6 5 2.3 -8 6 5.0 -10

7.2.3. Receiver

The receiver part of the simulator is used to extract the source data from the received signal through the channel. It runs in reverse mode to that of the transmitter, and includes two blocks - a demodulation block and a de-interleaving and decoding block.

The demodulation block includes a CP removing module, an OFDM demodulation module, a remove NULL sub-carrier module, a sub-carrier demapping module, and a channel estimation and decision module.

The de-interleaving and decoding block includes an inner de-interleaving module, a frame generating module, an convolutional decoder module, an outer de-interleaver module, and an outer RS decoder module. The ouput is Nts TS packets.

7.3. Hardware Design and Implementation

To develop of a fully operational WBC prototype with a real-time hardware testbed of the ‘WBC over DVB-H’ physical layer, an Audemat EMAA [164] DVB-H transmitter is used on the WBC-SP side (Figure 7.2), whereas a POD-1100 receiver and UDCast GOLDENEAGLE monitor and analyzer are used on the user side.

Figure 7.2: The Audemat DVB-H Transmitter (EMAA)

126 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

7.3.1. WBC-SP Side

Similarly to the link layer, the web application of the EMAA was integrated into the WBC-SP portal application. The WBC-SP can remotely control the ‘WBC over DVB-H’ physical-layer parameters. The main UIs are shown in Figure 7.3.

(a)

(b)

Figure 7.3: The DVB-H Physical-Layer Portal Application: (a) Transmitter Configuration; (b) Modulator Parameters.

127 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

7.3.2. User Side

7.3.2.1. GOLDENEAGLE Monitor and Analyzer

In addition to monitoring and analyzing the link layer, the GOLDENEAGLE DVB-H equipment can also monitor and analyse the physical layer. The RF signal real-time monitor (GUI) is shown in Figure 7.4.

Figure 7.4: GOLDENEAGLE DVB-H RF Signal Real-time Monitor

7.3.2.2. TeamCast POD-1100 Receiver

Figure 7.5 shows the physical layer UML diagrams of the POD-1100 receiver (the program entrance is WBC_over_DVBH_physical_layer_App). The application includes one dialog WBC_over_DVBH_physical_layer and a number of C++ structs. Similar to the link layer, the main functions include:

 WBC_over_DVBH_physical_layer(pParent:CWnd);  DoDataExchange(pDX: CDataExchange);  BEGIN_MESSAGE_MAP(WBC_over_DVBH_physical_layer, CDialog);  OnInitDialog(). The main Structs used in the application are:

 wbcDibInterfContext - a global context of the Dibcom-7000 driver;

128 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

 wbcTuneMonit - a channel description structure defined by wbcTuneChan and wbcTotalDemodMonit;  wbcTuneChan - a channel parameter's structure for adding a RF and bandwidth to the application;  wbcTotalDemodMonit - a signal monitoring descriptor structure for updating the signal monitoring from the driver;  wbcDemodMonit - a signal information structure.

WBC_over_DVBH_Physical_layer_App

<>-WBC_over_DVBH_Physical_layer_App() +InitInstance(): BOOL <> <>-DECLARE_MESSAGE_MAP() wbcDibInterfContext +pDevice: void WBC_over_DVBH_Physical_layer <> wbcTuneMonit #m_hIcon: HICON +m_rf_freq: UINT +ChannelDescriptor: sTuneChan +m_cmbBandWidth: CComboBox +ChannelMonit: sTotalDemodMonit <> +m_sRF_Frequency: CString wbcDemodMonit +m_sFFT_SIZE: CString +agc_pow er : UINT +m_sGUARD_INTERVAL: CString +agc_global: UINT +m_sINNER_CODE_RATE: CString <> +rf_total_gain: UINT +m_sCONSTELLATION: CString wbcTuneChan +wgn_fp: UINT +m _bS tr e a mW ithF EC : BOOL +scan_sta tus: UCHAR +sig_fp: UINT +isMonitor: BOOL +RF_kHz: ULONG +fec_ber_rs: UINT +tsChannelNumber: UCHAR +Bw : S HORT +fec_mpfa il_cnt: US HORT +m_pContext: sDibInterfContext +nfft: SHORT +agc_lock: UCHAR +m_bHighSpeed: BOOL +guar d: S HORT +cor m_lock: UCHAR +m_bPowerSaving: BOOL +invspec: S HORT +coff_lock: UCHAR +m _dA GC _RF : double +nqam: S HORT +coff_cpil_lock: UCHAR +m _dA GC _BB: double +intlv_native: SHORT +lmod4_lock: UCHAR +m _dA GC _Globa l: double +vit_hr ch: S HORT +pha3_lock: UCHAR +m_dC_N_l: double +vit_select_hp: S HORT +equal_lock: UCHAR +m _dBER: double +vit_alpha: SHORT +vit_lock: UCHAR +m_bMPEG_lock: BOOL +vit_code_r ate_hp: S HORT +fec_lock_fr m: UCHAR +m _bMPEG_DAT A _lock: BOOL +vit_code_r ate_lp: S HORT +fec_lock_mpeg: UCHAR +m_Monitor_Buffer: char +tsChannelNumber: UCHAR +tps_dec_lock: UCHAR <>-WBC_over_DVBH_Physical_layer(pParent: CWnd) +TPSInfo: sTPSInfo +tps_sync_lock: UCHAR #DoDataExchange(pDX: CDataExchange): void +tps_da ta_lock: UCHAR #OnInitDialog(): BOOL +tps_bch_uncor: UCHAR #OnSysCommand(nID: UINT, lParam: LPARAM): void +tps_cellid_lock: UCHAR <> #OnPaint(): void +dvsy_lock: UCHAR wbcTotalDemodMonit #OnQueryDragIcon(): HCURSOR +V_agc_1: USHORT <>-DECLARE_MESSAGE_MAP() +monit_sta tus: UCHAR +V_agc_2: USHORT +OnDeltaposSpinRfFreq(pNMHDR: NMHDR, pResult: LRESULT): void +tsChannelNumber : UCHAR +agc_w bd: US HORT +OnBnClickedButtonTuneChannel(): void +monitoring_version: UINT +agc_split_offset: USHORT +OnClose(): void +no_of_demods: UCHAR +lna_status: UCHAR +OnBnClickedButtonMonitor(): void +demod_monit: sDemodMonit +signal_quality: UCHAR +OnTimer(nIDEvent: UINT): void +signal_quality_fast: UCHAR +OnBnClickedCheckHighSpeed(): void

Figure 7.5: The Physical Layer UML Diagrams of POD-1100 Receiver

Figure 7.6 shows the UI of the physical-layer monitoring application. In this example, after selecting a RF of 666 MHz and a bandwidth of 8 MHz, the user clicks on the ‘Tune Channel’ button to monitor the ‘WBC over DVB-H’ physical-layer parameters in the monitoring area. If the user clicks on the ‘Monitor’ button, the signal information is shown dynamically.

129 Chapter 7. ‘WBC over DVB-H’ Physical Layer Design and Implementation

WBC over DVB-H Receiver

WBC Physical Layer WBC Link Layer WBC Service Layer

2009 TELECOMMUNICATIONS RESEARCH CENTRE, UNIVERSITY OF LIMERICK

WBC over DVB-H Physical Layer Parameters

RF(MHz) RF(MHz) 666 FFT Size Bandwidth(MHz) 8 Guard Interval Inner Code Tune Channel Constellation

WBC over DVB-H Physical Layer Monitoring AGC_RF AGC_BB High Speed Monitor AGC_Global Power Saving Service Layer-ADP C / (N+1) MPEG BER MPEG DATA Uncor Packets

Figure 7.6: The ‘WBC over DVB-H’ Physical-Layer Monitoring Application’s UI

7.4. Conclusion

This chapter has provided details on the design and implementation of ‘WBC over DVB-H’ physical layer. A physical-layer software simulation testbed has been developed with Matlab for system performance evaluation as described in the next Chapter. To develop a fully operational ‘WBC over DVB-H’ system prototype with a real-time hardware testbed, an Audemat EMAA transmitter, a TeamCast POD-1100 receiver, and an UDCast GOLDENEAGLE monitor and analzyer have been selected. In addition, a C++ based POD-1100 physical-layer receiver application has been developed.

130 Chapter 8. WBC System’s Performance Evaluation and Results

CHAPTER 8. ‘WBC OVER DVB-H’ PERFORMANCE EVALUATION AND RESULTS

8.1. Introduction

In this chapter, a 2SRL model is first introduced for speeding up the simulation of the TS packets output of the ‘WBC over DVB-H’ system. Then the performance evaluation results are presented along with the three layers of the ‘WBC over DVB-H’ system. At the physical layer, the byte error rate and the Transport Stream Packet Error Rate (TSPER) are obtained from the Matlab testbed described in Chapter 7. The TS packets stream is obtained by the 2SRL model. At the link layer, with the TS packets output behaviour, the IP Packet Error Rate (IPER) and WBC segment Error Rate (SER) under AWGN and Rayleigh fading channel conditions are obtained both analytically and by simulation. The overhead efficiency and optimal IP packet length are also studied. Moreover, the performance of the novel SSE and STSE schemes proposed in Chapter 6 is compared to that of the existing similar schemes. At the service layer, the WBC segment access time and tuning time (as discussed in Chapter 4) are studied. With this layered model, the evaluation results will show that the disigned ‘WBC over DVB-H’ system prototype can speed up the service discovery, improve the mobile reception performance and the robustness in mobile environments.

8.2. 2SRL Model for Physical Layer Simulation

From the viewpoint of the link layer of the ‘WBC over DVB-H’ system, the 204-byte TS packet is an atomic element. The software simulation testbed discussed in Chapter 7 is only suitable for simulating the TSPER in the offline mode, since the TS packets generation on the receiver side is too slow. For example, with the designed software testbed, for a 1Mbyte dataset, using an Intel double Xeon X5420 (2.5 GHz×8 CPU, 8GB RAM) Linux server, almost 26 hours are required to simulate the good/bad TS output from 10 dB to 17 dB Signal-to-Noise Ratio (SNR) for a given Doppler

131 Chapter 8. WBC System’s Performance Evaluation and Results frequency. Furthermore, the 1Mbyte dataset is insufficient for the link-layer performance analysis. Thus an accurate, efficient and flexible physical-layer simulation model needs to be designed and developed to represent the physical layer outputting behaviours. i.e., good/bad TS packet output behaviour in ‘WBC over DVB-H’ system.

As explained in Chapter 3.5.2, the 2SRL model over a Rayleigh fading channel (whereby the received signal envelop has a chi-square central distribution in a slow fading channel) is studied here for use in TS packet level simulator of the ‘WBC over DVB-H’ physical layer.

8.2.1. Two-State Run Length Model (2SRL)

The 2SRL model was developed from the Two-State Markov model (2SMM). Both models are shown in Figure 8.1. The difference is that the 2SMM is concerned with the state transition probability, whereas the 2SRL is concerned with the run-length probability.

f g ()m fb ()m 1-bb 1-g G B G B g

(a) (b)

Figure 8.1: (a) The 2SMM; (b) The 2SRL. There are two distribution functions in 2SRL used for statistical analysis: a good run length probability distribution f g ()m and a bad run length probability distribution

fb ()m . With these two distribution functions, the TS packets good/bad outputting can be easily generated. Figure 8.2 shows both distribution functions s for different average values of SNR, viz 12dB and 15dB of SNR. The channel is assumed to be Rayleigh with AWGN. The results demonstrate that by using the basic Curve Fitting Techniques (CFT), each distribution functions (in logarithmic scale) can be approximated as a linear function (the dash line in Figure 8.2).

In [133], the authors propose a Four-State Markov model to be used as an equivalent to 2SRL, where a state change can occur between a good long run state and a bad long run state, and f g ()m and fb (m ) in 802.11a (12Mbps) can be approximated by a mix of

132 Chapter 8. WBC System’s Performance Evaluation and Results two geometric distributions. This method is not suitable for the ‘WBC over DVB-H’ fading channels (where the symbol period is less than the coherence time [165]). Figure

8.2 demonstrates that the f g ()m and fb (m ) can be approximated by a single geometric distribution function. Thus in ‘WBC over DVB-H’, 2SMM is used for approximating the 2SRL instead of Four-State Markov model.

0 0 10 10

-1 -1 10 10 PDF PDF

(b) SNR=15dB (a) SNR=12dB Bad runs Bad runs Good runs -2 Good runs -2 10 10 0 20 40 60 80 100 0 20 40 60 80 100 Run length (number of TS packets) Run length (number of TS packets) (a) (b) Figure 8.2: The Observed Probability Distributions of Good Runs and Bad Runs in DVB-H: (a) SNR=12 dB; (b) SNR=15 dB. [PHY Parameters: 16-QAM, CR= 1/2, 4K OFDM, GI=1/4]. The 2SMM model transition matrix is defined in [71, 166, 167] as: 1 bb (8.1) , gg1 where b and g are the transition probabilities. The eigenvalues of  could be obtained as: (8.2) 1 0 , where 12 1, 1 gb ; 0 2 and

1 b 1 (8.3) H   and HH  . 1 g

The steady-state probability is: gb (8.4) steady_ state g,,. b  bgbg

With parameters b and g, the average number of good states X g and bad states Xb can be obtained as:

133 Chapter 8. WBC System’s Performance Evaluation and Results

 i 1 (8.5) Xibbg (1)(1) ; i0 b  i 1 (8.6) Xiggb (1)(1)  . i0 g Then the run length distributions of 2RSL can be calculated by using the 2SMM parameters as follows:

m imi (8.7) 1()1()pG g pB b fmg () ee; i0 m (8.8) fm() pGg()imi pBb () , b ee i0 where pe (G ) and pe (B ) are the error probabilities in state G and B, respectively.

8.2.2. 2SRL Parameters in 'WBC over DVB-H' Chi-Square Central (Rayleigh) Fading Channel

The Probability Density Function (PDF) of a central chi-square distribution is defined in [134] as: 1 r 2 (8.9) pr() rn1 exp , R n2 2 n n 2 2 2   2 where r denotes the received instantaneous signal amplitude in the ‘WBC over DVB-H’ physical layer ( r  0 );  2 is the variance of the Gaussian scattering component [134]; n denotes the number of degrees of freedom ( n mod 2 0 to simplify the analysis [8]), and (.) denotes the Gamma function, which has closed-form values

 at the half-integers for natural numbers n, ()nun1 exp()  udu and 0 ()nnn ( 1)!.

To get instantaneous SNR per symbol ,  ’s PDF in [168, 169] is given as:

2 2 (8.10) rTS rTS  TS prdr() f () d ,   2 , ddr  2 , and   2 , 2 n  n  n 2 where TS is the symbol time,  n is the Power Spectral Density (PSD) of the noise N which is equal to 0 , and  is the average SNR per symbol. 2

Then the PDF of SNR per symbol can be obtained as:

134 Chapter 8. WBC System’s Performance Evaluation and Results

2 1 n1 r n2 r exp 2 n n 2 2 2   dr 2 fpr()  ()  = d rTS 2  n

n 1  2  exp  . n  (8.11) n   2 2 The Cumulative Distribution Function (CDF) of (8.11) is:

2 rr 1 n1 x FrRR() pxdx () x exp  dx=   n2 2 n n 2 2 2   2

2 1 r x xn1 expdx . n2  2 n n 2 (8.12) 2 2   2 x2 xdx By letting u  , du  , Fr( ) equals to: 2 2  2 R

2 1 r n1  2 Fr()2 2 u 2 2 exp( u ) du= R n2 0   2 n n u2 2 2   2

nr2 , 2 22  . (8.13) n  2 2  2 n Since r  , FR ( ) is equal to: TS

n  , 2  F   , (8.14) R n  2 n 1 k n  n  2 1  where , =1!exp . 2  2! k0 k 

135 Chapter 8. WBC System’s Performance Evaluation and Results

vf Let f  c is the maximum Doppler frequency [132], where v is the MT moving D c speed, f is the carrier frequency, and c is the speed of light. The expected number c of times per unit interval (also known as the level crossing rate) that the received SNR passes downward across level rt can be obtained as in [170]:

 Nr()tt xpxr (, rdx ) , (8.15) 0 where x is the time derivative of r , and pxr(,) is the joint PDF of x and r at

r = rt . The PDF px() is obtained as:

1 x2  px() exp2 . (8.16) 2 2 n 2 22 To calculate  (variance of x ), let YX xi . Then: i1

n  n  xiix  i1 22XX xii x X . Hence: i1 X

n  xxii n  i1  EX E ExExii 0 ; X i1 

2 n xx 2  ii n Ex EX 222 Ei1 Ex i Ex 2  f 2 .  iiD 2   XXi1  

22  22 WithVar() X E ( X ) E () X , we can obtain   2(f D ) . Since px() and pr() are independent [171], Nr ( ) could be obtained as: t

  Nr()tt rprr (, r ) dr  rprpr  ()() t dr   pr ()t rprdr  () = 00  0

22 11rr pr() r exp dr pr () r exp dr. tt0022 2222  

2 2 r rdr 2  By letting u  , du  , ru2 and dr  du , Nr() 2 2  2 r t equals to:

136 Chapter 8. WBC System’s Performance Evaluation and Results

2 1   Nr() pr () r exp u du pr () f = tt2 0 r tD

2 f rrn12 Dt t . n1 exp2 2 2 2 n  (8.17) 2   2 Then

n1 2 2 2 2 f tn D 2 2 2 TS  tn2 N() t  exp2 = n 2 TS  2

n1 2  t 2 fD    t (8.18) exp. n   2 To represent the time-varying behaviour of a chi-square fading WBC channel, the received SNR was quantized with thresholds  t . Then  g , b were obtained as in [130]:

  gYfdF() Y ( ) F Yt ( ); (8.19)  t  t fdF() ( ) F (0). bY0 YtY (8.20) The transition probabilities g and b were approximated by the level crossing rate, average number of TS packets per unit interval (Tp ), and {,} g  b , as explained in [130]: NT() g  tp; (8.21)  b

NT() tp b  , (8.22)  g Finally, the error probabilities in state G and B were obtained as described in [132]:

 f () Pd ()  Re t (8.23) pGe () ;  g  t f () Pd () 0 Re (8.24) pBe () , b where P ( ) is the TS packet error probability for a given value in an AWGN e  

137 Chapter 8. WBC System’s Performance Evaluation and Results

channel. In ‘WBC over DVB-H’, Pe ( ) is defined as:

204 iini PCppenbb() [1 ()] () , (8.25) i196 where p ( ) is the byte error rate for SNR . b   For the rectangular M-QAM modulation scheme used in DVB-H, p can be b obtained as: 8/ M ppbs1(1  er ) , (8.26) where p is the symbol error rate in AWGN channel. ser

The values of parameters Tp and pb were obtained from the ‘WBC over DVB-H’ physical layer simulation testbed described in Chapter 7.

8.2.3. 2SRL Implementation

With the parameters of p (G ) , p ()B , b , , the 2SRL model can be implemented e e g easily using the functional model presented in Figure 8.3.

2SRL Starts

State B Initial Parameters State G Random First State m=0

m=0 m=0

onStart(m) onStart(m) m=m+1 m=m+1

Random A Double Random A Double decimal fraction x decimal fraction x

Yes No No Yes If x<= f b ()m If x<= f g ()m

Output m ‘0’ Output m ‘1’

Append to a Vector

onStop()

Save to File()

2SRL Ends

138 Chapter 8. WBC System’s Performance Evaluation and Results

Figure 8.3: The 2SRL Functional Model 8.3. Physical Layer Evaluation

As 4K mode is a popular to use in DVB-H evaluation [172], the byte error rate and TSPER are obtained using the software testbed shown in Figure 7.1, and the parameters are as shown in Table 8.1.

Table 8.1: DVB-H Physical Layer Matlab Testbed Parameters

Parameters Value Modulation Type 16 QAM Convolutional code rate 1/2 Guard interval 1/4 RF 700MHz Bandwidth 8MHz Number of continual pilot carriers 89 Number of TPS carriers 34 Outer interleaver’s parameters 12x17

8.3.1. AWGN Channel

Figure 8.4 shows the discrete time scatter plot scope in the AWGN channel. When more noise is added, the signal constellation from the DVB-H receiver becomes distorted.

6

3 4 2

2 1

0 0

-1 -2 Quadrature Amplitude Quadrature AmplitudeQuadrature

-2 -4 -3

-6

-3 -2 -1 0 1 2 3 -6 -4 -2 0 2 4 6 In-Phase Amplitude In-Phase Amplitude (a) (b)

Figure 8.4: The Discrete Time Scatter Plot Scope: (a) SNR=16 dB, (b) SNR=5 dB.

139 Chapter 8. WBC System’s Performance Evaluation and Results

The byte error rate and TSPER as functions of the SNR are shown in Figure 8.5. When the SNR is smaller than 5 dB, the TSPER is equal to 1; when the SNR is bigger than 6.4 dB, the TSPER is almost equal to 0.

0 10

-1 10

-2 10

-3 10 Error Ratio

-4 10

-5 10 Byte Error Rate TSPER

-6 10 4 4.5 5 5.5 6 6.5 7 The SNR(dB)

Figure 8.5: The Byte Error Rate and TSPER in the ‘WBC over DVB-H’ AWGN Channel To simulate the TS packet outputting behaviour in the AWGN channel, the following

2SRL parameters values used are b=g=0.5 and pe (G ) =()pe B =TSPER. With those parameters, the 2RSL model becomes a memoryless channel.

8.3.2. Rayleigh Fading Channel

With the defined physical-layer parameters, the average number of packets per unit interval ( Tp ) can be calculated as follows: tn (1 cp %) (8.27) T  ofdm ofdm , p nts where t is the transmission time of one OFDM symbol, n is the OFDM frame ofdm ofdm size, n is the number of TS packets in one OFDM frame, and cp% is the cyclical ts prefix ratio.

Table 8.2 shows the parameters of 2SRL with f  10 and  =5. The 2SRL state is D t slowly changing if bg1 . When  increases, b becomes smaller and g becomes bigger.

140 Chapter 8. WBC System’s Performance Evaluation and Results

Table 8.2: 2SRL Parameters for fD =10 and  t =5

g b pB() TSPER   g b e 11 0.2435 0.7565 0.0094 0.0292 0.4924 0.7511 12 0.3679 0.6321 0.0143 0.0245 0.3830 0.5885 13 0.6058 0.3942 0.0267 0.0174 0.2162 0.1739 14 0.7013 0.2987 0.0343 0.0146 0.1586 0.0600 15 0.7994 0.2006 0.0463 0.0116 0.1034 0.0098 16 0.8683 0.1317 0.0608 0.0092 0.0666 0.0012

Figure 8.6 shows the analytical and simulation results for the TSPER in the ‘WBC over

DVB-H’ physical layer with f D = {10Hz, 40Hz, 80Hz}. The results prove that the TSPER value produced by the 2SRL model are very close to the simulation values.

0 10

-1 10

Simulation, f =80Hz -2 D

TS Packet Error Rate [TSPER] Rate Error Packet TS 10 Simulation, f =40Hz D Simulation, f =10Hz D Analysis, f =80Hz D Analysis, f =40Hz D Analysis, f =10Hz D

11 11.5 12 12.5 13 13.5 14 14.5 15 15.5 16 SNR [dB]

Figure 8.6: The 'WBC over DVB-H' Physical Layer's TSPER

It is desirable that the TSPER is not dramatically changed by the parameter  t (thresholds for SNR observations). Table 8.3 shows the 2SRL parameters with

fD 10 and  =16. As seen from the table, the channel parameters are sensitive to the  t when comparing with the TSPER.

141 Chapter 8. WBC System’s Performance Evaluation and Results

Table 8.3: 2SRL Parameters for fD =10 and  =16

g b pB() TSPER  t  g b e 1 0.9453 0.0547 0.1006 0.0058 0.0666 0.0005 2 0.9317 0.0683 0.0890 0.0065 0.0666 0.0006 3 0.9147 0.0853 0.0786 0.0073 0.0666 0.0007 4 0.8939 0.1061 0.0692 0.0082 0.0666 0.0009 5 0.8683 0.1317 0.0608 0.0092 0.0666 0.0012 6 0.8371 0.1629 0.0532 0.0104 0.0666 0.0013

8.4. Link Layer Evaluation

8.4.1. IP Packet Error Rate (IPER) and Segment Error Rate (SER)

8.4.1.1. Theoretical Analysis

IPER and SER are important criteria to measure the decoding performance of the ‘WBC over DVB-H’ link layer. In this section, the theoretical analysis of IPER and SER is studied by using an one-state loss model, i.e., the physical-layer bit stream is modelled as an output of a Binary Symmetric Channel (BSC) with bit error probability p.

Table 8.4 lists the notations to be used in this section.

Table 8.4: Theoretical Analysis Parameters

parameters Descriptions n Number of encoding symbols per WBC segment. k Number of source symbols per WBC segment. w Total number of WBC segments per MPE-FEC frame. d Redundancy length of MPE-FEC frame. p Bit error probability in BSC.

pb Byte error probability in BSC.

pc MPE column error probability in BSC.

pt TS packet error probability in BSC.

N Number of rows of MPE-FEC frame. M Number of columns of MPE-FEC frame being filled.

To simplify analysis similarly to [55], the size of the IP packet/column is set to N =

535 (i.e., close enough to the standard value N = 512), and each column installs 3 TS

142 Chapter 8. WBC System’s Performance Evaluation and Results packets. The payload size of these TS packet is, 171, 184, and 180 bytes, respectively. The first TS packet includes 12B MPE or FEC header, and 1B section start indicator. The last TS packet includes 4B CRC-32 code.

8.4.1.1.1. Smart Section Erasure (SSE)

In SSE, with the testbed-measured bit error rate p , the probability of pc is:

pp1-(1 )N , where pp1-(1- )8 . (8.28) cb b As w WBC segments are installed in one MPE-FEC frame, then:

M  wnd . (8.29) With the SE decoding scheme, to reconstruct the originally sent MPE-FEC frame, at least wn MPE packets must be received successfully out of M MPE (IP) packets. Then the MPE-FEC Error Rate (MFER) can be obtained as:

jM (8.30) MFER1(1) Ciiji  p p  . SE j c c iwn The IPER after SE decoding can be obtained as:

1 (8.31) M IPERSE 1-(1 MFER ) , and corresponding SER can be obtained as:

SER1(1  IPER )k . (8.32) SE SE After running the smart cross-layer decoding algorithm (ADP erasure mode) in the link layer, the SER can be obtained as:

jn (8.33) SER1(1) Ciiji  IPER IPER  . SSE j SE SE ik The IPER after the cross-layer decoding algorithm in the link layer can be obtained as:

1 (8.34) n IPERSSE1-(1 SER SSE ) .

8.4.1.1.2. Smart Transport Stream Erasure (STSE)

In STSE, considering each TS packet contains 188 byte (header and payload), with bit error rate p , the probability of pt is:

pp1-(1 )188 . (8.35) tb

143 Chapter 8. WBC System’s Performance Evaluation and Results

With the TSE decoding scheme, to rebuild the MPE-FEC frame, at least wn TS packets must be received successfully in the first 171 rows, next 184 rows, and final 180 rows, respectively, Then the MFER can be obtained as:

3  jM  (8.36) MFER 1(1)Ciiji  p p  . TSE  j t t  iwn  The TS Packet Error Rate (TSPER) after TSE decoding can be obtained as:

1 (8.37)  jM  M TSPER 1-Ciiji (1 p ) p  . TSE  j t t  iwn  The IPER can be obtained as:

IPER1(1  TSPER )3 , (8.38) SE SE and corresponding SER can be obtained as:

SER1(1  TSPER )3k . (8.39) TSE TSE After running the smart cross-layer decoding algorithm (ADP erasure mode) in the link layer, the SER ban be obtained as:

3 jn (8.40) SER1(1) Ciiji  TSPER TSPER  . TSE j TSE TSE ik The TSPER after the cross-layer decoding algorithm in the link layer can be obtained as:

1 (8.41) jn n TSPER 1-Ciiji (1 TSPER ) TSPER  . STSE j TSE TSE ik The IPER can be obtained as:

IPER 1(1 TSPER )3 . (8.42) STSE STSE

8.4.1.1.3. Comparison of Decoding Methods of the ‘WBC over DVB-H’ Link Layer

The analytical results for IPER and SER as functions of the byte error rate pb are shown in Figure 8.7 (n=10, k = 8). Based on results, the four studied decoding algorithms can be ranked as follows: STSE TSE SSE SE . The analytical results show that the CRC-based decoding algorithms (i.e., SE, SSE) are not better than the TS based algorithms (i.e., TSE, STSE) because the TS packet is

144 Chapter 8. WBC System’s Performance Evaluation and Results shorter than the MPE/FEC section and thus more efficient for decoding. The cross-layer smart decoding algorithms (SSE, STSE) are better than ordinary decoding algorithms (SE, TSE) because the number of erasure columns can be fixed by the ADP PED scheme.

0 0 10 10 SE SE SSE SSE -1 -1 TSE 10 TSE 10 STSE STSE

-2 -2 10 10 SER IPER

-3 -3 10 10

-4 -4 10 10 -4 -3 -2 -4 -3 -2 10 10 10 10 10 10 Byte Error Rate (p) Byte Error Rate (p ) b b (a) (b)

Figure 8.7: The Comparison of the Link Layer Decoding Schemes Based on (a) IPER and (b) SER Analytical Results

8.4.1.2. AWGN Channel Simulation

The simulation results for IPER and SER versus SNR in an AWGN channel are shown in Figure 8.8. The results (which are close to the analytical results) confirm again that newly proposed algorithms outperform the erasure decoding algorithms in the AWGN channel.

0 0 10 10

-1 -1 10 10 SER IPER

-2 -2 10 10

SE SE SSE SSE TSE TSE STSE STSE -3 -3 10 10 5.35 5.4 5.45 5.5 5.55 5.6 5.65 5.7 5.75 5.35 5.4 5.45 5.5 5.55 5.6 5.65 5.7 5.75 SNR [dB] SNR [dB]

(a) (b)

Figure 8.8: The AWGN Simulation Result: (a) IPER; (b) SER.

8.4.1.3. Rayleigh Fading Channel Simulation

The IPER and SER simulation results of SE, SSE, TSE and STSE are shown in Figure 8.9. The following observations could be made from the simulation results:

145 Chapter 8. WBC System’s Performance Evaluation and Results

0 0 10 10

-1 -1 10 10 SER IPER

-2 -2 10 10

SE SE SSE SSE TSE TSE STSE STSE -3 -3 10 10 11 11.5 12 12.5 13 13.5 14 14.5 11 11.5 12 12.5 13 13.5 14 14.5 15 SNR [dB] SNR [dB]

(a) fD =10Hz;

0 0 10 10

-1 -1 10 10 IPER SER

-2 -2 10 10

SE SE SSE SSE TSE TSE STSE STSE -3 -3 10 10 11 11.5 12 12.5 13 13.5 14 14.5 15 11 12 13 14 15 16 SNR [dB] SNR [dB]

(b) fD =40Hz;

0 0 10 10

-1 -1 10 10 SER IPER

-2 -2 10 10

SE SE SSE SSE TSE TSE STSE STSE -3 -3 10 10 11 12 13 14 15 16 11 12 13 14 15 16 SNR [dB] SNR [dB]

(c) fD =80Hz. Figure 8.9: The IPER/SER Simulation Result for ‘WBC over DVB-H’:

(a) fD =10Hz; (b) fD =40Hz; (c) fD =80Hz.

146 Chapter 8. WBC System’s Performance Evaluation and Results

The Doppler effect: As can be seen from the results, IPER/SER worsen when the Doppler frequency increases, especially for the SE scheme. To get IPER/SER below 1% (a WBC datacasting requirement), the received signal value should be increased by about 0.5-1 dB for TSE schemes and 1.5-2.5 dB for SE schemes for fD = 80Hz comparing with fD = 10Hz.

The section-based and TS-based effect: As the TS packet is smaller than the IP packet, a byte error in a TS packet will not mark the corresponding IP packet in error, thus the performance of TSE and STSE is better than SE and SSE. The results show that IPER/SER of the TS-based algorithms can gain 1-2dB comparing with the section-based algorithms.

The smart cross-layer decoding effect: At the link layer, an ADP (packet erasure mode) scheme is used on SE/TSE to improve reliability. The results show that, to get IPER/SER below 1%, the SSE/STSE gain is about 0.6-1 dB comparing with SE/TSE when fD = 10Hz, and about 1-2 dB when fD = 80Hz. The results also show that in order to get IPER/SER below 1%, the new STSE scheme can gain 2 dB comparing with

SE when fD = 10Hz, and 3.5 dB when fD = 80Hz.

8.4.2. ‘WBC over DVB-H’ Overhead Efficiency

8.4.2.1. Theory

With the IPER , the overhead efficiency for different IP packet lengths ( IPl ) could be obtained as:

IPlh IP1 IPER EIP()l  IPlht MPE CRC IPlht MPE CRC TS h (8.43) TSlh TS IP IP1 IPER  lh , TSl IPlhtlht MPE CRC IP MPE CRC  TSlh TS IP IP1 IPER  lh , TSl IPlht MPE CRC 1 TSlh TS where MPE is a 12-byte MPE header, CRC is a 4-byte CRC-32 trailer, TS is 188 h t l bytes (184-byte payload plus 4-byte header TS ), IP is the length of the IP header. h h

147 Chapter 8. WBC System’s Performance Evaluation and Results

Figure 8.10 illustrates the overhead efficiency (at the IP layer) for different IP packet lengths in memoryless channels. The results clearly show that in all cases an optimal value of the IP packet length ( OPT ) exists, which corresponds to a maximal efficiency. IPl The red line (line 0) represents the error-free channel. The results show that by increasing the IP packet length from 168 byte to 1088 byte the overhead efficiency is increased from 71% to 93%. However, increasing the IP packet from 1088 byte to 3848 byte gives less than a 3 % benefit on overhead efficiency (93 % to 96 %). For the other lines, the OPT is equal to 904 bytes for line 5, 536 bytes for line 4, 352 IPl bytes for line 3, 168 bytes for line 2, and 168 bytes for line 1.

1

line 1 0.9 line 2 line 3 0.8 line 4 line 5 0.7 line 0

0.6

0.5

0.4 Overhead Efficiency Overhead

0.3

0.2

0.1

0 0 500 1000 1500 2000 2500 3000 3500 4000 4500 IP Packet Length [bytes]

Figure 8.10: The Overhead Efficiency (at IP Layer) versus the IP Packet Length for the AWGN and Rayleigh Fading Channel

8.4.2.2. Analytical Results

Table 8.5 lists the values of the byte error rate for SE, SSE, TSE, and STSE corresponding to different curves in Figure 8.10. In regards to the overhead efficiency, the SSE scheme outperforms again the SE scheme, and the STSE scheme outperforms again the TSE scheme.

148 Chapter 8. WBC System’s Performance Evaluation and Results

Table 8.5: The Byte Error Rate for Different Decoding Schemes (Analytical Results)

Line No SE SSE TSE STSE Line 0 0.00089 0.000966 0.00087 0.00095 Line 1 0.00114 0.001401 0.00108 0.00129 Line 2 0.00109 0.001306 0.00103 0.00122 Line 3 0.00104 0.001222 0.00099 0.00115 Line 4 0.00099 0.001132 0.00095 0.00109 Line 5 0.00094 0.001072 0.00091 0.00103

8.4.2.3. AWGN Channel Simulation

The SNR values for SE, SSE, TSE, and STSE (obtained through simulations) and corresponding to curves in Figure 8.10 are shown in Table 8.6. The results show that the SSE/STSE schemes outperform the SE/TSE schemes by more than 0.1 dB in the AWGN channel.

Table 8.6: The SNR (in dB) for AWGN Channel Simulation

Line No SE SSE TSE STSE Line 0 5.82 5.7 5.66 5.54 Line 1 5.72 5.6 5.55 5.46 Line 2 5.74 5.62 5.57 5.48 Line 3 5.76 5.64 5.59 5.49 Line 4 5.78 5.66 5.62 5.51 Line 5 5.80 5.68 5.64 5.52

8.4.2.4. Rayleigh Fading Channel Simulation

The SNR values for SE, SSE, TSE, and STSE (obtained through simulations) and corresponding to curves in Figure 8.10 are shown in Table 8.7 (a), (b) and (c) for fD

=10Hz, fD =40Hz and fD =80Hz, respectively. The results show that the SSE/STSE schemes outperform the SE/TSE schemes by about 1 dB in the Rayleigh fading channel.

The Doppler effect: As can be seen from the simulation results, the overhead efficiency worsens with the increase of the Doppler frequency fD . The results also show that the SSE scheme can better sustain the fading effect than the SE scheme.

The cross-layer decoding effect: Due to the enhanced cross-layer interaction, the SSE/STSE schemes outperform the SE/TSE schemes by about 1 dB.

149 Chapter 8. WBC System’s Performance Evaluation and Results

For a clear demonstration, Figure 8.11 shows the overhead efficiency obtained as a function of SNR for different values of the IP packet length and Doppler frequency for the SSE decoding scheme. The results clearly indicate the overhead efficiency increases slowly with the increase of the IP packet length, especially from 1088 bytes to 3848 bytes.

Table 8.7: The SNR (in dB) for Rayleigh Channel Simulation:

(a) fD =10Hz; (b) fD =40Hz; (c) fD =80Hz.

Line No SE SSE TSE STSE Line 0 16 15 15.5 13.8 Line 1 14.1 13.2 12.9 12.4 Line 2 14.2 13.3 13 12.5 Line 3 14.3 13.4 13.2 12.58 Line 4 14.4 13.6 13.3 12.66 Line 5 14.6 13.7 13.5 12.75

(a): fD =10Hz.

Line No SE SSE TSE STSE Line 0 17 15.6 16 14.5 Line 1 14.7 13.7 13.3 12.7 Line 2 14.9 13.9 13.5 12.8 Line 3 15 14 13.7 12.9 Line 4 15.1 14.2 13.8 13 Line 5 15.3 14.3 14.1 13.1

(b): fD =40Hz.

Line No SE SSE TSE STSE Line 0 20 18 17.5 16 Line 1 16.4 14.8 14.3 13.3 Line 2 16.6 15.1 14.6 13.5 Line 3 16.8 15.3 14.8 13.6 Line 4 17 15.5 15.1 13.8 Line 5 17.2 15.7 15.3 14

(c): fD =80Hz.

8.4.2.5. Results Summary

To summarize the results, the optimal IP packet length for use in a ‘WBC over DVB-H’ system should be between 536B to 1088B. The exact value should be chosen by the WBC service provider depending on the current prevailing noise/error conditions. However, choosing a value of 512B or 1024B would greatly facilitate the process of IP

150 Chapter 8. WBC System’s Performance Evaluation and Results packets encapsulation/decapsulation into/from the MPE-FEC frame because in this case the IP packet length would fit the column size of a 512-row or 1024-row MPE-FEC frame [124].

1 1 IP Packet Length=168B 0.9 0.9 IP Packet Length=352B IP Packet Length=536B 0.8 0.8 IP Packet Length=720B IP Packet Length=904B 0.7 0.7 IP Packet Length=1088B IP Packet Length=1640B 0.6 0.6 IP Packet Length=2192B IP Packet Length=2744B 0.5 IP Packet Length=168B 0.5 IP Packet Length=3848B IP Packet Length=352B 0.4 IP Packet Length=536B 0.4 Overhead Efficiency

IP Packet Length=720B Overhead Efficiency 0.3 IP Packet Length=904B 0.3 IP Packet Length=1088B 0.2 IP Packet Length=1640B 0.2 IP Packet Length=2192B 0.1 IP Packet Length=2744B 0.1 IP Packet Length=3848B 0 0 12 12.5 13 13.5 14 14.5 15 15.5 16 12 12.5 13 13.5 14 14.5 15 15.5 16 SNR [dB] SNR [dB] (a) (b)

Figure 8.11: The Overhead Efficiency for Different IP Packet Lengths with SSE

Decoding Scheme: (a) fD =10Hz; (b) fD =80Hz. 8.5. Service Layer Evaluation

There are two main criteria – the tuning time ( ) and access time (T) - used for evaluating the performance of the WBC service layer. Considering the fact that the client access pattern usually follows a skewed distribution [95], the SD/WBC segment demand access frequency p was set to follow a Zipf distribution:

 1/ M (8.44) , where p  1 . p  M   1  1/ j  j1 

8.5.1. Tuning Time

In DVB-H, due to the time slicing and data broadcasting in a burst mode, (4.9) is changed to:

3 (8. 457) ndt()/23(1)BO  ser, where  is the time needed to download one WBC segment (  = const because all WBC segments are equal in size) and ser is the WBC segment error rate. For a fading

7 The mobile terminal first needs to wait for the next burst of WBC segments ( ()/2BOdt ), then download the first WBC segment in the burst (  ), read the inner index to find the inter-index, then wait for and download the inter-index (  ), read the inter index to find the needed WBC segment position / broadcasting time, and finally download the needed WBC segment (  ).

151 Chapter 8. WBC System’s Performance Evaluation and Results channel, we consider that the first WBC segment is downloaded at 0 time slice, the second WBC segment - at x*  time slice, and the third WBC segment - at y*  time slice, xy, integer . In a fading channel, the tuning time may increase due to the necessity of re-downloading the corresponding WBC segment in the next inter-cycle/inner-cycle.

8.5.2. Access Time

To measure the access time, M=500 distinct WBC segments were generated and broadcast over a simulated ‘WBC over DVB-H’ channel. The simulation results in Figure 8.12 show that the mean WBC segment access time T decreases when the client access pattern becomes more skewed. These results prove that the newly proposed WBC indexing algorithm is more efficient than the broadcast disks algorithm [95]. The access time for SNR=13dB is greater than that for SNR=16dB due to WBC segments downloading errors.

1400 Broadcast Disks Algorithm 'WBC over DVB-H', SNR 13dB, f 40Hz D WBC Algorithm Ideal (No Collision) 1200

1000 slots]

[time

800 Time

'WBC over DVB-H', SNR 16dB, f 40Hz D Access 600 Segment

400 Virtual Channel Mean

200

0 0 0.2 0.4 0.6 0.8 1 1.2 1.4 Current Client Access Pattern - ()

Figure 8.12: The Mean WBC segment Access Time for Different Access Patterns ( ) The access time in the ‘WBC over DVB-H’ system is greater than that in an ideal channel due to the extra FEC data added to the broadcasting WBC segment sequence to improve the reliability in wireless fading channels.

152 Chapter 8. WBC System’s Performance Evaluation and Results

8.6. Conclusion

In order to evaluate the performance of the ‘WBC over DVB-H’ system, a 2SRL model has been used to represent the physical layer. To simulate the signal envelops having appropriate distribution, a Rayleigh wireless fading channels has been considered. The corresponding Probability Density Function (PDF), Cumulative Distribution Function (CDF) and Level Crossing Rate (LCR) have been investigated. By contrast to the other studies, the average SNR  acts as a parameter in PDF,

CDF and LCR instead of the received instantaneous signal amplitude r ( is a basic parameter of the ‘WBC over DVB-H’ physical layer Matlab simulators). The 2SRL model makes it simple to generate the good/bad TS packets with the corresponding 2SMM parameters, which include the error probabilities in state G (()p G ), error probabilities in state B (p (B ) ) and transition probabilities b and e e g . The values of these parameters depend on the wireless channel used in the physical-layer testbed.

With the proposed model, the obtained results for the Transport Stream Packet Error Rate (TSPER) in the physical layer, IP Packet Error Rate (IPER) and Segment Error Rate (SER) in the link layer, and tuning time and access time in the server layer, have been presented. In the physical layer, the 2SRL parameters for Rayleigh fading channel have been obtained analytically from the corresponding DVB-H parameters. In the link layer, the IPER, SER and the overhead efficiency have been evaluated analytically for an Additive White Gaussian Noise (AWGN) channel and a Rayleigh fading channel. In the service layer, the tuning time and access time have been studied and evaluated.

153 Chapter 9. Conclusions

CHAPTER 9. CONCLUSIONS

9.1. Introduction

In this chapter, the key results obtained throughout this research work are highlighted and research conclusions are presented. Included also are some ideas for future research work.

9.2. Main Research Goal Achieved

In brief my principal PhD contribution is that a fully operational ‘WBC over DVB-H’ system prototype was designed, developed, evaluated and tested. Different parts of this were published in internationally archived research papers (c.f. Appendix E).

9.2.1. On WBC Service Layer

At the WBC service layer, the Access Network Providers (ANPs) and Teleservice Providers (TSPs) submit/publish descriptions of their services to the web portal of the Wireless Billboard Channel - Service Provider (WBC-SP) in a very active, dynamic and competitive manner. The service descriptions are then collected, clustered, scheduled, indexed, and encoded by the WBC-SP, and the final octet streams are sent to broadcasting servers for further broadcasting to Mobile Terminals (MTs). In order to save battery power and memory space, the terminals only receive the descriptions of the user’s favourite services. After discovering the needed services, the terminals associate with the "best" service in each preferred category.

9.2.2. On WBC Link Layer

The Digital Video Broadcasting - Handheld (DVB-H) is a broadcast platform which is well suited for acting as carriers for WBCs. Exploiting the DVB-H features of time-slicing and Multi-Protocol Encapsulation - Forward Error Correction (MPE-FEC), the feasibility of having an IP Datacasting (IPDC) WBC mode, which can perform

154 Chapter 9. Conclusions effectively in a mobile environment, was demonstrated. The flexibility in network bandwidth planning, (e.g., the ability to share the channel with other DVB-H services) is not compromised; this is an important factor in smoothing the way for the standardization of a ‘WBC over DVB-H’ system.

Also, the ‘WBC over T-DMB’ alternative has been studied (C.f. appendix C].

9.2.3. On WBC physical Layer

Using the Markov model for analysing the TS Packet Error Rate (TSPER) of the DVB-H outputting behaviours has been studied and proposed for use in the multipath fading channel. To analyze the TSPER in wireless fading channel environments, an iterative TSPER algorithm has been proposed and used with a new SNR partition algorithm.

9.3. Conclusion

Wireless networks and Mobile Terminals (MTs) have experienced rapid development in recent years. Nowadays, it is increasingly believed that the future wireless world should allow the Mobile Users (MUs) to stop their long-term subscriptions with Access Network Providers (ANPs) and use advertised wireless services from any consumer-centric wireless ANP that is available to them. This will allow MUs to be truly Always Best Connected and Best Served (ABC&S), i.e., MUs to use any wireless service anytime, anywhere, and anyhow through the best possible connection.

Telecommunications Research Centre (TRC) researchers in the University of Limerick (UL) have suggested a new wireless Next Generation Network (NGN) environment named Ubiquitous Consumer Wireless World (UCWW). The UCWW is based on IP integrated heterogeneous environment encompassing complementary types of wireless access networks (e.g. GSM/GPRS/UMTS/CDMA2000, Wi-Fi, Wi-Max, Bluetooth, etc). In UCWW, the MU can use multiple teleservices delivered simultaneously via different Access Networks (ANs) and paid by means of Third-Party Authentication, Authorisation and Accounting Service Providers (3P-AAA-SPs). This will be greatly facilitated by the Consumer-centric Business Model (CBM) having a user-centric structure rather than a network-centric structure.

155 Chapter 9. Conclusions

To sell wireless services to a great common MU market in overlapping local, regional, and global domain, rapid deployed on-demand and customized to the user’s needs, and adapted to the current wireless connection environment, in [1], a Wireless Billboard Channel (WBC) was proposed as a proactive push-based solution. WBCs are broadcasting channels used to push service advertisements simultaneously to a large number of mobile terminals. To choose the “best” service, each terminal filters the Service Descriptions (SDs) using the user profiles, the terminal’s Composite Capability/ Preference Profiles (CC/PP), and the user location. WBCs are narrow, unidirectional and point to multi-point broadcasting channels, operated by non-ANP WBC service providers - WBC-SPs. It is a novel solution for facilitating services Advertisement, Discovery and Association (ADA) and a core element in the UCWW. WBC is the research focus of this thesis.

Besides further development of the essentials of the general WBC concept as proposed in [1] (c.f. Chapter 2), the overall objective of the research was to investigate the conceptualisation, design, implementation and testing of a ‘WBC over Digital Video Broadcasting - Handheld (DVB-H)’ system prototype. The WBC design goals include: (i) WBC system architecture – with layered structure, and combining novel algorithms, schemes and protocols; (ii) carrier platform choice – a suitable WBC platform should be chosen for wireless advertisement broadcasting; (iii) system prototype implementation; and (iv) proof-of-concept testing and performance evaluation – for proofing and refining of the WBC designs.

In Chapter 2, an extensive background study of CBM, UCWW, the motivation and concepts of WBCs was undertaken. This involved the study of the history and development of the UCWW, service discovery protocols, WBC concept and characteristics, and WBC service discovery model. Also, the structure of Service Descriptions (SDs) has been defined with two service divisions in mind: Access Networks' Communication Services (ANCS) and teleservices.

Considering the trend that the future MTs (e.g., within LTE) will have integrated IP-based transmission techniques and services support, the IP Datacasting (IPDC) scheme support was targeted in the WBCs. To simplify the design and achieve compatibility with this technique, the WBC system architecture was built on three communications layers: (i) a service layer, which describes the service discovery model, and data collection, clustering, scheduling, indexing, broadcasting, discovery, and

156 Chapter 9. Conclusions association schemes, etc.; (ii) a link layer concerned with the frame processing issues, such as forward error control, etc.; and (iii) a physical layer, which realizes the transmitter (on the WBC-SP node) and receiver (on the user mobile node). This layered architecture was described in Chapter 3. The background studies were undertaken in each of the three layers. The service layer is a pure software layer, independent of the carrier technology. In this layer, the Abstract Syntax Notation One (ASN.1) language, JAVA EE Environment, light-weight HTTP container, GWT, Android, MIDP, MAS, and Java Rule Engine were overviewed. The link layer and physical layer are hardware-dependent layers and thus have different structures depending on the carrier technology used. A number of carrier technologies are suitable to carry the WBC dataset, for example, the digital audio broadcast (DAB), digital multimedia broadcasting (DMB), digital radio mondiale (DRM), DVB-H, multimedia broadcast/multicast service (MBMS), satellite DMB (S-DMB), digital audio radio satellite, and so forth. Among these technologies the DVB-H was chosen as an attractive solution due to its full support for IPDC. The IPDC over DVB-H is a new European Telecommunications Standards Institute’s (ETSI) standard which enables effective distribution of digital content to mass audiences. As commercial DVB-H services have already been rolled out, the market prospect of DVB-H devices seems very bright thus having a potential to be exploited effectively in creating the ‘WBC over DVB-H’ system. We published several papers on the topic of “WBC over DVB-H”, e.g., “Novel Scheme and System for Mobile Services' Advertisement and Discovery in the Future Telecommunications World” at the World Telecommunications Congress 2010 (WTC 2010); “A 'WBC over DVB-H' Prototype System” at the Royal Irish Academy Research Colloquium 2010 on Emerging Trends in Wireless Communications; and “Building a ‘WBC over DVB-H’ Software Testbed” at the 13th IEEE International Symposium on Consumer Electronics (ISCE 2009).

To check the ‘WBC over DVB-H’ feasibility, the whole system was designed and implemented as described in detail in Chapters 4, 5, 6, and 7.

The server layer has been described in Chapter 4 and 5 for service advertisement from the WBC-SP node and discovery and association on the MT, respectively. The ASN.1 Packed Encoding Rules (PER) encoder/decoder was selected to carry the SDs data. The encoder/decoder was implemented in Java to ensure platform independency. A corresponding Java template supported by the encoding/decoding process was

157 Chapter 9. Conclusions developed for each SD. A paper was published on this topic entitled “Formal Description of Services for Advertisement on Wireless Billboard Channels” at the 14th IEEE ISCE 2010 conference. The service layer was implemented with of two sub-layers. The application enabler sub-layer is used for facilitating the SD’s collecting, clustering, scheduling, and indexing in the WBC-SP node, and discovery and association in the MT. This sub-layer has a heterogeneous three-tier software architecture consisting of: a service discovery and maintenance tier that maintains the client’s requests and server’s responses, organizes service discovery model, and serializes objects to the persistence sub-tier; a rule-based expert system running in the intelligent application tier to provide WBC common services and maintain ontologies; and a peer-to-peer MAS tier running a set of agents to collect, cluster, schedule, index, and broadcast wireless services in the WBC-SP's node, and to discover and associate with chosen services in the MT. The research on this sub-layer was summarized in a paper entitled “Intelligent Software Architecture for the Service Layer of Wireless Billboard Channels” presented at the 6th annual IEEE Consumer Communications & Networking Conference (CCNC’09) and in another paper entitled “Implementation the Intelligent Application for the Service Enabler Sub-Layer on WBC-SP Node” submitted to the 7th IEEE International Symposium on Wireless Communication Systems (ISWCS 2010). The service enabler sub-layer runs a novel Advertisements Delivery Protocol (ADP) to broadcast WBC segments to the link layer in the WBC-SP node, and to assemble segments from the received IP packets in MT. The ADP is a protocol designed to act as a bridge between the WBC service layer and link layer. With an ADP server, the link layer on the WBC service provider's side can enable the IPDC processing. It was developed based on a modified Asynchronous Layered Coding/Layered Coding Transport (ALC/LCT) protocol. The resultant ADP packet structure is simple and compact. The ADP packet header only needs 8 bytes, which is less than the standard File Delivery over Unidirectional Transport (FLUTE) protocol (44 bytes) and File multiCasting (FCAST) protocol (60 bytes). The final results show that the APD is also faster than FLUTE and FCAST in terms of the encoding/decoding speed achieved. The application enabler sub-layer is implemented as an enterprise application on the WBC-SP node and as a light-weight personal mobile application on MT. The service enabler sub-layer is realized as an ADP encoder on the WBC-SP node and as an ADP decoder on MT. We published a paper

158 Chapter 9. Conclusions on this sub-layer entitled “Reliable and efficient Advertisements Delivery Protocol for use on wireless billboard channels” at the 12th IEEE ISCE 2008 conference.

A number of open-source Integrated Development Environments (IDEs)/APIs/ frameworks were employed for building an efficient, distributed, extendable, flexible, and maintainable system on the WBC-SP node. These include Eclipse, DB4O, MySQL, JUnit, ANT, Mock Objects, Maven, Hibernate, Lucene, XDoclet, XWork, Spring, JBoss, JADE, Jena, etc. Chapter 4 provided the details of the system implementation. A number of UML diagrams have been provided for each tier. A light-weight MAS container was designed and successfully implemented. We have published two papers on WBC-SP node’s implementation, entitled “Building a Heterogeneous Software Architecture for the WBC Service Layer” at the IET China-Ireland International Conference on Information and Communications Technologies (CIICT 2008) and “On WBC Service Layer for UCWW” at the 9th Mobile and Wireless Communication Networks (MWCN 2007) conference, respectively. Besides developing efficient software architecture on the WBC-SP node, reducing the MT access time and tuning time were other design goals. In Chapter 4, a novel SDs collecting and clustering schemes along with hot- and cold WBC segments scheduling algorithms were proposed for minimizing the MT access time, and efficient inner-index and inter-index schemes have been adopted for reducing the MT tuning time. The final generic format of the WBC broadcasting cycle was also provided in Chapter 4 and a paper has been published at the International Conference on Telecommunications (ICT 2008) entitled “Efficient Collecting, Clustering, Scheduling, and Indexing Schemes for Advertisement of Services over Wireless Billboard Channels”.

For the mobile handset side, a light-weight MT three-tier architecture was proposed in Chapter 5 to correspond to the WBC-SP three-tier architecture. In the service discovery and maintenance tier, it still includes three sub-tiers but has the number of components than in the WBC-SP side. To build an efficient discovery and association system, a light-weight iWBC HTTP container and JADE environment were developed for hosting the iWBC content provider and UI applications. The iWBC content provider mainly works on updating the user profiles, discovering new ‘interesting’ wireless advertisements, and communicating with personalized WBC User Interface (iWBC-UI). The iWBC UI acts as an MT application for association with the wireless

159 Chapter 9. Conclusions services chosen. Three different types of iWBC-UI were developed, including an iWBC-JSE application, an iWBC-Android application, and an iWBC-MIDP application, running on Ultra-Mobile PC (UMPC) or PC, Pocket PC (PPC), and resource limited MT, respectively. To build an intelligent iWBC mobile application, a number of novel components were developed on the client side, such as the unified iWBC-JADE, message manager, and iWBC-UI profiles design. We have published a conference paper entitled “An iWBC-MIDP Client Application Design for Use in WBCs” at the IEEEE 71th Vehicular Technology Conference (VTC2010-Spring) and have submitted a journal paper entitled “iWBC Client Application for 'WBC over DVB-H': Design and Implementation” to the IEEE Transactions on Consumer Electronics journal, on the mobile handset side. The details of the design and implementation of the ‘WBC over DVB-H’ link layer and physical layer were presented in Chapter 6 and 7, respectively. To evaluate the system performance and implement a fully operational WBC prototype, the link layer and physical layer were implemented both in software (simulator testbed) and in hardware (real-time hardware testbed).

In a software simulator testbed, the link layer was implemented in C++ and the physical layer was implemented with Matlab.

To increase the reliability of the ‘WBC over DVB-H’ system, novel cross-layer Smart Section Erasure (SSE) and Smart Transport Stream Erasure (STSE) decoding schemes were developed and set out in Chapter 6. With these new efficient solutions, the 'WBC over DVB-H' system is able to operate in a flexible and more reliable way. We have published a conference paper entitled “Novel Cross-layer Decoding Design for 'WBC over DVB-H' Link Layer” at the 6th IEEE ISWCS Conference 2009 and a journal paper entitled “Performance Analysis of 'WBC over DVB-H' Link Layer” in the EURASIP Journal on Wireless Communications and Networking 2010 on this topic.

A Matlab physical-layer testbed was designed by following the ETSI-EN-300-744 standard. Considering that a DVB-H wireless channel simulator is currently unavailable on the market, a Rayleigh fading channel following the COST207 TU6 model with six-tap multipath channel corresponding to typical urban propagation conditions was selected to obtain simulation results for the Transport Stream Packet Error Rate (TSPER).

160 Chapter 9. Conclusions

In the real-time hardware testbed’s design and implementation section, the WBC-SP side uses an UDCast IPE-10 equipment as an encapsulator, an Audemat EMAA transmitter as a modulator, and an UDCast GOLDENEAGLE as a monitor. All the hardware is controlled by the developed WBC-SP portal application. In contrast, the MT user side only includes a POD-1100 DVB-H receiver. The software of the link layer and physical layer were implemented with Microsoft Foundation Classes (MFC). In the link layer, the application can add and remove Packet Identifiers (PIDs) from the setting area, and dynamically monitor the Multi-Protocol Encapsulation - Forward Error Correction (MPE-FEC) tables, IP packets, padding and puncturing information. In the physical layer, the application can tune in to a particular radio frequency, and dynamically monitor the physical-layer signal in power-saving or high-speed mode.

The performance evaluation of the proposed ‘WBC over DVB-H’ system has been studied in Chapter 8. The physical-layer simulator presented in Chapter 7 was used to simulate the TSPER in offline mode. However, the TS packets outputting on the receiver side was too slow. To improve the efficiency of performance evaluation, an accurate and flexible Two-State Run Length Model (2SRL) physical-layer simulation model representing the good/bad TS packet outputs was designed and successful implemented. The received signal envelop has the chi-square central distribution, and the corresponding PDF, CDF, LCR and corresponding 2SRL parameters have been analysed at the start of that chapter. Then the performance evaluation results have been presented for each of the three layers of the ‘WBC over DVB-H’ system. In the physical layer, the TSPER was evaluated both in an AWGN channel and Rayleigh fading channel. In the link layer, the IPER/SER was first analysed theoretically and then evaluated in both an AWGN channel and Rayleigh fading channel. The overhead efficiency of a ‘WBC over DVB-H’ system was also analysed theoretically and evaluated both in an AWGN channel and Rayleigh fading channel. In the service layer, the MT tuning time and access time were evaluated. We published two journal papers on performance evaluation entitled “'WBC over DVB-H' Testbed Design, Development and Results” in the EURASIP Journal on Wireless Communications and Networking in 2010 and “Performance Evaluation of 'WBC over DVB-H' System” in the IEEE Transactions on Consumer Electronics in 2009.

The WBC established over DVB-H carrier for service ADA in a UCWW has been presented in this thesis. The design and development of corresponding experimental

161 Chapter 9. Conclusions testbed have been described in detail. The main contributions could be summarized as follows:

 A foundational WBC infrastructure was developed;  A WBC three-layer system architecture was designed, tested and verified;  A WBC multi-tier service-layer software framework was designed and implemented;  A potential WBC carrier (DVB-H) was studied, and successfully simulated and demonstrated. New cross-layer smart decoding algorithms (SSE and STSE) were developed and evaluated;  Novel WBC schemes for SD encoding/decoding, collecting, clustering, scheduling, indexing, IPDC broadcasting, discovery and association algorithms were elaborated;  The end-to-end WBC ADA processing has been successfully tested and its successful operation demonstrated. 9.4. Future Work

There are some key areas of this research work that merit future research. At the WBC service layer – in addition to the intelligent software architecture already presented, other issues for future investigation include:

(1) Agent environment.

In this research, JADE has been used to act as an agent environment in the heterogeneous WBC software architecture. However, JADE is a heavy agent platform with a big footprint for executing both the SD collecting, clustering, scheduling, indexing, broadcasting on the server side, and the SD discovery and association on the user side. In addition, it does not fully support the Belief-Desire-Intention (BDI) agent. Therefore, an investigation into light-weight BDI-based Java agent platforms (WBC-BDI) is recommended for future research. Formatting the communication language's messages with WBC-ASN is also recommended.

(2) SD formatting.

In order to encode SDs in a more compact way, an efficient abstract syntax notation language based on ASN.1 (WBC-ASN) is suggested to be developed. Any design

162 Chapter 9. Conclusions should take into account the requirement for minimizing the decoder's power consumption.

(3) Rule engine.

Resolution of the need to improve the flexibility and scalability could be approached by designing an intelligent SD self-organization light-weight Java rule engine. In suggesting this, we also recommend that the rules configuration file here could be defined with WBC-ASN.

(4) ADP.

With scalable system design in mind, the route of developing the ADP protocol in Java, together with a Java-based Reed-Solomon FEC algorithm being fully implemented is suggested as worthy of investigation.

(5) Profile design.

To increase security and privacy for WBC-SPs, and mobility and personalization for mobile users, investigation of the benefits from this perspective of a well-structured rule-based profile developed and formatted with WBC-ASN is suggested.

(6) Content awareness.

Content awareness is an important part in designing the iWBC receiver. The Mobile Terminal (MT) should initialize the iWBC application with MT’s Composite Capability / Preference Profiles (CC/PP) and Mobile User (MU)’s personal profiles. The web-based iWBC application should be designed and implemented with the Extensible Hypertext Markup Language (XHTML). The interface of iWBC should be content aware, i.e., different MTs should avail of different User Interfaces (UIs). For compatibility with the XML markup languages, an ASN.1 Packed Encoding Rules (PER) stream to XML API should be developed.

(7) Personalized.

With personalized iWBC receiver, the mobile user can be Always Best Connected and Best Served (ABC&S). The iWBC personalized receiver is defined in terms of distributed and intelligent software modules (agents), which can help MU handover between different iWBC content-aware MTs.

163 Chapter 9. Conclusions

At the WBC link layer and physical layer the potential broadcast platform solutions include WBC over DVB-H, over DRM, over DAB, etc. The ‘WBC over DVB-H’ concept has been studied and its implementation described in this thesis. The hardware testbed for DRM, DAB, etc, has yet to be established. There is little doubt about the potential consumer base into which WBC advertisement may be pushed. Today, for instance, there is an expectation of 300 million DVB-H capable handsets operational by the end of 2010.

The WBC paradigm faces a number of difficulties in becoming an international standard. However, it has a great potential for stand-alone standardization and takeoff, even without awaiting the acceptance of the UCWW by the world network community.

164 References

REFERENCE

[1] P. Flynn, I. Ganchev, M. O'Droma, “Wireless Billboard Channels: Vehicle and Infrastructural Support for Advertisement, Discovery, and Association of UCWW Services,” Annual Review of Communications, vol. 59, pp. 493-504, 2006. [2] P. Flynn, I. Ganchev, and M. O'Droma, “WBCs - ADA vehicle and infrastructural support in a UCWW,” in Proceedings of IEEE Tenth International Symposium on Consumer Electronics (ISCE 2006), St.Petersburg. Russia, pp. 351-356, 29 June - 1 July, 2006. [3] Z. Ji, I. Ganchev, and M. O'Droma, “Efficient Collecting, Clustering, Scheduling, and Indexing Schemes for Advertisement of Services over Wireless Billboard Channels,” in Proceedings of International Conference on Telecommunications (ICT 2008), St. Petersburg, Russia, pp. 225-230, 16-19 June, 2008. [4] Z. Ji, I. Ganchev, and M. O'Droma, “Reliable and efficient Advertisements Delivery Protocol for use on wireless billboard channels,” in Proceedings of 12th IEEE International Symposium on Consumer Electronics (IEEE ISCE 2008), Algarve, Portugal, pp. 261-264, 14-16 April, 2008. [5] Z. Ji, I. Ganchev, and M. O'Droma, “Building a ‘WBC over DVB-H’ Software Testbed,” in Proceedings of 13th IEEE International Symposium on Consumer Electronics (ISCE 2009), Kyoto, Japan, pp. 626-629, 25-28 May, 2009. [6] Z. Ji, I. Ganchev, and M. O'Droma, “New Method for Analyzing the Transport Stream Packet Error Rate of `WBC over DVB-H`,” in Proceedings of IEEE Wireless Communications & Networking Conference (WCNC 2009), Budapest, Hungary, pp. 73-76, 5-8 April, 2009. [7] Z. Ji, I. Ganchev, and M. O'Droma, “Optimal IP Packet Length for ‘WBC over DVB-H’,” in Proceedings of IEEE 70th Vehicular Technology Conference (VTC2009-Fall), Alaska, USA., pp. 1-4, 20-23 September, 2009. [8] Z. Ji, I. Ganchev, and M. O'Droma, “Using a Rayleigh Fading Channel and Finite State Markov Model for Analyzing the 'WBC over DVB-H' Performance,” in Proceedings of IEEE 70th Vehicular Technology Conference (VTC2009-Fall), Alaska, USA., pp. 1-4, 20-23 September, 2009.

165 References

[9] Z. Ji, I. Ganchev, and M. O'Droma, “Wireless Billboard Channel over DAB/T-DMB in Transmission Mode I,” in Proceedings of 3th IEEE International Conference and Exhibition on Next Generation Mobile Applications, Services and Technologies (NGMAST 2009), Wales, UK, pp. 149-152, 15-18 September, 2009. [10] Z. Ji, I. Ganchev, and M. O'Droma, “Novel Cross-layer Decoding Design for 'WBC over DVB-H' Link Layer,” in Proceedings of 6th IEEE International Symposium on Wireless Communication Systems 2009, Siena, Italy, pp. 687-690, 7-10 September, 2009. [11] Z. Ji, I. Ganchev, and M. O'Droma, “Performance Evaluation of 'WBC over DVB-H' System,” IEEE Transactions on Consumer Electronics, vol. 55, No.2, pp. 754-762, May 2009. [12] Z. Ji, I. Ganchev, and M. O'Droma, “The Performance Analysis of Link Layer of Wireless Billboard Channel over DVB-H,” EURASIP Journal on Wireless Communications and Networking, vol. 2010, Article ID 306709, pp. 1-15, 2010. [13] Z. Ji, I. Ganchev, and M. O'Droma, “Building a Heterogeneous Software Architecture for the WBC Service Layer,” in Proceedings of China-Ireland International Conference on Information and Communications Technologies (CIICT 2008), Beijing, China, pp. 14-18, 26-28 September, 2008. [14] Z. Ji, I. Ganchev, and M. O'Droma, “On WBC Service Layer for UCWW,” in Proceedings of 9th International Conference on Mobile and Wireless Communication Networks (MWCN 2007), Cork, Ireland, pp. 106-110, 19-21 September, 2007. [15] Z. Ji, I. Ganchev, and M. O'Droma, “'WBC over DVB-H' Testbed Design, Development and Results,” EURASIP Journal on Wireless Communications and Networking, vol. 2010, Article ID 769683, pp. 1-18, 2010. [16] M. O'Droma, and I. Ganchev, “Toward a ubiquitous consumer wireless world,” IEEE Wireless Communications, vol. 14, no. 1, pp. 52-63, 2007. [17] M. O'Droma, and I. Ganchev, “Strategic innovations through NGN standardisation for a Ubiquitous Consumer Wireless World,” in Proceedings of First ITU-T Kaleidoscope Academic Conference Innovations in NGN: Future Network and Services, Geneva, Switzerland, pp. 135-142, 12-13 May, 2008. [18] M. O'Droma, I. Ganchev, and N. Wang, “On incoming call connection service

166 References

in a ubiquitous consumer wireless world,” in Proceedings of 6th International Conference on Next Generation Wired/Wireless Networking, St. Petersburg, Russia, pp. 287-297, 29 May - 2 June, 2006. [19] N. Passas, S. Paskalis, A. Kaloxylos et al., “Enabling technologies for the 'Always Best Connected' concept,” Wireless Communications & Mobile Computing, vol. 6, no. 4, pp. 523-540, 2006. [20] E. Gustafsson, and A. Jonsson, “Always best connected,” IEEE Wireless Communications, vol. 10, no. 1, pp. 49-55, 2003. [21] M. O'Droma, “Wireless, Mobile and Always Best Connected,” IEEE Communications Magazine & GCN, vol. 42, pp. 29-30, 2004. [22] M. O'Droma, I. Ganchev, G. Morabito et al., “Always best connected enabled 4G wireless world,” in Proceedings of 12th European Union IST Summit on Mobile and Wireless Communications, Aveiro, Portugal, pp. 710-716, 15-18 June, 2003. [23] M. O'Droma, and I. Ganchev, “Enabling an Always Best-Connected Defined 4G Wireless World,” Annual Review of Communications, vol. 57, pp. 1157-1170, 2004. [24] I. Ganchev, and M. O'Droma, “New personal IPv6 address scheme and universal CIM card for UCWW,” 2007 7th International Conference on ITS Telecommunications, Proceedings, pp. 381-386, 2007. [25] F. McEvoy, I. Ganchev, and M. O'Droma, “Building a testbed with new security features for UCWW research,” in Proceedings of IEEE Tenth International Symposium on Consumer Electronics (ISCE 2006), St.Petersburg, Russia, pp. 581-586, 28 June-01 July, 2006. [26] Q. Hu, X. C. Zou, and S. M. Sun, “ASN.1 application in parsing ISUP PDUs,” in Proceedings of International Symposium on Communications and Information Technologies, Bangkok, Thailand, pp. 946-949, 18-29 October, 2006. [27] ITU-T, "Rec. X.680 Information technology - Abstract Syntax Notation One (ASN.1): Specification of basic notation. http://www.itu.int/ITUT," 2008. [28] D. Gallardo, E. Burnette, R. McGovern et al., Eclipse in action: a guide for Java developers: Manning Publications, 2003. [29] J. Brittain, and I. Darwin, Tomcat: the definitive guide: O'Reilly & Associates, Inc, 2003.

167 References

[30] K. Topley, Core Swing: advanced programming: Prentice Hall PTR, 2000. [31] N. TED, C. Dumoulin, G. Franciscus et al., Struts in Action, Building web applications with the leading Java framework: Manning Publications, 2003. [32] C. B. i. logiciel, G. King, and L. De Michiel, Hibernate in action: Manning Publications, 2005. [33] C. Walls, and R. Breidenbach, Spring in action: Manning Publications, 2007. [34] E. Hatcher, and S. Loughran, Java development with Ant: Manning Publications, 2003. [35] R. Hightower, W. Onstine, and P. Visan, Professional Java tools for extreme programming: Ant, Xdoclet, JUnit, Cactus, and Maven: Wrox, 2004. [36] G. C. "Short introduction to log4j," http://logging.apache.org. [37] S. Edlich, J. Paterson, H. Horning et al., The Definitive Guide to Db4o: Apress, 2006. [38] M. Widenius, D. Axmark, and P. DuBois, MySQL reference manual: O'Reilly & Associates, Inc, 2002. [39] D. Kayal, Pro Java EE Spring Patterns: Best Practices and Design Strategies Implementing Java EE Patterns with the : Apress, 2008. [40] L. Huan-huan, Z. Xiao-hui, and W. Jie, “Mobile development of Java ME based on eclipse,” Mechanical & Electrical Engineering Magazine, vol. 26, no. 8, pp. 221-225, 2009. [41] J. DiMarzio, Android - A Programmers Guide: McGraw-Hill Osborne Media, 2008. [42] M. Ughetti, T. Trucco, and D. Gotta, “Development of Agent-Based, Peer-to-Peer Mobile Applications on ANDROID with JADE,” in Proceedings of Second International Conference on Mobile Ubiquitous Computing,Systems, Services and Technologies, Valencia, Spain, pp. 287-294, 29 September-04 October, 2008. [43] E. Burnette, and A. Houghton, “Hands-on Google Web Toolkit,” Dr Dobbs Journal, vol. 33, no. 1, pp. 26-30, 2008. [44] F. Bellifemine, G. Caire, D. Greenwood et al., Developing multi-agent systems with JADE: Springer, 2007. [45] G. Caire, JADE tutorial: JADE programming for beginners: Telecom Italia Laboratory, 2007. [46] E. Friedman-Hill, JESS in Action: Manning Publications, 2003.

168 References

[47] M. Proctor, M. Neale, M. Frandsen et al., Drools Documentation, Version 4.0.3, http://www.jboss.com/products/rules, 2007. [48] P. Leroux, V. Verstraete, F. De Turck et al., “Synchronized interactive services for mobile devices over IPDC/DVB-H and UMTS,” in Proceedings of 2nd IEEE/IFIP International Workshop on Broadband Convergence Networks (BCN 2007), Munich, Germany, pp. 1–12, 21-21 May, 2007. [49] T. ETSI, "102 469 v1.1.1: Digital Video Broadcasting (DVB)," IP Datacast Over DVB-H: Architecture, 2006. [50] T. ETSI, "102 472 v1.1.1: Digital Video Broadcasting (DVB)," IP Datacast Over DVB-H: Content Delivery Protocols, 2006. [51] T. ETSI, "102 470 v1.1.1: Digital Video Broadcasting (DVB)," IP Datacast over DVB-H: Program Specific Information (PSI)/Service Information (SI), 2006. [52] T. ETSI, "102 471 v1.1.1: Digital Video Broadcasting (DVB)," IP Datacast over DVB-H: Electronic Service Guide, 2006. [53] S. Liang, Java Native Interface: Programmer's Guide and Reference: Addison-Wesley Longman Publishing Co., Inc, 1999. [54] M. Kornfeld, and G. May, “DVB-H and IP datacast - Broadcast to handheld devices,” IEEE Transactions on Broadcasting, vol. 53, no. 1, pp. 161-170, March, 2007. [55] J. Paavola, H. J. Himmanen, T. Jokela et al., “The performance analysis of MPE-FEC decoding methods at the DVB-H link layer for efficient IP packet retrieval,” IEEE Transactions on Broadcasting, vol. 53, no. 1, pp. 263-275, 2007. [56] X. Yang, J. Vare, and T. Owens, “A survey of handover algorithms in DVB-H,” IEEE Communications Surveys & Tutorials, vol. 8, no. 4, pp. 16-29, 2006. [57] D. P. Office. "DVB-H Online," http://www.dvb-h.org. [58] E. ETSI, "300 744 v1.6.1, Digital Video Broadcasting (DVB); Framing structure, channel coding and modulation for digital terrestrial television," European Standard (Telecommunications series), 2009. [59] E. ETSI, “301 192 Digital Video Broadcasting (DVB) V1.4.1,” DVB specification for data broadcasting, 2004. [60] T. ETSI, "102 377 v1.2.1: Digital Video Broadcasting (DVB)," DVB-H Implementation Guidelines, 2009.

169 References

[61] T. ETSI, "EN 302 304 V1.1.1: Digital Video Broadcasting (DVB)," Transmission system for handheld terminals, 2004. [62] T. ETSI, "EN 300 468 V1.6.1: Digital Video Broadcasting (DVB)," Specification for Service Information (SI) in DVB Systems, 2004. [63] ETSI, "Digital Audio Broadcasting (DAB); Data Broadcasting - MPEG-2 TS streaming," ETSI TS 102 427, V1.1.1, 2005. [64] E. ETSI, "Radio Broadcasting Systems; Digital Audio Broadcasting (DAB) to mobile, portable and fixed receivers," European Standard (Telecommunications series), 2001. [65] G. Lee, S. Cho, K. Yang et al., “Development of terrestrial DMB transmission system based on Eureka-147 DAB system,” IEEE Transactions on Consumer Electronics, vol. 51, no. 1, pp. 63-68, 2005. [66] J. Cho, N. Cho, K. Bang et al., “PC-based receiver for Eureka-147 digital audio broadcasting,” IEEE Transactions on Broadcasting, vol. 47, no. 2, pp. 95-102, 2001. [67] D. Nathan, B. Sputh, O. Faust et al., “Design and Features of an Intelligent PC-based DAB Receiver,” IEEE Transactions on Consumer Electronics, vol. 48, no. 2, pp. 322-328, 2002. [68] K. Lee, Y. Park, S. Park et al., “Development of portable T-DMB receiver for data services,” IEEE Transactions on Consumer Electronics, vol. 53, no. 1, pp. 17-22, 2007. [69] ETSI, "Digital Audio Broadcasting (DAB); DMB video service; User Application Specification," ETSI TS 102 428, V1.1.1, 2005. [70] E. ETSI, “300 744 v1.5.1, Digital Video Broadcasting (DVB); Framing structure, channel coding and modulation for digital terrestrial television,” European Standard (Telecommunications series), Valbonne, France, 2004. [71] J. McDougall, and S. Miller, “Sensitivity of wireless network simulations to a two-state Markov Model channel approximation,” in Proceedings of IEEE Global Telecommunications Conference 2003 (Globecom 2003), San Francisco, California, pp. 697-701, 1-5 December 2003. [72] H. Himmanen, A. Hazmi, and J. Paavola, “Comparison of DVB-H link layer FEC decoding strategies in a mobile fading channel,” in Proceedings of 17th Annual IEEE International Symposium on Personal, Indoor and Mobile Radio Communications (PIMRC 2006), Helsinki, Finland, pp. 1-5, 11-14 September,

170 References

2006. [73] C. Prehofer, and Q. Wei, “Active networks for 4G mobile communication: Motivation, architecture, and application scenarios,” Lecture Notes in Computer Science, vol. 2546, pp. 132-145, 2002. [74] I. Ganchev, M. O'Droma, M. Siebert et al., “A 4G generic ANWIRE system and service integration architecture,” ACM SIGMOBILE Mobile Computing and Communications Review, vol. 10, no. 1, pp. 13-30, 2006. [75] I.-T. F. N. TR-TERM, Terminological framework for NGN; ITU-T NGN FG Proceedings, 2005. [76] J. Yang, and Z. Ping, “MUSE: A vision for 4G service and architecture,” in Proceedings of IEEE 60th Vehicular Technology Conference (VTC 2004 Fall), Los Angeles, CA, USA, pp. 4842-4845, 26-29 September, 2004. [77] M. Frodigh, S. Parkvall, C. Roobol et al., “Future-generation wireless networks,” IEEE Wireless Communications, vol. 8, no. 5, pp. 10-17, 2001. [78] I. Ganchev, M. O'Drorna, J. Jakab et al., A New Global Ubiquitous Consumer Environment for 4G Wireless Communications In "Fourth-Generation (4G) Wireless Networks: Applications and Innovations": Information Science Publishing, 2009. [79] Y. Guo, and H. Chaskar, “Class-based quality of service over air interfaces in 4G mobilenetworks,” IEEE Communications Magazine, vol. 40, no. 3, pp. 132-137, 2002. [80] S. Hui, and K. Yeung, “Challenges in the migration to 4G mobile systems,” IEEE Communications Magazine, vol. 41, no. 12, pp. 54-59, 2003. [81] A. Misra, S. Das, A. Dutta et al., “IDMP-based fast handoffs and paging in IP-based 4G mobile networks,” IEEE Communications Magazine, vol. 40, no. 3, pp. 138-145, 2002. [82] M. O'Droma, and I. Ganchev, “Techno-Business Models for 4G,” in Proceedings of International Forum on 4G Mobile Communications, King's College, London, pp. 3.5.1-30, 20-21 May, 2004. [83] J. Sun, J. Sauvola, and D. Howie, “Features in future: 4G visions from a technical perspective,” in Proceedings of IEEE Global Telecommunications Conference, San Antonio, TX, USA, pp. 3533-3537, 25-29 November, 2001. [84] M. O'Droma, I. Ganchev, and A. Vinel, “The use of WiMAX as a carrier technology for Wireless Billboard Channels,” in Proceedings of International

171 References

Conference on Telecommunications (ICT 2008), St. Petersburg, Russa, pp. 423-426, 16-19 June, 2008. [85] M. Miozzo, M. Rossi, and M. Zorzi, “Routing Schemes in Heterogeneous Wireless Networks Based on Access Advertisement and Backward Utilities for QoS Support,” IEEE Communications Magazine, vol. 45, no. 2, pp. 67-73, 2007. [86] Y. Wang, P. Zhang, Y. Zhou et al., “Handover Management in Enhanced MIH Framework for Heterogeneous Wireless Networks Environment,” Wireless Personal Communications, vol. 52, no. 3, pp. 22, November, 2008 [87] I. Ganchev, and M. O'Droma, “New personal IPv6 address scheme and universal CIM card for UCWW,” in Proceedings of 7th International Conference on ITS Telecommunications, France, pp. 381-386, 6-8 June, 2007. [88] I. Ganchev, F. McEvoy, and M. O'Droma, “New 3P-AAA Architectural Framework and Supporting Diameter Application,” WSEAS Transactions on Communications, vol. 4, no. 4, pp. 176-185, 2005. [89] N. Wang, I. Ganchev, and M. O'Droma, “An architecture for the provision of Incoming Call Connection service in UCWW,” in Proceedings of IEEE 65th Vehicular Technology Conference (VTC 2007 Spring), Dublin, Ireland, pp. 649-653, 22-25 April, 2007. [90] I. Kumaran, and S. Kumaran, JINI technology: an overview: Prentice Hall PTR, 2001. [91] J. Ball, D. Carson, I. Evans et al., The Java EE 5 Tutorial: , 2006. [92] E. Guttman, “Service location protocol: Automatic discovery of IP network services,” IEEE Internet Computing, vol. 3, no. 4, pp. 71-80, 1999. [93] J. Rekesh, UPnP, Jini and Salutation-A look at some popular coordination framework for future network devices, California Software Labs, 1999. [94] M. Jeronimo, and J. Weast, UPnP design by example: a software developer's guide to universal plug and play: Intel Press, 2003. [95] S. Acharya, R. Alonso, M. Franklin et al., “Broadcast disks: data management for asymmetric communication environments,” in Proceedings of ACM SIGMOD international conference on Management of data, San Jose, California, United States, pp. 199-210, 22-25 May, 1995. [96] C. Kiss, "Composite capability/preference profiles (cc/pp): Structure and

172 References

vocabularies 2.0," W3C Working Draft, 2006. [97] Z. Ji, I. Ganchev, and M. O'Droma, “Formal Description of Services for Advertisement on Wireless Billboard Channels,” in Proceedings of 14th IEEE International Symposium on Consumer Electronics (ISCE 2010), Braunschweig, Germany, pp. 1-6, 7-10 June, 2010. [98] M. Carugi, B. Hirschman, and A. Narita, “Introduction to the ITU-T NGN focus group release 1: target environment, services, and capabilities,” IEEE Communications Magazine, vol. 43, no. 10, pp. 42-48, 2005. [99] R. Braden, D. Clark, and S. Shenker, "Integrated Services in the Internet Architecture: an Overview," IETF RFC 1633, 1994. [100] P. Overell, and D. Crocker, "Augmented BNF for Syntax Specifications: ABNF," RFC 4234, 2008. [101] ITU-T, "Rec. X.691 - Information technology – ASN.1 encoding rules: Specification of Packed Encoding Rules (PER). http://www.itu.int/ITUT/studygroups," 2002. [102] Z. Ji, I. Ganchev, and M. O'Droma, “Intelligent Software Architecture for the Service Layer of Wireless Billboard Channels,” in Proceedings of 6th Annual IEEE Consumer Communications & Networking Conference (CCNC09), Las Vegas, USA, pp. 172-173, 10-13 January, 2009. [103] J. Gosling, B. Joy, G. Steele et al., Java (TM) Language Specification: Addison-Wesley Professional, 2005. [104] J. Paterson, and J. Haddow, “Teaching Java: using an object-oriented database and the BlueJ IDE,” in Proceedings of 8th annual conference on Innovation and technology in computer science education, Thessaloniki, Greece, pp. 273-273, 30 June - 02 July, 2003. [105] K. Brown, G. Craig, G. Hester et al., Enterprise Java Programming with IBM Websphere: IBM Press, 2003. [106] E. Gamma, R. Helm, R. Johnson et al., Design patterns: elements of reusable object-oriented software: Addison-Wesley Professional, 1995. [107] JBOSS. "JBoss Community and JBoss Enterprise," http://www.jboss.org. [108] SUN. "Sun GlassFish Enterprise Server," http://www.sun.com/software/products/appsrvr. [109] IBM. "Software for SOA environments," www.ibm.com/websphere. [110] WebLogic. "Oracle WebLogic Portal," webservice.bea.com.

173 References

[111] Microsoft. "Internet Server API (ISAPI) Extensions," http://msdn.microsoft.com. [112] W3schools. "AJAX Introduction," http://www.w3schools.com. [113] D. Crockford, "RFC 4627: Javascript object notation," Technical report, IETF, 2006. [114] G. Goth, “The Google Web Toolkit shines a light on Ajax frameworks,” IEEE Software, vol. 24, no. 2, pp. 94-98, 2007. [115] SUN. "Sun Java Wireless Toolkit for CLDC," http://java.sun.com. [116] F. Bellifemine, A. Poggi, and G. Rimassa, “JADE: a FIPA2000 compliant agent development environment,” in Proceedings of AGENTS 2001, Montreal, Canada, pp. 216-217, 28 May-1 June, 2001. [117] T. Italia. "Jade - Java Agent DEvelopment Framework," http://jade.tilab.com. [118] G. Caire, and F. Pieri, Leap user guide: TILAB, 2003. [119] B. Whetten, L. Vicisano, R. Kermode et al., "Reliable multicast transport building blocks for one-to-many bulk-data transfer," IETF RFC3048, 2001. [120] M. Luby, J. Gemmell, L. Vicisano et al., "Asynchronous layered coding (ALC) protocol instantiation," IETF RFC 3450, 2002. [121] V. Roca, "FCAST: Scalable Object Delivery on top of the ALC Protocol," IETF RMT Working Group, 2007. [122] T. Paila, M. Luby, R. Lehtonen et al., "FLUTE-File Delivery over Unidirectional Transport," IETF RFC 3926, October 2004. [123] M. Luby, and L. Vicisano, "Compact forward error correction (FEC) schemes," IETF RFC3695, 2004. [124] G. Faria, J. A. Henriksson, E. Stare et al., “DVB-H: Digital broadcast services to handheld devices,” Proceedings of the IEEE, vol. 94, no. 1, pp. 194-209, 2006. [125] E. ETSI, “301-192 Digital Video Broadcasting (DVB) V1.4.1,” DVB specification for data broadcasting, 2004. [126] T. ETSI, "102 377 v1.2.1: Digital Video Broadcasting (DVB)," DVB-H Implementation Guidelines, 2005. [127] UDcast. http://www.udcast.com. [128] TeamCast. http://www.teamcast.com. [129] D. Dalalah, L. Cheng, and G. Tonkay, “Modeling end-to-end wireless lossy channels: A Finite-State Markov approach,” IEEE Transactions on Wireless

174 References

Communications, vol. 7, no. 4, pp. 1236-1243, 2008. [130] S. R. Kundu, K. Basu, and S. K. Das, “Finite state Markov model for effective bandwidth calculation in wireless packet networks,” in Proceedings of Third International Symposium on Modeling and Optimization in Mobile, Ad Hoc, and Wireless Networks, Trentino, Italy, pp. 351-357, 3-7 April, 2005. [131] H. Wang, and N. Moayeri, “Finite-state Markov channel - a useful model for radio communication channels,” IEEE Transactions on Vehicular Technology, vol. 44, no. 1, pp. 163-171, 1995. [132] Q. Q. Zhang, and S. A. Kassam, “Finite-state Markov model for Rayleigh fading channels,” IEEE Transactions on Communications, vol. 47, no. 11, pp. 1688-1692, 1999. [133] J. Yun, and M. Kavehrad, “Markov error structure for throughput analysis of adaptive modulation systems combined with ARQ over correlated fading channels,” IEEE Transactions on Vehicular Technology, vol. 54, no. 1, pp. 235-245, 2005. [134] J. Proakis, Digital communications: Mc-GrawHill International Editions, 2001. [135] J. Larmouth, ASN.1 complete: Morgan Kaufmann Pubication, 2000. [136] W. Crawford, and J. Kaplan, J2EE design patterns: O'Reilly & Associates, Inc, 2003. [137] G. Klyne, J. Carroll, and B. McBride, "Resource description framework (RDF): Concepts and abstract syntax," W3C recommendation, 2004. [138] P. Buitelaar, D. Olejnik, and M. Sintek, “A protege plug-in for ontology extraction from text based on linguistic analysis,” Lecture Notes in Computer Science, vol. 3053, pp. 31-44, 2004. [139] J. Greenfield, and K. Short, Software Factories: Assembling Applications with Patterns, Frameworks, Models & Tools: John Wiley & Sons, Inc, 2004. [140] T. Imielinski, S. Viswanathan, and B. R. Badrinath, “Data on air: Organization and access,” IEEE Transactions on Knowledge and Data Engineering, vol. 9, no. 3, pp. 353-372, May, 1997. [141] T. Imielinski, S. Viswanathan, and B. Badrinath, “Energy efficient indexing on air,” in Proceedings of ACM-SIGMOD, Intl Conference on Management of Data, Minnesota, pp. 25-36, 24-27 May, 1994. [142] J. Gennari, M. Musen, R. Fergerson et al., “The evolution of Protege: an

175 References

environment for knowledge-based systems development,” International Journal of Human-Computer Studies, vol. 58, no. 1, pp. 89-123, 2003. [143] L. Padgham, and M. Winikoff, Developing intelligent agent systems: a practical guide: Wiley, 2004. [144] W. Humphrey, PSP: A Self-Improvement Process for Software Engineers-Instructor's Guide: Pittsburgh, PA: Software Engineering Institute, Carnegie Mellon University, 2005. [145] L. Crispin, “Driving software quality: How test-driven development impacts software quality,” IEEE Software, vol. 23, no. 6, pp. 70-71, 2006. [146] P. Coad, E. LeFebrve, and J. De Luca, Feature-driven development: Prentice Hall PTR, 1999. [147] G. Booch, J. Rumbaugh, and I. Jacobson, Unified Modeling Language User Guide, The (Addison-Wesley Object Technology Series): Addison-Wesley Professional, 2005. [148] V. Massol, and T. Husted, JUnit in action: Manning Publications, 2003. [149] O. Gospodnetic, and E. Hatcher, Lucene in action: a guide to the Java search engine: Manning Publications, 2005. [150] B. McBride, “Jena: A semantic web toolkit,” IEEE Internet Computing, vol. 6, no. 6, pp. 55-59, 2002. [151] L. Rizzo, “Effective erasure codes for reliable computer communication protocols,” ACM SIGCOMM Computer Communication Review, vol. 27, no. 2, pp. 24-36, 1997. [152] N. Josuttis, The C++ standard library: a tutorial and reference: Addison-Wesley Longman Publishing Co., Inc, 1999. [153] Z. Ji, I. Ganchev, and M. O'Droma, “An iWBC-MIDP Client Application Design for Use in WBCs,” in Proceedings of IEEE 71th Vehicular Technology Conference (VTC2010-Spring), Taiwan, pp. 1-4, 16-19 May, 2010 (Accepted). [154] SUN. "Mobile Information Device Profile (MIDP)," http://java.sun.com/products/midp. [155] Google. "Android Platform," http://code.google.com/android. [156] H. Joki, and J. Paavola, “A novel algorithm for decapsulation and decoding of DVB-H link layer forward error correction,” in Proceedings of IEEE International Conference on Communications, 2006 (ICC 2006), Istanbul, Turkey, pp. 412-416, 11-15 June, 2006.

176 References

[157] DiBcom. http://www.dibcom.info. [158] L. Chen, and C. Lee, “Design of a DVB-T/H COFDM Receiver for Portable Video Applications,” IEEE Communications Magazine, vol. 45, no. 8, pp. 112-121, 2007. [159] G. Shepherd, and D. Kruglinski, Programming with Microsoft Visual C++. NET: core reference: Microsoft Press, 2003. [160] D. Kruglinski, Inside Visual C++: Microsoft Press Redmond, 1997. [161] W. Palm, Introduction to MATLAB 7 for Engineers: McGraw-Hill Science/Engineering/Math, 2004. [162] Mathworks. "Simulink - Simulation and Model-Based Design," http://www.mathworks.com. [163] COST 207 Report, Digital land mobile radio communications, commission of European Communities, Directorate General, Telecommunications, Information Industries and Innovation, Luxemburg, 1989. [164] Audemat. http://www.audemat-aztec.com. [165] T. Rappaport, Wireless communications: principles and practice: Prentice Hall PTR, 2002. [166] G. Sharma, A. Hassan, and A. Dholakia, “Performance evaluation of burst-error-correcting codes on a Gilbert-Elliott channel,” IEEE Transactions on Communications, vol. 46, no. 7, pp. 846-849, 1998. [167] L. R. Wilhelmsson, “Evaluating the performance of Raptor codes for DVB-H by using the Gilbert-Elliott channel,” in Proceedings of IEEE 66th Vehicular Technology Conference (VTC 2007 Fall), Baltimore, USA, pp. 1932-1936, 30 September - 3 October, 2007. [168] A. Goldsmith, Wireless communications: Cambridge Univ Press, 2005. [169] X. Dong, and N. Beaulieu, “Average level crossing rate and average fade duration of selection diversity,” IEEE Communications Letters, vol. 5, no. 10, pp. 396-398, 2001. [170] I. Syst, “Level crossing rate and average fade duration for pure selection and threshold selection diversity-combining systems,” International Journal of Communication Systems, vol. 14, no. 10, pp. 897-907, 2001. [171] N. Beaulieu, and X. Dong, “Level crossing rate and average fade duration of MRC and EGC diversity in Ricean fading,” IEEE Transactions on Communications, vol. 51, no. 5, pp. 722-726, 2003.

177 References

[172] H. Joki, and J. Poikonen, Analysis and Simulation of DVB-H Link Layer, TUCS Technical Report, 2005. [173] Z. Ji, I. Ganchev, and M. O'Droma, “Wireless Billboard Channel over T-DMB,” in Proceedings of China-Ireland International Conference on Information and Communications Technologies (CIICT 2009) Maynooth, Ireland, pp. 57-60, 19-21 August, 2009.

178 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

APPENDIX A AN EXAMPLE OF SD ON WBC: STRUCTURE, ENCODING AND DECODING

A.1. Introduction

This appendix describes the use and implementation of a sample SD on the WBC, including the notation structure, encoding and decoding architecture. The example selects a news teleservices SD for demonstration purpose.

A.2. ASN.1 Notation

The news SD is composed of two components - a template and parameters. The code of the news template is as follows:

WBCTSTS DEFINITIONS IMPLICIT TAGS ::= BEGIN WBCTSNews ::= SEQUENCE { name [0] IA5String(SIZE(1..64)), software [1] TSSoftwareInfo, newsTypes [2] BIT STRING{international(0), national(1), local(2)}, noSubscription [3] NewsNoSubscription, subscriptions [4] SEQUENCE OF NewsSubscription, advertiserText [5] IA5String OPTIONAL, advertiserURL [6] IA5String OPTIONAL } NewsNoSubscription ::= SEQUENCE { newsArticles [0] Currency OPTIONAL, archiveArticles [1] Currency OPTIONAL, breakingNewsAlerts [2] Currency OPTIONAL } NewsSubscription ::= SEQUENCE { subscriptionLength [0] ENUMERATED{day, week, month, year}, cost [1] Currency, newsArticles [2] Currency OPTIONAL, archiveArticles [3] Currency OPTIONAL, breakingNewsAlerts [4] Currency OPTIONAL } TSSoftwareInfo ::= SEQUENCE { serviceSpecific [0] SEQUENCE{ latestVersion INTEGER, oldestVersion INTEGER, dlURL IA5String } OPTIONAL,

179 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

http [1] SEQUENCE{ address IPv6Addr, port PortNumber } OPTIONAL, sip [2] SEQUENCE{ address IPv6Addr, port PortNumber } OPTIONAL, h323 [3] SEQUENCE{ address IPv6Addr, port PortNumber } OPTIONAL } END

In this example, the WBCTSNews is defined as a SEQUENCE type [135]. It includes seven fields. To define multiple subscriptions, the subscriptions field is defined as the SEQUENCE type.

The code of the sample is as follows:

SampleWBCTSNews DEFINITIONS ::= BEGIN IMPORTS AWBCTSNews FROM WBCTSNews; valueWBCTSNews AWBCTSNews ::= { service-Type{ division '600001FD'H, category '600001FD'H, type '600001FD'H, version '600001FD'H }, ccpp defaultCCPP : {'500001FD'H,'500001FD'H,'600001FD'H,'600001FD'H,'600001FD'H} , length 456, attributes { name "aNews", software{ serviceSpecific{ latestVersion 10, oldestVersion 9, dlURL "http://wwbc/wbc.jar" }, http{ address '32303033313132313136333934323232'H,--0x02, port 111 }, sip{ address '32303033313132313136333934323232'H,--0x02, port 222 }, h323{ address '32303033313132313136333934323232'H,--0x02, port 333 } }, newsTypes international, noSubscription { newsArticles "d", archiveArticles "d", breakingNewsAlerts "d" },

180 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

subscriptions { {subscriptionLength day, cost "13", newsArticles "e", archiveArticles "e", breakingNewsAlerts "e"}, {subscriptionLength week, cost "120", newsArticles "f", archiveArticles "f", breakingNewsAlerts "f"} }, advertiserText "this is a test", advertiserURL "http://wbc" } } END A.3. SD’s POJO

As described in Chapter 3, the WBC system includes a distributed enterprise application on the WBC-SP side and a portable receiver application on the MT side. The SDs on the application should be described as POJOs. Like the ASN.1 notation, the SD’s POJO also includes two components - a template POJO and parameters. The code of the news template POJO is as follows: package wbcts.wbctsnews; import com.oss.asn1.*; import com.oss.metadata.*; import wbcts.*; /* Define the ASN1 Type AWBCTSNews from ASN1 Module WBCTSNews. */ public class AWBCTSNews extends Sequence { /* The default constructor. */ public AWBCTSNews() { } /* Construct with AbstractData components. */ public AWBCTSNews(Service_Type service_Type, CCPP ccpp, SDLength length, Attributes attributes) { setService_Type(service_Type); setCcpp(ccpp); setLength(length); setAttributes(attributes); } /* Construct with required components. */ public AWBCTSNews(Service_Type service_Type, CCPP ccpp, Attributes attributes) { setService_Type(service_Type); setCcpp(ccpp); setAttributes(attributes); } public void initComponents() { mComponents[0] = new Service_Type(); mComponents[1] = new CCPP(); mComponents[2] = new SDLength(); mComponents[3] = new Attributes(); } // Instance initializer { mComponents = new AbstractData[4]; } // Method to create a specific component instance public AbstractData createInstance(int index) { switch (index) { case 0: return new Service_Type();

181 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

case 1: return new CCPP(); case 2: return new SDLength(); case 3: return new Attributes(); default: throw new InternalError("AbstractCollection.createInstance()"); } } // Methods for field "service_Type" public Service_Type getService_Type() {return (Service_Type) mComponents[0]; } public void setService_Type(Service_Type service_Type) {mComponents[0] = service_Type; } // Methods for field "ccpp" public CCPP getCcpp() {return (CCPP) mComponents[1]; } public void setCcpp(CCPP ccpp) {mComponents[1] = ccpp; } // Methods for field "length" public SDLength getLength() {return (SDLength) mComponents[2];} public void setLength(SDLength length) {mComponents[2] = length; } public boolean hasLength() {return componentIsPresent(2); } public void deleteLength() {setComponentAbsent(2); } // Methods for field "attributes" public Attributes getAttributes() {return (Attributes) mComponents[3];} public void setAttributes(Attributes attributes) { mComponents[3] = attributes; } /*Initialize the type descriptor. */ private static final SequenceInfo c_typeinfo = new SequenceInfo(new Tags( new short[] { 0x0010 }), new QName("wbcts.wbctsnews", "AWBCTSNews"), new QName("WBCTSNews", "AWBCTSNews"), 14354, null, new Fields( new SequenceFieldInfo[] { new SequenceFieldInfo(new TypeInfoRef(new QName( "wbcts.wbctsnews", "Service_Type")), "service-Type", 0, 2, null), new SequenceFieldInfo(new TypeInfoRef(new QName( "wbcts.wbctsnews", "CCPP")), "ccpp", 1, 2, null), new SequenceFieldInfo(new TypeInfoRef(new QName( "wbcts.wbctsnews", "SDLength")), "length", 2, 3, null), new SequenceFieldInfo(new TypeInfoRef(new QName( "wbcts.wbctsnews", "Attributes")), "attributes", 3, 2, null) }), 0, new TagDecoders(new TagDecoder[] { new TagDecoder( new TagDecoderElement[] { new TagDecoderElement( (short) 0x0010, 0) }), new TagDecoder(new TagDecoderElement[] { new TagDecoderElement((short) 0x8000, 1), new TagDecoderElement((short) 0x8001, 1) }), new TagDecoder(new TagDecoderElement[] { new TagDecoderElement((short) 0x0002, 2), new TagDecoderElement((short) 0x0010, 3) }), new TagDecoder( new TagDecoderElement[] { new TagDecoderElement( (short) 0x0010, 3) }) }), 0); /* Get the type descriptor (TypeInfo) of 'this' AWBCTSNews object. */ public TypeInfo getTypeInfo() {return c_typeinfo; } /* Get the static type descriptor (TypeInfo) of 'this' AWBCTSNews object. */ public static TypeInfo getStaticTypeInfo() {return c_typeinfo; } public boolean isPDU() { return true; } } // End class definition for AWBCTSNews

182 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

The corresponding POJO code of the sample is as follows: package wbcts.samplewbctsnews; import com.oss.asn1.*; import com.oss.metadata.*; import wbcts.*; public abstract class SampleWBCTSNews extends ASN1Module { // Value references public static final wbcts.wbctsnews.AWBCTSNews valueWBCTSNews = init_valueWBCTSNews(); private static wbcts.wbctsnews.AWBCTSNews init_valueWBCTSNews() { return new wbcts.wbctsnews.AWBCTSNews ( new wbcts.wbctsnews.Service_Type ( new com.oss.asn1.OctetString ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD }), new com.oss.asn1.OctetString ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ), new com.oss.asn1.OctetString ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ), new com.oss.asn1.OctetString ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ) ), wbcts.wbctsnews.CCPP.createCCPPWithDefaultCCPP ( new wbcts.wbctsnews.CCPP.DefaultCCPP ( new wbcts.wbctsnews.CCPPProperty[] { new wbcts.wbctsnews.CCPPProperty ( new byte[]{ (byte)0x50, (byte)0x00, (byte)0x01, (byte)0xFD}), new wbcts.wbctsnews.CCPPProperty ( new byte[] { (byte)0x50, (byte)0x00, (byte)0x01, (byte)0xFD } ), new wbcts.wbctsnews.CCPPProperty ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ), new wbcts.wbctsnews.CCPPProperty ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ), new wbcts.wbctsnews.CCPPProperty ( new byte[] { (byte)0x60, (byte)0x00, (byte)0x01, (byte)0xFD } ) } ) ), new wbcts.wbctsnews.SDLength(456), new wbcts.wbctsnews.Attributes ( new com.oss.asn1.IA5String ( "aNews" ), new wbcts.wbctsts.TSSoftwareInfo ( new wbcts.wbctsts.TSSoftwareInfo.ServiceSpecific ( new com.oss.asn1.INTEGER(10), new com.oss.asn1.INTEGER(9), new com.oss.asn1.IA5String ( http://wwbc/wbc.jar ) ), new wbcts.wbctsts.TSSoftwareInfo.Http ( new wbcts.wbctsts.IPv6Addr ( new byte[] { (byte)0x32, (byte)0x30, (byte)0x30, (byte)0x33, (byte)0x31, (byte)0x31, (byte)0x32, (byte)0x31, (byte)0x31, (byte)0x36, (byte)0x33, (byte)0x39, (byte)0x34, (byte)0x32, (byte)0x32, (byte)0x32 } ), new wbcts.wbctsts.PortNumber(111)), // Other Sip or H323 address new wbcts.wbctsts.TSSoftwareInfo.Sip ( new wbcts.wbctsts.IPv6Addr (), new wbcts.wbctsts.PortNumber(222) ), new wbcts.wbctsts.TSSoftwareInfo.H323 ( new wbcts.wbctsts.IPv6Addr ( ),

183 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

new wbcts.wbctsts.PortNumber(333) ) ), new wbcts.wbctsts.WBCTSNews.NewsTypes ( new byte[]{ (byte)0x80},1 ), new wbcts.wbctsts.NewsNoSubscription ( new wbcts.wbctsts.Currency ("d"), new wbcts.wbctsts.Currency ("d"), new wbcts.wbctsts.Currency ("d") ), new wbcts.wbctsts.WBCTSNews.Subscriptions ( new wbcts.wbctsts.NewsSubscription[] { new wbcts.wbctsts.NewsSubscription ( wbcts.wbctsts.NewsSubscription.SubscriptionLength.day, new wbcts.wbctsts.Currency ("13"), new wbcts.wbctsts.Currency ("e"), new wbcts.wbctsts.Currency ("e"), new wbcts.wbctsts.Currency ("e") ), new wbcts.wbctsts.NewsSubscription ( wbcts.wbctsts.NewsSubscription.SubscriptionLength.week, new wbcts.wbctsts.Currency ("120"), new wbcts.wbctsts.Currency ("f"), new wbcts.wbctsts.Currency ("f"), new wbcts.wbctsts.Currency ("f")) } ), new com.oss.asn1.IA5String ("this is a test"), new com.oss.asn1.IA5String ("http://wbc") ) ); } }

The ASN.1-PER encoder/decoder depends on the Java classes used for encoding/decoding of a Java SD object into/from PER octets.

The encoding process is as follows:

Wbc.initialize () ; Coder coder = Wbc.getPERCoder () ; ByteArrayOutputStream sink= new ByteArrayOutputStream () ; SampleWBCTSNews Sample = new SampleWBCTSNews () ; coder.encode (Sample. valueWBCTSNews, sink) ; byte [ ] encoding = sink. toByteArray () ; sink.close () ;

The decoding process is shown as follows:

Wbc.initialize () ; Coder coder = Wbc.getPERCoder () ; InputStream source = new ByteArrayInputStream(encoding); decodedData = (AWBCANCSCellularUMTS) coder.decode(source, decodedData); Service_Type xaService_Type = decodedData.getService_Type(); CCPP xCCPP = decodedData.getCcpp(); SDLength xSDLength = decodedData.getLength(); Attributes xAttributes = decodedData.getAttributes(); String _accppsequence = "";

184 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

ArrayList alist = new ArrayList(); if (xCCPP.hasDefaultCCPP()) { CCPP.DefaultCCPP g = new CCPP.DefaultCCPP(); g = (CCPP.DefaultCCPP) xCCPP.getChosenValue(); int size = g.getSize(); for (int i = 0; i < size; i++) { _accppsequence = _accppsequence + bytetostring(g.get(i).byteArrayValue()) + ";"; alist.add(bytetostring(g.get(i).byteArrayValue())); } } source.close();

A.4. Software Architecture for Encoding and Decoding

A.4.1 SD Encoding Design on WBC-SP Node

The WBC-SP node’s software architecture consists of three tiers [102]. This section focuses on SD’s encoding process module. Figure A.1 depicts the time-sequence UML diagram of a xSP submitting a SD to the WBC-SP enterprise application.

WBC-SP Enterprise Application Java EE Enviroment MAS ASN.1 PER Enviroment Encoder Server Presentation Business Persistence xSP SD Web Tier Tier Tier PAA Agent

Submit a SD via Send SD WBC-SP portal POJO to SD Encoder EJB Home object application SDManager SDManager saves POJO Reference of Home Object to Database JNDI SDManager creates a new BlackBoard Object,then Sends it to PAA agent ACL ASK Create EJB Reference EJB Home Object Object

Create EJB Bean Remote Encoding EJB ACL Save Result Object Invoke SD Update encoding Send BlackBoard to View process Update UI SDManager

Figure A.1: The SD's Encoding Time-Sequence UML diagram In Figure A.1, the xSP submits a SD via the WBC-SP portal application. In the presentation web tier, a POJO is built in the controller, and then sent to the business tier. The SDManager is the service manager, which saves the POJO to an OO database, creates a new blackboard object, and then sends it to the Personal Assistance Agent

185 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

(PAA). The PAA acts as a gateway agent in the WBC-SP enterprise application. It receives the blackboard object, formats an ACL message, and then sends the message to the SD agent for encoding. The latter requests creating a home object, which then creates the EJB object. With the reference of EJB object, the SD agent invokes the SD encoding process to generate the byte stream.

A.4.2 SD Decoding Design on MU Node

Considering that the MT node runs a light-weight Java application (iWBC application [153]), the decoding process should be processed in an efficient way. Figure A.2 shows the time-sequence UML diagram of the iWBC content provider receiving a new WBC segment and decoding it to SDs. The WBC segment agent monitors the WBC when the MU turns on his/her MT. When a new interesting WBC segment is broadcast, the SD agent runs the decoding behaviour to decode the WBC segment to SDs with the ASN.1 decoder APIs. The decoder class design pattern follows the singleton design pattern to enable light-weight designing. After decoding, the PAA saves the POJO to the OO database. Then the PAA creates a blackboard object and sends it to the SDManager in the business tier. Finally, the MT UI will receive an update message and the main page of a favorite category will be automatically updated.

iWBC Content Provider

Java SE Enviroment MAS ASN.1 PER Enviroment Decoder API Presentation Business Persistence MU Tier Tier Tier PAA Segment Agent

New -INST Segment Decoder +INST: Decoder Decoding +Wbcts.initialize() +static {coder = Wbcts.PERCoder();} SD POJO ACL +coder.decode(source, decodedData) Save Update Send BlackBoard to View Update SDManager UI

Figure A.2: The SD's Decoding Time-Sequence UML Diagram

186 Appendix A. An Example of SD on WBC: Structure, Encoding and Decoding

A.5. Conclusion

A WBC SD's structure, encoding and decoding design and implementation have been described in this appendix. Using the ASN.1 notation to describe the wireless service advertisement is a flexible solution as the ASN.1 is a standard notation language which is used to represent data in the telecommunication protocols. The Packed Encoding Rules (PER) present a space efficient method to encode SDs to a byte stream because compared with the other encoding rules, PER uses only the very minimum of bits to encode fields. The details of SD structure, encoder and decoder have been studied. In order to integrate the SD encoder into the WBC-SP enterprise application and the decoder - into the WBC MU portable application, two novel software architectures have been designed and realized.

187 Appendix B. Broadcast Disks

APPENDIX B BROADCAST DISKS

B.1. Introduction

This appendix describes the broadcast disks algorithm and the proof of formula 4.1.

B.2. Algorithm

This section introduces the broadcast disks algorithm. It is an off-line data scheduling algorithm for reducing data access time [95] in an asymmetric communication environment. It is a popular technique for broadcasting a non-uniformly accessed WBC segment (data unit). The broadcast disk algorithm divides the data into broadcast disks and assigns a particular broadcast time to a broadcasting cycle, i.e., those disks ‘spin’ at different speeds. Each disk contains a number of WBC segments, and the size of the WBC segment is equal. The higher-demand WBC segments are usually assigned to a higher speed disk. This is suitable for the WBC hot segment broadcasting. A minor cycle is defined in broadcast disk algorithm, which contains of one chunk (the broadcast disk element) from each disk.

The broadcast disk algorithm is shown in Figure B.1. It include five steps:

 Order the WBC segment from hottest to coldest by the access times.  Partition the WBC segments into multiple disks. The WBC segments in each disk should be with similar access times.  Choose the relative frequency for each disk.  Split each disk into a number of chunks and assign a chunk number. For

example, Cij, refer j-th WBC segment in disk i.  Run the following algorithm: for(int i=0;i

broadcast WBC segment C j(mod i number ( chunks )), j } }

188 Appendix B. Broadcast Disks

Data Set HOT a bcdefg COLD

Disks Fast a bc defg Slow D1 D2 D3

Chunks a b c d e f g

C1,1 C2,1 C2,2 C3,1 C3,2 C3,3 C3,4

A Broadcast Cycle a b d a c e a b facg

C1,1 C2,1 C3,1 C1,1 C2,2 C3,2 C1,1 C2,1 C3,3 C1,1 C2,2 C3,4

Minor Cycle

Figure B.1: Deriving a Broadcast Disk Algorithm B.3. Proof of Formula 4.1

F As listed in table 4.1, the n denotes as the n-th WBC segment broadcasting time,

Fn >1. M denotes the total number of distinct WBC segments. The total number of data WBC segments in a broadcasting cycle is obtained as:

M NF  j1 n (B.1)

The inter-arrival gaps for n-th WBC segment denotes as Ig,n , one WBC segment time slot denotes as 1, z is the number of WBC segments between the WBC segment where clients begin monitoring channels and the next copy of the n-th WBC segment.

Thus the Tn can be calculated as:

1 Fn Ign, 1 Tz I ngs1 z0 ,n N 2 I 1 1 Fi 1 gn,  II 1 0 I . (B.2) s1 gn,, gn gn , 2N 22 

1 F 2  i I 1 . s1 gn, 2N B.4. Conclusion

Within this appendix, the broadcast disks algorithm has been introduced and a proof of Formula 4.1 has been provided.

189 Appendix C. Wireless Billboard Channels over T-DMB

APPENDIX C WIRELESS BILLBOARD CHANNELS OVER T-DMB

C.1. Introduction

T-DMB is a new multimedia broadcasting technique developed by Korea in 2005 based on the European DAB standard [63, 64, 69]. Compared with DAB, T-DMB adds a Reed-Solomon (RS) Forward Error Correction (FEC) to improve communication in wireless channels and uses a highly efficient MPEG4 part 3 bit sliced arithmetic coding (BSAC) or advanced audio codec (HE AAC) to replace the DAB's MPEG Audio Layer 2 (MP2) audio codec scheme [9, 65]. To improve spectrum efficiency, T-DMB uses the OFDM modulation scheme, and supports a single frequency network (SFN). T-DMB is well suited as an alternative carrier for WBC.

The 'WBC over T-DMB' system could be developed along the same three layers: a service layer, a link layer, and a physical layer.

The error protection of service advertisements is an important issue in WBCs, since even a single bit error may cause a full WBC segment to be discarded [11]. In the 'WBC over T-DMB' system, the physical layer reliability is ensured by a RS code, convolutional interleaver, punctured convolutional code, and inner interleaver. The service layer reliability is ensured by an ADP [4]. For extra error protection, a DVB-H compatible link layer is proposed in this appendix to enable IPDC [124].

Four T-DMB transmission modes are defined by ETSI 300-401 [64], with 1536, 384, 192, and 768 subcarriers in one OFDM symbol respectively. The coverage of mode I and IV is bigger than that of mode II and III. Mode I can be used in band I (47-68MHz), band II (87.5-108MHz), and band III (174-230MHz); mode II and IV are suitable for band I, II, III, IV (470-582 MHz) & V (582-862MHz) and Band L (1452-1490MHz); and mode III is suited for satellite broadcasting. These modes enable ‘WBC over DAB’ running a different mode in a different area. This appendix focuses on WBCs established over T-DMB and operating in all four transmission modes [9, 173].

190 Appendix C. Wireless Billboard Channels over T-DMB

C.2. T-DMB Transmission Frame

Figure C.1 shows the structure of the T-DMB transmission frame.

Transmission frame

non time-interleaved time-interleaved

Synchronization Fast Information Main Service Channel (MSC) Channel Channel (FIC)

FIB ...... FIB CIF ...... CIF

Fast Information Blocks Common Interleaved Frames (FIBs) (CIFs)

Figure C.1: The Structure of the T-DMB Transmission Frame

Three channels are used:

 Main service channel (MSC) carries data services. The MSC consists of Common Interleaved Frames (CIFs);  Fast information channel (FIC) carries multiplex configuration information (MCI) and other information for the user to access broadcasting information. The FIC consists of Fast Information Blocks (FIBs);  Synchronization channel carries demodulator information. The general transport characteristics of the T-DMB transmission frame are shown in Table C.1.

C.2. 'WBC over T-DMB' IPDC Mode

The T-DMB standard supports two operational modes [9, 68, 173]: a stream mode - for broadcasting audio stream datasets, and a packet mode - for IP packets broadcasting. However, the stream mode is not suitable for WBCs, whereas the packet mode does not provide sufficient error protection for WBC data broadcasting in wireless fading channels. Thus, a DVB-H compatible module [9] was added in T-DMB as the link layer operating in a new 'WBC over T-DMB' IPDC mode (Figure C.2). With the strong outer layer of a FEC scheme, i.e., MPE-FEC solution, the reliability of 'WBC over T-DMB' can be improved without changing the T-DMB standard.

191 Appendix C. Wireless Billboard Channels over T-DMB

Table C.1: The Characteristics of the T-DMB Transmission Frame

Mode I II III IV

Duration (ms) 96 24 24 48

Number of FIBs 12 3 4 6

Number of CIFs ( NCIF ) 4 1 1 2

Number of OFDM symbols per Frame 76 76 153 76

Number of useful carriers per symbol ( N used ) 1536 384 192 768

Number of OFDM symbols in MSC 72 72 144 72 ( NOFDM_MSC )

Number of OFDM symbols in FIC 3 3 8 3 ( NOFDM_FIC )

NULL Symbol Duration ( s ) 2656 664 345 1328

'WBC over T-DMB' T-DMB T-DMB IPDC Mode Stream Mode Packet Mode

WBC-ADP Higher Layer

BSAC/ IP Packets Cache IP Packet HE AAC/ MPEG-4 Segments Index Table AVC/H.264 MSC Source Data Group MPE-FEC Coding (DG)

TS Packet Mode

Channel Coder FIC MSC Multiplexer

Transmission Multiplexer

OFDM T-DMB Signal Transmitter

Figure C.2: The New 'WBC over T-DMB' IPDC Mode vs. Standard T-DMB Stream Mode and Packet Mode

C.3. Software Testbed Design

The WBC service layer and link layer have been detailed in Chapters 4, 5, and 6. This

192 Appendix C. Wireless Billboard Channels over T-DMB section focuses on the 'WBC over T-DMB' physical layer testbed design and implementation. Based on the DAB ETSI 300-401 [64] and TS 102-427 [63] standards. The T-DMB simulator implements all compulsory features with Matlab as shown in Figure C.3. Considering the ‘WBC over T-DMB’ broadcasting advertisement dataset, the audio/video coding is not considered in this research.

Similar to DVB-H, T-DMB also build with three basic components, a transmitter, a channel, and a receiver. As the ‘WBC over T-DMB’ channel part is similar to ‘WBC over DVB-H’, this chapter focuses on the transmitter and receiver.

Time RS Convolutional Convolutional Bit 1 ScramblerSlicer Encoder Interleaver MUX QPSK Encoder interleaver (ony T -DMB ) (ony T -DMB) Input TS Packets u QPSK Frequency OFDM Differential _modulator Modulator y interleavor modulator Baseband PRS

PRS_generator y Rayleigh Delay Fading z^-N

Tx BER Error Rate ------Calculation Rx Total Bits AWGN Total Errors

Output TS Packets RS Convolutional fft 1 Decoder Bit QPSK Differential Frequency OFDM Descrambler de -Interleaver DeMUX synchronization u (only Viterbi Decoder Deinderleaver DeMapper demodulator deinterleavor Demodulator (ony T -DMB ) y T-DMB) Viterbi Decoder

Figure C.3: The 'WBC over T-DMB' Matlab PHY Testbed

C.3.1 Transmitter

C.3.1.1 Source

In ‘WBC over T-DMB’, the data is transmitted in transport stream (TS) packets. In order to be compatible with the interleaver, x TS packets should be broadcast within y OFDM symbols. The value of x is obtained from:

188xyKN / /8 / M  Nused  CR (C.1) where CR is the convolutional code rate. N and K are Reed-Solomon (RS) block code parameters, equal to 204 and 188 resepctively. M is the modulation index (equal to 2 for QPSK). For example, x=16, for y={17, 68, 136, 34} in T-DMB mode {I, II, III, IV} respectively.

C.3.1.2 Encoder and Interleaver

The channel encoder and interleaver blocks include the following function modules:

193 Appendix C. Wireless Billboard Channels over T-DMB

The RS encoder module, outer interleaver module and the Galois field to bit convertor module are same to DVB-H.

In the convolutional encoder module, the above output is sent to the convolutional encoder with constraint length 7 (poly2trellis(7,[177 133])).

In the inner bit interleaver modules, an interleaving algorithm is applied to the output of the convolutional codeword with the parameters Nrow_bit =16 and Slope_bit obtained from:

Slope_bit 188x N/K/CR  8/NCIF /Nrow_bit (C.2) In the MUX module, the transmission frame (without NULL OFDM symbol) is produced by three vectors, the FIC bit vector, the inner interleaver outputting bit vector, and the padding bit vector. For easy implementation, the FIC and other service bits are replaced by random bits. The FIC bit vector length is equal to:

FIC bit Length NOFDM_FIC N used M (C.3) And the length of the padding bit section is equal to:

SR N 8 (C.4) Padding bit Length (NOFDM_MSC - ) Nused M KrNused  M The output MUX module is a bit vector.

C.3.1.3 Modulator

The input is first reshaped and mapped with a QPSK modulator algorithm, followed by differential modulation, zero IF insertion operation, and finally frequency interleaving and OFDM modulation (IFFT) operations for OFDM frame generation. After inserting a cyclic prefix symbol and a NULL symbol, an OFDM frame is generated and sent to the broadcasting channel.

C.3.2 Receiver

The receiver process algorithm runs in reverse mode as transmitter. It includes a de-modulator block and a de-interleaver and decoder blocks.

The de-modulator block includes a frame de-building module, an OFDM de-modulation module, a frequency de-interleaver module, a differential de-modulation module, and a de-mapping module.

194 Appendix C. Wireless Billboard Channels over T-DMB

The de-interleaver and decoder block includes an inner de-interleaving module, an convolutional decoder module, a bit to Galois field convertor module, an outer de-interleaver module, and an outer RS decoder module.

C.4. Results

The IPER is an important criterion for measuring the performance of 'WBC over T-DMB'. For the purposes of simulation, at the service layer 5000 distinct WBC segments were produced by means of the ADP protocol and sent down to the link layer for broadcasting using the following parameters: WBC segment size - 4016B, IP packet length - 1024B, ADP (n=6, k=4). To test the IPER in offline mode, the link layer first stores all IP packets into a database, and processes them one by one. The MPE-FEC frame has 1024 rows and 255 columns. At the physical layer, the following parameters were used: WBC source rate - 384 Kbps, data length in 24ms - 9216 bits, convolutional code rate - 1/2, interleaving depth - 16, cyclic prefix ratio - 0.25. Figures C.4 (a) and C.4 (b) show the IPER simulation results for the packet mode and IPDC mode when the Doppler frequency is equal to 10Hz and 80Hz, respectively. The results confirm that the IPDC mode outperforms the packet mode with approximately 2.5dB SNR gain at IPER value of 102 . The results also show that the transmission modes III and II have better anti-Doppler effect resistance than modes IV and I. The reason for that is that they use higher subcarrier frequency (8kHz and 4kHz, respectively) than transmission modes IV and I (2kHz and 1kHz, respectively), which gives better results in fading environments. So with same Doppler value, the normalized Doppler frequency's order is: mode III< mode II < mode IV < mode I. From the results it is clear that in order to sustain the effects of fading and noise in WBCs, and thus to achieve better QoS, the 'WBC over T-DMB' IPDC mode - a novel solution for broadcasting service advertisements to mobile terminals - must be employed.

195 Appendix C. Wireless Billboard Channels over T-DMB

0 10 IPDC mode I Packet mode I IPDC mode II Packet mode II IPDC mode III

-1 Packet mode III 10 IPDC mode IV Packet mode IV R IPE

-2 10

-3 10 4 5 6 7 8 9 10 11 12 13 SNR[dB] (a)

0 10

-1 10 R IPE

IPDC mode I -2 10 Packet mode I IPDC mode II Packet mode II IPDC mode III Packet mode III IPDC mode IV Packet mode IV -3 10 4 5 6 7 8 9 10 11 12 13 SNR[dB] (b) Figure C.4: The IPER in Packet Mode and IPDC Mode. (a) Doppler Frequency= 10Hz; (b) Doppler Frequency = 80Hz

196 Appendix C. Wireless Billboard Channels over T-DMB

C.5. Conclusion

The establishment of WBC over T-DMB, for facilitating the service ADA in the UCWW has been presented in this appendix. A physical layer software testbed has been designed with Matlab to evaluate the T-DMB operational modes. The performed simulation has confirmed that with the proposed novel IPDC solution, the 'WBC over T-DMB' system is able to operate more reliably and efficiently.

197 Appendix D. Project Develop Environment

APPENDIX D PROJECT DEVELOPMENT ENVIRONMENT

D.1. Introduction

This appendix introduces the software development environment of ‘WBC over DVB-H’ testbed.

D.2. WBC Service Layer – SP Side Software Environment

The WBC service layer – SP side software architecture has been delineated in Chapter 4. It includes three software projects, namely the WBC-SP enterprise distributed application, the portal application and the ADP application.

D.2.1 WBC-SP Enterprise Distributed Application

Figure D.1 shows the WBC-SP enterprise distributed application development environment. It has been designed with Eclipse and compiled with ANT. To automatically generate the source structure, all POJO codes are integrated with the xdoclet notation.

Figure D.1: The WBC-SP Enterprise Distributed Application Environment

198 Appendix D. Project Development Environment

After running the ant build command, the application is deployed to the corresponding category. Figure D.2 shows the enterprise application category structure.

Figure D.2: The WBC-SP Enterprise Distributed Application Structure

D.2.2 WBC-SP Portal Application

The WBC-SP portal application has been designed and implemented with Netbeans. All the panels are plotted by the UI design tool. Figure D.3 shows the development environment.

Figure D.3: The WBC-SP Portal Application Environment

D.2.3 ADP Application

The ADP DLL has been designed and implemented with Visual C++. Figure D.4 shows the development environment.

199 Appendix D. Project Development Environment

Figure D.4: The ADP DLL Design Environment The ADP Java invoke application is designed and implemented with Eclipse. Figure D.5 shows the development environment.

Figure D.5: The ADP Java Invoking DLL Design Environment

200 Appendix D. Project Development Environment

D.3. WBC Service Layer – User Side Software Environment

The WBC service layer – user side software architecture has been outlined in Chapter 5. It includes three software projects, namely the WBC-SP enterprise distributed application, the portal application and the ADP application.

D.3.1 iWBC Content Provider

Figure D.6 shows the WBC-MU iWBC content provider development environment. It has been designed with Eclipse. The iWBC HTTP light-weight server is included in this project.

Figure D.6: The WBC-MU Content Provider Development Environment

D.3.2 Receiver

D.3.2.1 iWBC-JSE

Figure D.7 shows the iWBC-JSE development environment. It has been designed with Eclipse with GWT.

201 Appendix D. Project Development Environment

Figure D.7: The iWBC-JSE Development Environment

D.3.2.2 iWBC-MIDP

Figure D.8 shows the iWBC-MIDP development environment. It was designed with Eclipse with Sun wireless toolkit.

Figure D.8: The iWBC-MIDP Development Environment

202 Appendix D. Project Development Environment

D.3.2.3 iWBC-Android

Figure D.9 shows the iWBC-Android development environment. It has been designed with Eclipse with Android SDK.

Figure D.9: The iWBC-Android Development Environment

D.4. ‘WBC over DVB-H’ Link Layer and Physical Layer Software Environment

Figure D.10 shows the iWBC receiver’s link layer and physical layer development environment. It has been designed with C++ with MFC.

203 Appendix D. Project Development Environment

Figure D.10: The Link Layer and Physical Layer Development Environment on User Side

D.5. Conclusion

In order to assist the reader a greater understanding of the WBC system implementation discussed in Chapters 4, 5 and 6, the software development environments have been provided in this appendix. It includes WBC-SP side and MU-side environment design. The IDE includes Visual C++ 2003, Visual C++2005, Eclipse and Netbeans.

204 Appendix E. Zhanlin Ji’s List of Relevant Publications

APPENDIX E ZHANLIN JI’S LIST OF RELEVANT PUBLICATIONS

1. Z. Ji, I. Ganchev, and M. O'Droma, “Performance Analysis of ‘WBC over DVB-H’ Link Layer,” EURASIP Journal on Wireless Communications and Networking, vol. 2010, Article ID 306709, pp. 1-15, 2010.

2. Z. Ji, I. Ganchev, and M. O'Droma, “’WBC over DVB-H’ Testbed Design, Development and Results,” EURASIP Journal on Wireless Communications and Networking, vol. 2010, Article ID 769683, pp. 1-18, 2010.

3. Z. Ji, I. Ganchev, and M. O'Droma, “Performance Evaluation of 'WBC over DVB-H' System,” IEEE Transactions on Consumer Electronics, Vol. 55, No. 2, pp. 754-762, May, 2009.

4. Z. Ji, I. Ganchev, and M. O'Droma, “iWBC Client Application for ‘WBC over DVB-H’: Design and Implementation,” IEEE Transactions on Consumer Electronics, pp 1-9, 2010. (submitted).

5. Z. Ji, I. Ganchev, and M. O'Droma, “A T-DMB Simulink Testbed Design for Wireless Billborad Channel,” in Proceedings of 7th IEEE International Symposium on Wireless Communication Systems 2010, York, United Kingdom, pp. 1-4, 19-22 September, 2010. (submitted)

6. Z. Ji, I. Ganchev, and M. O'Droma, “Implementation the Intelligent Application for the Service Enabler Sub-Layer on WBC-SP Node,” in Proceedings of 7th IEEE International Symposium on Wireless Communication Systems 2010, York, United Kingdom, pp. 1-4, 19-22 September, 2010. (submitted)

7. Z. Ji, I. Ganchev, and M. O'Droma, “Formal Description of Services for Advertisement on Wireless Billboard Channels,” in Proceedings of 14th IEEE International Symposium on Consumer Electronics (ISCE 2010), Braunschweig, Germany, pp. 1-6, 7-10 June, 2010.

8. Z. Ji, I. Ganchev, and M. O'Droma, “Novel Scheme and System for Mobile Services' Advertisement and Discovery in the Future Telecommunications World,” in Proceedings of World Telecommunications Congress 2010 (WTC 2010), Vienna, Austria, pp. 1-6, September 13-14, 2010.

205 Appendix E. Zhanlin Ji’s List of Relevant Publications

9. Z. Ji, I. Ganchev, and M. O'Droma, “A 'WBC over DVB-H' Prototype System,” in Proceedings of the Royal Irish Academy Research Colloquium on Emerging Trends in Wireless Communications, pp. 1-5, 22 April, Dublin, Ireland, 2010.

10. Z. Ji, I. Ganchev, and M. O'Droma, "An iWBC-MIDP Client Application Design for Use in WBCs," in Proceedings of IEEE 71th Vehicular Technology Conference (VTC2010-Spring),Taiwan, pp. 1-4, 16-19 May, 2010.

11. Ganchev I., M. O'Droma, J. Jakab, Z. Ji, D. Tairov. 2009. “A New Global Ubiquitous Consumer Environment for 4G Wireless Communications,” in “Fourth-Generation (4G) Wireless Networks: Applications and Innovations.” Adibi, Sasan and Mobasher, Amin, editors. pp. 1-24. 2009.

12. Z. Ji, I. Ganchev, and M. O'Droma, “Wireless Billboard Channel over T-DMB,” in Proceedings of IET China-Ireland International Conference on Information and Communications Technologies (CIICT 2009), Maynooth, Ireland, pp. 57-60, 19-21 August, 2009.

13. Z. Ji, I. Ganchev, and M. O'Droma, “Novel Cross-layer Decoding Design for 'WBC over DVB-H' Link Layer,” in Proceedings of 6th IEEE International Symposium on Wireless Communication Systems 2009, Siena, Italy, pp. 687-690, 7-10 September, 2009.

14. Z. Ji, I. Ganchev, and M. O'Droma, “Wireless Billboard Channel over DAB/T-DMB in Transmission Mode I,” in Proceedings of 3th IEEE International Conference and Exhibition on Next Generation Mobile Applications, Services and Technologies (NGMAST 2009), Wales, UK, pp. 149-152, 15-18 September, 2009.

15. Z. Ji, I. Ganchev, and M. O'Droma, “Using a Rayleigh Fading Channel and Finite State Markov Model for Analyzing the 'WBC over DVB-H' Performance,” in Proceedings of IEEE 70th Vehicular Technology Conference (VTC2009-Fall), Alaska, USA., pp. 1-4, 20-23 September, 2009.

16. Z. Ji, I. Ganchev, and M. O'Droma, “Optimal IP Packet Length for ‘WBC over DVB-H’,” in Proceedings of IEEE 70th Vehicular Technology Conference (VTC2009-Fall), Alaska, USA., pp. 1-4, 20-23 September, 2009.

17. Z. Ji, I. Ganchev, and M. O'Droma, “Building a ‘WBC over DVB-H’ Software Testbed,” in Proceedings of 13th IEEE International Symposium on Consumer Electronics (ISCE 2009), Kyoto, Japan, pp. 626-629, 25-28 May, 2009.

206 Appendix E. Zhanlin Ji’s List of Relevant Publications

18. Z. Ji, I. Ganchev, and M. O'Droma, “New Method for Analyzing the Transport Stream Packet Error Rate of `WBC over DVB-H`,” in Proceedings of IEEE Wireless Communications & Networking Conference (WCNC 2009), Budapest, Hungary, pp. 73-76, 5-8 April, 2009.

19. Z. Ji, I. Ganchev, and M. O'Droma, “Intelligent Software Architecture for the Service Layer of Wireless Billboard Channels,” in Proceedings of 6th Annual IEEE Consumer Communications & Networking Conference (CCNC09), Las Vegas, USA, pp. 172-173, 10-13 January, 2009.

20. Z. Ji, I. Ganchev, and M. O'Droma, “Building a Heterogeneous Software Architecture for the WBC Service Layer,” in Proceedings of IET China-Ireland International Conference on Information and Communications Technologies (CIICT 2008), Beijing China, pp. 14-18, 26-28 September, 2008.

21. Z. Ji, I. Ganchev, and M. O'Droma, “Efficient Collecting, Clustering, Scheduling, and Indexing Schemes for Advertisement of Services over Wireless Billboard Channels,” in Proceedings of 2008 International Conference on Telecommunications, St. Petersburg, Russia, pp. 225-230, 16-19 June, 2008.

22. O'Droma M., I. Ganchev, J. Jakab, Z. Ji, N. Wang. 2008. “On Ubiquitous Consumer Wireless World – A Wireless Communications Environment for Future Wireless NGNs,” in Proceedings of the Royal Irish Academy Research Colloquium on Emerging Trends in Wireless Communications, pp. 1-4, 23-24 April, Dublin, Ireland, 2008.

23. Z. Ji, I. Ganchev, and M. O'Droma, “Reliable and efficient Advertisements Delivery Protocol for use on wireless billboard channels,” in Proceedings of 12th IEEE International Symposium on Consumer Electronics (ISCE 2008), Algarve, Portugal, pp. 261-264, 14-16 April, 2008.

24. M. O'Droma, I. Ganchev, J Jakab, Z. Ji, N. Wang. 2007. "Protocol Foundations for ABC&S Paradigm Realisation in a Ubiquitous Consumer Wireless World," Science Foundation Ireland, Dublin, 26-27 November, 2007.

25. Z. Ji, I. Ganchev, and M. O'Droma, “On WBC Service Layer for UCWW,” in Proceedings of 9th International Conference on Mobile and Wireless Communication Networks (MWCN 2007), Cork, Ireland, pp. 106-110, 19-21 September, 2007.

207