Top Banner
T-Engine Middleware T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory [email protected]
29

T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory [email protected].

Mar 27, 2015

Download

Documents

Grace Cooper
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

T-Engine T-Engine MiddlewareMiddleware

Tomas Sanchez Lopez

Real-time & Embedded Systems [email protected]

Page 2: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

2AA

NN

TT

SS

ContentsContents

■ Introduction■ Middleware Classification■ Middleware Activities

■ T-Format■ Device Drivers■ Subsystems■ T-Collection■ T-Builder■ T-Dist

■ Conclusions

Page 3: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

3AA

NN

TT

SS

Introduction Introduction

T-EngineT-Engine: An open standardopen standard platform for real-real-timetime, embedded systems development

MiddlewareMiddleware: software agentssoftware agents acting as an intermediaryintermediary between different application components

Page 4: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

4AA

NN

TT

SS

Introduction Introduction

T-Engine Middleware:T-Engine Middleware: Layer that provides services to application software with user-defined system calls, application

tasks, and libraries offered by T-KernelT-Kernel. The T-FormatT-Format specification standardizes formats for middleware source and

execution code.

Page 5: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

5AA

NN

TT

SS

Middleware Classification Middleware Classification

AA - By the way it acts Subsystem-type Middleware Device Driver-type Middleware Library-type Middleware User Task-type Middleware

BB - By the service it provides Device Driver-type Middleware Abstract Device Driver-type Middleware Extended Kernel-type Middleware Middleware to provide general functions

Page 6: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

6AA

NN

TT

SS

Middleware Classification Middleware Classification - - AA

Subsystem-type Middleware Middleware which acts as a subsystems on the T-

Kernel Called by the applications through its interface Called when event happens

Device Driver-type Middleware Uses the device management functionality provided

by the T-Kernel Use it through general device driver interface

provided by T-Kernel

More

More

Page 7: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

7AA

NN

TT

SS

Middleware Classification Middleware Classification - - AA

Library-type Middleware Middleware that acts as a user library User apps need to be linked with it in code creation

Provided function or global variable

User Task-type Middleware Middleware that acts as a user-task server “Management server Task” User apps get services from it:

Inter-task communication provided by T-Kernel Synchronization provided by T-Kernel

Page 8: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

8AA

NN

TT

SS

Middleware Classification Middleware Classification - - BB

Device Driver-type Middleware Middleware that provides an API in a certain level of

abstraction concerning: Each device on T-Engine Each device connected to T-engine

Communication devices connect other devices To achieve portability, the API of lower level devices

should be standardized

Examples: RS232C driver, PCMCIA driver, Ethernet Driver, USB driver, Graphic Card Driver…

Page 9: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

9AA

NN

TT

SS

Middleware Classification Middleware Classification - - BB

Abstract Device-type Middleware Provides SW interface of high abstraction to single or

plural devices on T-Engine

Extended Kernel-type Middleware Middleware that provides service or higher

abstraction level through T-Kernel or middleware functions to HW and SW resources managed by T-Kernel

Examples: TCP/IP, Printing I/F, FAT file system, GUI package…

Examples: Process Management function, virtual memory function, loader function, CLI (command line interpreter)…

Page 10: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

10AA

NN

TT

SS

Middleware Classification Middleware Classification - - BB

Middleware to provide General Functions Provides general calculation functions Weak relation with kernel resources or external

devicesExamples: Sort function, Search function, random number generation function, encryption/authentication function…

Page 11: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

11AA

NN

TT

SS

Middleware ActivitiesMiddleware Activities

Related to the development of Middleware Standards T-Format Device Driver Specification

Related to increasing amount of middleware Subsystem design Porting activities T-collection T-Builder

Related to distribution of middleware T-Dist

Page 12: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

12AA

NN

TT

SS

Middleware Stnd. ~ T-Format Middleware Stnd. ~ T-Format

Code format of Middleware and application Software running on T-engine/T-Kernel.

Source code style guidelines Source-code style format for middleware and

applications running on T-Engine/T-kernel Source code written by various vendors can be

compiled in one program

Document format Type and format of documentation attached and

distributed with middleware and applications

Page 13: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

13AA

NN

TT

SS

Middleware Stnd. ~ T-Format Middleware Stnd. ~ T-Format

Binary-code format Executable binary format to run in T-Engine/T-kernel Follow the ELF format Compiler dependent part of the ELF format should follow the GNU-

based reference environment and is separately defined by T-Engine forum

Symbol rules for avoiding name conflicts when combining different pieces of software from different vendors

Global symbols (Exported functions, global variables, etc) Middleware Package name Version assignation

Example: char unl_mpeg2_etronid[16];

Page 14: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

14AA

NN

TT

SS

Middleware Stnd. ~ Device Middleware Stnd. ~ Device DriverDriver

Specifications of the Device Driver Interface Library Convenient dev. of device drivers designed to run on T-

Kernel Device Drivers consist of:

Interface layer Logical Layer Physical Layer

Interface layer: Reduce burden on developersand bring together the aspects that can be standardized

SDI (Simple Device driver interface layer)Devices that can perform all processing immediately without

queuing requests (i.e. RTC or other register-based devices) GDI (General Device driver interface layer)

For devices that must attend request in order of request (specially for those to interrupt processing) (i.e. RS-232C)

Page 15: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

15AA

NN

TT

SS

Middleware Stnd. ~ Device Middleware Stnd. ~ Device DriverDriver

SDI GDI

Also concerns about implementation issues: Waiting functions Abort functions Buffer management between the OS and the requesting

