Showing posts with label Program. Show all posts
Showing posts with label Program. Show all posts

Monday, 19 May 2014

Embedded System

by Unknown  |  in The AVR Microcontroller at  03:15
Embedded System

Introduction:

            A system is a way of working, organizing or doing one or many tasks according to afixed Plan, program, or set of rule.

            An embedded system is a system that has embedded software and computer hardware, which makes it a system dedicated for an application or specific part of an application or product or a part of a larger system.

It is not easy to give precise definition of embedded system as it is complex   system but in simple words we can say that:

“It is the system which is on a single chip or employs a combination of hardware (computational engine) and software to perform a specific function.”

It is one type of computing device but not like PC. We can better understand such systems by examining common examples and common characteristics. Embedded system is found in a variety of common electronic devices such as consumer electronics, home appliances, office automation, business equipment and automobiles.

Characteristics of embedded system:

  1. It acts as single functioned or has tightly bound set of functions means it is not used as general purpose.
  2. It is very reactive and real time constrained.
  3. Increasingly high performance.
  4.  
  5. Application specific processor design can be a significant component of some embedded system.

Requirements of embedded systems:


 Types of requirements imposed by embedded applications:

 1 Functional requirement
 2 Temporal requirements
 3 Dependability requirements

1. Functional Requirements
Ø  Data Collection
Ø  Direct Digital Control
Ø  Man-Machine Interaction

2. Temporal Requirements
Ø  Tasks may have deadlines
Ø  Minimal latency jitter
Ø  Minimal error detection latency
Ø  Timing requirements due to tight software control loops
Ø  Human interface requirements.

3. Dependability Requirements.
Ø  Reliability
Ø  Safety
Ø  Maintainability
Ø  Availability
Ø  Securit



Classification

There are three types of embedded system are classify.



1). Small scale embedded system:
          
           These system are designed with a single 8 or 16 bit microcontroller; they have little

hardware and software complexities and involve board-level design. They may even be battery

operated. When developing embedded software for these, an editor, assembler and cross

assembler, an integrated development environment tool specific to the microcontroller or

processor used, are the main programming tools

2) Medium scale embedded system :
          
           These system are usually designed with a single or a few 16 or 32 bit microcontrollers,

DSPs or RISCs.These system may also employ the readily available single purpose processors

and IPs for the various function –for example, bus interfacing.Mediam scale embedded system

have both hardware and software complexities.

3) Sophisticated embedded systems:

           Sophisticated embedded system have enormous hardware and software complexities and

may need several IPs, ASIPs, scalable processors or configurable processors and programmable

logicarrays.They are used for cutting edge application that need hardware and software co-

design and components that have to be integrated in the final system .They are constrained by

the processing speeds available in their hardware units.




Block diagram of embedded system 




An embedded system typically comprises the embedded hardware, embedded RTOS, device drivers, communication stacks and embedded application software.

  1. Hardware: processors, ASICs (application specific ics), memory. It is used for performance and sometimes.
  2. Software: C or Assembly language is used as software. It is used for providing features and flexibilities.


Major Components in Embedded Systems
Ø  Data acquisition and processing
Ø  Communication
Ø  System logic and control algorithm
Ø  Interface
Ø  Auxiliary units
§  Display
§  Storage
§  Monitoring and protection
§  Test and diagnosis.
ARCHITECTURE

Embedded hardware

Functioning of any embedded system is depended on three aspects processing, storage, and communication. We use processor to implement processing, memory to implement storage and buses to communicate.

  1. Processor:

A processor is a digital circuit designed to perform computation tasks. A processor consists of data lines capable of storing and manipulating data and controller capable of moving data through the data lines.


Processor Types Used in New Embedded Designs
 
 



In many applications we use micro controllers in place of processors.” A micro controller is a device that includes microprocessor, memory and I/O signal lines on a chip.”e.g.families of  MC68HC11,MC68HC12 .                            

  1. ASICs: (Application Specific Integrated Circuits)
It is the silicon chip with an array of unconnected transistors. It includes gate arrays and standard cell ICs. It is the basic part of embedded system. It is a semi custom device. The function is defined by the designer for particular application but not defined by the manufacture.


  1. Memory:
A fixed size volatile memory such as DRAM or SRAM & non-volatile    memory such as flash or EPROM, connected to microprocessor or micro controller, is used. So the range of memory is depend upon the application means according to microprocessor or micro controller Memory access refers to either read or write. Some types of memory write ability refers to the manner & speed. Depending upon various memory types of writing that particular memory.
           
