Embedded Systems...

Preview:

Citation preview

Embedded Systems Introduction

Prof. Prabhat Ranjan

(Material based on Wikipedia.org)

Definition

● An embedded system is a special-purpose system in which the computer is completely encapsulated by the device it controls.

● Unlike a general-purpose computer, such as a personal computer, an embedded system performs one or a few pre-defined tasks, usually with very specific requirements.

● Since the system is dedicated to specific tasks, design engineers can optimize it, reducing the size and cost of the product.

Examples of embedded systems

● automatic teller machines (ATMs)● avionics, such as inertial guidance systems, flight

control hardware/software and other integrated systems in aircraft and missiles

● cellular telephones and telephone switches● engine controllers and antilock brake controllers

for automobiles● home automation products, such as thermostats, air

conditioners, sprinklers, and security monitoring systems

Examples of embedded systems-2

● handheld calculators● household appliances, including microwave ovens,

washing machines, television sets, DVD players/recorders

● medical equipment● handheld computers● videogame consoles● even computer peripherals themselves such as

routers and printers have embedded processors

History

● In the 1960s, computers possessed an ability to acquire, analyze, process data, and make decisions at very high speeds.

● However there were some disadvantages with the computer controls. – high cost, – program complexity, and – hesitancy of personnel to learn

History-2

● However the new concept of electronic devices evolved - Programmable controllers

● Later became a part of embedded systems ● Concept developed from a mix of computer

technology, solid state devices, and traditional electromechanical sequences

● The first recognizably modern embedded system was the Apollo Guidance Computer, developed by Charles Stark Draper at the MIT

● Each flight to the moon had two● They ran the inertial guidance systems of both the

command module and LEM● At the project's inception, the Apollo guidance

computer was considered the riskiest item● Use of the then new monolithic integrated circuits,

to reduce the size and weight, increased this risk.

Apollo Guidance Computer

● First mass-produced embedded system - Autonetics D-17 guidance computer for the Minuteman missile ( in 1961)

● Built from discrete transistor logic and had a hard disk for main memory

● Minuteman II - production in 1966, the D-17 was replaced with a new computer that was the first high-volume use of ICs

● Reduced prices on quad nand gate ICs from $1000/each to $3/each, permitting their use in commercial products.

● Since these early applications in the 1960s, where cost was no object, embedded systems have come down in price.

● There has also been an enormous rise in processing power and functionality.

● For example the first microprocessor was the Intel 4004, which found its way into calculators and other small systems, but required external memory and support chips

● By the mid-1980s, most of the previously external system components had been integrated into the same chip as the processor, resulting in integrated circuits called microcontrollers, and widespread use of embedded systems became feasible.

● Cost of a microcontroller fell below $1- feasible to replace expensive knob-based analog components such as potentiometers and variable capacitors with digital electronics controlled by a small microcontroller with up/down buttons or knobs

● By the end of the 80s, embedded systems were the norm rather than the exception for almost all electronics devices, a trend which has continued since

Characteristics

● Embedded systems are designed to do some specific task, rather than be a general-purpose computer for multiple tasks

● Some also have real-time performance constraints that must be met, for reason such as safety and usability; others may have low or no performance requirements, allowing the system hardware to be simplified to reduce costs

Characteristics

● Their functionality examines the interface input status, and in response to it, it controls the output interface.

● In order to carry out the control plan, several logic combinations are needed.

● They are called as program and are stored in the memory of the device.

● The period of time during the program execution is called a scan. During the scan all inputs are tested, the control plan is evaluated and the outputs are updated.

● The input and output devices such as switches, motors and lights, which are attached to the interface, are called field devices

● Programmable controllers do not always come in separate blocks.

● Very often they are built-in to devices which can be classified as field devices

● They can be integrated into the field devices "housing", and can even be a part of a circuit board of the field device

● That is why such systems are called embedded devices

● For high volume systems such as portable music players or mobile phones, minimizing cost is usually the primary design consideration

● Engineers typically select hardware that is just “good enough” to implement the necessary functions

● For example, a digital set-top box for satellite television has to process large amounts of data every second, but most of the processing is done by custom integrated circuits

● The embedded CPU "sets up" this process, and displays menu graphics, etc. for the set-top's look and feel

● For low-volume or prototype embedded systems, personal computer hardware can be used, by limiting the programs or by replacing the operating system with a real-time operating system

● The software written for embedded systems is often called firmware, and is stored in ROM or Flash memory chips rather than a disk drive.

● It often runs with limited hardware resources: small or no keyboard, screen, and little RAM memory

● Embedded systems reside in machines that are expected to run continuously for years without errors, and in some cases recover by themselves if an error occurs.

● Therefore the software is usually developed and tested more carefully than that for personal computers, and unreliable mechanical moving parts such as disk drives, switches or buttons are avoided

● Recovery from errors may be achieved with techniques such as a watchdog timer that resets the computer unless the software periodically notifies the watchdog

