CPEN 120- EMBEDDED SYSTEMS
Topic 3
Embedded System Design Process
Intended Leaming Outcomes:
At the end if this topic, the student should be able to:
1. Describe stages of the embedded system design process
2. ldentify functional and non-functional requirements for embedded systems
based on user needs and system constraints.
3. Apply established design methodologies to create embedded system
solutions.
Learning Discussions
specialized computing
Embedded system design is the process of creating product. This involves
larger device or
systems that peform dedicated tasks within a
like microcontrollers, sensors, and
selecting and integrating hardware components optimized software (firmware) to
communication interfaces, alongside developing requirements. Embedded systems
and power
meet specific functional, performance,
constraints, requiring fast and reliable responses to
often operate under real-time
external inputs.
Embedded System Design Process developing
embedded system design process is a structured approach to devices. It
The
perform dedicated tasks within larger software
specialized computing systems that and
defining system requirements, designing hardware system.
involves a cohesive
selecting components, and integrating them intodevelopment, system
architecture, fimware
like hardware design,
The process includes steps to ensure the system meets functional, performance,
integration,and rigorous testing and validated, the system is
deployed in its
Once tested
and power constraints.
by ongoing maintenance and updates to enhance
target environment, followed process.
issues. Figure 3-1 shows the steps in the design
performance or address
CEIT -DCEEE
CPEN120 - EMBEDDED SYSTEMs
Requirement
Top down Bottom-up
design design
Specifications
Architecture
Components
System
Integration
Steps
Figure 3-1: Design Process
approaches
process, top-down and bottom-up approaches
design
In the embeddedmethodologies for system development. Both they
represent two distinct integrate different parts of a system, but
break down and
guide how designers
points and focus.
differ in their starting
the overall system's high-level
approach begins with broken down intO smaller,
The top-down From there, the system is
detail as the
requirements and architecture. modules. Each module is refined in
components and
more specific
design progresses.
overall
Advantages top-down approach provides a clear within the
System Architecture: The component fits well
Clear each
system, ensuring that
Structure of the
as a
bigger picture. Issues: By focusing on the system
pertormance
System-Level intera ction,
Early Detection of architectural issues (e.g., module
whole, potential identified early in the design process.
bottlenecks)can be
CET -DCEEE 2
CPEN 120- EMBEDDED SYSTEMS
Easler Maintenance: The design is modular,
replace individual components without disruptingmaking it easier to update or
the entire system.
Disadvantages
Risk of Over-Planning: Since detailed design is
deferred until after high-level
architecture is developed, there is a risk that some low-level design aspects
may not fit neatly into the system architecture, requiring later
adjustments.
Requires Comprehensive Initial Knowledge: It assumes that designers fully
understand the entire system at the start, which may not always be feasible.
Example:
In designing an automotive embedded systemlike a smart braking system
(ABS), the top-down approach would begin with the high-level requirement of
ensuring safety by controllingthe brakes under specific conditions. From there, the
designer would break the system into subsystems such as the sensor module (wheel
speed sensors), the actuator module (braking mechanism), and the controller
module (microcontroller managing decision-making), refining each module as
needed.
implementing the
The bottom-up approach begins with designing and components are then
individual
smallest, most specific components first. These
eventually building up to the
gradually combined to form higher-level subsystems,
complete system.
Advantages
Each individual component is tested thoroughly as it's
Early Testing: early in the design process.
developed, allowing issues to be caught reusable
The bottom-up approach promotes the creation of
Reusability:
development time in future projects.
modules, which can reduce
work on different components independently and
Flexibility: Designers can in complex
they are completed, which can save time
integrate them as
projects.
Disadvantages components,
Since the focus is on individual leading to
Overview: potentially
Lack of System sight of the bigger picture,
there is a risk of losing
integration issues later. architecture,
Without a well-defined high-level interactions
Integration Challenges: become complex, particularly if the
may
Integrating components planned out.
between modules aren't
CET -DCEEE
CPEN 120- EMBEDDED SYSTEMS
Risk of Redesign: If early components are not designed with the ful system
in mind, they may need to be reworked to fit the final architecture.
Example:
Inthe case of an loT-based embedded home automation system, using the
bottom-up approach would involve first designing individual components such as a
temperature sensor module, a relay control module for turning devices on and off,
and a Wi-Fi communication module. Once each module works independentiy, they
are integrated into a larger controlsystem that communicates with a central server or
mobile app.
Top-Down vs Bottom-Up
Criteria Top-Down Approach Bottom-Up Approach
Starting Point High-level system architecture Small, specific components and
and design modules
Focus System behavior and Building reliable and reusable
interaction between subsystems components
Development Decomposes system into Combines components into
subsystems subsystems
Planning Heavily planned from the start More exploratory and flexible
Risk Overlooking low-level details Integration issues due to lack of
system overview
Testing System-level testing perfomed Early component-level testing
after major design
Best Use Complex systems requiring Systems with reusable
Cases clear overall archite cture components or incremental
builds
Which Approach to Use?
Top-Down Approach is better suited for complex, large-scale systems where
the interactions between components need to be carefully orchestrated. This
method provides a clear understanding of the overall system before delving
into details.
Bottom-Up Approach is useful in scenarios where components are wel
understOod and can be developed independently, or in systems where
Components need to be hiahly reusable. It is more flexible and allows for
incremental progress.
CEIT -DCEEE
CPEN 120- EMBEDDED SYSTEMS
In practice, many embedded systems are designed using a hybrid approach
that combines elements of both top-down and bottom-up strategies. For example,
high-level architecture may be defined early on (top-down), while specific
subsystems are developed and tested incrementally (bottom-up).
Designing embedded systems involves a structured approach, from gathering
requirements to system integration.
1. Requirement Gathering
The first step in designing an embedded system is to collect the requirements
from the stakeholders like the ciient or end-users. It defines the high-level goals
and objectives of the system, such as what the embedded system is supposed
to do.
and non-functional
It involves gathering and understanding the functional is supposed
requirements of the system. Youneed to determine what the system constraints,
consumption limits, cost
to do, its performance expectations, power
and any real-time or safety requirements.
Functional and Non-functional
Requirements are generally split into two types:
requirements.
should do) - These are the
Functional Requirements (What the system
demands as basic facilities that the
specifically
requirements that the end user
system should offer.
Requirements are:
Example:Smart Thermostat Functional
the
Monitoring: The themostat must continuously monitor
Temperature
display it on the user interface.
room temperature and desired target
Temperature Setting: Users must be able to set a
Target or a mobile app.
temperature through physical buttons
themostat must activate the heating byor
Heating/Cooling Control: The from the target
system when the room temperature deviates
Cooling
threshold. or weekly
more than a specified should allow users to set daily
Scheduling: The system
temperature adjustments.
schedules for automatic themostat must connect to the home's Wi-Fi
W-Fi Connectivity: The control via amobile application.
network to allow remote
are
the system should pertom) - Theseproject
(How
Non-Functional Requirements system must satisfy according to the
constraints that the
ne quality CEIT-DCEEE
CPEN 120-EMBEDDED SYSTEMS
contract. They are also called non-behavioral requirements. Some of the non
functional requirements are
Portability
Security
Maintainability
Reliability
Scalability
Performance
Reusability
Flexibility
Example: Smart Thermostat Non-Functional Requirements are:
Usability: The user interface (both physical and mobile app) must be
less.
intuitive, allowing users to set preferences within 3 steps or
constant
Reliability: The system must maintain 99.9% uptime, ensuring
monitoring and controlof the HVAC system.
temperature
Response Time: The thermostat must react to changes in seconds.
app within 5
within 1 second and update the display or mobile
consume less than 0.5W in
Energy Efficiency: The device itself should extend battery life
power to
standby mode and must efficiently manage
(if battery-operated). Communication protocols (e.g.,
Security: The system must use secure
prevent unauthorized access.
HTTPS, WPA2) to protect user data and
handle up to 10 connected
Scalability: The system should be able to
multiple themostats or remote
devices in the same household (e.g.,
sensors). modular and well-documented,
Maintainability: The firmware must be downtime.
fixes with minimal
allowing for easy updates or bug
2. System Speciflcatlons
refined into a specification. The specifications
Requirements gathered are
descriptions to meet the requirements.
provide detailed technical
Specifications
Example: Smart Thermostat
accuracy.
to 50°C with +0.5°C
Temperature Sensor Range: -20°C resolution of 320x240 pixels.
with a
Display: A2-inch LCD screen(32-bit, 120 MHz).
Processor: ARM Cortex-M4 802.11 b/g/n for wireless
connectivity.
Communication Protocols: Wi-Fi
0.5W in standby mode.
Power Consumption: Max buttons and amobile app (using a REST
Interface: Capacitive touch
API).
Operating Voltage: 3.3V. CHII -DCEEE 6
CPEN 120- EMBEDDED SYSTEMS
3. System Architecture
The system architecture is the blueprint for how the components of the
embedded system will interact with each other. It defines how the hardware and
software components interact. It includes communication protocols, interfaces,
data flow, and control algorithms.
It often involves modular design, where each module performs a specific
function, such as sensing, processing, communication, or user interaction.
User input temperalure
User
Set temperature
Transmit weather forecast Smart HVAC System
Wifi Router Thermostat
Send temperatre
Temperature
Sensor
Current lemperatwe
diagram for Smart Thermostat
Figure 3-2: Example of Data flow
Components
4. Hardware and Software need to be
architecture is already defined, specific componentshardware and
When the
design. The component in general includes both (procesSors,
selected for the choose appropriate hardware
components
modules. You must goal is to
software
modules, etc.) based on the specifications. The
sensors, Communication the required performance, reliability, and cost
meet from
ensure that the hardware can are ready-made. some can be modified
constraints. Some componentsdesigned from scratch.
existing designs, others must be
CPEN 120- EMBEDDED SYSTEMS
Example: Hardware Components for Smart Thermistor
Microcontroller: STM32F4 Series (Cortex-M4) due to its processing power,
low energy consumption, and peripheral support.
Temperature Sensor: DS18B20, a digital temperature sensor known for
high accuracy and ease of interfacing.
WI-Fi Module: ESP8266, a low-cost, low-power Wi-Fi chip with sufficient
support for embedded systems.
Display: 2" TFT LCD with SPI interface.
input to 3.3V
Power Supply: A buck converter circuit that steps down a 5V
for the microcontroller and peripherals.
Capacitive Touch IC: TTP223 touch sensor for user input buttons.
5. System Integration
integrated into a
Once the hardware and software are developed, they are
connected, and the
complete system. During integration, the components are together correctly.
software is loaded onto the hardware to ensure they function behavior
Communication between modules, sensor data flow, and overall system
is tested.
Testing and Validation
perform as
Embedded systems undergo rigorous testing to ensure they
performance
required in real-world conditions. This includes functional testing,
testing, and reliability testing.
Testing includes:
Unit Testing: Testing individual components or software modules.
System Testing: Ensuring that the entire system operates as expected
when all components are integrated.
Performance Testing: Checking that the system operates efficiently
and meets timingor real-time constraints.
o Power Testing: Ensuring power consumption is within acceptable
limits.
Field Testing: Testing the system in real-wortd conditions to
ensure its
o
reliability and robustness.
Validation ensures the system meets the end-user's needs and operates
reliably over time.
CEIT -DCEEE
CPEN 120- EMBEDDEDSYSTEMS
Embedded System Design lssues
In general, an embedded system design must consider the
following :
1. It should handle real time operations and react to external
events
2. It should conform to size and weight limits
3. It should be within the power budget and cooling requirements.
4. It should satisfy safety and reliability requirements
5. It must meet tight cost targets.
Embedded system design faces several challenges due to the nature of
embedded systems and their application-specific requirements. Some of the
common embedded design issues:
Real-Time Constraints
Many embedded systems must respond to inputs or changes in the
environment within strict time limits. Missing these deadlines can cause the
system to fail or behave unpredictably.
Example: In automotive safety systems like airbags, real-time processing is
critical for timely deployment during an accident.
Power Consumption
Embedded systems, especially in portable or battery-operated devices, must
consume minimal power to extend battery life. Designers need to balance
performance with power efficiency.
Example: Wearable health monitors need to operate continuously for
extended periods on small batteries.
Memory and Resource Constraints
Embedded systems typically have limited memory (RAM, ROM, Flash) and
Computational resources due to size, cost, and power constraints. This limits
the complexity of the software and algorithms that can be implemented.
Example: An embedded microcontroller in a smart sensor might only have a
few kilobytes of RAM, requiring highly optimized software.
Security
Embedded systems are increasingly connected to networks (loT), making
hem vulnerable to cyber-attacks. Ensuring data security and
unauthorized access are crucial challenges. prevening
CEIT -DCEEE
CPEN120- EMBEDDED SYSTEMS
Example. A connected home security system must
attempts, ensuringthat the data and controls are safeguard against hacking
protected
Reliability and Robustness
Many embedded systems are deployed in harsh
automotive, industrial, medical) and need to operate environments (e.g.
reliably over long
periods. They must tolerate temperature fluctuations, vibrations, or humidity
without failure
Example: A medical device like a pacemaker must operate flawlessly in
diverse conditions without failure, as it dire ctly impacts a patient's life.
Scalability
Embedded systems must be designed to support future enhancements and
integrations without requiring a complete redesign. Adding new features or
capabilities can be challenging within the constrained environment.
Example: Asmart home thermostat that needs to support more devices or
sensors over time must scale without significant redesign.
Integration with Hardware
integration between hardware
Embedded system design often involves tight the hardware components
ensure that
and software. Designers must be
actuators) and the software work seamlessly together, which can
(sensors,
involved.
difficult whenmultiple vendors are system
Designing firmware for a sensor in an industrial monitoring in data
Example: or latency
hardware's quirks, such as noise
must account for the
collection.
Cost Constraints
produced at low cost, especially for
need to be and requires
Many embedded systems limits the choice of components
Consumner products. This reduce hardware and production costs.
optimization of the design to household appliance must
embedded system for a processing
Example: A loW-cost affordability, leading to compromises on
balance performance with
power or memory.
CET -DCEEE 10
CPEN 120- EMBEDDED SYSTEMS
Software Complexity and Testing
Embedded softvware can become complex, especially as
systems add more
features. Ensuring thorough testing and validation is difficult,
real-time or critical systems where bugs can lead to particularly in
catastrophic failure.
Example: Asoftware bug in an embedded flight control system can lead
serious consequences, making thorough testing essential. to
Upgrade and Maintenance
Many embedded systems are deployed in environments where physical
access is limited, making upgrading and maintenance difficult. Ensuringover
the-air (OTA) updates while maintaining security and system integrity is a
challenge.
Example: An embedded system in aremote wind turbine must support OTA
updates since manualacCcess is Costly and inconvenient.
Interfacing and Communication Protocols
Embedded systems often need to interface with other systems or sensors
using various communication protocols (e.g., 12C, SPI, CAN, Bluetooth).
Ensuring compatibility and reliability across different interfaces can be a
challenge.
Example: An loT sensor network may need to support multiple wireless
protocols like Wi-Fi and Zigbee for different devices, requiring careful protocol
management.