Introduction to Embedded Systems
Bindu C J
Outline
Introduction Categories Embedded System Architecture Specialties of Embedded Systems Recent Trends in Embedded Systems Communication Interfaces
Bindu C J
2
What is Embedded System?
A system that has hardware with software embedded in it as one of its most important component and intended for a dedicated application.
Bindu C J
How its different
Single-functioned
Executes a single program, repeatedly.
Embedded software sometimes called firmware. Tightly-constrained Low cost, low power, small, fast, etc. Reactive and real-time
Continually reacts to changes in systems environment
Must compute certain results in real-time without delay
Bindu C J
4
Embedded Systems Overview
Hard to define. Nearly any computing system other than a desktop computer. Computing systems embedded within electronic
devices.
Billions of units produced yearly, versus millions of desktop units.
Perhaps 50 per household and per automobile.
Bindu C J
5
A short list of Embedded Systems
Anti-lock brakes Auto-focus cameras Automatic teller machines Automatic toll systems Automatic transmission Avionic systems Battery chargers Camcorders Cell phones Cell-phone base stations Cordless phones Cruise control Digital cameras Disk drives Electronic card readers Electronic instruments Electronic toys/games Factory control Fax machines Fingerprint identifiers Home security systems Life-support systems Medical testing systems Modems MPEG decoders Network cards Network switches/routers On-board navigation Pagers Photocopiers Point-of-sale systems Portable video games Printers Satellite phones Scanners Smart ovens/dishwashers Speech recognizers Stereo systems Teleconferencing systems Televisions Temperature controllers Theft tracking systems TV set-top boxes VCRs, DVD players Video game consoles Video phones Washers and dryers
and the list goes on and on
6
Bindu C J
Application Areas
Consumer Electronics Automobiles Office Automation/Data Communication Industrial Automation Biomedical Engineering Wireless Communication, etc,etc
Bindu C J
7
Application Examples
Bindu C J
Application Examples
Bindu C J
Application Examples
Medical Instrumentation
Bindu C J
10
Automotive Electronics Platform
Bindu C J
11
Categories of Embedded Systems
Stand-Alone Systems Networked Embedded Systems Real Time Systems Mobile Devices
Bindu C J
12
Real Time Systems
Real Time systems may be classified as
Hard Real Time Systems Firm Real Time Systems Soft Real Time Systems
Bindu C J
13
Hard Real Time Systems
A hard real-time system has time-critical deadlines that must be met; otherwise a catastrophic system failure can occur. Should perform absolutely, positively, first time and every time. Requires formal verification/guarantees of always
meeting its hard deadlines.
Bindu C J
14
Hard Real Time S/M-Examples
Air traffic control Vehicle subsystems control Imagine a car accident
What happens when the airbag is fired too late? Even one ms late is too late!
Nuclear power plant control
Bindu C J
15
Soft real-time system
If deadlines are occasionally missed, it is considered undesirable, but not catastrophic, Examples:
Multimedia transmission and reception,
Networking, telecom (cellular) networks, Web sites and services Computer games.
Bindu C J
16
Firm Real Time Systems
Comes in between Hard and Soft Real Time Systems. Missing of a deadline is tolerable once in a while.
Eg. ATM
Bindu C J
17
Embedded System Architecture
Application Software Operating System Hardware
Bindu C J
18
Parts of an Embedded System
Bindu C J
19
Hardware Architecture
RAM ROM
Input Devices
Processor
Output Devices
Application Specific Circuitry
Communication Interfaces
Bindu C J
20
Processor
It is the core of the Embedded System
Microprocessors Microcontrollers DSPs FPGAs
Bindu C J
21
Processor Selection
Speed & Word length Packaging Power Consumption Amount of on chip RAM,ROM RISC/CISC Program Storage Architecture (Harward/ Von-Nuemann) Availability of peripherals How easy to develop products How easy to upgrade Availability in the market
Bindu C J
22
Other H/W Components
Memory Input & Output Devices ADC/DAC Watch Dog Timer Communication Interface Application Specific Circuitry
Bindu C J
23
Specialties of Embedded Systems
Reliability Cost Effectiveness Low Power Consumption
Size
Limited User Interface
Performance
Flexibility
Bindu C J
24
Recent Trends
Processing Power
Memory
Operating Systems Communication Interfaces Networking Capability Programming Languages
Development Tools
Programmable Hardware
Bindu C J
25
Need for Communication Interfaces
Needs to communicate with other embedded system to transmit/receive data. A number of embedded systems need to be networked to share data. May need to send raw data to PC for analyzing and presenting through GUIs. Mobile devices to be connected to other devices such as PCs for data synchronization.
Software in embedded system may need upgradation after being installed in the field.
May be connected to internet so that anyone can access them.
Bindu C J
26
Communication Interfaces
RS 232/UART; RS422/RS 485 USB SPI, PCI I2C, CAN, Firewire (IEEE 1394) Bluetooth, Zigbee , WiFi
Bindu C J
27
RS 232
RS (Recommended Standard) set in 1960s
Most widely used standard
Used for serial communication Speeds up to 115.2Kbps Distances up to 100 meters Not TTL compatible, so line drivers to be used
Bindu C J
28
RS 232 Communication Parameters
Data rate No. of data bits Start bit / Stop bit/ Parity Flow control (Handshaking) Best suited in applications such as
Modems,
printers and other PC peripherals Evaluation Boards connected to Hosts
Bindu C J
29
Null modem connection
DTE DTE
TxD
TxD RxD
RxD
ground
Bindu C J
30
RS 422
Uni-directional full duplex standard Suitable for electrically noisy industrial environments. Bit rate above 50Mbps
Distance up to 1200m
Bindu C J
31
RS 422
Used in industrial environments that require only one bus master. Typical applications
Process automation Factory automation Motor control
Bindu C J
32
Rs 485
Bi-directional half duplex standard. Meets all RS 422 specifications, but more robust. Industrial applications with more than one bus master. Used in networked applications. >512 devices can be connected.
Bindu C J
33
RS 485
Typical application areas are similar to those of RS 422. Shielded twisted pair cable.
Data rate 1 Mbps to 35 Mbps.
Trade off between data rate and cable length
Cable length of the order of 900 ft.
Bindu C J
34
UART
Used to bridge the processor and RS 232 port. Two sections: Receiver and Transmitter
Processor
UART
Level Shifter
RS 232
Connector
Bindu C J
35
UART
Receiver Receives data in serial format, convert to parallel format and gives to processor Transmitter Take data from processor in parallel format, convert to serial format and transmits.
Bindu C J
36
USB
Uses Master/Slave architecture. Can connect up to 127 devices to a host. USB 1.1 supports 12Mbps & USB2.0 supports 480 Mbps. Supports plug and play. USB devices are hot pluggable. Communication is in the form of packets of size up to 1023 bytes.
Bindu C J
37
USB
USB Host Controller
Keyboard USB Hub
Printer
Scanner
Digital Camera
Bindu C J
38
SPI
SPI is a synchronous serial data link standard. Devices communicate in master/slave mode where the master device initiates the data frame. Multiple slave devices are allowed with individual slave select (chip select) lines.
Bindu C J
39
SPI Bus, Single Master, Single Slave
SCLK MOSI SPI Master MISO SS
SCLK MOSI MISO SS SPI Slave
Bindu C J
40
SPI-Single Master, Multiple Slaves
SCLK
MOSI SPI Master MISO SS1 SS2 SCLK MOSI MISO SS2 Bindu C J
41
SCLK MOSI MISO SS1 SPI Slave
SPI Slave
SPI
The SPI bus specifies four logic signals.
SCLK Serial Clock (output from master)
MOSI/SIMO Master Output, Slave Input
(output from master)
MISO/SOMI Master Input, Slave Output (output from slave)
SS Slave Select (active low; output from
master)
Bindu C J
42
Advantages
Full duplex communication Higher throughput than IC Typically lower power requirements than IC Slaves don't need a unique address -- unlike IC At most one "unique" bus signal per device (chip select); all others are shared
Bindu C J
43
Disadvantages
Requires more pins on IC packages than IC Supports only one master device Only handles short distances compared to RS232, RS-485, or CAN-bus
Bindu C J
44
SPI is used with Peripherals, such as:
Sensors: temperature, pressure, ADC, touch screens Control devices: audio codecs, digital potentiometers, DAC Camera lenses Communications: Ethernet, USB, USART, CAN, IEEE 802.15.4, IEEE 802.11 Memory: flash and EEPROM Real-time clocks LCD displays, sometimes even for managing image data
Bindu C J
45
PCI and PCI/X Buses
Most used synchronous parallel bus 32 bit data bus extendable to 64 bits 32 bit address bus extendable to 64 bits
Bindu C J
46
Typical PCI cards
Bindu C J
47
PCI Revision 2.1 Features
Processor independence Low-power consumption Bus speed up to 66 MHz 64-bit bus width
Bindu C J
48
I 2C
Developed early 1980s.
I2C Bus protocol consists of two active wires (SDA & SCL) and a ground connection.
Every device hooked up to the bus has its own unique address. Each device can act as a receiver and/or transmitter.
I2C Bus is a multi master bus.
Device initiating data transfer is master and others are slaves. 49
Bindu C J
I2C
SDL Master
SCL
Slave Slave Slave Slave
Bindu C J
50
CAN (Controller area network)
Protocol for real-time applications Developed by Robert Bosch GmbH Originally for communication among components of cars
Applications using CAN include:
Elevator controllers, copiers, telescopes, production-
line control systems, and medical instruments
Bindu C J
51
CAN Features
Data transfer rates up to 1 Mbit/s and 11-bit addressing Requires devices to transmit/detect dominant and recessive signals to/from bus
e.g., 1 = dominant, 0 = recessive if single data wire used
Bus guarantees dominant signal prevails over recessive signal if asserted simultaneously.
Bindu C J
52
Firewire
High-performance serial bus developed by Apple Computer Inc. in late 1980s Designed for interfacing independent electronic components
e.g., Desktop, scanner
Data transfer rates from 12.5 to 400 Mbits/s, 64-bit addressing Hot insertion & Plug-and-play capabilities Packet-based layered design structure
Bindu C J
53
Bluetooth
New, global standard for wireless connectivity Based on low-cost, short-range radio link Connection established when within 10 meters of each other No line-of-sight required
e.g., Connect to printer in another room
Bindu C J
54
Zigbee
Technological Standard Created for Control and Sensor Networks Based on the IEEE 802.15.4 Standard Created by the ZigBee Alliance
Bindu C J
55
Zigbee
Designed for wireless controls and sensors Operates in Personal Area Networks (PANs) and device-to-device networks Connectivity between small packet devices Control of lights, switches, thermostats, appliances, etc.
Bindu C J
56
The ZigBee Name
Named for erratic, zig-zagging patterns of bees between flowers Symbolizes communication between nodes in a mesh network Network components analogous to queen bee, drones,
worker bees
Bindu C J
57
THANK YOU
Bindu C J
58