Embedded PDF

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 23

EMBEDDED SYSTEMS DIGITAL CONTROL

Mandefro Beshahwured
mandebeshah@gmail.com

Department of Electromechanical Engineering (Mechatronics)

December 8, 2021
Content I

1 EMBEDDED SYSTEMS
COMPONENTS OF EMBEDDED SYSTEMS
TYPES OF EMBEDDED SYSTEMS
CHARACTERISTICS OF EMBEDDED SYSTEMS
REAL LIFE APPLICATIONS OF EMBEDDED SYSTEMS

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 1 / 22


Computer

General-purpose computers are those that we use every day like


our desktops, laptops, and Macs which provides various function-
alities to the user. Even our smartphones stand in the general-
purpose end of the spectrum which means they have more than one
specific task to perform. Special purpose computers are very spe-
cific to serve a particular function. A calculator is a special-purpose
computer as compared to a laptop that is a general-purpose com-
puter. The only job of a calculator is to do calculations. You cannot
use it for more than one purpose like general-purpose computers.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 2 / 22
EMBEDDED SYSTEMS
A system is an arrangement in which all its unit assemble to work
together according to a set of rules. It is a group of units, joined
together to work in a specific routine and perform some fixed op-
eration. example, a watch is a time displaying system. Its com-
ponents follow a set of rules to show time. If one of its parts fails,
the watch will stop working. So we can say, in a system, all its
sub-components depend on each other.
Embedded means something that is attached to another thing.
An embedded system is a custom-built special purpose computer
used for a specific purpose. An embedded system can be an inde-
pendent system or it can be a part of a large system. It is a sys-
tem that combines both hardware and software to perform a certain
task and which can operate without human interaction. An embed-
ded system is a micro-controller or microprocessor based system
which is designed to perform one or a few specific task.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 3 / 22
For example, a fire alarm is an embedded system; it will sense only
smoke. An automated system that doesnt involve human interfer-
ence is also an example of an embedded system. For example, you
can interface the conveyer belt with the sensor to count the number
of filled bottles. Once you install a combination of both hardware
and software embedded programming, you can watch the number
of filled bottles on the computer screen without any human interfer-
ence. The devices that perform certain tasks where no user is in-
volved are termed as the no user interface (UI) embedded systems
and where user interference is involved are termed as graphical
user interface (GUI) embedded systems.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 4 / 22


Embedded system components

1. It has hardware.
2. It has application software.
3. It has Real Time Operating system (RTOS) that supervises the
application software and provide mechanism to let the processor
run a process as per scheduling by following a plan to control the
latencies. RTOS defines the way the system works. It sets the
rules during the execution of application program. A small scale
embedded system may not have RTOS.
So we can define an embedded system as a Microcontroller based,
software driven, reliable, real-time control system.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 5 / 22


Hardware components

1. Power Supply
A power supply is a crucial component of the embedded system
design. It is an electrical device mainly used to power up the elec-
trical load. Normally, a 5V power supply is required for the system,
however, it can also range from 1.8 to 3.3V. You can pick either
one based on your requirements and application. To work the em-
bedded system properly, a smooth and efficient power supply is
needed. Both wall adopter and battery can be used as a power
supply.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 6 / 22
2. Microcontroller
An embedded system is either a microcontroller-based or microprocess
based system. They give a system computing power and are called
integrated circuits. The embedded hardware performance is mainly
dependent on the processor which is normally called the brain of
the embedded system. Pick from a range of processors includ-
ing 8-bit, 16-bit, and 32-bit processors. They are different in terms
of processing speed. For example, a 32-bit processor comes with
more processing speed and can manipulate 32-bits at a time while
an 8-bit processor comes with less processing speed and can ma-
nipulate 8-bits at a time. For simple applications, an 8-bit processor
would suffice while for complex and advanced applications, pro-
cessors with more bits are used. The 8-bit processor is normally
clocked to 8MHz while the 32-bit processor can run up to hundreds
of MHz.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 7 / 22


