Download - 8051 Based Embedded System Design
![Page 1: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/1.jpg)
Product: NASA's Mars Sojourner Rover.
Microprocessor: 8-bit Intel 80C85.
Introduction To Embedded systems
![Page 2: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/2.jpg)
“An embedded system is a combination of Computer Hardware and software designed to control the additional Hardware attached to it”.
![Page 3: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/3.jpg)
More.., An embedded system is a specialized computer
system that is part of a larger system or machine.
Embedded systems can also be thought of as information processing subsystems integrated in a larger system.
As part of a larger system it largely determines its functionality.
![Page 4: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/4.jpg)
Desktop vs Embedded Systems.
Embedded systems are dedicated to specific tasks, whereas PC’s are generic computing platforms.
The implications of software failure is much more severe in embedded systems than in desktop systems.
![Page 5: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/5.jpg)
How Embedded Systems are Different ? They are application specific. Supported by wide array of processor and
processor architectures. Cost sensitive Real time constraints. Power constraints. Demand for special tools for their complete design.
![Page 6: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/6.jpg)
Embedded Product Life Cycle 1. Exploring the components. 2. Selecting the components 3. Programming. 4. Detailed Development. 5. Unit testing. 6. Integration 7. System Under Test.
![Page 7: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/7.jpg)
A Typical Embedded System
CPU
SOFTWARE
MEMORY
D/A ConversionA/D Conversion
AuxiliarySystems(PowerCooling)
DIAGNOSTICPORT
HumanInterface
ELECTROMECHANICALBACKUP & SAFETY
EXTERNAL ENVIRONMENT
FPGA/ASIC
Actuators
![Page 8: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/8.jpg)
Significance With an Example.
Automobile emissions have decreased by 90% over the last 20 years, primarily due to the use of micro processors in the embedded systems.
The open loop fuel control systems, characterized by carburetor is now a fuel injected, closed loop system using sensors to provide control under wide range of operating conditions.
![Page 9: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/9.jpg)
Sensors & Actuators in Embedded Systems
![Page 10: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/10.jpg)
Categories of Embedded
Communication devices modems, cellular phones Home Appliances CD player, VCR, microwave oven Control Systems Automobile anti-lock braking systems, robotics,
satellite control
![Page 11: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/11.jpg)
Characteristics of Embedded Systems Application Specific Systems. Reactive Systems. Distributed Systems. Heterogeneous Architectures. Harsh environment. System safety and reliability. Small and low weight. Cost sensitivity. Power management.
![Page 12: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/12.jpg)
Requirements for Embedded Systems Functional Requirements. Temporal Requirements (Timeliness). Dependability Requirements
![Page 13: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/13.jpg)
Compilation Tools
Native Compilers. Cross Compilers.
![Page 14: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/14.jpg)
GNU Auto tools
Used to configure software for different compilation environments
Contains many ready made tests for testing compiler tool-chain ,C-library etc. features
Composed of Autoconf, Automake, Libtool, m4 tools
Produce ’configure’ script which is shipped with the software
![Page 15: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/15.jpg)
Embedded Applications
![Page 16: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/16.jpg)
The first Embedded System: Apollo Guidance Computer.
![Page 17: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/17.jpg)
MK 57 Advanced Vertical Launching System (AVLS) is the next-generation naval missile launching system for future surface combatants of the U.S. Navy
![Page 18: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/18.jpg)
Shipboard Self-Defense System (SSDS) is a family of systems designed for use in future Navy ship combat systems such as DD(X) destroyers
![Page 19: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/19.jpg)
IDM (improved data modem) is a communications and targeting system that can interface between the different communications formats in use by the U.S. Army and the U.S. Air Force. A real-time operating system resides inside the IDM
![Page 20: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/20.jpg)
Automated Radar Terminal Systems (ARTS) manage air-traffic control at USA airport locations such as New York, Dallas/Fort Worth, Chicago, Southern California, and Atlanta
![Page 21: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/21.jpg)
Real-Time System
Definition: Any system in which the time at which output is produced is significant.
This is usually because the input corresponds to some movement in the physical world, and the output has to relate to the same movement.
The lag from input time to output time needs to be sufficiently small for acceptable timeliness.
![Page 22: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/22.jpg)
Classifications Of Real Time Systems Hard Real time Systems
Soft Real Time Systems
Firm Real Time
![Page 23: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/23.jpg)
An RTOS Kernel provides an Abstraction Layer between Application Software and Embedded Hardware
![Page 24: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/24.jpg)
Design Flow
![Page 25: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/25.jpg)
![Page 26: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/26.jpg)
The Embedded System Design Life Cycle
![Page 27: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/27.jpg)
Product Specifications
•Product requirements
•Customer needs
•Development tools required to develop the
product.
•Concentrating on the performance to cost ratio.
![Page 28: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/28.jpg)
PartitionDeciding on the things to be implemented in hardware and software
Hardware: cost increases speed increases
Software: low cost
Example:Implementing FPU.
![Page 29: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/29.jpg)
Developing software and hardware for microcontroller based systems involves the use of a range of tools that can include editors, assemblers, compilers, debuggers ,simulators, emulators and flash/ OTP programmer.
![Page 30: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/30.jpg)
IntegrationLoading the software into the hardware
Demand for debugging circuitry.
The following are the debug requirements
Run control: The ability to start, stop, peak and poke processor and the memory.
Memory substitution: Replacing RAM based memory with RAM for rapid and easy code download, debug and repair cycles.
Real time analysis: Following code flow in real time with real time.
![Page 31: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/31.jpg)
Writing The Code
Software Code for a microcontroller is written in a programming language of choice.
This source code is written with a standard ASCII text editor and saved as an ASCII text file.
A higher level language like C is for the most part independent of a microcontroller's specific architecture, but still requires some controller specific extensions of the standard language to be able to control all of a chip's peripherals and functionality.
![Page 32: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/32.jpg)
Translating the code
The source code needs to be translated into instructions the microcontroller can actually execute.
A microcontrollers instruction set is represented by "op codes". Op codes are a unique sequence of bits ("0" and "1") that are decoded by the controller's instruction decode logic and then executed.
Instead of writing opcodes in bits, they are commonly represented as hexadecimal numbers, whereby one hex number represents 4 bits within a byte, so it takes two hex numbers to represent 8 bits or 1 byte.
![Page 33: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/33.jpg)
Debugging Tools
Simulators
Simulators try to model the behavior of
the complete microcontroller in software
![Page 34: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/34.jpg)
Debugging
A Debugger allows you to download your code to the emulator's memory and then control all of the functions of the emulator from a PC.
Common debugging features include the capability to examine and modify the microcontroller's on-chip registers, data- and program-memory;
pausing or stopping program executing at defined program locations by setting breakpoints;
![Page 35: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/35.jpg)
Single-Stepping (execute one instruction at a time) through the code; and looking at a history of executed code (trace).
![Page 36: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/36.jpg)
Starter kits
Starter Kits, commonly bundle a hardware board and in-system programmer with some software components
(assembler, linker, debugger, sometimes an IDE and a code-size limited "evaluation" version of a compiler)
To allow for very basic emulation and debugging functions.
![Page 37: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/37.jpg)
Emulator
An emulator is a piece of hardware that ideally behaves exactly like the real microcontroller chip with all its integrated functionality. It is the most powerful debugging tool of all.
A microcontroller's functions are emulated in real-time and non-intrusively.
![Page 38: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/38.jpg)
All emulators contain 3 essential functions in different implementation forms:
The Emulator Control Logic, including Emulation Memory .
The actual Emulation Device
A Pin Adapter that gives the emulator's target connector the same "package" and pin out as the microcontroller to be emulated
![Page 39: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/39.jpg)
Design of Embedded Systems
system specification – emphasis on integrated design
Programming languages and language requirements,
Operating Systems (including real-time kernels),
Architecture and Hardware.
![Page 40: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/40.jpg)
Laboratory projects in data acquisition, instrumentation, embedded control, including Real-Time Kernel Enhancement, Embedded Systems software Development, Hardware/Software Co-Design
![Page 41: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/41.jpg)
Design of Embedded Systems --Outcomes
comprehend organization of various components of an embedded system.
Develop embedded applications using off-the-shelf software and hardware components and production tools.
Assess the cost effectiveness of various design alternatives.
![Page 42: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/42.jpg)
Embedded Systems Engineering - Outcomes
Understand and address (within a software
architecture) the critical issues most often associated with embedded software including high availability, performance, integrity, survivability, reliability safety, and predictability.
model and analyze a system in order to observe system characteristics and the system architecture level.
to develop systems utilizing both hardware and software components.
to perform testing at different levels such as the component, integration, and system levels.
![Page 43: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/43.jpg)
Future
Continue to examine requirements motivated by next generation of embedded communications systems lightning-fast and intelligent network
infrastructure. Must be able to analyze and develop
software and hardware solutions for these infrastructures
![Page 44: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/44.jpg)
Device Driver For 8051
![Page 45: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/45.jpg)
Pin Description Of ADC
VccCSRDWRClkin
D0 – D7
INTR
Clkr
Vin+Vin-
AGnd
DGndVref\2
1
2
3
4
5
6
7
8
9
10
15
1112
13
14
16
17
18
19
![Page 46: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/46.jpg)
Interfacing With Microcontroller
![Page 47: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/47.jpg)
CS : Used to activate the adc0804. active low.
RD: This is an input signal and active low.The ADC converts the data to binary and holds it in the internal register. This pin is used to get the converted data out of the chip.
WR: converter pin. This initiates the DAC to start the conversion process.
The conversion rates depends on the clock in values.
![Page 48: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/48.jpg)
When data conversion is complete INTR pin is forced low.
F=1/rc Vref/2: pin is open then the volatage ranges
is between 0 to 5volts.
![Page 49: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/49.jpg)
Clr a Mov p1,#0ffh ; making port1 as an input
port. Setb intr Clr wr Setb wr Here:jb intr here Clr rd ;conversation finished enable
rd Mov a,p1 Setb rd
Driver for ADC in assembly
![Page 50: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/50.jpg)
Char value x;main(){ p1 = 0xffIntr =1;Wr=1;Rd=1;While(1){Wr=0;wr=1;While(intr==1)Rd=0; X=p1Rd=1.}}
In C Version
![Page 51: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/51.jpg)
![Page 52: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/52.jpg)
Role Of Sensors
A sensor is a type of Transducer. Sensors are used in everyday life. Applications
include automobiles, machines, aerospace, medicine, industry and robotics
![Page 53: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/53.jpg)
Types Of Sensors
Thermal Electromagnetic Mechanical Chemical Optical and radiation Acoustic
![Page 54: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/54.jpg)
Thermal sensors
Temperature sensors: thermometers, thermocouples.
Temperature sensitive resistors Thermistors and resistance temperature detectors
Bi-Metal : Thermometers and thermostats Heat sensors: bolometer, calorimeter
![Page 55: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/55.jpg)
Mechanical sensors
Pressure sensors Mechanical sensors: Acceleration sensor
![Page 56: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/56.jpg)
Chemical sensors
Chemical sensors detect the presence of specific chemicals or classes of chemicals. Examples include oxygen sensors
![Page 57: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/57.jpg)
Optical and radiation sensors
Electromagnetic time-of-flight. Generate an electromagnetic impulse, broadcast it, then measure the time a reflected pulse takes to return
Commonly known as – RADAR (Radio Detection And Ranging)
Infra red sensors
![Page 58: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/58.jpg)
![Page 59: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/59.jpg)
PIN DESCRIPTION OF LM 35
![Page 60: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/60.jpg)
Features Of LM 35
Calibrated directly in ß Celsius (Centigrade)
Suitable for remote applications Low cost due to wafer-level trimming Operates from 4 to 30 volts Less than 60 mA current drain Low impedance output, 0.1 X for 1 mA
load
![Page 61: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/61.jpg)
PIN DESCRIPTION OF LM 336
![Page 62: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/62.jpg)
FEATURES OF LM 336
Low temperature coefficient . Wide operating current of 400ma to10ma 0.2w dynamic impedance . Guaranteed temperature stability . Fast turn-on
![Page 63: 8051 Based Embedded System Design](https://reader034.vdocument.in/reader034/viewer/2022052315/546a6080af795985298b4661/html5/thumbnails/63.jpg)