Orientation
To
EMBEDDED SYSTEMS
Yogesh Misra Mody Institute of Technology & Science (Deemed University) Faculty of Engineering & Technology Sikar [Raj.]
[Q] What is a controller?
Ans. A controller is used to control some process.
[Q] How much big it is? Ans. In 50s, it was of the size of room, in 60s it was of the size of a board and now it is fitted in a chip due to the development in the IC fabrication technology. [Q] What is an Embedded System ? Ans. An embedded system is a controller which is embedded in a system to perform single task repeatedly OR An Embedded System is a microprocessor based system that is embedded as a subsystem, in a larger system
General Characteristics of Embedded Systems
Perform a single / few task Reactive and meet real time constrained Tightly constrained
Embedded System Structure
Sensor ADC Processor DAC Actuator
Essential Components Processor (P, C , DSP or ASIC) Sensor (it convert a physical quantity into electrical signal) Converters (ADC and DAC) Actuator (it transforms electrical energy into mechanical energy) Memory (On-chip / Off chip) Communication path with the interacting environment
Application of Embedded Systems
microwave oven air conditioner cell phones swing machine Printer fuel injection control ABS Many more
(1) Automated Car Assembly Plant
At each workstation, a sensor senses the arrival of the partially assembled car chassis.
As soon as the partially assembled car chassis is sensed, the workstation begins to perform its work on the car chassis.
Car Chassis Car Chassis Car Chassis
Car Chassis
Car Chassis
Fit Engine
Fit Door
Fit Wheel
Spray Paint
Finished Car
Conveyor Belt
(2) Chemical Plant Control
A real-time computer monitors periodically the pressure, temperature and plant conditions. Based on the values of these parameters the real-time computer generates a corrective signal which control the reaction rate at that instant within certain predetermined time bounds.
(3) Multi-Point Fuel Injection (MPFI) System
MPFI is a real-time system that controls the rate of fuel injection and allows the engine of a car to operate at its optimal efficiency. In older model of cars, a mechanical device called carburettor was used to control the fuel injection rate to the engine.
A microcontroller (embedded system) receives the data from various sensors. These sensors constantly monitor the engine rpm, vehicle road speed, emission gas content, exhaust temperature, the engine coolant temperature, etc.
Depending upon the data received by various sensors the microcontroller control the PULSE WIDTH
which ultimately controls the duration for which the injector valve is open.
(4) Laser Printer
Laser printers have microcontrollers embedded in them to control different activities associated with printing. The important activities that a microcontroller embedded in a laser printer performs include: getting data from the communication port, typesetting fonts, sensing paper jams, noticing when the printer runs out of paper, sensing when the user presses a button on the control panel, displaying various messages to the user, etc.
(5) Anti-Lock Braking System (ABS)
The ABS is designed to help the driver maintain steering control during hard braking, especially in slippery conditions. Due to sudden application of brake a car without ABS skids out on a slippery road. This is because all the wheels are locked up when the brake pedal is holding down. As a result, you lose the ability to steer the vehicle. The ABS prevents the wheels from locking up and help us in maintain steering control during braking.
How the actual ABS system works
Major components of the typical ABS system include:
(i) (ii) Four speed sensors (one at each wheel) An electronic control unit (microcontroller)
(iii) A hydraulic control unit. The microcontroller constantly monitors the signal from each wheel speed sensor. When it senses that any of the wheels are approaching lock up during braking, the microcontroller sends the signal to the hydraulic control unit, which modulates the braking pressure for a corresponding wheel(s) preventing it from locking up.
(A) Wheel speed sensor
(B) ABS control module
(C) Hydraulic motor and pressure release valves
(D) Brake pipe leading to caliper
Due to heavy brake pedal application let the green wheel is about to lock up. The ABS control module (B)
detects this locking up of the wheel through the sensor (A) and reacts by releasing the brake pressure slightly by rapidly opening a pressure release valve (C). This lowers the pressure in the brake pipe (D) which causes the brake caliper to loosen its grip on the brake disc on the locking wheel. If this corrects the locked wheel, the hydraulic motor (C) will build up the pressure again to the optimum braking force and the valve will revert to the closed position.
Design Metrics
[To be optimized by design engineer] 1. NRE Cost 2. Unit Cost
3. Size 4. Power
5. Performance 6. Flexibility 7. Time-to-Prototype
8. Time-to-market 9. Maintainability 10. Safety and Reliability
Embedded System Design Technology
1. Processor Technology
It relates to the architecture of processor used to implement the desired functionality
2. IC Technology
It relates with the different technologies involve for the implementation of processors onto an IC
3. Design Technology
It relates with the way how we convert our idea of desired functionality into an implementation
1. Processor Technology
(A) General-Purpose Processors
Advantages: Low Time to market Low NRE Cost ,
High Flexibility
Unit cost low for small quantities
Disadvantages: Unit cost high for large quantities Size and power is more
1. Processor Technology
(B) Single Purpose Processors
Advantages: Fast performance Size and power is small
Unit cost low for large quantities
Disadvantages: High NRE High Time to market Low flexibility Unit cost high for small quantities Size and power is more
1. Processor Technology
(C) Application-Specific Processors (ASIP)
It is a programmable processor optimized for a particular class of applications having common characteristics.
Embedded control application
Digital Signal Processing application
Telecommunication application
IC Technology Full Custom ASIC Technology
Full Custom ASICs are designed from scratch for complex, one-of-a-kind applications.
Advantages of the full custom ASIC are:
* Silicon area is small * High processing speed * Low power dissipation
Disadvantages of the full custom ASIC are:
* Maximum design effort * Longest time-to-market
IC Technology Semi Custom ASIC Technology
Semi Custom ASICs implement their functionality by using pre-designed building blocks, called cells.
Advantages of the Semi custom ASIC are:
* Reduced design effort * Reduced time-to-market
Disadvantages of the full custom ASIC are:
* More design effort * Long time-to-market
IC Technology
Standard Cell Based Design
(i) A logic is built by combining standard logic blocks (called cells) to form the overall logic function.
(ii)
The manufacturer provides a Standard library of such cells.
(iii) Each cell is deigned at transistor level.
Various Cells
VDD
VDD
NOT
In
out
GND
GND
VDD
VDD
VDD
VDD
In 1
In 1
NAND2
NOR2
out In 2
out
In 2 GND GND GND
GND
Creating Cell F using Basic cells
VDD
NOT
NAND2
NOR2
F
GND
VDD
VDD
Cell F
F
GND
GND
* Now Cell F is as basic as cell NOT, cell NAND and cell NOR
Standard Cell Based Design
C1 C2 C3 C4 C5 C6 C7 C8
F1
F2
F3
Final Design
Gate Array Based Design
Reduce development cost by reducing no of custom Masks required Now suppose out of 12 masks , 10 are common and shared by 100 different customers and only two are Customer programmable Every design is made of interconnection of N and P Transistors! From an array of such transistors any Circuit can potentially be made
Step-I
An array of uncommitted transistors are fabricated on the chip using standard mask.
Step-II
As per the requirement uncommitted transistors are interconnected by defining the metal interconnect using custom mask.
The design time is less because designer can purchase the uncommitted transistors chip from the market and he has to concentrate only on the interconnection part.
Uncommitted Transistor Array
Gate Array Design for 2 input NAND gate
Programmable Logic Devices (PLDs)
(1) PLDs were first introduced in 1970 (2) PLD is a user configurable chip (3) PLD consist of logic gates and programmable switches
(4) In PLD technology a designer purchase the IC (PLD) before the start of the design.
(5) The design is implemented in PLD by programming. The programming means creating or destroying the connections between the logic gates. (6) No mask is required.
Various types of PLDs available are : (1) ROM (Read Only Memory) (2) PLA (Programmable Logic Array) (3) PAL (Programmable Array Logic) (4) CPLD (Complex PLD) (5) FPGA (Field Programmable Gate Array)
PLA
X1 X2
...................
Xn
Input Buffers & Inverters X1 X1 X2 X2 .. Xn Xn P1 P2 Programmable OR Plane
..
Programmable AND Plane
Pk
F1 F2
Fm
Gate level diagram of PLA
2 Inputs, 3 Product terms and 2 Outputs A B
Programmable AND Plane
Output-1 Output-2 Programmable OR Plane
Implement OF Half Adder In PLA.
A B AB
AB AB
Sum
Carry
Programmable Array Logic (PAL)
X1 X2 Xn
Input Buffers & Inverters
X1 X1 X2 X2 .. Xn Xn
Programmable AND Plane
P1 P2 Pk
Fixed OR Plane
..
F1 F2
Fm
Gate level diagram of PAL
2Inputs, 4 Product terms and 2 Outputs
A B
Output-1
Output-2
Programmable AND Plane Fixed OR Plane
Design of BCD to Excess-3 code converter using PAL
B3 B2 B1 B0
P1
E0
P2
P3 P4 P5 P6
E1
E2
P7
P8
P9
E3
B3
B2
B1
B0
P1
P2
P3 P4 P5 P6
P7
P8 P9
E3
E2
E1
E0
FPGA
PLD`S[Like ROM ,PAL,PLA,& CPLD] are used for two level logic implementation.[2-level logic is useful for relatively small logic function]. FPGA`s are used for multi-level logic implementation ie for complex logic. FPGA`s can be programmed while it is in the circuit.
Basic elements of FPGA : CLB(Combinational Logic Block) PIA(Programmable Interconnect Array) I/O (Input output) Pins (1). CLB : FPGA contains two dimensional array of CLB`s .The required logic is implemented in CLB`s.In CLB the basic element to store a logic is LUT. A flipflop is generally used as storing element in LUT for storing one bit. Generally 4-input LUT is used. (2). PIA : a pia is used to interconnect two CLB`s. The PIA`s are organized as horizontal and vertical channels. Interconnections are required not only between the CLB`s and wires but also between horizontal and vertical wires. (3). I/O Blocks : Input /Output pins are referred as I/O Blocks.Any pin can be made input or output pin through programming.
Field Programmable Gate Array
A Comparison Full Custom
Performance Very High Medium
Semi custom
Standard Cell GateArray Medium
FPGA
Low
Silicon Utilization Time-to-market
Volume
Very High Very Long
Very High
Medium Long
High
Low Fast
Medium
Low Very Fast
Low
Design Technology
[It is the way by which we convert the idea of our desired functionality into an implementation]
Design Idea
VHDL Model Simulation Simulated Waveforms Synthesis
Circuit Generated
Circuit Implemented
Simulation Tool
VHDL Model
Compile It (e.g Modelsim)
Syntax Error Exists
Generated Waveforms
Synthesis Tool
Inputs to Synthesis Tool are: - HDL Description - Device Selection (Target Technology) - Information about design priority ( area vs speed )
Output of Synthesis Tool: - Gate level Netlist [EDIF file]
VHDL Model Information about Device
Design Priority (area vs speed) Synthesis Tool (e.g Leonardospectrum)
Netlist Generated for Target Technology
Place & Route Tool
Place tool takes the gate level netlist generated by Synthesis tool and figure out which logic blocks in the chip should contain which logic and where these logic blocks are placed inside the chip (this is called floor planning). Route Tool makes interconnections between various logic blocks.
EDIF File
Place & Route Tool
Bit Map File [ for FPGA ] GDS II File [ for cell based design ]
Technology Schematic of Half Adder
Figure 20 Technology Schematic [Half Adder]
Result of a Place Tool after placement of various logic blocks
Logic inside FPGA