At the high end of the range, we have types of memory where we simply or quickly write. At the middle range, we can slowly write.  At the lower end of range, we have types memory that can be only written by programmer. In some cases the available memory is larger then needed this becomes easy to deal with but if the available memory is smaller than needed, then we must imposed several smaller memories to behave as a large memory.

4.      Peripherals:
According to the block diagram of embedded system as shown in the figure above analog I/O consists of the several peripherals according to the requirement or the application. Some of the peripherals are listed below:

·         Timer, counter
Timer is the most common peripheral device that measures time intervals. It can be used to either generate events at specific times or to determine the duration between two external events. As for the example, keeping the traffic light green for a specific duration, etc.

Counter is a more general version of timer. For example, counter can be used to count the number of cars that pass over road sensor or the number of people passing through the turnstile.

  • UART (universal asynchronous receiver/transmitter)
It is used in serial communication. It is needed to communicate bytes of data between devices that are separated by long distances or when those devices have few available I/O pins. Internal construction of UART includes some registers and two independent operating processors one for receiving and other for transmitting.

  • Pulse width modulators
Pulse width modulation is used to generate clock like signals to another devices. This approach is beneficial for single purposes by simplicity and efficiency
For example, pulse width modulation can be used to blink a light at a specific rate.

  • DMA controller (direct memory access)
It is used for transferring data between memories and peripherals. We have IC 8257 for DMA controller. We can easily interface it with microprocessor. It can transfer a full block of data, hence is used in CD ROM or disk controllers.


  • LCD controllers (liquid crystal display)
It is the display or output device. It is a very low cost power device. It can display text and images. For example, watches, fax and copy machines, calculators.


  • Keypad controllers
It is the input device and is used to give the input to the embedded system.

  • Stepper motor controllers
It rotates a fixed number of degrees whenever step signal is applied. We can directly give DC signal to it. Stepper motors are common in embedded systems with moving parts like disk drivers, printers, photocopy and fax machines, robots, camcorders, etc.


  • ADC converters
It is most useful as embedded systems deal with digital signals but its surroundings consist of many analog signals, which are the input to the embedded system like temperature, speed.

  • Real time clocks (RTC)
It keeps the time and date in an embedded system.

Depending on the targeted application of the device the peripherals can include communication devices such as serial controllers, Ethernet controller or wireless communication controller and other application specific ICs.

Other blocks of ES:
                  
Major functional block decisions must be made under this, such as the selection of real time kernel, major algorithms and data structures in software, or the power source or networking protocol used in hardware.

                        For micro controller – based designs we require MCU resources such as GPIO ports, timers and ADCs.

Interfacing schemes
                        One factor that makes an ES different from a regular computer is the special I/O devices we interface to our ES. Interfacing includes both the physical connections of the hardware devices & software routines that affect information exchange. We can use many interfacing schemes like: parallel I/O interface, memory interface, high speed I/O interface, analog interface.




 
Embedded Software





Programming is the design and debugging of a sequence instruction. Basically software contains programming of processor of the embedded system. Two types of programming languages are mainly used:

  1. Assembly language
  2. C programming language

The selection of language affects the selection of processor, memory and development tools and is driven by portability, reliability and readability.

Assembly language
It is made up of a set of mnemonics each mnemonics corresponds directly to a processor machine instruction code. So for translating assembly language we need assembler and in embedded system we use cross assembler. Nearly every embedded system requires that at least some portion of the program be written in assembly language, which may deal with low-level I/O operations. But assembly language is not widely used.

C language
As it is the high level language it is shorter and easier to write. It is independent of the processor, but we need a compiler to translate high level language to machine code. Using C language has two important advantages, because of which it is much easier for programmer to write quality programs that are easier to read, revise, and port to a different system. This advantages are- 1.built in structure.
2.type checking & abstraction.
 If the embedded device is capable of communicating total eternal world, it has a software-communicating stack running on the top of the operating system. In order to connect the Internet the embedded device needs a TCP/IP stack. Hence it is used more frequently thanassembly language. In many application user used this language.

OPERATING SYSTEM

All intelligent devices that perform complex functions have an embedded OS inside it. This OS is typically real time in nature i.e., it is capable of responding to time critical external events.