User Interfaces

● The physical nature of the user interface depends on the type of programmable controller or an embedded system

● It can be,in form of some terminal contacts on device's body,on circuit board , or just some intermediate point on a circuit board

● In reality, more sophisticated devices such as computer ports, dedicated ports, are in use

● Very often user interface comes on basis of some standard like RS232, USB, Bluetooth, GPIB, etc.

Simple Interfaces

● Embedded systems range from no user interface at all - dedicated only to one task - to full user interfaces similar to desktop operating systems in devices such as PDAs

● In between are devices with small character- or digit-only displays and a few buttons

Simple Interfaces

● One approach widely used in embedded systems without sophisticated displays, uses a few buttons to control a menu system, with some for movement and some for adjustments

● On such devices simple, obvious, and low-cost approaches like red-yellow-green lights (mirroring traffic lights) are common

In more complex systems

● On larger screens, a touch-screen or screen-edge soft buttons also provides good flexibility while minimising space used

● The advantage of this system is that the meaning of the buttons can change with the screen, and selection can be very close to the natural behavior of pointing at what's desired

● Handheld systems often have a screen with a "joystick button" for a pointing device

In more complex systems

● The rise of the World Wide Web has given embedded designers another quite different option, by providing a web page interface over a network connection

● This is successful for remote, permanently installed equipment

● This avoids the cost of a sophisticated display, yet provides complex input and display capabilities when needed, on another computer

CPU Platform

● There are many different CPU architectures used in embedded designs such as ARM, MIPS, Coldfire/68k, PowerPC, x86, PIC, 8051, Atmel AVR, Renesas H8, SH, V850, FR-V, M32R etc.

● This in contrast to the desktop computer market, which is currently limited to just a few competing architectures

CPU Platform

● PC/104 is a typical base for small, low-volume embedded and ruggedized system design. These often use DOS, Linux, NetBSD, or an embedded real-time operating system such as QNX or Inferno.

● A common configuration for very-high-volume embedded systems is the system on a chip (SoC), an application-specific integrated circuit (ASIC), for which the CPU was purchased as intellectual property to add to the IC's design.

CPU Platform

● A related scheme is to use a field-programmable gate array (FPGA), and program it with all the logic, including the CPU

Tools

● As for other software, embedded system designers use compilers, assemblers, and debuggers to develop embedded system software

● However, they may also use some more specific tools:– An in-circuit emulator (ICE) is a hardware device that

replaces or plugs into the microprocessor, and provides facilities to quickly load and debug experimental code in the system

Tools

– Utilities to add a checksum or CRC to a program, so the embedded system can check if the program is valid

– For systems using digital signal processing, developers may use a math workbench such as MathCad or Mathematica to simulate the mathematics

– Custom compilers and linkers may be used to improve optimisation for the particular hardware

– An embedded system may have its own special language or design tool, or add enhancements to an existing language

Tools

● Software tools can come from several sources:– Software companies that specialize in the embedded

market– Ported from the GNU software development tools

(GNU cross compiler)– Sometimes, development tools for a personal computer

can be used if the embedded processor is a close relative to a common PC processor

Debugging

● Embedded Debugging may be performed at different levels, depending on the facilities available, ranging from assembly- or source-level debugging with an in-circuit emulator, to output from serial debug ports, to an emulated environment running on a personal computer

Debugging

● As the complexity of embedded systems grows, higher level tools and operating systems are migrating into machinery where it makes sense

● For example, cellphones, personal digital assistants and other consumer computers often need significant software that is purchased or provided by a person other than the manufacturer of the electronics

Debugging

● In these systems, an open programming environment such as Linux, NetBSD, OSGi or Embedded Java is required so that the third-party software provider can sell to a large market

● Most such open environments have a reference design that runs on a PC

● Much of the software for such systems can be developed on a conventional PC

Debugging

● However, the porting of the open environment to the specialized electronics, and the development of the device drivers for the electronics are usually still the responsibility of a classic embedded software engineer.

Examples from our projects

Collar Design : wildCENSE

ZzZz!

ZzZzZzZz

Sequence of operation

TigerCense – IR Image Sensor Networks

Micro-Controller

microSD card Power SupplyReal Time Clock

Energy Harvesting and Battery Recharging Module

Light sensor

PIR sensor

IR flash with superCap Camera

Radio Module

Communication Power Sensing Processing

Relationship with other courses

● ESP => Introduction to Sensor Networks (Device Design) => Sensor Network (Systems Approach)

● ESP covers 8/16/32 bit micro-controller/processor● 8/16 bit uC needs no OS or special OS● 32 bit uC/uP can use general purpose OS such as

Linux● DSA course focuses on FPGA using HDL(useful

in many embedded system)● DSP focuses on use of specialized processors

(useful in many embedded systems as well)

Grading

● Projects● Presentation● Exams/Assignments● Class attendance/ Participation● Lab work

Recommended