eT-Kernel Extended is a memory protection and pertitioning, process-model compatible Real-Time Operating System (RTOS) created using a new and completely different concept than the conventional μITRON model. It is especially ideal for large-scale systems. Many functional enhancements have been added with the eT-Kernel Standard Extension as a base, and eT-Kernel Compact at the core, standardized by T-Engine Forum. A memory protection function using the MMU (Memory Management Unit) and a process model are fully supported.
This RTOS offers a memory protection function using MMU. The function can detect when a running process is about to accidentally corrupt memory space or kernel resources managed by another process in advance, and prevents it from occurring. This makes it easy to discover bugs during the development process. Also, unauthorized program operation may occur while the system is running. Even in such a case, the memory protection function can keep damage to a minimum. Loadable drivers and subsystems can be safely added as well.
The relationship between the OS and programs is more loosely coupled, and a process management support establishes virtual addresses so that management and execution can be performed with the entire system divided into transactions (processes). Since each process can be developed and debugged, it is an ideal OS for large-scale systems being used by a large number of people.
Basic functions of eT-Kernel Extended
eT-Kernel Extended includes the following basic functions.
||Memory management functions for local memory, shared memory, and system memory within a process
||Various process/task management functions required for operating single user/multi-process systems
||Functions for sending/receiving messages between any processes
||Functions that generate data that can be shared and used between processes using any selected name, and a function for referencing data by generated name.
||A mechanism for synchronization or communication between tasks (semaphore/mutex/event flag/email box/message buffer/rendezvous)
|POSIX file system
||I/O-related functions for POSIX-compliant files
||Functions that handle and manage event notifications from each device as unified events
||Functions for operating devices registered in the system using the T-Kernel device management function
||Functions for acquiring/setting system time, and converting to calendar date and time
||Functions for acquiring version information and loading/unloading system programs
||Functions for managing shareable programs (libraries) from multiple processes.
More advanced applications using eT-Kernel Extended
eT-Kernel Extended offers multiple process contexts, suitable for building higher-complexity applications, as well as system programs suitable for kernel application structures, including loadable drivers and middleware. Using this setup makes it possible to modularize, layer, design, and develop the entire system. This is ideal for a large-scale systems being developed by bigger teams.
It also offers a shared library and DLL setup that can be used from processes. Using this in an effective manner can provide a flexible system structure, but also save memory space by using copy-on-write (CoW) mechanism.
A process mechanism suitable for building more advanced and more structured applications. eT-Kernel Extended features two process types.
- User process
CPU operates in user mode. It operates within a unique, virtual address space. Kernel memory and I/O areas cannot be accessed.
- System process
CPU operates in system mode. It operates with a unique address space. Kernel memory and I/O areas can be accessed.
|What is a process?
"A Process is a program installation that is controlled so that mutual interaction does not occur in a multi-programming environment between multiple programs that switched due to events. Fixed resources are allocated to a process, including virtual/local address space, memory, execution time, and program execution environment.
A process can consist of a single "task", or execution flow or multiple of them. “Task” refers to a transaction within the process, and is also called a thread. Tasks share the resources of the process they belong to, which can be accessed mutually and freely. For example, a single variable within a process can be freely accessed by multiple tasks. But it follows that a task cannot access the resources of another process, unless the memory is shared between processes.
System program refers to a kernel application that operates in the same address space as T-Kernel. A system program includes device drivers, subsystems, and other kernel applications. A system program can be statically linked to T-Kernel, while it can also be used as a different link and be loaded statically via the system. This makes driver and system library updates easy, and is useful for improving development efficiency.
“Shared libraries” are libraries that can be used from multiple processes. When using a normal library, it is statically linked to all process images using it while building a program. In contrast, when using a shared library, multiple processes can share and use a single library image, which reduces memory consumption. All shared libraries used by processes are accessible (mapped) to the local memory of each process before the application is executed.
DLL (Dynamic Link Library)
A DLL is a library that can be loaded while a process is running. Unlike a shared library, it is not loaded before the application launches. When it is needed, an API is issued from the process to load it for the first time, and then it can be used from the process. Ideal for plugin modules, etc.
Reuse of software assets built with eT-Kernel Compact
Device drivers built with eT-Kernel Compact, using the same model as μITRON, as well as middleware, etc. made into subsystems can be used just as they are, but as kernel applications, with eT-Kernel Extended.
eBinder can debug all programs in a development environmentUser processes/system processes, system programs, shared libraries, and all DLLs built with eT-Kernel Extended can be developed using eBinder. Debugging can be performed for process units, but also for individual tasks within the process. Device driver debugging is also possible. Since eBinder can be used to develop all programs from PrKERNELv4 to eT-Kernel Compact and eT-Kernel Extended, experience on how to use the acquired development tools can be used to efficiently advance development.
Back to top
Unique functions of eT-Kernel Extended
eT-Kernel Extended offers all functions offered by T-Kernel Standard Extension, but the following eT-Kernel Extended unique functions are provided as well.
This function detects CPU exceptions, and sends notification of such events to the user application. Important system information acquired when the CPU exception occurs, and a message is displayed on the serial console. (Acquired information includes CPU internal information such as CPU register set, MMU and coprocessor, the task ID for which the CPU exception occurred, and kernel internal information such as task name.) This system information can be acquired by using a C language interface API for audit, logging or debugging purposes. Using the exception manager function allows the user to handle runtime issues during development as well as after field deployment.
Enhanced commands can be added to Target Shell
The Target Shell is a command library for embedded systems, providing a function similar to UNIX Shell. Commands corresponding to OS system calls are available and can be used to control resources within the system. User-defined commands can be added as well. Since the Target Shell can be embedded in the final system, it is useful for implementing commands for system maintenance, inspection, etc. Series of commands can be combined into a script.
The command library enables calls from the application, but also enables the user to perform external calls via communication port. The serial port or eBinder debug port can be used as a communication port. When using the eBinder debug port, VTTY can be used as a console. If the target system’s console driver is not yet completed, or a debug serial port cannot be ensured for the target system, using VTTY via eBinder’s debug port is a convenient alternative.
High-speed suspend and resume support
This function can provide a high-speed boost when starting up the system for the second time and beyond. The system structure makes it possible to restart the system several times faster than normal speed. This function can also be used to keep RAM content in the system when resetting it. eT-Kernel Extended keeps tables in a part of its memory for managing information on programs loaded once (processes, system programs, DLLs, etc.), configuration files loaded during startup, addresses, etc. Files existing in the memory are searched for and loaded from this table. By keeping this data in RAM instead of reloading every item from storage media, the system is then capable of booting much quicker.
POSIX file mapping
Memory mapping of files using mmap() is supported. This can also be used as memory shared between processes.
Protection function for task stacking and system program data selection
This function prevents pointer overrun and underrun to protect stacking of each task and .data/.bss sections within system programs. If an overflow or underflow occurs for stack and data sections, a CPU exception will occur, preventing destruction due to other memory errors.