3. ROM/RAM Memory
Memory is essential to store important information in the embedded
computer system. Memory is integrated into a microcontroller or
microprocessor. There are two types of memories including ROM
(read-only-memory) and RAM (random access memory). The for-
mer is called the code memory that stores the program code and
is non-volatile which means it stays stored in the system when the
power supply is removed. While latter is called the data memory
and is a volatile memory which means it is used for temporally stor-
ing the information and is removed from the system when the power
supply is turned off.
4. Timers / Counters
Sometimes you need to create a delay before a specific function.
Timers are used in such cases. While at times you want to count
the number of times a particular event occurs. Counters are used
in such cases. If an up counter is used in the system, it will count
up from the initial value to 0xFF and if it is down counter, it will
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 8 / 22
count down to 0x00. The counters are integrated using register-
type circuits like a flip-flop.
5. Communication Ports
Communication ports are used in embedded systems to establish
communication with other embedded systems. There are several
communication ports including USB, UART, I2C, SPI, and RS-485.
For simple applications, communications ports are utilized from the
microcontroller, and for complex and advanced applications these
ports are externally installed inside the embedded systems.
6. Output and Input
Input is required to interact with the embedded system. A sensor
can be used to provide input to the system. The microcontroller
used in the system can be configured as an input or output port.
In the microcontroller, there are a fixed number of input and output
ports that you can utilize as per your requirement.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 9 / 22


7. Electrical component and Circuit
a. PCB (printed circuit board), Resistors, Capacitors, Diodes, Inte-
grated Circuits, LED, Inductors, Transistors:-Transistors are used in
the electrical circuit for amplification and switching purposes.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 10 / 22


Software component of ES

Both computer software and embedded system software are dif-


ferent in terms of their purposes. The computer software can be
installed on many devices to achieve the required goals while em-
bedded system software, on the other hand, is specifically written
for a certain device to meet a certain goal.
software components of embedded system:- Editor, Compiler,
Assembler, Emulator, Linker, Debugger.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 11 / 22


a. Editor
The editor is the first tool you required for embedded system soft-
ware. The code you write in C and C++ programming languages will
be saved in a text file in the editor. This editor supports scores of
languages including Java, C, micro-C, HTML, Python, PHP, Matlab.
b. Compiler The code is written in a text editor. But how does a ma-
chine understand this code? A compiler is used to turn this written
code into low-level machine language that the machine can com-
prehend. The main purpose of this tool is to develop an executable
program. The name compiler is mainly used for the written pro-
grams that convert high-level programming language source code
into a low-level programming language.
c. Assembler converts the written code into a machine language.
It is slightly different than a compiler. The compiler directly converts
the written code into machine language while the assembler, on
the other hand, first converts source code to object code and then
to the language that the machine can understand.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 12 / 22
d. Emulator The main task of the emulator is to make the em-
bedded system act like a real system in a simulation environment.
Using an emulator, youll get an idea of how the code will function in
real-time. It is used to simulate software performance, and it helps
in achieving the ideal performance of the written code. With an em-
ulator, you can run one operating system into another device. For
example, using an emulator you can run Mac operating system into
your windows operating system.
e. Linker Typically, software code is written in small modules and
pieces. A linker, also called a link editor, is a tool that takes one or
more object files and combines them to develop a single executable
code.
f. Debugger A debugger is a tool used for testing and debugging
purposes. It scans the code thoroughly and removes the errors and
bugs, and identifies the places where they occur. Programmers can
quickly address the errors and fix them.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 13 / 22
CHARACTERISTICS OF EMBEDDED
SYSTEMS

Single-functioned An embedded system usually performs a spe-


cialized operation and does the same repeatedly.
Tightly constrained All computing systems have constraints on
design metrics, but those on an embedded system can be espe-
cially tight. Design metrics is a measure of an implementation’s
features such as its cost, size, power, and performance. It must be
of a size to fit on a single chip, must perform fast enough to process
data in real time and consume minimum power to extend battery
life.
HW-SW systems Software is used for more features and flexibility.
Hardware is used for performance and security.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 14 / 22