source DMA Interrupt handlers

Page 16: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

16AA

NN

TT

SS

Middleware Stnd. ~ Device Middleware Stnd. ~ Device DriverDriver

Examples

Audio Device Driver Enables audio IO with T-

Engine Provides audio codec

control Allows extensions with

more driver units and subunits (i.e. multiple implementations of ADC & DAC)

Page 17: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

17AA

NN

TT

SS

Middleware Stnd. ~ Device Middleware Stnd. ~ Device DriverDriver

MIDI Device Driver T-Engine Units lack of MIDI connector Control the protocol converters and sending

or receiving logical MIDI streams Individual devices are controlled by

application’s messages (not the MIDI driver)

Back to Classification

Examples

Page 18: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

18AA

NN

TT

SS

Increasing Middle. ~ Subsystems Increasing Middle. ~ Subsystems

T-Kernel doesn’t include file management, GUI-related, communication functions, etc

Implement these functionalities by adding subsystems to T-Kernel. Allows both lightweight and advanced systems on the same kernel

T-Kernel Extensions provide: Virtual Memory: Using MMU, create multiple virtual address

spaces Process Management functions: to modularize programs Event Management functions: for mouse, keyboard, etc File management functions

Back to Classification

Page 19: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

19AA

NN

TT

SS

Increasing Middle. ~ Porting Increasing Middle. ~ Porting Act.Act.

Other systems hold a lot of software assets that could be very beneficial for the T-Engine

Establish porting guidelines for reusing those assets Operate other systems on top of T-Kernel Examples: ITRON middleware, Windows CE .Net

ITRON Middleware 20 years of embedded development to reuse System call level highly compatible Porting main changes:

Change in and reuse the Kernel API Changes to improve distribution (T-Format,

Subsystems…)

Page 20: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

20AA

NN

TT

SS

Increasing Middle. ~ Porting Increasing Middle. ~ Porting Act.Act.

Hybrid mechanism of T-Kernel and other OS: T-Bus

Provide Real-Time functionality to other OS

Benefit from the guest OS capabilities (interoperation, GUI, etc)

Digital Video

Camera Example

Hybrid implementation

Page 21: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

21AA

NN

TT

SS

Increasing Middle. ~ Porting Increasing Middle. ~ Porting Act.Act.

Linux Kernel on top of T-Kernel

Light-Weight Object Oriented programming framew.

Middleware for third-generation mobile phones

T-W

ind

ow

s

J2ME with T-engine profiles

Windows CE .Net

Page 22: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

22AA

NN

TT

SS

Increasing Middle. ~ T-Increasing Middle. ~ T-CollectionCollection

Basic set of software that runs on T-engine and T-kernel Standard format that makes easy to run code immediately Basic modules such as algorithms or large-scale practical

software They are assumed to be Open-source Source code or binaries offered by T-Engine Forum Distributed with T-Dist

Example of Collection: Small library containing tree programs Sorting function Searching function Encryption and Signatures Data compression algorithms Basic resident programs (i.e TCP/IP, file system based on

allocation tables)

Page 23: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

23AA

NN

TT

SS

Increasing Middle. ~ T-Increasing Middle. ~ T-BuilderBuilder

Standard development environment Ensures de portability of middleware and application

software Reference development environment

Vendors might provide better Development Environments compatible with T-Builder

Adopted the GNU development environment

Requirements Open Compatible with multiple CPUs

Page 24: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

24AA

NN

TT

SS

Middleware Distrib. ~ T-DistMiddleware Distrib. ~ T-Dist

Distribute encrypted Software (binary) When the executable is run, the software is decrypted

and billed using the eTron (License ticket) Prevent illegal use of Software Promoting Distribution

• Generation of the encrypted Software by the server

• License control using eTRON

• Software-specific License control

Page 25: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

25AA

NN

TT

SS

Middleware Distrib. ~ T-DistMiddleware Distrib. ~ T-Dist

Target Systems Software

Applications Subsystems Device Drivers Dynamic Libraries

Contents Static Libraries Audio-Visual

Software Electronic Book

Examples Permit execution

only on eTRON systems that store a certain encryption key

Payment mechanism based in the number of times the software runs

Page 26: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

26AA

NN

TT

SS

Middleware Distrib. ~ T-DistMiddleware Distrib. ~ T-Dist

Server

Client / eTRON

Page 27: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

27AA

NN

TT

SS

Middleware Distrib. ~ T-DistMiddleware Distrib. ~ T-Dist

Encrypted Middleware Format

Page 28: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

28AA

NN

TT

SS

Middleware Distrib. ~ T-DistMiddleware Distrib. ~ T-DistM

idd

lew

are

Ven

dor

T-e

ngin

e F

oru

m

U

ser

Encrypted

Use

End of Use

Software Registration

Order

Agreement (T-Engine Forum acts as Proxy)

Delivery

eTRON

• 16 bit CPU

• 16 Mb Address Space

• 4 Kb RAM

• 96 Kb ROM

• 32 Kb EEPROM

eTRON/16 Chip

Page 29: T-Engine Middleware Tomas Sanchez Lopez Real-time & Embedded Systems Laboratory tomas@icu.ac.kr.

29AA

NN

TT

SS

ConclusionsConclusions

T-Engine forum emphasize the standardization and distribution methodology of the middleware

Don’t directly provide software Encourage vendors to produce the software

Easing development and interoperability Easing distribution Guarantying licensing

Provision of tools for porting existing software as T-Engine middleware

On top of the T-kernel