Maths is not everything

Embedded Systems
2 - Introduction
What are embedded systems?
Challenges in embedded computing sys...
Overview

Embedded computers are all around us.

Maths is not everything

RMR©2012

© 2008 Wayne Wolf

Many systems have c...
Maths is not everything

What are embedded systems?

RMR©2012
Definition

Embedded system: any device that
includes a programmable computer but
is not itself a general-purpose
computer....
Embedding a computer

output

Maths is not everything

RMR©2012

© 2008 Wayne Wolf

CPU

embedded
computer

analog
(digita...
Examples

Cell phone.
Printer.
Automobile: engine, brakes, dash, etc.
Airplane: engine, flight controls, nav/
comm.

Maths...
Early history

Late 1940’s: MIT Whirlwind computer was
designed for real-time operations.
Originally designed to control a...
Early history

Automobiles used microprocessor-based
engine controllers starting in 1970’s.
Control fuel/air mixture, engi...
Microprocessor varieties

Microcontroller: includes I/O devices, onboard memory.

Maths is not everything

RMR©2012

© 200...
Application examples

Simple control: front panel of microwave
oven, etc.
Canon EOS 3 has three microprocessors.
32-bit RI...
Automotive embedded systems

Today’s high-end automobile may have 100
microprocessors:
4-bit microcontroller checks seat b...
BMW 850i brake and stability control system

Anti-lock brake system (ABS): pumps
brakes to reduce skidding.

Maths is not ...
BMW 850i, cont’d.

sensor

sensor

brake

brake

ABS

hydraulic
pump

Maths is not everything

RMR©2012

© 2008 Wayne Wolf...
Characteristics of embedded systems

Sophisticated functionality.
Real-time operation.
Low manufacturing cost.

Maths is n...
Functional complexity

Often have to run sophisticated
algorithms or multiple algorithms.

Maths is not everything

RMR©20...
Real-time operation

Must finish operations by deadlines.
Hard real time: missing deadline causes failure.

Maths is not e...
Non-functional requirements

Many embedded systems are mass-market
items that must have low manufacturing
costs.
Limited m...
Design teams

Often designed by a small team of
designers.
Often must meet tight deadlines.

Maths is not everything

RMR©...
Why use microprocessors?

Alternatives: field-programmable gate
arrays (FPGAs), custom logic, etc.

Maths is not everythin...
Maths is not everything

RMR©2012

20

© 2008 Wayne Wolf

System on a chip
The performance paradox

Microprocessors use much more logic to
implement a function than does custom
logic.
But microproc...
Power

Custom logic uses less power, but CPUs
have advantages:
Modern microprocessors offer features to help
control power...
Platforms

Embedded computing platform: hardware
architecture + associated software.
Many platforms are multiprocessors.
E...
The physics of software

Computing is a physical act.
Software doesn’t do anything without hardware.

Maths is not everyth...
What does “performance” mean?

In general-purpose computing,
performance often means average-case,
may not be well-defined...
Characterizing performance

We need to analyze the system at several
levels of abstraction to understand
performance:
CPU....
Maths is not everything

Challenges in embedded computing system
design

RMR©2012
Challenges in embedded system design

How much hardware do we need?
How big is the CPU? Memory?

How do we meet our deadli...
Challenges in development

Does it really work?
Is the specification correct?
Does the implementation meet the spec?
How do...
Maths is not everything

Design methodologies

RMR©2012
Design methodologies

A procedure for designing a system.
Understanding your methodology helps
you ensure you didn’t skip ...
Design goals

Performance.
Overall speed, deadlines.

Functionality and user interface.

Maths is not everything

RMR©2012...
Levels of abstraction

requirements

specification

architecture

Maths is not everything

RMR©2012

© 2008 Wayne Wolf

co...
Top-down vs. bottom-up

Top-down design:
start from most abstract description;
work to most detailed.

Maths is not everyt...
Stepwise refinement

At each level of abstraction, one must:
analyze the design to determine
characteristics of the current...
Requirements

Plain language description of what the
user wants and expects to get.
May be developed in several ways:

Mat...
Functional vs. non-functional requirements

Functional requirements:
output as a function of input.

Non-functional requir...
Maths is not everything

RMR©2012

© 2008 Wayne Wolf

Our requirements form
Example: GPS moving map requirements

I-78

Maths is not everything

RMR©2012

© 2008 Wayne Wolf

Scotch Road

Moving map ...
GPS moving map needs

Functionality: For automotive use. Show
major roads and landmarks.
User interface: At least 400 x 60...
GPS moving map needs, cont’d.

Physical size/weight: Should fit in hand.

Maths is not everything

RMR©2012

© 2008 Wayne ...
Maths is not everything

RMR©2012

© 2008 Wayne Wolf

GPS moving map requirements form
Specification

A more precise description of the system:
should not imply a particular architecture;
provides input to the ...
GPS specification

Should include:
What is received from GPS;
map data;
user interface;

Maths is not everything

RMR©2012
...
Architecture design

What major components go satisfying the
specification?
Hardware components:
CPUs, peripherals, etc.

...
GPS moving map block diagram

GPS
receiver

search
engine

Maths is not everything

RMR©2012

© 2008 Wayne Wolf

database
...
GPS moving map hardware architecture

display

frame
buffer

CPU
GPS
receiver

Maths is not everything

RMR©2012

© 2008 W...
GPS moving map software architecture

position

© 2008 Wayne Wolf

RMR©2012

renderer

user
interface
Maths is not everyth...
Designing hardware and software components

Must spend time architecting the system
before you start coding.

Maths is not...
Maths is not everything

System’s Integration

RMR©2012
System integration

Put together the components.
Many bugs appear only at this stage.

Maths is not everything

RMR©2012

...
Upcoming SlideShare
Loading in …5
×

S emb t2-definition

375 views
255 views

Published on

Published in: Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
375
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
14
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

S emb t2-definition

  1. 1. Maths is not everything Embedded Systems 2 - Introduction What are embedded systems? Challenges in embedded computing system design Design methodologies System’s Integration RMR©2012
  2. 2. Overview Embedded computers are all around us. Maths is not everything RMR©2012 © 2008 Wayne Wolf Many systems have complex embedded hardware and software. Embedded systems pose many design challenges: design time, deadlines, power, etc. Design methodologies help us manage the design process.
  3. 3. Maths is not everything What are embedded systems? RMR©2012
  4. 4. Definition Embedded system: any device that includes a programmable computer but is not itself a general-purpose computer. Maths is not everything RMR©2012 © 2008 Wayne Wolf Take advantage of application characteristics to optimize the design: don’t need all the general-purpose bells and whistles.
  5. 5. Embedding a computer output Maths is not everything RMR©2012 © 2008 Wayne Wolf CPU embedded computer analog (digital) input analog (digital) mem
  6. 6. Examples Cell phone. Printer. Automobile: engine, brakes, dash, etc. Airplane: engine, flight controls, nav/ comm. Maths is not everything RMR©2012 © 2008 Wayne Wolf Digital television. Household appliances. PC peripherals (keyboard, storage, ...) ...
  7. 7. Early history Late 1940’s: MIT Whirlwind computer was designed for real-time operations. Originally designed to control an aircraft simulator. Maths is not everything RMR©2012 © 2008 Wayne Wolf First microprocessor was Intel 4004 in early 1970’s. HP-35 calculator used several chips to implement a microprocessor in 1972.
  8. 8. Early history Automobiles used microprocessor-based engine controllers starting in 1970’s. Control fuel/air mixture, engine timing, etc. Maths is not everything RMR©2012 © 2008 Wayne Wolf Multiple modes of operation: warm-up, cruise, hill climbing, etc. Provides lower emissions, better fuel efficiency.
  9. 9. Microprocessor varieties Microcontroller: includes I/O devices, onboard memory. Maths is not everything RMR©2012 © 2008 Wayne Wolf Digital signal processor (DSP): microprocessor optimized for digital signal processing. Typical embedded word sizes: 8-bit, 16bit, 32-bit.
  10. 10. Application examples Simple control: front panel of microwave oven, etc. Canon EOS 3 has three microprocessors. 32-bit RISC CPU runs autofocus and eye control systems. Maths is not everything RMR©2012 © 2008 Wayne Wolf Analog TV: channel selection, etc. Digital TV: programmable CPUs + hardwired logic for video/audio decode, menus, etc.
  11. 11. Automotive embedded systems Today’s high-end automobile may have 100 microprocessors: 4-bit microcontroller checks seat belt; Maths is not everything RMR©2012 © 2008 Wayne Wolf microcontrollers run dashboard devices; 16/32-bit microprocessor controls engine.
  12. 12. BMW 850i brake and stability control system Anti-lock brake system (ABS): pumps brakes to reduce skidding. Maths is not everything RMR©2012 © 2008 Wayne Wolf Automatic stability control (ASC+T): controls engine to improve stability. ABS and ASC+T communicate. ABS was introduced first---needed to interface to existing ABS module.
  13. 13. BMW 850i, cont’d. sensor sensor brake brake ABS hydraulic pump Maths is not everything RMR©2012 © 2008 Wayne Wolf brake brake sensor sensor
  14. 14. Characteristics of embedded systems Sophisticated functionality. Real-time operation. Low manufacturing cost. Maths is not everything RMR©2012 © 2008 Wayne Wolf Low power. Designed by small teams on tight deadlines.
  15. 15. Functional complexity Often have to run sophisticated algorithms or multiple algorithms. Maths is not everything RMR©2012 © 2008 Wayne Wolf Cell phone, laser printer. Often provide sophisticated user interfaces.
  16. 16. Real-time operation Must finish operations by deadlines. Hard real time: missing deadline causes failure. Maths is not everything RMR©2012 © 2008 Wayne Wolf Soft real time: missing deadline results in degraded performance. Many systems are multi-rate: must handle operations at widely varying rates.
  17. 17. Non-functional requirements Many embedded systems are mass-market items that must have low manufacturing costs. Limited memory, microprocessor power, etc. Maths is not everything RMR©2012 © 2008 Wayne Wolf Power consumption is critical in batterypowered devices. Excessive power consumption increases system cost even in wall-powered devices.
  18. 18. Design teams Often designed by a small team of designers. Often must meet tight deadlines. Maths is not everything RMR©2012 © 2008 Wayne Wolf 6 month market window is common. Can ’ t mi ss b ack -t o-school w i n d ow f or calculator.
  19. 19. Why use microprocessors? Alternatives: field-programmable gate arrays (FPGAs), custom logic, etc. Maths is not everything RMR©2012 © 2008 Wayne Wolf Microprocessors are often very efficient: can use same logic to perform many different functions. Microprocessors simplify the design of families of products.
  20. 20. Maths is not everything RMR©2012 20 © 2008 Wayne Wolf System on a chip
  21. 21. The performance paradox Microprocessors use much more logic to implement a function than does custom logic. But microprocessors are often at least as fast: Maths is not everything RMR©2012 © 2008 Wayne Wolf heavily pipelined (architecture optimization); large design teams (design optimization); aggressive VLSI technology (technology optimization).
  22. 22. Power Custom logic uses less power, but CPUs have advantages: Modern microprocessors offer features to help control power consumption. Software design techniques can help reduce power consumption. Maths is not everything RMR©2012 © 2008 Wayne Wolf Heterogeneous systems: some custom logic for well-defined functions, CPUs + software for everything else.
  23. 23. Platforms Embedded computing platform: hardware architecture + associated software. Many platforms are multiprocessors. Examples: Single-chip multiprocessors for cell phone baseband. Maths is not everything RMR©2012 23 © 2008 Wayne Wolf Automotive network + processors.
  24. 24. The physics of software Computing is a physical act. Software doesn’t do anything without hardware. Maths is not everything RMR©2012 24 © 2008 Wayne Wolf Executing software consumes energy, requires time. To understand the dynamics of software (time, energy), we need to characterize the platform on which the software runs.
  25. 25. What does “performance” mean? In general-purpose computing, performance often means average-case, may not be well-defined. In real-time systems, performance means meeting deadlines. Maths is not everything RMR©2012 25 © 2008 Wayne Wolf Missing the deadline by even a little is bad. Finishing ahead of the deadline may not help.
  26. 26. Characterizing performance We need to analyze the system at several levels of abstraction to understand performance: CPU. Platform. Maths is not everything RMR©2012 26 © 2008 Wayne Wolf Program. Task. Multiprocessor.
  27. 27. Maths is not everything Challenges in embedded computing system design RMR©2012
  28. 28. Challenges in embedded system design How much hardware do we need? How big is the CPU? Memory? How do we meet our deadlines? Maths is not everything RMR©2012 © 2008 Wayne Wolf Faster hardware (Amdahl’s law) or cleverer software? How do we minimize power? Slow down? Turn off unnecessary logic? Reduce memory accesses?
  29. 29. Challenges in development Does it really work? Is the specification correct? Does the implementation meet the spec? How do we test for real-time characteristics? How do we test on real data? Maths is not everything RMR©2012 © 2008 Wayne Wolf How do we work on the system? Observability, controllability? What is our development platform?
  30. 30. Maths is not everything Design methodologies RMR©2012
  31. 31. Design methodologies A procedure for designing a system. Understanding your methodology helps you ensure you didn’t skip anything. Maths is not everything RMR©2012 © 2008 Wayne Wolf Compilers, software engineering tools, computer-aided design (CAD) tools, etc., can be used to: help automate methodology steps; keep track of the methodology itself.
  32. 32. Design goals Performance. Overall speed, deadlines. Functionality and user interface. Maths is not everything RMR©2012 © 2008 Wayne Wolf Manufacturing cost. Power consumption. Other requirements (physical size, etc.)
  33. 33. Levels of abstraction requirements specification architecture Maths is not everything RMR©2012 © 2008 Wayne Wolf component design system integration
  34. 34. Top-down vs. bottom-up Top-down design: start from most abstract description; work to most detailed. Maths is not everything RMR©2012 © 2008 Wayne Wolf Bottom-up design: work from small components to big system. Real design uses both techniques.
  35. 35. Stepwise refinement At each level of abstraction, one must: analyze the design to determine characteristics of the current state of the design; Maths is not everything RMR©2012 © 2008 Wayne Wolf refine the design to add detail.
  36. 36. Requirements Plain language description of what the user wants and expects to get. May be developed in several ways: Maths is not everything RMR©2012 © 2008 Wayne Wolf talking directly to customers; talking to marketing representatives; providing prototypes to users for comment.
  37. 37. Functional vs. non-functional requirements Functional requirements: output as a function of input. Non-functional requirements: time required to compute output; Maths is not everything RMR©2012 © 2008 Wayne Wolf size, weight, etc.; power consumption; reliability; etc.
  38. 38. Maths is not everything RMR©2012 © 2008 Wayne Wolf Our requirements form
  39. 39. Example: GPS moving map requirements I-78 Maths is not everything RMR©2012 © 2008 Wayne Wolf Scotch Road Moving map obtains position from GPS, paints map from local database. lat: 40 13 lon: 32 19
  40. 40. GPS moving map needs Functionality: For automotive use. Show major roads and landmarks. User interface: At least 400 x 600 pixel screen. Three buttons max. Pop-up menu. Maths is not everything RMR©2012 © 2008 Wayne Wolf Performance: Map should scroll smoothly. No more than 1 sec power-up. Lock onto GPS within 15 seconds. Cost: $500 street price = approx. $100 cost of goods sold.
  41. 41. GPS moving map needs, cont’d. Physical size/weight: Should fit in hand. Maths is not everything RMR©2012 © 2008 Wayne Wolf Power consumption: Should run for 8 hours on four AA batteries.
  42. 42. Maths is not everything RMR©2012 © 2008 Wayne Wolf GPS moving map requirements form
  43. 43. Specification A more precise description of the system: should not imply a particular architecture; provides input to the architecture design process. Maths is not everything RMR©2012 © 2008 Wayne Wolf May include functional and non-functional elements. May be executable or may be in mathematical form for proofs.
  44. 44. GPS specification Should include: What is received from GPS; map data; user interface; Maths is not everything RMR©2012 © 2008 Wayne Wolf operations required to satisfy user requests; background operations needed to keep the system running.
  45. 45. Architecture design What major components go satisfying the specification? Hardware components: CPUs, peripherals, etc. Maths is not everything RMR©2012 © 2008 Wayne Wolf Software components: major programs and their operations. Must take into account functional and non-functional specifications.
  46. 46. GPS moving map block diagram GPS receiver search engine Maths is not everything RMR©2012 © 2008 Wayne Wolf database renderer user interface display
  47. 47. GPS moving map hardware architecture display frame buffer CPU GPS receiver Maths is not everything RMR©2012 © 2008 Wayne Wolf memory panel I/O
  48. 48. GPS moving map software architecture position © 2008 Wayne Wolf RMR©2012 renderer user interface Maths is not everything database search timer pixels
  49. 49. Designing hardware and software components Must spend time architecting the system before you start coding. Maths is not everything RMR©2012 © 2008 Wayne Wolf Some components are ready-made, some can be modified from existing designs, others must be designed from scratch.
  50. 50. Maths is not everything System’s Integration RMR©2012
  51. 51. System integration Put together the components. Many bugs appear only at this stage. Maths is not everything RMR©2012 © 2008 Wayne Wolf Have a plan for integrating components to uncover bugs quickly, test as much functionality as early as possible. Having a structured (planned) testing approach is paramount - design for testability think about which tests and how they will be made in the embedded system (Hw, Sw & global) at the design phase!

×