Title: Embedded Systems: Principles and Practice
1Embedded Systems Principles and Practice
- Christopher Alix
- Prairie City Computing, Inc.
- ECE 420
- April 9, 2007
2Traditional Definition
- A dedicated computer (a combination of hardware
and software) that serves a specific purpose, and
which is completely encapsulated within another
device.
3Traditional Definition
- NOT general-purpose computers, which arent
dedicated to a specific task.
- NOT devices which dont employ software at all
(but which are becoming increasingly rare). Even
something as simple as a digital clock is
generally easier and cheaper to implement with a
combination of hardware/software than as a
hardware-only device.
4Embedded Systems are Everywhere
5Design Considerations
Common issues in many embedded system designs
- Form factor (size, shape, weight)
- Power (battery life, heat dissipation)
- Environment (shock, vibration, temperature,
moisture, RF)
- Reliability
- User Interface
- Non-User Interface
- (or even )
6Revised Definition
- Handheld appliances like cellular phone handsets,
MP3 players, PDAs, calculators, game consoles,
DVD players, etc. arent embedded in anything,
but most engineers lump them in with ES because
they share so many of the hardware and software
constraints, components, tools, techniques and
engineering skills relevant to traditional ES
design. - Given predictions that cellular handset sales
will reach a billion units per year by 2009, the
handheld device industry is essentially driving
most of the innovation in the ES design world.
7Software or Hardware? (Both!)
- Software for simple or high-reliability systems
is often read-only firmware - Most systems now use flash memory, enabling
in-the-field software updates - No externally-visible difference between hardware
and software, so designers draw the line based
on the specifics of the features to be
implemented.
8Software or Hardware? In Practice...
- Well-defined, fundamental, repetitive and/or
performance-sensitive tasks are generally
implemented in hardware. - Complex, non-performance-sensitive, and/or
likely-to-change tasks are generally implemented
in software.
9Hardware Architecture Processors
- Wide range of processor choices 4-, 8-, 16-,
32-, even 64-bit Floating-point or integer math - Specialized on-chip peripherals General Purpose
Input/Output (GPIO) Comparators, amplifiers,
LED drivers A/D and D/A conversion Digital
Signal Processing Interfaces I2C, USB, and in
between
10Hardware Architecture FPGAs and CPLDs
- Field Programmable Gate Array
- Complex Programmable Logic Device
- Grab Bag of useful hardware on a single chip,
often with flexible I/O - Reconfigures itself on power-up
- Often used as a front end to reduce CPU
processing demands or pin count
Xilinx (www.xilinx.com), Altera (www.altera.com)
11Hardware Architecture FPGAs (continued)
- Powerful design tools generate FPGA code using
software-like functional descriptions (VHDL,
Verilog) - Designs can be extensively simulated
- Programmable (FPGA) designs can be easily
converted to hard coded ASIC (Application
Specific Integrated Circuit) designs for lower
cost at high volume
12Hardware Architecture SoC
- System-on-a-Chip Use an FPGA/ASIC to implement
the CPU, too - Many standard CPU architectures are available as
intellectual property--ready-to-use VHDL or
Verilog code - Core IP also available for complicated I/O
tasks (IEEE1394, Ethernet, etc.) - True single-chip solution for some systems
13Software Architecture OS or No-OS?
- Very simple systems may run a single, main loop
style program that does everything. - Most systems have at least a low-level monitor
program (like the BIOS in a PC) that handles
power-on initialization and common
hardware-related tasks. - More complex systems may use an embedded OS like
VxWorks or OS/9, or even an embedded variant of
Linux or Windows.
14Software Architecture Realtime
- Most embedded systems have tasks that must be
performed reliably at a specific rate. (e.g.,
capture a new audio sample every 22ms, or open a
fuel injector within 10ms of a TDC indication). - Embedded OSs and software use various techniques
to satisfy this need for realtime performance. - Realtime only means consistent--it doesnt mean
fast. Many realtime systems are far slower
than the average desktop PC, but you dont want
your engine to die when you stick a CD in your CD
player.
15Development Process (Not ES-specific)
- Often done within the constraints of a
structured design methodology as part of a Total
Quality System (IEEE, ISO, 6s, etc.) - Specification
- Design
- Development
- Verification against Design
- Validation against Specification
16Specification
- Defining essential requirements of the final
product, regardless of implementation - Generally market-driven
- Look and feel and external interfaces
- Regulatory compliance requirements
17Design
- Determining a specific solution that meets the
overall project requirements - Hardware and software considerations are closely
related, so an understanding of both worlds is
essential - Multitude of constraints put a high price tag on
overengineering
18Design (System)
- Selection of hardware and software architectures
- Allocation of feature set between hardware and
software - Segmentation of system to enable parallel design
(e.g., hardware, software, packaging)
19Design (Hardware) Component Selection
- Low Volume Products (Cs, Ks) Minimum
availability issues Some parts out of
contention Can utilize distributor stock
Parts finder services - High Volume Products (Ms) Production
limits/allocation Multiple sourcing
requirements - All Products Long-term availability and
upgrade paths Regulatory changes (RoHS)
20Design (Hardware) Circuit Design
- EDA (Electronic Design Automation) Tools
- Schematic capture (OrCAD, EAGLE, etc.)
- Circuit simulation where necessary (SPICE)
- Prototyping of new concepts
- Often incremental (borrowing circuits or portions
of circuits from earlier products) - Reference designs are a key resource
- Design-for-testability (DFT) and debugging tools
21Design (Hardware) PCB Design
- Most non-trivial ES use high-density
surface-mount components on multilayer PC boards - 4-, 6-, 8-layer boards are common
- Dedicated power and ground layers simplify layout
and improve RF characteristics - More complicated than you might think!
- Surface-mount technology (SMT) offers high
density and facilitates automated assemblybut
are difficult or impossible to tweak later, so
require extra care during the design process.
22Design (Hardware) Physical Design
- Packaging
- RF shielding (radiation and susceptibility)
Metallized enclosures Bonding of PCB to
enclosure Connector shielding Shape and
placement of openings - Reliability shake and bake testing Drop
testing
23Design (Hardware) Regulatory Compliance
- US FCC (RF shielding), UL (safety) FDA,
DOT, FAA, FRA, et al. - International CSA (Canada), CE (Europe), GS,
Europe CE mark - Risk analysis (root-cause, fault-tree, etc.) is
often required as a part of regulatory
submissions - Less innovative products are generally easier to
gain regulatory approval for, for better or for
worse.
24Design (Software)
- Typically 101 (or higher) ratio of software
engineers to hardware engineers on many ES
projects - Selection of development and debugging tools, in
concert with hardware debugging support - Software is key to debugging the hardware, and
vice versa--groups must work closely together - User interface design is important to the quality
and usability of the resulting product
25Development
- Hardware and software development is done in
parallel, so agreement on standards and protocols
is critical to keep the project moving forward - Development often involves multiple groups and
vendors, both in- and out-of-house - A clear specification and design helps keep all
the relevant parties moving in the same direction - An extra hour of design time saves many hours of
development time in virtually every case
26Development (Hardware)
- PCB Fabrication and assembly generally outsourced
- High level of automation
- Most large-scale CM (Contract Manufacturing) is
done overseas good communication is key to
success - Testability must be designed in (test coupons on
PC boards, test jigs and fixtures, special
provision for debugging very-high-speed signals,
etc.)
27Development (Software)
- Software makes the hardware work (or not work)
- Open-source tools common in ES world
- Debugging environments vary widely based on the
capabilities of the hardware - Software is easier to change than hardware, but
quality is equally important
28Verification
- Does the implementation match the design?
- Hardware and software test plans are essential
- Automated testing is valuable
- Regression testing is important as changes are
made - Good development processes offer traceability
29Validation
- Does the product satisfy the requirements?
- If the design process was done right, validation
should be a formality - Product and Project Managers need to keep the
fundamental requirements in mind during all
phases of the project to ensure a positive
outcome
30Closing Comments
- Embedded Systems development is a large and
growing part of both the EE and software worlds - Managers and lead engineers in ES projects need a
solid understanding of hardware and software - Outsourcing is prevalent in every aspect of ES
work - Successful outcomes demand motivated, skilled and
competent leaders with a broad set of skills
31Embedded Systems Principles and Practice
- Christopher Alix
- Prairie City Computing, Inc.
- ECE 420
- April 9, 2007