Embedded system basics


Embedded system:

To start from what is a Embedded system?

In simple word Embedded system is a system which is dedicated to do specific job. Generally embedded system will involve computer hardware with software embedded in it, what not right from Micro-controller in digital display thermometer to processors in Aeronautical control system everything come under embedded systems.
Anything that has computer hardware with software embedded in it embedded system.

Components  of Embedded System:
1) Hardware: Depending system requirements this could change, but in general essential HW components if embedded system would be as listed below. 
• Power Supply:  For any system to start working we need power supply, most of the time for small scale Systems this would be from a DC source like rechargeable battery Eg: All mobiles and PDAs work on battery source.
• Processor : For making any kind of computations or action initiation depending on sensor outputs, processor/controllers will be used depending on the System application, These Processor selection would on the basis of  processing data capacity 8bit to 64bit OR on processor speed which depends on clock rate calculated in Hz's.
• Memory : For storing the executable code, to store temporary values while doing executing computations on processor. both ROM and RAM memories would be needed.
• Timers : One of the impotent components of RTOS embedded systems, as they handle tasks of more time-bound.
• Serial communication ports: 
• Output/Output circuits
• System application specific circuits : these three items are more dependent on System application.
2) Software: In middle level to sophisticated  Embedded systems Software would be comprising three parts, 
     a) Software to handle UI (user interface) in general this would be called application software.
     b) Middle ware to handle to provide Network to UI related Serveries as APIs to application      software layer.
     c) Operating system : Any light wait OS or RTOS, or a Board Support Package to initiate and control HW on Board, and Device Drivers along with Kernel like Linux.
will see each software components in details, in next posts. :-)


Embedded Software Components:  

Kernel: 
The central module of an operating system. It is the part of the operating system that loads first, and it remains in main memory. Because it stays in memory, it is important for the kernel to be as small as possible while still providing all the essential services required by other parts of the operating system and applications. Typically, the kernel is responsible for memory management, process and task management, and disk management.
The definition of kernel is "the portion of an OS (Operating System) that is responsible for interacting with the hardware. It is the operating system software that runs in kernel mode on the computer's processor and which provides low-level intelligence for the operating system. In other words, the kernel is the "heart" of an operating system.

There are two types of kernels available,
1. Monolithic Kernel
2. Micro Kernel

Monolithic Kernel: As the name itself suggests, the kernel has every services like, FS Management, MM, Process Management, etc. in the kernel space. It does not run as a separate process. So there won’t be context switching, when you ask for a service. But, the probability of a monolithic kernel getting struck is more. Because, if there is a bug in the kernel itself, nothing can rescue it. Linux and Windows are good examples of Monolithic kernel. Linux, being a monolithic kernel, you can insert modules into the kernel dynamically using insmod command.

Micro Kernel: Micro kernel runs all the services as a daemon in the user space. So, if a problem occurs in any of the service, the kernel will be able to decide what to do next. But, you pay-off the time to switch to a service in this type of kernel. Micro kernels are somewhat difficult to design and build than the monolithic kernel.

BSP (Board Support Package):
A board support package is the layer that sits directly above the hardware and below the RTOS kernel. It provides as abstraction from the hardware. Writing a BSP is different for different RTOSs. However, it will almost always involve initial bootup, hardware initialization and then placing a call to the kernel inititalization and spawning the root task. The BSP is written according to the hardware present on the board

No comments:

Post a Comment