Reactive and Real time Many embedded systems must continu-
ally react to changes in the system’s environment and must com-
pute certain results in real time without any delay. Consider an
example of a car cruise controller; it continually monitors and re-
acts to speed and brake sensors. It must compute acceleration or
de-accelerations repeatedly within a limited time; a delayed compu-
tation can result in failure to control of the car.
Microprocessors based It must be microprocessor or microcon-
troller based.
Memory It must have a memory, as its software usually embeds in
ROM. It does not need any secondary memories in the computer.
Connected It must have connected peripherals to connect input
and output devices.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 15 / 22


Basic Structure of an Embedded System
Sensor It measures the physical quantity and converts it to an elec-
trical signal which can be read by an observer or by any electronic
instrument like an A2D converter. A sensor stores the measured
quantity to the memory.
A-D Converter An analog-to-digital converter converts the analog
signal sent by the sensor into a digital signal.
Processor & ASICs Processors process the data to measure the
output and store it to the memory.
D-A Converter A digital-to-analog converter converts the digital
data fed by the processor to analog data
Actuator An actuator compares the output given by the D-A Con-
verter to the actual (expected) output stored in it and stores the
approved output.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 16 / 22
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 17 / 22
REAL LIFE APPLICATIONS OF EMBEDDED
SYSTEMS

-consumer electronics industrial machinery


-automobiles agriculture
-processing industrial devices airplanes (Avionics)
-digital watches vending machines
- air-conditioners mobile devices
- Robotics Banking
-Security systems Smart Cards
-Safety-Critical Systems Telecommunication
-Medical fields Motes(sensor node, wireless commun

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 18 / 22


Microprocessors & microcontrollers
Microcontroller (also called microcomputer, MCU) is a small com-
puter on a single integrated circuit consisting internally a relatively
simple CPU, clock, timers, I/O ports, and memory... Integrated cir-
cuit is semiconductor chip that performs the bulk of the processing
and controls the parts of a system; ”a microprocessor functions as
the central processing unit of a microcomputer”; Eg. a disk drive
contains a microprocessor to handle the internal functions of the
drive
Microprocessors generally requires
1. external components to implement program memory,
2. ram memory and
3. Input/output. Intel’s 80186, 80188, and 80386 are examples of
microprocessors.
MB (WU EME) EMBEDDED SYSTEM December 8, 2021 19 / 22
Microcontrollers incorporate
i. program memory,
ii. RAM memory and
iii. input/output resources internal to the chip
i.e. everything that requires in a Microprocessor based system ex-
ternally are built inside a single chip called micro controller that is
why they are also known as SYSTEM ON CHIP. Microchip’s pic
series and Atmel’s AVR series are examples of microcontrollers.
One of the main differences is that micro controllers are usually
designed to perform a small set of specific functions, for example
as in the case of a Digital Signal Processor which performs a small
set of signal processing functions, whereas microprocessors tend
to be designed to perform a wider set of general purpose functions.

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 20 / 22


For example, microcontrollers are widely used in modern cars where
they will each perform a dedicated task, i.e. a microcontroller to
regulate the brakes on all four wheels, or a microcontroller to regu-
late the car air conditioning, or a microcontroller responsible for the
cruise control.
These microcontrollers will perform few other tasks (if any) other
than those specified.
Compare this on the other hand to a microprocessor in a PC which
performs a wide range of tasks related to the general requirements
of a PC, i.e. performing the necessary calculations for a very wide
set of software applications, performing I/O for the main sub-systems,
peripheral control etc.
Microprocessor = CPU
Micro controller= CPU + Peripherals + Memory

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 21 / 22


Peripherals = Ports + Clock + Timers + UARTS + ADC Converters
+LCD Drivers + DAC + other stuff
Memory = EEPROM + SRAM + EPROM + flash
A microcontroller has a combination of all this stuff.
A microprocessor is just a CPU .

MB (WU EME) EMBEDDED SYSTEM December 8, 2021 22 / 22

You might also like