ECE 493T9 Real Time Embedded System Tutorial Set 3 June 10, Spring 2008.

Slides:



Advertisements
Similar presentations
I2C bus Inter Integrated Circuits bus by Philips Semiconductors
Advertisements

INPUT-OUTPUT ORGANIZATION
4-1 Timers Timers can be used for  timing  event counting  pulse width measurement  pulse generation  frequency multiplication There are 8 Timers.
Programmable Interval Timer
The 8051 Microcontroller Chapter 5 SERIAL PORT OPERATION.
Chapter 10 Input/Output Organization. Connections between a CPU and an I/O device Types of bus (Figure 10.1) –Address bus –Data bus –Control bus.
I/O Unit.
Khaled A. Al-Utaibi  Computers are Every Where  What is Computer Engineering?  Design Levels  Computer Engineering Fields  What.
Serial Interfaces, Part Deux -I 2 C and SPI December 4, 2002 Presented by Eugene Ho.
Starting with serial Chapter Ten 10.1, 10.2,
Introduction An interrupt is an event which informs the CPU that its service (action) is needed. Sources of interrupts: internal fault (e.g.. divide by.
University College Cork IRELAND Hardware Concepts An understanding of computer hardware is a vital prerequisite for the study of operating systems.
Coordinate Based Tracking System
7-1 Digital Serial Input/Output Two basic approaches  Synchronous shared common clock signal all devices synchronised with the shared clock signal data.
Chapter 6 Serial Communications Objectives Introduce the RS232 standard and position it within the crowded field of serial communications standards. Configure.
ECE 353 Introduction to Microprocessor Systems Michael G. Morrow, P.E. Week 13.
Engineering 1040: Mechanisms & Electric Circuits Fall 2011 Introduction to Embedded Systems.
Computer Architecture Lecture 08 Fasih ur Rehman.
Serial Peripheral Interface Module MTT M SERIAL PERIPHERAL INTERFACE (SPI)
LSU 10/22/2004Serial I/O1 Programming Unit, Lecture 5.
4.0 rtos implementation part II
8254 Programmable Interval Timer
PIT: Programmable Interval Timer
UART and UART Driver B. Ramamurthy.
1 SERIAL PORT INTERFACE FOR MICROCONTROLLER EMBEDDED INTO INTEGRATED POWER METER Mr. Borisav Jovanović, Prof.dr Predrag Petković, Prof.dr. Milunka Damnjanović,
MICROPROCESSOR INPUT/OUTPUT
Lecture Set 9 MCS-51 Serial Port.
Lecture 20: Communications Lecturers: Professor John Devlin Mr Robert Ross.
1 Microprocessor-based Systems Course 9 Design of the input/output interfaces (continue)
I/O Example: Disk Drives To access data: — seek: position head over the proper track (8 to 20 ms. avg.) — rotational latency: wait for desired sector (.5.
Universal Asynchronous Receiver/Transmitter (UART)
DEVICES AND COMMUNICATION BUSES FOR DEVICES NETWORK
EGRE 6311 Midsize Microcontrollers and Microprocessors The 8051 is an example of a small inexpensive microcontroller intended for simple applications.
(More) Interfacing concepts. Introduction Overview of I/O operations Programmed I/O – Standard I/O – Memory Mapped I/O Device synchronization Readings:
Advanced Microprocessor1 I/O Interface Programmable Interval Timer: 8254 Three independent 16-bit programmable counters (timers). Each capable in counting.
 8251A is a USART (Universal Synchronous Asynchronous Receiver Transmitter) for serial data communication.  Programmable peripheral designed for synchronous.
I2C Master Core Simulation Environment. I2C Master Core Requirements Coverage (*) Requirement I2C IP RS-906: The I2C IP shall define the period of time,
Computer Architecture Lecture 2 System Buses. Program Concept Hardwired systems are inflexible General purpose hardware can do different tasks, given.
EEE440 Computer Architecture
MCS51 - lecture 6. Lecture 6 1/32 Extending MCS51 system Built-in peripherals MCS51 family.
8254 Timer.
©2008 R. Gupta, UCSD COSMOS Summer 2008 Peripheral Interfaces Rajesh K. Gupta Computer Science and Engineering University of California, San Diego.
Chapter 13 – I/O Systems (Pgs ). Devices  Two conflicting properties A. Growing uniformity in interfaces (both h/w and s/w): e.g., USB, TWAIN.
© 2009, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction  Purpose:  This course provides an overview of the serial communication.
بسم الله الرحمن الرحيم MEMORY AND I/O.
Time Management.  Time management is concerned with OS facilities and services which measure real time.  These services include:  Keeping track of.
Chapter 3 System Buses.  Hardwired systems are inflexible  General purpose hardware can do different tasks, given correct control signals  Instead.
Submitted by:.  Project overview  Block diagram  Power supply  Microcontroller  MAX232 & DB9 Connector  Relay  Relay driver  Software requirements.
Networked Embedded Systems Pengyu Zhang & Sachin Katti EE107 Spring 2016 Lecture 4 Timers and Interrupts.
CORDLESS MOUSE FEATURES BY TV REMOTE USING PIC MICROCONTROLLER
UNIT – Microcontroller.
I2C PROTOCOL SPECIFICATION
Communication Lines Fundamentals.
BJ Furman ME 106 Fundamentals of Mechatronics 15NOV2012
Introduction to Microprocessors and Microcontrollers
Asynchronous Serial Communications
Serial Communication Interface: Using 8251
Programmable Interval timer 8253 / 8254
Programmable Interval timer 8253 / 8254
Md. Mojahidul Islam Lecturer Dept. of Computer Science & Engineering
Md. Mojahidul Islam Lecturer Dept. of Computer Science & Engineering
8051 Micro Controller.
8253 – PROGRAMMABLE INTERVAL TIMER (PIT). What is a Timer? Timer is a specialized type of device that is used to measure timing intervals. Timers can.
Presentation transcript:

ECE 493T9 Real Time Embedded System Tutorial Set 3 June 10, Spring 2008

Basic ES Peripherals Timer / Counter Intel 8253, MC62830, Timer Processors, Real-Time Clocks. Serial Ports SPI, I 2 C, M-Bus, RS232 Parallel Port DMA (To Be Covered in the future if needed)

Timers A Must-Have for all the Synchronous Operations. Pre-scalar: Divide the clock freq. down to the desired counting freq. Phase-Lock Loop: Multiply the clock freq. up to the desired counting freq. Often available in FPGA. Counter I / O Control Can provide more functionalities than just a timer interrupt generator. Characterized by 2 Properties: 1)Pre-scalar Value (Min Clock Freq.) 2)Counter Size

