Top Banner
1
65

0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

Jan 21, 2016

Download

Documents

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: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

1

Page 2: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

2

Contents

I. VISION

II. dooroos.realtime

III. USE dooroos.realtime

Page 3: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

3

VISION

Page 4: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

4

TOPappliedRTOS

various various embedded systemembedded system

third party third party

application fieldapplication field

network servernetwork server

windows serverwindows server

filesystem serverfilesystem server

device serverdevice server

LIBRARY

MIDDLEWARE

dooroos .realtime KERNEL

APPLICATIONS Third party

kernel functionkernel function

modularitymodularity

all platform all platform portingporting

game enginegame engine

multimediamultimedia

graphicgraphic

VISION

Page 5: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

5

LOADMAP

JBOSN RTOS

• Nano kernel for ARM

• Micro kernel

• Device Server

• Filesystem server

• Window server

• Network server

• Graphic Library is expanded • Support the various tools

2002~2005

•Add useful Graphic Library

• Add multimedia library

• Sample Apps is provided

•IDE Tools is serviced

•Porting/Testing to various hardware

2009 ~ 20112006 2007~2008

• OS function is expaned• Add standard Device Driver

• Many useful Middleware is added

•Visual IDE Tools

• New OS function is added• Useful Device Driver is added• Useful network protocol is added

•PC Emulator

1st Generation

2011 ~

• Loader Server is added

• All library is converted to DLL files

• All device driver is converted to Driver DLL (DRV file)

dooroos.realtime• dooroos.embedded

Page 6: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

6

dooroos history

Page 7: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

7

app1app appapp

NANOKERNEL

TIMESERVER

SYSTEMSERVER

SYNCSERVER

DEVICESERVER

FILESYSTEMSERVER

WINDOWSERVER

NETWORKSERVER

NANO-KERNEL

MICRO-KERNEL

MACRO-KERNEL

dooroos.RealTime Structure

DRV DRV

DRV

DRV DRVDLL

DLL DLL DLL

apps apps appsapps

Page 8: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

8

dooroos.realtime

I. About dooroos.realtime

II. NANO - KERNELIII. MICRO - KERNELIV. MACRO - KERNEL

Page 9: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

9

H/WH/W

HALHAL

Device driversDevice drivers

DisplayDisplay InputInput

IPCIPC

TIMETIME

RESOURCE MANAGERESOURCE MANAGE

TASK/THREAD MANAGETASK/THREAD MANAGE

APPLICATIONSAPPLICATIONS

DEVICE MANAGERDEVICE MANAGER FIELSYSTEMFIELSYSTEM

WINDOWWINDOW

FA

TFA

T

RA

MR

AM

RO

MR

OM

NETWORKNETWORK

NetDrvsNetDrvs

GENERAL OS Functions & structures

Page 10: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

10

• Kernel 1. Multi-Layer kernel structure:

modularity, portability, scalability2. Multi-Tasking/Thread and flexible IPC3. Precise timer and Priority based real time scheduler4. Scalable hard-real-time5. No interrupt blocking

• I/O manager1. Constant device management and efficient I/O system2. Driver module

• Resource Management1. Cost efficient use of memory2. Reliable and Robust system services

• User1. Easy to use2. Low latency

dooroos.realtime Design Principles

Page 11: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

11

• Bus emulation (Message-Bus)• Communication between

servers• Modularity• Independency• Scalability

SERVER1SERVER1

nano-kernel ( Message-Bus)nano-kernel ( Message-Bus)

SERVER2SERVER2 SERVERnSERVERn…

dooroos.realtime Backplane

Page 12: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

12

app1

app appapp

NANOKERNEL

TIMESERVER

SYSTEMSERVER

SYNCSERVER

DEVICESERVER

FILESYSTEMSERVER

WINDOWSERVER

NETWORKSERVER

NANO-KERNEL

MICRO-KERNEL

MACRO-KERNEL

dooroos.realtime Structure

LOADERSERVER

