Академический Документы
Профессиональный Документы
Культура Документы
UNIT - 1
INTRODUCTION TO EMBEDDED SYSTEMS – 1: Embedded systems; Processor embedded into a
system; Embedded hardware units and devices in a system; Embedded software in a system; Examples of
embedded systems; Design process in embedded system.
UNIT - 2
INTRODUCTION TO EMBEDDED SYSTEMS – 2, DEVICES - 1: Formalization of system design;
Design process and design examples; Classification of embedded systems; Skills required for an
embedded system designer.I/O types and examples; Serial communication devices; Parallel device ports;
Sophisticated interfacing features in device ports.
UNIT - 3
DEVICES - 2, COMMUNICATION BUSES FOR DEVICE NETWORKS: Wireless devices; Timer
and counting devices; Watchdog timer; Real time clock; Networked embedded systems; Serial bus
communication protocols; Parallel bus device protocols; Internet enabled systems; Wireless and mobile
system protocols.
UNIT - 4
DEVICE DRIVERS AND INTERRUPTS SERVICE MECHANISM: Device access without
interrupts; ISR concept; Interrupt sources; Interrupt servicing mechanism; Multiple interrupts; Context
and the periods for context-switching, interrupt latency and deadline; Classification of processors’
interrupt service mechanism from context-saving angle; Direct memory access; Device drivers
programming.
UNIT - 5
PROGRAM MODELING CONCEPTS, PROCESSES, THREADS, AND TASKS: Program models;
DFG models; State machine programming models for event controlled program flow; Modeling of
multiprocessor systems. Multiple processes in an application; Multiple threads in an application; Tasks
and task states; Task and data; Distinctions between functions, ISRs and tasks.
UNIT - 6
REAL-TIME OPERATING SYSTEMS – 1: Operating System services; Process management; Timer
functions; Event functions; Memory management; Device, file and I/O sub-systems management;
Interrupt routines in RTOS environment and handling of interrupt source calls.
UNIT - 7
REAL-TIME OPERATING SYSTEMS – 2: Real-Time Operating Systems; Basic design using an
RTOS; RTOS task scheduling models, interrupt latency and response times of the tasks as performance
metrics; OS security issues.
DEPT OF CSE, JCET Page 1
Embedded System(17CS563)
UNIT - 8
EMBEDDED SOFTWARE DEVELOPMENT, TOOLS: Introduction; Host and target machines;
Linking and locating software; Getting embedded software in to the target system; Issues in hardware-
software design and co-design; Testing on host machine; Simulators; Laboratory tools.
TEXT BOOK:
1. Embedded Systems Architecture: Programming and Design – Rajkamal, 2nd Edition, Tata
McGraw Hill, 2008.
REFERENCE BOOKS:
1. Computers as Components: Principles of Embedded Computer System Design – Wayne
Wolf, Elsevier, 2005.
2. Embedded Systems Architecture – Tammy Noergaard, Elsevier, 2005.
3. Embedded Systems Design – Steve Heath, 2nd Edition, Elsevier, 2003.
4. Embedded/Real-Time Systems: Concepts, Design and Programming: The Ultimate
Reference – Dr. K.V.K.K. Prasad, Dreamtech Press, 2004.
5. Embedded C – Michael J.Point, Pearson Education, 2002.
5 41-45
PROGRAM MODELING CONCEPTS, PROCESSES,
THREADS, AND TASKS
UNIT - 1
INTRODUCTION TO EMBEDDED SYSTEMS – 1:
Embedded systems
Processor embedded into a system
Embedded hardware units and devices in a system
Embedded software in a system
Examples of embedded systems
Optimizing the microprocessors, ASIPs and single purpose processors in the system
Optimizing according to the performance, power dissipation, cost and other design metrics the
system Optimizing hardware (memory RAM, ROM or internal and external flash or secondary
memory in the system, peripherals and devices internal and external to the system, ports and buses
in the system and power source or battery in the system).
Design metrics examples –power dissipation, physical size, number of gates and engineering,
prototype dissipation, physical size, number of gates and engineering, prototype development and
manufacturing costs.
Clock Rate Reduction Operating Voltage Reduction Wait, Stop and Cache Disable Instructions
Clever real- time programming. It is by using of 'Wait' and 'Stop' instructions and disabling or
controlling certain units when not needed is one method of saving power during program
execution.
iv> Disable use of certain structural units of the processor to reduce power dissipation
Caches—when not necessary and Keep in disconnected state those structure units that are not
needed during a particular software-portion execution, for example display screen, timers or IO
Meeting the deadline of all processes in the system while keeping the memory, power dissipation,
processor clock rate and cost at minimum is a challenge
Ability to offer the different versions of a product for marketing and offering the product in
advanced versions later on.
Microcontroller — Intel, Motorola, Hitachi, TI, Philips and ARM For example, an Intel® —
MCS51, Philips® Motorola — 68HC11, 68HC12, 68HC16
i) Processor : Program Flow and data path Control ,Unit (CU) —includes a fetch unit for fetching
instructions from the memory.Processor Execution Unit (EU) —includes circuits for arithmetic
and logical unit (ALU), and for instructions for a program control task, say, data transfer
instructions, halt, interrupt, or jump to another set of instructions or call to another routine or
sleep or reset
ii) Power Source
1. System own supply with separate supply rails for IOs, clock, basic processor and memory and
analog units, or
2. Supply from a system to which the embedded system interfaces, for example in a network
card, or
3. Charge pump concept used in a system of little power needs, for examples, in the mouse or
contact-less smart card.
Interrupt Handling element for the external port interrupts, IO interrupts, timer and RTC
interrupts, software interrupts and exceptions
vii )IO Communication Unit a. Communication Driver(s) : Network Ethernet or serial driver
to communicate with host embedded system Expansion Facility … Serial Bus(es): For example,
UART (512 kbaud/s), 1-wire CAN (33 kbps), Industrial I C (100kbps), SM I C Bus 2
(100 kbps), SPI (100 kbps), Fault tolerant CAN (110 kbps), Serial Port (230 kbps), MicroWire
(300 kbps), … Parallel Bus(es): PCI, PCI-X
Transform and transaction mapping Transform and transaction mapping For example, an
image is input data to a system; it can have a different number of pixels and colors of each pixel.
The system has to store or process each pixel and color Transform mapping of image is done by
appropriate compression and storage algorithms. Transaction mapping is done to define the
sequence of the images
Processors in Embedded system
UNIT - 2
Skills required for an embedded system designer. I/O types and examples
Serial communication devices; Parallel device ports
Sophisticated interfacing features in device ports.
Mapping : Mapping into various representations done considering the software requirements.
For example, data flow in the same path during the program flow can be mapped together as a
single entity.
Transform and transaction mapping Transform and transaction mapping For example, an
image is input data to a system; it can have a different number of pixels and colors of each pixel.
The system has to store or process each pixel and color Transform mapping of image is done by
appropriate compression and storage algorithms. Transaction mapping is done to define the
sequence of the images
ii>Interpreter
iii>Complier
iv>Assembler
v>Simulator
vii>Locator
A charge pump is a kind of DC to DC converter that uses capacitors as energy storage elements
to create either a higher or lower voltage power source. Charge pump circuits are capable of high
efficiencies, sometimes as high as 90-95% while being electrically simple circuits.
Charge pumps use some form of switching device(s) to control the connection of voltages to the
capacitor. For instance, to generate a higher voltage, the first stage involves the capacitor being
connected across a voltage and charged up. In the second stage, the capacitor is disconnected
from the original charging voltage and reconnected with its negative terminal to the original
positive charging voltage. Because the capacitor retains the voltage across it (ignoring leakage
effects) the positive terminal voltage is added to the original, effectively doubling the voltage.
The pulsing nature of the higher voltage output is typically smoothed by the use of an output
capacitor.
This is the charge pumping action, which typically operates at tens of kilohertz up to several
megahertz to minimize the amount of capacitance required. The capacitor used as the charge
pump is typically known as the "flying capacitor".
The clock controls the time for executing an instruction .after the power supply, the clock
basic unit of a system. a processor needs a clock oscillator circuit. The clock controls the
various clocking requirements of a system the cpu of the system timers and the cpu machine
cycles are for fetching codes and the data forms memory and then decoding and executing
them at the processor and for transferring the result to memory.
In VLSI devices, the power-up reset is an electronic device incorporated into the integrated
circuit that detects the power applied to the chip and generates a reset impulse that goes to the
entire circuit placing it into a known state. A simple PUR is composed by an RC device that
charges with the rising of the supply voltage. A schmitt trigger is used so that the rising charged
voltage of the RC network generates an impulse. This impulse is generated based on the two
threshold voltages of the schmitt trigger. When the input voltage at the schmitt trigger coming
from the RC network reaches the first threshold voltage the output of the schmitt trigger switches
so that it generates the first edge of the input. The charging of the RC network should be long
enough so that the PUR can reset all the internal circuits before the charging voltage reaches the
other threshold voltage of the schmitt trigger and the output to switch back.
One of the issues with using RC network to generate power up reset pulse is the sensitivity of the
R and C values to the power-supply ramp characteristics. When the power supply ramp is rapid,
the R and C values can be calculated so that the time to reach the switching threshold of the
schmitt trigger is enough to apply a long enough reset pulse. When the power supply ramp itself
is slow, the RC network tends to get charged up along with the power-supply ramp up. So when
the input schmitt stage is all powered up and ready, the input voltage from the RC network
would already have crossed the schmitt trigger point. This means that there might not be a reset
pulse supplied to the core of the VLSI.
A watchdog timer (or computer operating properly (COP) timer) is a computer hardware or
software timer that triggers a system reset or other corrective action if the main program, due to
some fault condition, such as a hang, neglects to regularly service the watchdog (writing a
"service pulse" to it, also referred to as "kicking the dog", ―petting the dog‖, "feeding the
watchdog" or "waking the watchdog"). The intention is to bring the system back from the
nonresponsive state into normal operation.
Watchdog timers can be more complex, attempting to save debug information onto a persistent
medium; i.e. information useful for debugging the problem that caused the fault. In this case a
second, simpler, watchdog timer ensures that if the first watchdog timer does not report
completion of its information saving task within a certain amount of time, the system will reset
with or without the information saved. The most common use of watchdog timers is in embedded
systems, where this specialized timer is often a built-in unit of a microcontroller.
Even more complex watchdog timers may be used to run untrusted code in a sandbox.[2]
Watchdog timers may also trigger fail-safe control systems to move into a safety state, such as
turning off motors, high-voltage electrical outputs, and other potentially dangerous subsystems
until the fault is cleared.
Skills required for an embedded system designer. I/O types and examples
Data Communication is one of the most challenging fields today as far as technology
development is concerned. Data, essentially meaning information coded in digital form, that is, 0s
and 1s, is needed to be sent from one point to the other either directly or through a network.
And when many such systems need to share the same information or different information through
the same medium, there arises a need for proper organization (rather, ―socialization‖) of the whole
network of the systems, so that the whole system works in a cohesive fashion.
Therefore, in order for a proper interaction between the data transmitter (the device needing to
commence data communication) and the data receiver (the system which has to receive the data sent
by a transmitter) there has to be some set of rules or (―protocols‖) which all the interested parties
must obey.
The requirement above finally paves the way for some DATA COMMUNICATION STANDARDS.
Depending on the requirement of applications, one has to choose the type of communication strategy.
There are basically two major classifications, namely SERIAL and PARALLEL, each with its
variants. The discussion about serial communication will be undertaken in this lesson.
Serial data communication is the most common low-level protocol for communicating between two
or more devices. Normally, one device is a computer, while the other device can be a modem, a
printer, another computer, or a scientific instrument such as an oscilloscope or a function generator.
As the name suggests, the serial port sends and receives bytes of information, rather characters (used
in the other modes of communication), in a serial fashion - one bit at a time. These bytes are
transmitted using either a binary (numerical) format or a text format.
All the data communication systems follow some specific set of standards defined for their
communication capabilities so that the systems are not Vendor specific but for each system the user
has the advantage of selecting the device and interface according to his own choice of make and
range.
The most common serial communication system protocols can be studied under the following
categories: Asynchronous, Synchronous and Bit-Synchronous communication standards.
• The protocol defines that the data, more appropriately a ―character‖ is sent as ―frames‖ which in
turn is a collection of bits.
• The start of a frame is identified according to a START bit(s) and a STOP bit(s) identifies the
end of data frame. Thus, the START and the STOP bits are part of the frame being sent or
received.
• The protocol assumes that both the transmitter and the receiver are configured in the same way,
i.e., follow the same definitions for the start, stop and the actual data bits.
• Both devices, namely, the transmitter and the receiver, need to communicate at an agreed upon
data rate (baud rate) such as 19,200 KB/s or 115,200 KB/s.
• This protocol has been in use for 15 years and is used to connect PC peripherals such as
modems and the applications include the classic Internet dial-up modem systems.
• Most important observation here is that the individual characters are framed (unlike all the
other standards of serial communication) and NO CLOCK data is communicated between the
two ends.
UART
HDLC Protocol
UNIT - 3
Software Timer
i> A timer is a specialized type of clock. A timer can be used to control the sequence of an
event or process. Whereas a stopwatch counts upwards from zero for measuring elapsed
time, a timer counts down from a specified time interval, like an hourglass. Timers can be
mechanical, electromechanical, electronic (quartz), or even software as all modern computers
include digital timers of one kind or another. When the set period expires some timers simply
indicate so (e.g., by an audible signal), while others operate electrical switches.
ii>Watchdog timer
A watchdog timer (or computer operating properly (COP) timer) is a computer hardware
or software timer that triggers a system reset or other corrective action if the main program,
due to some fault condition, such as a hang, neglects to regularly service the watchdog
(writing a "service pulse" to it, also referred to as "kicking the dog", ―petting the dog‖,
"feeding the watchdog"[1] or "waking the watchdog"). The intention is to bring the system
back from the nonresponsive state into normal operation
Timer functions
Bluetooth
ZigBee
UNIT - 4
Interrupt sources
Multiple interrupts
Hardware assigned priorities
Context and the periods for context-switching interrupt latency and deadline
Interrupt Latency
Context switching
UNIT - 5
Task
UNIT - 6
REAL-TIME OPERATING SYSTEMS – 1:
Operating System services
Process management
Memory management
UNIT - 7
RTOS task scheduling models, interrupt latency and response times of the tasks as
performance metrics
OS security issues.
RTOS task scheduling models, interrupt latency and response times of the
tasks
UNIT - 8
Introduction
Host and target machines
Linking and locating software
Target System
Simulators
ICE