Intel 8253 Timer 5 Modes Mode 1: Interrupt on Termination Count Mode 2: Programmable One-Shot Mode 3: Rate Generator (Pulse Generator) Mode 4: Square-Wave Generator – Software Generated Strobe Mode 5: Square-Wave Generator – Hardware Generated Strobe When Interrupts are generated from the Intel 8253 Timer, the interrupt signal does not have a dedicated output pin; instead, the OUT pin is often used as the interrupt output pin.

MC62830 Timer 24bit Timer Higher Resolution than Intel bit Pre-Scalar Drawback: Designed to work with 8-bit processors => loading the timer requires 4 cycles: 1) Load 3 8-bit preload registers 2) Reset Z flag to start countdown

Timer Processor Just like memory management and graphic processing, the timing operation can also get “emancipated” from the mother CPU, giving rise the Timer Processor. Design Note: Use it only when your design really requires a pinpointing timing!! Each addition of an application- specific processor means an additional burden on your design budget.

Real-Time Clocks Rather than generating clock counts from timers, RT clocks keep track of timing in terms of current time and date. With modern microprocessors running at MHz range, RT clocks can also be software simulated to effectively reduce the design cost.

Serial Ports Dominant data transfer method from ES to its peripherals Two interconnected shift registers Sync. and Async.

Serial Peripheral Interface (SPI) By Motorola Synchronous Master-Slave System.

Inter-IC Bus (I 2 C) Developed by Philips in the 80s for IC components communication in TV. Two-line serial bus (SCL, SDA) with Master / Slave Communication Mode. Serial Control Line: (SCL) Carries controlled clock signal, used for both synchronizing and flow control. Serial Data and Address: (SDA) Carries address and data; used in combination with SCL to facilitate flow control. Basic Flow Control Mechanism:

Inter-IC Bus (I 2 C) Three Main Data Transfer Modes: –Read Byte with ACK –Write Byte with ACK –Write Byte with STOP

Inter-IC Bus (I 2 C) Multiple Slave Access: How to access a specific slave? Transfer Address before Data!! Basic Access Procedure: Extended Address Access Procedure:

Inter-IC Bus (I 2 C) Other Issues: –Multi-Register Transfer Inheritant Address Increment Write Index –ACK Flag Timing Issue I 2 C Masters would need a timer to determine the length of a valid ACK flag. –Multi Master Access Regulation When two or more masters are on the bus, they generally monitor the bus and wait until it’s clear before they attempt to initiate any bus activity.

Recommended Standard 232 Implemented with DSub9 port. CMOS or TTL Voltage Standard. –+5V and -5V –+12V and -12V –Logical Voltage Tolerance: ±2V RS232 is the physical interface on top of which serial transmission is facilitated via serial protocols(ex. DF1, ModBus, etc.). Basic RS232 Packet (by Physical Layer Definition, ref. OSI Model)

Recommended Standard 232 Async. Flow Control Signal Lines Fact: - The layout is outdated for most applications nowadays, since RS232 has not been used as a networking infrastructure for more than a decade. - Instead of utilizing all 9 lines, only TxD and RxD are being used for point-to-point data transfer – Very similar to USB. - Occasionally, some specialized chips (such as a CANbus Interface Chip ELM232 I’ve used for my FPGA project) would require RTS / CTS to facilitate simple handshaking - The rest signal lines are rarely used in new ES’s. If you ever need to use them, reference materials are all over the internet for grab.

Recommended Standard 232 How to Implement RS232 Interface? –Most uC’s come with at least one async. channel. –Connect the async. channel to a RS232 physical driver chip in order to conform to the voltage standard. How about USB? As mentioned previously, most USB chips have similar interface as the RS232 driver chip.

About the Project…=( =( =( Until we are 100% sure the dev kit will arrive in time, we will not have a tutorial on Atmel Processor User Manual. One thing I’m sure about the project: It’s a simple design project without much constraints on the end-product to be delivered. It doesn’t mean that you get to hand in a first-year level design!! It also doesn’t mean that the professor will be extra lenient on marking!! Base your designs on RTOS concepts taught in this course to earn a decent mark.

Questions?