Embedded System Design Module
Embedded System Design Module
(ICE – NITT)
Introduction
Dr. N. Mathivanan
Outline
• Overview of Embedded Systems
• Embedded System Architecture
• Processors: ARM - ARM7-TDMI, Cortex-M3
• Microcontroller: LPC214x, LPC1768 from NXP Ltd.
• Processor Peripherals: Memory, DMA, Interrupt controllers
• User Peripherals: Timer, PWM, ADC, DAC
• Communication Interfaces: UART, I2C, SPI, USB
• Network Protocols: CAN
• Embedded System Software, OS, RTOS, Scheduling
• Case Studies: 3 (assignment)
Books
• ARM System Developer’s Guide: Designing and Optimizing System
Software, Andrew N. Sloss, Dominic Symes, Chris Wright, Morgan
Kaufman Publication, (2004).
• LPC214x User Manual, UM10139: NXP Ltd. (2012)
• The Insider’s Guide to the Philips ARM7-Based Microcontrollers,
Trevor Martin, Hitex (UK) Ltd., (2005).
• Cortex-M3 Devices Generic User Guide: ARM DUI, 0552A, ID
121610 (2010)
• The Definitive Guide to ARM Cortex-M3, II Ed., Joseph Yiu,
(Elsevier – Newnes)
• PC Based Instrumentation: Concepts and Practice, N. Mathivanan,
PHI, (2007)
• Embedded System (Embedding a computer)
That has built-in small computer (not general-purpose)
Software embedded with it, preprogrammed.
Not programmable by users and not visible to users
It is a part of a larger system
System performing single function, repeatedly.
Starts by itself and runs independently without human intervention.
Responds, monitors, controls external environment
Uses sensors, actuators and has analog interfacing
Generally built around microcontroller
• Examples
• Camera
Typically 3 microcontrollers are used,
A 32-bit mC provides auto-focus fn.
• Automobile
More than 100 microcontrollers provide ABS, ESC, etc. functions
4-bit mC checks seat belt, 8-bit mC manages dashboard function,
Networked,
Embedded System Classification
• Based on functionality
Stand-alone, Networked, Real-time, Wireless
• Designer objective:
To find cheapest solution that meets requirements
Typical Embedded System
• Differential drive mobile robot
M IC R O C O N TR O L L E R
M S lo t S e n s o r
EXT
PW M
D RIVER IN T
M S lo t S e n s o r
Z ig B e e
G P IO UA RT
T r a n s ie v e r
(L P C 2 1 2 9 )
Embedded System Organization
• Embedded System Hardware
CPU: Processor/Microcontroller/Embedded Processor
Memory: EEPROM, SRAM,
Controllers: Memory, Bus, interrupt & DMA controllers
Peripherals: ADC, DAC, Timer/Counter, PWM, RTC
Communication interfaces: UART, I2C, SPI, USB
Network interfaces: CAN, Ethernet,
Power Control
Application software
Flash Memory Reprogramming
• In-System Programming (ISP)
Requires running program to be stopped
System set to programming mode
Restarted after reprogramming is completed
Design component level hardware Repeat the above cycle till test O.K.
instructions.
Characteristics:
memory accesses.
• Uses less silicon, pin count, and runs at high clock speed
• Real-time applications
• Emphasis on software
Characteristics:
• Emphasis on hardware
faster
Program In s t r u c ti o n In s t r u c ti o n
D e co d e r D e co d e r
M e m ory
R e g is t e r s R e g is t e r s
V o n N e u m a n A r c h it e c t u r e H a r v a r d A r c h it e c t u r e
Microprocessor vs. Microcontroller
Microprocessor Microcontroller
Basic components Basic Components
ALU, Accumulator, Registers, Control CPU, ROM, RAM, Peripherals, I/O ports,
Unit, Instruction Decoder, Bus Serial interfaces, Controllers, Bus
Microcontrollers
Address bus 16-bit 16-bit 16-bit 16-bit 14-bit 16-bit 32-bit 32-bit
Clock Speed 12 MHz 0–33 MHz 0–4 MHz 20 MHz 20 MHz 0–40 MHz 10–25 MHz 0-100 MHz
Memory
Interrupts 5 8 18 2 4 18 22
One One
DAC No No No No No No
10-bit 10-bit
I2S No No No No No No No One
Yes
SPI No No One Yes No
(MSSP)
One One
Ethernet Ethernet
No No No No No No No
Port MAC
4. Brief any four major fields where embedded systems are used.
7. What is interrupt?
12. What are the basic elements providing analog I/O functions?
13. List various hardware components used in implementing embedded system
15. Outline the hardware design of any typical embedded system (may be a
mobile robot).
21. Name any one microcontroller for low end, mid range and high end
embedded applications.
Cycle Test - Question Paper Pattern
I. 1. Objective Type – three questions 3x1=3
a. -----------
b. -----------
c. -----------
a. -----------
b. -----------
c. -----------
----
Total 20
Embedded System Implementation
• Hardware
Processing element:
Microcontroller – Processor, Memory (Flash, RAM, Cache)
Peripherals:
Input & Output devices
Interfacing sensors and actuators
Communication interfaces:
Interfacing protocols
Bus system
• Software
System software:
Operating system, RTOS,
Development tools: Cross compilers, emulators, simulators
Debug tools:
Application software