Page 13: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

13

1.Modularity

Applications by userapplications

Consisted of the necessary library, device driver and HAL

Expanded RTOS servers. (loader, device server, filesystem server, window server, network server)

Principal RTOS servers, 3 server ( system server, time server, sync server)

Minimum real-time operating system and library (16KB)

library/Driver/HAL

Macro-kernel

Micro-kernel

Nano-kernel

The resources is mutually exclusive between servers, then the expansion of required function is very easy.

The in-house library can be added and applied to server-development.

Main function is designed by server concept and added to dooroos.realtime. So, User-required server can be developed by server concept.

Mutual exclusion

User developed library

Server concept

The problem of one module can not propagate to the others.

The modules are separated in physical area.

The independency between modules increase the stability and make easy to debug.

Error propagation

modular

Independency

2.Scalability

3.Stability

4.Memory

All modules can be generated by separated binary images. The relocation is very easy and efficient.

The memory requirement of modules are very small. For example Nano-kernel size is 16KB.

Efficient relocation

Small memory requirement

Advantages

Page 14: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

14

HARDWAREHARDWARE

HALHAL

TRAPTRAPMEMORY MANAGEMENTMEMORY MANAGEMENT Task/Thread ManagementTask/Thread Management

TIME SERVERTIME SERVER

MESSAGE BUSMESSAGE BUS

ApplicationApplication

DEVICE SERVERDEVICE SERVER

SYSTEM SERVERSYSTEM SERVER SYNC. SERVERSYNC. SERVER

FILESYSTEM SERVERFILESYSTEM SERVERWINDOW SERVERWINDOW SERVERNETWORK SERVERNETWORK SERVER

DEV

ICE

DR

IVER

DEV

ICE

DR

IVER

ApplicationApplication ApplicationApplication

NANOKERNEL

MICROKERNEL

MACROKERNEL

DEV

ICE

DR

IVER

DEV

ICE

DR

IVER

dooroos.realtime Structure

LOADER SERVERLOADER SERVER

Page 15: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

15

ROM/DISK

SYNC. SERVERSYNC. SERVER

SYSTEM SERVERSYSTEM SERVERTIME SERVERTIME SERVER

NANO-KERNELNANO-KERNEL

NETWORK SERVERNETWORK SERVER

ApplicationApplication

dooroosdooroos.realtime.realtime

(DLL, DRV)(DLL, DRV)

FAT library DLLFAT library DLL

System System ConfigurationConfiguration

Hardware DLLHardware DLL

JBOOTJBOOT

WindowWindow(Widget)(Widget)

Task(threads)Task(threads)

Widget Draw DLLWidget Draw DLL

PLATFORMPLATFORM

RAMRAM

ROM IMAGE LAYOUT

FilesystemFilesystem

(DLL, DRV)(DLL, DRV) GL library DLLGL library DLL

HALHAL

WINDOW SERVERWINDOW SERVER

FILESYSTEM SERVERFILESYSTEM SERVER

DEVICE SERVERDEVICE SERVER

LOADER SERVERLOADER SERVERDrivers DRVDrivers DRV

Page 16: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

16

Boot sequence

Page 17: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

17

Page 18: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

18

dooroos.realtime

I. About dooroos.realtime

II. NANO - KERNEL

III. MICRO - KERNELIV. MACRO - KERNEL

Page 19: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

19

HARDWARE

HAL

TRAPMEMORY MANAGEMENT Task/Thread Management

MESSAGE BUSNANO-KERNEL

library

NANO-KERNEL Structure

Page 20: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

20

Port / Channel

Page 21: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

21

ConvertKey to port

Port

Message Req/Resp

Port

Server Client

Port Port

Channel Key

1 23

4

23

1

4

Page 22: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

22

Message Structure

#define JB_MESSAGE_CONTENTS \ UINT32 Type; \ UINT32 Param; \