The concept of real-time operating system (RTOS) is inseparable when we talk about embedded systems. RTOS is built for specific applications and guarantees response to an external event within a specified time constrain. It responds to inputs immediately. for example, when u suddenly apply breaks of yr car to avoid an accident, the “intelligent gadget” responds immediately. Vxworks is the most widely adopted RTOS in the embedded industry.

OS is larger software that provides low-level services to large applications. OS is responsible for deciding what program is to run next on the processor and for how long. This is called task scheduling. OS provides various software hardware interrupts. Device drivers are the lowest level software that acts as glue between the operating system and the peripheral device that is connected to the microcontroller. Best example of OS is Linux. It is used in many applications. In recent times, Linux has migrated from servers and workstations to be used in diverse embedded applications.


Real time ES


Ø  All Virtually embedded systems require real-time response while running more than one task.

Ø  A Real-time system is the system that must respond to signals within explicit and bounded time requirements.

Ø  To coordinate the process of sharing the CPU between multiple tasks, we use a program called a kernel. A kernel is the part of an operating system that schedules and dispatches tasks. For most ES we need a real time kernel because deterministic response time is required. In new ES real time kernels are used, e.g., Digital camera
ATM, Battery charger, Camcorders, Cell phones, etc.


Application:

  • Military and aerospace embedded software applications


From in-orbit embedded systems to jumbo jets to vital battlefield networks, designers of mission-critical aerospace and defense systems requiring real-time performance, scalability, and high-availabilityfacilities consistently turn to the LynxOS® RTOS and the LynxOS-178 RTOS for software certification to DO-178B.
Rich in system resources and networking services, LynxOS provides an off-the-shelf software platform with hard real-time response backed bypowerful distributed computing (CORBA), high reliability, software certification, and long-term support options.





Medical devices can now have the best of both worlds, with hard real-time applications running alongside commercial desktop operating systems on the same industry-standard Intel® processors.

·         Communications applications

Communication is essential to achieving a dependable distributed embedded system.An example of an event based communication system is the typical office network. Messages are generated by users whenever they send data to printers, access data on shared network drives, run applications that exist on other machines or send email to others in the network.



Various classes of embedded systems such as home media systems, portable players, smart phones, embedded medical devices and sensors, automotive embedded systems have surrounded us and with continued convergence of communications and computing functions within these devices, embedded systems are transforming themselves into really complex systems,  thus creating newer opportunities and challenges to develop and market more powerful, energy efficient processors, peripherals and other accessories.



Industrial automation (IA) is the vast area of embedded computing devoted to industrial applications. Apart from many tailored solutions (numerical controllers, hardware controllers, etc.) the scene is dominated by programmable logic controllers, widely known by the abbreviation PLC, which represent the most wide-spread class of embedded computing platforms.


Advantages:


Ø  Customization yields lower area means compact size
Ø  Lower power
Ø  Lower cost
Creating computer hardware requires precise engineering design & when it is an embedded system, it has to be more than reliable. Besides being low in cost & sufficiently high on performance.



Disadvantages:

Ø  Higher hardware/software
Ø  Need designer, compilers, debuggers
Ø  May result in delayed time.


Conclusion:
           


From what we saw above we conclude that embedded systems are very much advantageous. More & more developments are taking place in embedded systems. Even in INDIA software called mistral has developed text to speech and speech to text recognition technologies to give the car occupants the ultimate comfort. A   DSP based biomedical card developed by mistral allows remote   monitoring of up to 32 patients at a given time through central computer. This system is capable of acquiring ECG data from patient 7 analyzing it.

Tata InfoTech has done many remarkable projects in embedded application. Now a days readymade chip of micro controllers which are already programmed for specific functions, are available. It is very cheap also.

Finally we can say that embedded systems are electronic devices that incorporate a computer (usually a microprocessor) within their implementation.  A computer is used in such devices primarily as a means to simplify the system design and to provide flexibility.Often the user of the device is not even aware that a computer is present.

The day is not far when almost all automobiles would interact with computers on dashboards from ordering a pizza to booking tickets at nearest theater. Things would be as easy as giving orders to your servant.                                                                                                                                                                                     
Bibliography




1.     Embedded system  : by – Raj Kamal

2.     Embedded system : Wikipedia.com

3.  www.lynuxworks.com

4.  Embedded Systems Design

by Arnold S. Berger,

Proudly Powered by Blogger.