Module-3 Embedded System Notes
Module-3 Embedded System Notes
E.g. Electronic Toys, Mobile Handsets, Washing Machines, Air Conditioners, Automotive Control Units,
Set Top Box, DVD Player etc…
Based on Generation
Based on Complexity & Performance Requirements
Based on deterministic behavior
Based on Triggering
a) First Generation: The early embedded systems built around 8-bit microprocessors like 8085 and
Z80 and 4-bit microcontrollers
Ex: stepper motor control units, Digital Telephone Keypads etc.
b) Second Generation: Embedded Systems built around 16-bit microprocessors and 8 or 16-bit
microcontrollers, following the first generation embedded systems
Ex: SCADA, Data Acquisition Systems etc.
c) Third Generation: Embedded Systems built around high performance 16/32 bit
Microprocessors/controllers, Application Specific Instruction set processors like Digital Signal
Processors (DSPs), and Application Specific Integrated Circuits (ASICs).The instruction set is
complex and powerful.
Ex: Robotics, industrial process control, networking etc.
d) Fourth Generation: Embedded Systems built around System on Chips (SoC’s), Re- configurable
processors and multicore processors. It brings high performance, tight integration and
miniaturization into the embedded device market
Ex: Smart phone devices, MIDs etc.
a) Small Scale: The embedded systems built around low performance and low cost 8 or 16 bit
microprocessors/ microcontrollers. It is suitable for simple applications and where performance is not time
critical. It may or may not contain OS.
b) Medium Scale: Embedded Systems built around medium performance, low cost 16 or 32 bit
microprocessors / microcontrollers or DSPs. These are slightly complex in hardware and firmware. It may
contain GPOS/RTOS.
c) Large Scale/Complex: Embedded Systems built around high performance 32 or 64 bit RISC
processors/controllers, RSoC or multi-core processors and PLD. It requires complex hardware and software.
These system may contain multiple processors/controllers and co-units/hardware accelerators for offloading
the processing requirements from the main processor. It contains RTOS for scheduling, prioritization and
management.
Dept. of CSE, LAEC Bidar Page 2
Embedded Systems
Each Embedded Systems is designed to serve the purpose of any one or a combination of the following
tasks.
Data Collection/Storage/Representation
Data Communication
Monitoring
Control
1. Data Collection/Storage/Representation:-
Performs acquisition of data from the external world.
Data collection is usually done for storage, analysis, manipulation and transmission
The collected data may be stored directly in the system or may be transmitted to some other systems or it
may be processed by the system or it may be deleted instantly after giving a meaningful representation
2. Data Communication:-
Embedded Data communication systems are deployed in applications ranging from complex satellite
communication systems to simple home networking systems
Embedded Data communication systems are dedicated for data communication
The data communication can happen through a wired interface (like Ethernet, RS-
232C/USB/IEEE1394 etc) or wireless interface (like Wi-Fi, GSM,/GPRS, Bluetooth, ZigBee etc)
Network hubs, Routers, switches, Modems etc are
typical examples for dedicated data transmission embedded systems
Embedded systems with Signal processing functionalities are employed in applications demanding
signal processing like Speech coding, synthesis, audio video codec, transmission applications etc
4. Monitoring:-
Embedded systems coming under this category are specifically designed for monitoring purpose
They are used for determining the state of some variables using input sensors
They cannot impose control over variables.
Electro Cardiogram (ECG) machine for monitoring the heart beat of a patient is a typical example
for this
The sensors used in ECG are the different Electrodes connected to the patient‟s body
Measuring instruments like Digital CRO, Digital Multi meter, Logic Analyzer etc used in Control &
Instrumentation applications are also examples of embedded systems for monitoring purpose
5. Control:-
Embedded systems with control functionalities are used for imposing control over some variables
according to the changes in input variables
Embedded system with control functionality contains both sensors and actuators
Sensors are connected to the input port for capturing the changes in environmental variable or
measuring variable
The actuators connected to the output port are controlled according to the changes in input variable
to put an impact on the controlling variable to bring the controlled variable to the specified range
Air conditioner for controlling room temperature is a typical example for embedded system with
„Control‟ functionality
Air conditioner contains a room temperature sensing element (sensor) which may be a thermistor
and a handheld unit for setting up (feeding) the desired temperature
The air compressor unit acts as the actuator. The compressor is controlled according to the current
room temperature and the desired temperature set by the end user.
Real World
Embedded systems are basically designed to regulate a physical variable (such Microwave Oven) or to
manipulate the state of some devices by sending some signals to the actuators or devices connected to the
output port system (such as temperature in Air Conditioner), in response to the input signal provided by the
end users or sensors which are connected to the input ports. Hence the embedded systems can be viewed as
a reactive system.
The control is achieved by processing the information coming from the sensors and user interfaces and
controlling some actuators that regulate the physical variable.
Keyboards, push button, switches, etc. are Examples of common user interface input devices and LEDs,
LCDs, Piezoelectric buzzers, etc examples for common user interface output devices for a typical embedded
system.The requirement of type of user interface changes from application to application based on domain.
Some embedded systems do not require any manual intervention for their operation. They automatically
sense the input parameters from real world through sensors which are connected at input port. The sensor
information is passed to the processor after signal conditioning and digitization. The core of the system
performs some predefined operations on input data with the help of embedded firmware in the system and
sends some actuating signals to the actuator connect connected to the output port of the system.
The memory of the system is responsible for holding the code (control algorithm and other important
configuration details). There are two types of memories are used in any embedded system. Fixed memory
(ROM) is used for storing code or program. The user cannot change the firmware in this type of memory.
The most common types of memories
Used in embedded systems for control algorithm storage are OTP,PROM,UVEPROM,EEPROM and
FLASH .
An embedded system without code (i.e. the control algorithm) implemented memory has all the
peripherals but is not capable of making decisions depending on the situational as well as real world
changes. Memory for implementing the code may be present on the processor or may be implemented as a
separate chip interfacing the processor In a controller based embedded system, the controller may contain
internal memory for storing code such controllers are called Micro-controllers with on-chip ROM, eg.
Atmel AT89C51.
The core of the embedded system falls into any one of the following categories.
Microprocessor:
A silicon chip representing a Central Processing Unit (CPU), which is capable of performing
arithmetic as well as logical operations according to a pre-defined set of Instructions, which
is specific to the manufacturer
Dept. of CSE, LAEC Bidar Page 8
Embedded Systems
In general the CPU contains the Arithmetic and Logic Unit (ALU), Control Unit and
Working registers
Microprocessor is a dependent unit and it requires the combination of other hardware like
Memory, Timer Unit, and Interrupt Controller etc for proper functioning.
Intel claims the credit for developing the first Microprocessor unit Intel 4004, a 4 bit
processor which was released in Nov 1971
Developers of microprocessors.
Microcontroller:
A highly integrated silicon chip containing a CPU, scratch pad RAM, Special and
General purpose Register Arrays, On Chip ROM/FLASH memory for program
storage, Timer and Interrupt control units and dedicated I/O ports
Microcontrollers can be considered as a super set of Microprocessors
Microcontroller can be general purpose (like Intel 8051, designed for generic
applications and domains) or application specific (Like Automotive AVR from Atmel
Corporation. Designed specifically for automotive applications)
Since a microcontroller contains all the necessary functional blocks for independent
working, they found greater place in the embedded domain in place of
microprocessors
Microcontrollers are cheap, cost effective and are readily available in the market
Microprocessor Vs Microcontroller:
Microprocessor Microcontroller
A silicon chip representing a Central Processing Unit A microcontroller is a highly integrated chip that
(CPU), which is capable of performing arithmetic as contains a CPU, scratch pad RAM, Special and
well as logical operations according to a pre-defined General purpose Register Arrays, On Chip
set
of Instructions ROM/FLASH memory for program storage, Timer
and Interrupt control units and dedicated I/O ports
It is a dependent unit. It requires the combination of It is a self contained unit and it doesn’t require
other chips like Timers, Program and data memory external Interrupt Controller, Timer, UART etc for
chips, Interrupt controllers etc for functioning its functioning
Most of the time general purpose in design and Mostly application oriented or domain specific
operation
Doesn‟t contain a built in I/O port. The I/O Port Most of the processors contain multiple built-in I/O
functionality needs to be implemented with the help ports which can be operated as a single 8 or 16 or 32
of
external Programmable Peripheral Interface Chips bit Port or as individual port pins
like
8255
Targeted for high end market where performance is Targeted for embedded market where performance is
important not so critical (At present this demarcation is invalid)
Limited power saving options compared to Includes lot of power saving features
microcontrollers
RISC CISC
Lesser no. of instructions Greater no. of Instructions
Instruction Pipelining and increased execution Generally no instruction pipelining feature
speed
Orthogonal Instruction Set (Allows each Non Orthogonal Instruction Set (All instructions
instruction to operate on any register and use are not allowed to operate on any register and
any addressing mode) use any addressing mode. It is instruction
specific)
Operations are performed on registers only, the Operations are performed on registers or
only memory operations are load and store memory depending on the instruction
Large number of registers are available Limited no. of general purpose registers
Programmer needs to write more code to . A programmer can achieve the desired
execute a task since the instructions are simpler functionality with a single instruction which in
ones turn provides the effect of using more simpler
single instructions in RISC
Single, Fixed length Instructions Variable length Instructions
Less Silicon usage and pin count More silicon usage since more additional
decoder logic is required to implement the
decoder logic is required to implement the
With Harvard Architecture Can be Harvard or Von-Neumann Architecture
Endianness specifies the order in which the data is stored in the memory by processor
operations in a multi byte system (Processors whose word size is greater than one byte).
Suppose the word length is two byte then data can be stored in memory in two different ways
Higher order of data byte at the higher memory and lower order of data byte at
location just below the higher memory
Lower order of data byte at the higher memory and higher order of data byte at
location just below the higher memory
Little-endian means the lower-order byte of the data is stored in memory at the lowest
address, and the higher-order byte at the highest address. (The little end comes first)
Big-endian means the higher-order byte of the data is stored in memory at the lowest address,
and the lower-order byte at the highest address. (The big end comes first.)
small area in the total system and thereby helps in the design of smaller systems with
high capabilities/functionalities.
ASICs can be pre-fabricated for a special application or it can be custom fabricated by
using the components from a re-usable „building block‟ library of components for a
particular customer application
Fabrication of ASICs requires a non-refundable initial investment (Non Recurring
Engineering (NRE) charges) for the process technology and configuration expenses
If the Non-Recurring Engineering Charges (NRE) is born by a third party and the
Application Specific Integrated Circuit (ASIC) is made openly available in the
market, the ASIC is referred as Application Specific Standard Product (ASSP)
The ASSP is marketed to multiple customers just as a general-purpose product , but to
a smaller number of customers since it is for a specific application.
Some ASICs are proprietary products; the developers are not interested in revealing
the internal details.
2.2 MEMORY
The MROM is permanent in bit storage, it is not possible to alter the bit
information.
Erasable Programmable Read Only (EPROM) memory gives the flexibility to re-
program the same chip.
During development phase , code is subject to continuous changes and using an OTP
is not economical.
EPROM stores the bit information by charging the floating gate of an FET
Bit information is stored by using an EPROM Programmer, which applies high
voltage to charge the floating gate
EPROM contains a quartz crystal window for erasing the stored information. If the
window is exposed to Ultra violet rays for a fixed duration, the entire memory will be
erased
Even though the EPROM chip is flexible in terms of re-programmability, it needs to
be taken out of the circuit board and needs to be put in a UV eraser device for 20 to 30
minutes
Erasable Programmable Read Only (EPROM) memory gives the flexibility to re-
program the same chip using electrical signals
The information contained in the EEPROM memory can be altered by using electrical
signals at the register/Byte level
They can be erased and reprogrammed within the circuit
These chips include a chip erase mode and in this mode they can be erased in a few
milliseconds
It provides greater flexibility for system design
The only limitation is their capacity is limited when compared with the standard ROM
(A few kilobytes).
The advantages of DRAM are its high density and low cost compared to SRAM
The disadvantage is that since the information is stored as charge it gets leaked off
with time and to prevent this they need to be refreshed periodically
Special circuits called DRAM controllers are used for the refreshing operation. The
refresh operation is done periodically in milliseconds interval
SRAM Vs DRAM:
SRAM Cell DRAM Cell
Made up of 6 CMOS transistors (MOSFET) Made up of a MOSFET and a capacitor
Doesn‟t Require refreshing Requires refreshing
Low capacity (Less dense) High Capacity (Highly dense)
More expensive Less Expensive
Fast in operation. Typical access time is 10ns Slow in operation due to refresh
requirements. Typical access time is 60ns.
Write operation is faster than read operation.
2.3.1 Sensors
A transducer device which converts energy from one form to another for any
measurement or control purpose. Sensors acts as input device
Eg. Hall Effect Sensor which measures the distance between the cushion and magnet
in the Smart Running shoes from adidas
Example: IR, humidity , PIR(passive infra red) , ultrasonic , piezoelectric ,
smoke sensors
2.3.2 Actuator:
The I/O subsystem of the embedded system facilitates the interaction of the embedded
system with external world
The interaction happens through the sensors and actuators connected to the Input and
output ports respectively of the embedded system
The sensors may not be directly interfaced to the Input ports, instead they may be
interfaced through signal conditioning and translating systems like ADC,
Optocouplers etc