typedef struct _JB_RECVMESSAGE {

JB_MESSAGE_CONTENTS HANDLE hSender; HANDLE Handle; // NOT FOR USER: only for device handle on io_subsystem } JB_RECVMESSAGE, *JB_PRECVMESSAGE;

typedef struct _JB_MESSAGE {

JB_MESSAGE_CONTENTS } JB_MESSAGE, *JB_PMESSAGE;

Page 23: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

23

Server Model

Server

Port & Channel Setting

Message Receive

Message Service…

Message Reply

Message Service…

Message Service…

Page 24: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

24

Device Driver Model

Device Driver

Port & Channel SettingDriver Registration

Message Receive

Message Service…

Message Reply

Message Service…

Message Service…

Page 25: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

25

• Portable across microprocessors

: No exposed API for porting

• Supports RAM/ROM execution

: Other modules support RAM/ROM execution

• Supports Nano-Kernel architecture

: Server concept

KERNEL DESIGN

Page 26: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

26

• Unlimited tasks, unlimited threads

• Full synchronization primitives

• Multitasking, preemptive, priority based

scheduler

: 256 priority levels, reserved for server

• Low ISR and thread latency

• Easy implementation of driver with ISR

Task/Thread Model

Page 27: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

27

Thread IDThread ID

StackStack

CPU Register CPU Register ValuesValues

Priority LevelPriority Level

MessageMessageQueueQueue

Other ThreadOther ThreadOptionsOptions

Other resourcesOther resources

Primary ThreadPrimary Thread

ThreadsThreads

Task IDTask ID

HEAPHEAP

Task/Thread Model

Page 28: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

28

• User selection of MMU use

• Special low memory handling mechanisms

• User modified slab mechanism: Partition concept

: page concept

• Fast IPC, sharing

• Shared memory, Local heaps

• Common system wide low memory handler

Memory Model

Page 29: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

29

dooroos.realtime

I. About dooroos.realtime

II. NANO - KERNEL

III. MICRO - KERNEL

IV. MACRO - KERNEL

Page 30: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

30

TIMETIMESERVERSERVER

SYSTEMSYSTEMSERVERSERVER

SYNC.SYNC.SERVERSERVER

MICRO-KERNEL Structure

Page 31: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

31

TIME SERVER

• RTC time management• System time management• Driver Timer management• Application Timer management• Alarm Timer management• Thread Quantum management• Watch-Dog management• Sleep

services all the time related function

Page 32: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

32

SYNCHRONIZATION SERVER

• Semaphore

• Mutex

• CriticalSection

• ConditionalVariable

• Event

• Message Queue

services all the synchronizations and communications between Task/Threads

Page 33: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

33

SYSTEM SERVER

• Creation/Destroy of Task/Thread

• Message-Bus Port management

• Message-Bus Channel management

• Memory management

• Power management

services all the system resource management

Page 34: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

34

Partition

RAM

User allocation /User responsibility

Memory Pool

Partition

User responsibility

Memory Model

User responsibility

Page 35: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

35

dooroos.realtime

I. About dooroos.realtime

II. NANO - KERNELIII. MICRO - KERNEL

IV. MACRO - KERNEL

Page 36: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

36

DEVICESERVER(Device

Management)

Page 37: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

37

Device Device DriversDrivers(DRV)(DRV)

Window Window ServerServer

Disp

lay

Disp

lay

Touch

PTouch

PK

eyB

dK

eyB

dI/O I/O

ServerServerKernelKernel

PlatformPlatform

ApplicationApplication

FileFileServerServer

Device Driver Model

NetworkNetworkServerServer

NIC

Page 38: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

38

• All work encouraged to be done

in driver

servers

• OS provides easy connecting

to driver

server

• No nesting interrupt

• Yields more deterministic

latencies

Interrupt Model

Page 39: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

39

Kernel ComponentsKernel Components

Device Driver Device Driver ServerServer

InterruptInterruptService RoutineService Routine

HALHALRoutinesRoutines

ExceptionExceptionHandlerHandler

HardwareHardware

InterruptInterruptMessage HandlerMessage Handler

ThreadISR

INT

Virtual

INT

INTsignal

Interrupt Model

Page 40: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

40

INT_AINT_A INT_BINT_B

Interrupt Model

INT_AINT_A INT_BINT_B

INT_A

INT_B

INT_AINT_A

INT_AINT_A INT_BINT_B

INT_AINT_A INT_BINT_B INT_AINT_A

Nesting

No Nesting

dooroosKernel LayerKernel Layer

Driver LayerDriver Layer

Page 41: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

Kernel ComponentsKernel Components

BLOCKEDBLOCKED

OPENEDOPENED

SYSTEM

CA

LL

INTTERUPT

SystemCall Model

Others

dooroos.realtime

INTTERUPT

Page 42: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

42

interrupt

read

Time signal

Message Receive

Message Bus

Keyboard Driver

write

I/O control

read adc/gpioSend keyinput

toWindow server

Driver thread(loop)

Page 43: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

43

Message BusMessage Bus

USB M/S Driver Example

JFTLJFTL

FLASHFLASH

Flash driver thread

USB DEVICEUSB DEVICE

USB M/S driver thread

PCPCUSB cable

Page 44: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

44

H/W

HAL

USB

M/S

LCD

KB

D

Synchronization server

Time server

System server

Nano-kernel

DEV

ICE

SE

RV

ER

FILES

YSTEM

SE

RV

ER

WIN

DO

W

SE

RV

ER

GR

APH

ICLIB

RA

RY

(DLL)

FAT

12

/16

/32

RO

MR

AM

libra

ry(D

LL)

APPLICATION

Logical device driver structure

JFTL (DRV)

FLASH

Sound

NETW

OR

KSE

RV

ER

NETW

OR

KPR

OTO

CO

LN

etD

rvs

LOA

DE

R S

ER

VER

UA

RT

Mix

er T

OU

CH

cpu core

Page 45: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

45

FILESYSTEMSERVER

Page 46: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

46

FILES

YS

TEM

SER

VER

FILESYSTEM SERVER

BLOCK DEVICEBLOCK DEVICE

Tasks (threads)Tasks (threads)

1

2

Block Driver (DRV)Block Driver (DRV)

APPLICATIONAPPLICATIONFILESYSTEM SERVERFILESYSTEM SERVER

RAMFS DLLRAMFS DLL

ROMFS DLLROMFS DLL

FATFS DLLFATFS DLL3

Page 47: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

47

ROOT (BD1)FILESYSTEM

SERVER

BLOCK

DEVICE

_1

(ROOT)

BLOCK

DEVICE_2

(MMC)

Logical FILESYSTEM Structure

Tasks (threads)Tasks (threads)

MMC (BD2)

wav

romdoc

wav

romdoc

FATFS DLLFATFS DLL

Page 48: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

48

NETWORKSERVER

Page 49: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

49

NETWORK SERVER

NICnNICnNIC1NIC1 NIC2NIC2

TCPTCP

Tasks (threads)Tasks (threads)

IPIP

UDPUDP

ICMPICMP

ARPARPRARPRARP

ApplicationsApplications

NETWORK SERVERNETWORK SERVER

DEVICE DRIVERSDEVICE DRIVERS

SOCKET INTERFACESOCKET INTERFACE

NICnNICnNIC1NIC1 NIC2NIC2

IPIPARPARPRARPRARP

ApplicationsApplications

NETWORK SERVERNETWORK SERVER

DEVICE DRIVERSDEVICE DRIVERS

Page 50: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

50

WINDOWSERVER

Page 51: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

51

Widget1

Widget2

Widget2

Widget1

Widget & Window Definition

Widget0

Widget0

WINDOW

is the collection of widgetsis the collection of widgetsWINDOW

WINDOW

is the atomic unit of window and operationsis the atomic unit of window and operationsWIDGETWIDGET

Page 52: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

52

Widget

WINDOW

All drawing unit is called widgetAll drawing unit is called widget

Example of Widget & Window

Page 53: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

53

Difference of dooroos.realtime

1 - The child window should not be larger than it’s parent.- The child window should be inside of parent area.- The child window should not be larger than it’s parent.- The child window should be inside of parent area.SIZESIZE

2- The clipping between overlapped windows is not supported.- The higher z-order window is only updated.

- The clipping between overlapped windows is not supported.- The higher z-order window is only updated.

CLIPPINGCLIPPING

3- The key-input is not delivered to the focused window.- The key-input is delivered to the top parent window of the focused window.-The key-input delivery is responsibility to the top parent window.

- The key-input is not delivered to the focused window.- The key-input is delivered to the top parent window of the focused window.-The key-input delivery is responsibility to the top parent window.

FOCUSFOCUS

Page 54: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

54

Win

dow

Serv

er

WINDOW SERVER

LCDLCDKBDKBD TCHTCH

Wid

get

Wid

get

pro

ced

ure

pro

ced

ure

(DLL)

(DLL)

WindowsWindows(Widgets)(Widgets)

GL library DLLGL library DLL

Tasks (threads)Tasks (threads)

Widget Draw DLLWidget Draw DLL

1 2

3

APPLICATIONAPPLICATIONWINDOW SERVERWINDOW SERVER

MouseMouse

Page 55: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

5555

widget1

Task(T

hre

ad

)

window1

Window_n

widget2

Widget_n

WINDOW Iooks like

Page 56: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

56

MESSAGE MODEL

Message LoopMessage Loop

Thread1

WinProcWinProc

APPLICATIONAPPLICATION

WINDOW SERVERWINDOW SERVER

WinProcWinProc

Message LoopMessage Loop

WinProcWinProc

WinProcWinProc

Thread2

Message QueueMessage Queue

. . .. . .

Page 57: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

57

APPLICATIONEXAMPLE

Page 58: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

58

RSSIwidget

Batterywidget

Image widget

Menu button widget

Child Window 1

List box widget

Play

Progress bar widget

ESC Stop

Main Window

Window

Page 59: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

59

dooroos.realtime

Main Window

Main window management thread

Wave p

layer th

read

RS

SI

wid

get

DEBUG THREAD

Batte

ryw

idg

et

Imag

e w

idg

et

Men

u b

utto

nw

idg

et

Child Window1

Lis

t box

wid

get

Pro

gre

ss b

ar

wid

get

Pla

y b

utto

n w

idg

et

Sto

p b

utto

nw

idg

et

“ES

C” b

utto

nw

idg

et

Application

Page 60: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

6060

COMPARISON

Page 61: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

61

H/W

HAL

USB

M/S

LCD

KB

D

Synchronization server

Time server

System server

Nano-kernel

DEV

ICE

SE

RV

ER

FILES

YSTEM

SE

RV

ER

WIN

DO

W

SE

RV

ER

GR

APH

ICLIB

RA

RY

(DLL)

FAT

12

/16

/32

RO

MR

AM

libra

ry(D

LL)

APPLICATION

JFTL (DRV)

FLASH

Sound

NETW

OR

KSE

RV

ER

NETW

OR

KPR

OTO

CO

LN

etD

rvs

LOA

DE

R S

ER

VER

UA

RT

Mix

er T

OU

CH

cpu core

DLL DLLDLL DLL DLL DLL

DLL

Page 62: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

62

V.S

V.S

Page 63: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

63

OS Comparison

dooroos.realtime Linux Windows CE UCOSII

structure module monolithic mixed monolithic

filesystem supported supported supported

IO system supported supported Supported

windowing supported supportedsupported

networking supported supported supported

library Not enough enough enough

apps Not enough enoughenough

Memory 500KB 8MB ~ 16MB ~

royalty ~ 2,000 won Free 16$

Page 64: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

64

실 습

Page 65: 0 1 Contents I. VISION II.dooroos.realtime III.USE dooroos.realtime.

65