Asynchronous Serial I/O Unit 12 - Part 1. SCI Registers – Channel 0 SCI0BDH – SCI Baud Rate Register High Byte SCI0BDL – SCI Baud Rate Register Low.

Slides:



Advertisements
Similar presentations
Serial Communication Interface (SCI)
Advertisements

Serial Communications Interface (SCI) Michael LennardZachary PetersBao Nguyen.
11-1 ECE 424 Design of Microprocessor-Based Systems Haibo Wang ECE Department Southern Illinois University Carbondale, IL I/O System Design.
ECT 357 Ch 18 UART. Today’s Quote: Be careful that your marriage doesn’t become a duel instead of a duet. Be careful that your marriage doesn’t become.
The 8051 Microcontroller Chapter 5 SERIAL PORT OPERATION.
H. Huang Transparency No.9-1 The HCS12/MC9S12 Microcontroller Copyright © 2010 Delmar Cengage Learning Chapter 9: Serial Communication Interface – SCI.
SCI: Serial Communications Interface Presented by: Sean Kline Chad Smith Jamie Cruce.
Serial Communication Interface
Asynchronous Communication Hardware  Data within a DTE is usually stored and moved in a parallel fashion.  Data sent across the channel is generally.
The Serial Communication Interface (SCI) Chapter 11.
USARTS CS423 Dick Steflik. USART ● Universal Synchronous Asynchronous Receiver Transmitter ● used to send and receive small packets over a serial line.
Chapter 9 Serial Communication Interface  SCI. Why Serial Communication? Parallel data transfer requires many I/O pins. This requirement prevents the.
USART and Asynchrono us Communica tion The USART is used for synchronous and asynchronous serial communication. USART = Universal Synchronous/Asynchronous.
7-1 Digital Serial Input/Output Two basic approaches  Synchronous shared common clock signal all devices synchronised with the shared clock signal data.
Harrison Jones Alexis Noel William Allen SERIAL COMMUNICATION INTERFACE (SCI)
Network and Systems Laboratory nslab.ee.ntu.edu.tw.
EEE305 Microcontroller Systems Lecture 7: Embedded C using PIC microcontrollers Serial i/o with the XC8 Teaching resources are at
1 SCI Serial Communication Interface Gerrit Becker James McClearen Charlie Hagadorn October 21, 2004.
Serial Communication Interface (SCI) Kevin Stuart Matt Betts March 27, 2007 ME 6405, Sp 07.
Serial Peripheral Interface Module MTT M SERIAL PERIPHERAL INTERFACE (SPI)
Serial Communication ETEC 6416.
EET 2261 Unit 11 Serial Communications Interface  Read Almy, Chapter 24.  Homework #11 and Lab #11 due next week.  Quiz next week.
Lecture 9. - Synchronous Devices require a timing signal. Clock generated Interval Timer Microprocessor Interval Timer Clk PCLK = MHz PCLK (for.
Lecture 7 Universal Asynchronous Receiver/Transmitter (UART) NCHUEE 720A Lab Prof. Jichiang Tsai.
Universal Asynchronous Receiver/Transmitter (UART)
Chapter 8 Serial and Parallel Port Interfacing Valvano’s Intro. To Embedded Systems.
Scott Baker Will Cross Belinda Frieri March 9 th, 2005 Serial Communication Overview ME4447/6405.
Advanced Microprocessor1 I/O Interface Programmable Interval Timer: 8254 Three independent 16-bit programmable counters (timers). Each capable in counting.
Example. SBUF Register SCON Register(1) SCON Register(2)
NS Training Hardware. Serial Controller - UART.
Universal Asynchronous Receiver/Transmitter (UART)
Sparkfun Electronics ATtiny85 Arduino Quick Reference Sheet
Serial Communication Interface Ta Kim Nicholas Earnhart Razid Ahmad ME 6405 – Fall 2008 November 6, 2008.
CE-2810 Dr. Mark L. Hornick 1 Using the USART Configuration and Programming.
ME 4447/6405 Microprocessor Control of Manufacturing Systems and
1 October 26, 2006ME 6405 MechatronicsSerial Communication Interface Brian Guerriero Jon Rogers Robert Thiets.
Serial Communications Interface Module Slide #1 of 19 MC68HC908GP20 Training PURPOSE -To explain how to configure and use the Serial Communications Interface.
ESCI Base. Serial Communication TX RX 8bits Interrupt on Receiver Full 4 Enhanced Serial Communication Interface (eSCI) in the PXR40 eSCIB is used for.
Example 1 Program the divisor Latch for 300 baud. Assume Xin=1.8432MHz The Base Address: 0x3F8 0RX_TX / Divisor.low 1IER: Interrupt Enable Reg. / Divisor.high.
Embedded Systems February 10, Serial Interface - SPI  Serial Peripheral Interface  Synchronous communications  Clock supplied by the Master.
Using TRF7970A in SPI w/o SS mode, then in Direct Mode 1 Texas Instruments Embedded RF 12/15/2011.
Communicating. The ATmega16 communicates through one of the following ways: Serial Peripheral Interface (SPI) Universal Synchronous and Asynchronous serial.
CE-2810 Dr. Mark L. Hornick 1 Serial Communications Sending and receiving data between devices.
Chap.6.3 UART.
8251 USART.
Tiva C TM4C123GH6PM UART Embedded Systems ECE 4437 Fall 2015 Team 2:
SCI Communication Proudly Presented By: Adam Cardi & Aaron Enes.
Lecture 15. Modem Controller Register 4310 DTR 0 = Polling Operator 1 = Interrupts Enabled RTS 1 =Self Test 0 =Normal.
 The LPC2xxx devices currently have two on- chip UARTS.  Except UART1 has additional modem support.
The HCS12 SCI Subsystem A HCS12 device may have one or two serial communication interface. These two SCI interfaces are referred to as SCI0 and SCI1. The.
Serial I/O Port.
Serial mode of data transfer
CS-401 Computer Architecture & Assembly Language Programming
Refer to Chapter 16 in the reference book
Source: Serial Port Source:
SERIAL PORT PROGRAMMING
Serial Communications Interface (SCI)
Computer Organization and Design
Source: Serial Port Source:
UART Serial Port Programming
Using TRF7970A in SPI w/o SS mode, then in Direct Mode 1
8251A UNIVERSAL SYNCHRONOUS ASYNCHRONOUS RECEIVER TRANSMITTER
UART Protocol Chapter 11 Sepehr Naimi
Configuration and Programming
NS Training Hardware.
Source: Serial Port Source:
Serial Communication 19th Han Seung Uk.
Source: Serial Port Source:
Using TRF7970A in SPI w/o SS mode, then in Direct Mode 1
AVR UART The UART, or Universal Asynchronous Receiver Transmitter, provides hardware support for a serial port on AVR processors Signaling is compatible.
Presentation transcript:

Asynchronous Serial I/O Unit 12 - Part 1

SCI Registers – Channel 0 SCI0BDH – SCI Baud Rate Register High Byte SCI0BDL – SCI Baud Rate Register Low Byte SCI0CR1 – SCI Control Register 1 SCI0CR2 – SCI Control Register 2 SCI0SR1 – SCI Status Register 1 SCI0SR2 – SCI Status Register 2 SCI0DRH – SCI Data Register High Byte SCI0DRL – SCI Data Register Low Byte

SCI Register Definitions Channel 0 #define SCI0BDH _P(0xC8) #define SCI0BDL _P(0xC9 #define SCI0CR1 _P(0xCA) #define SCI0CR2 _P(0xCB) #define SCI0SR1 _P(0xCC) #define SCI0SR2 _P(0xCD) #define SCI0DRH _P(0xCE) #define SCI0DRL _P(0xCF)

Baud Rate Generation BAUD RATE = 2 MHZ 16 * (BAUD RATE DIVISOR) THEREFORE, SET BAUD RATE DIVISOR = 2MHZ 16 * (DESIRED BAUD RATE)

Example – Baud Rate Initialization Let Desired Baud = 9600 Using formula: Baud Rate Divisor = *9600 = (Use integer value of 13) Register Initialization: SCIOBDH= 0 SCIOBDL=13 (Max value of Baud Rate Divisor = = 8192

Parity Type 1: Odd 0: Even Parity Enable 0: 9 data bits 1: 8 data bits Select Loop-Back Mode Wake-up Condition Selection

Interrupt EnablesTransmitter and Receiver Enables Enter Sleep Mode Send Break Character

Break Character Start Bit = “0” All Data Bits = “0” Parity Bits if present = “0” Stop Bit = “0” 68HC12 keeps line in “0” for additional bit times

Example: Initialize SCI Channel 0 /* Baud = 9600 */ int divisor = /9600; // divisor = 13 SCI0BDH = divisor>>8; // SCIOBDH= 0 SCI0BDL = divisor; // SCIOBDL=13 /* Standard Operation M=0 – 8 data bits PE =0 – No Parity PT =0 – Parity type*/ SCI0CR1 = 0x00; /* TE = 1 – Enable Transmitter RE = 1 – Enable Receiver */ SCI0CR2 = 0x0C;

Parity Type 1: Odd 0: Even Parity Enable 0: 9 data bits 1: 8 data bits Select Loop-Back Mode Wake-up Condition Selection (repeated slide)

Interrupt EnablesTransmitter and Receiver Enables Enter Sleep Mode Send Break Character (repeat slide)

Serial I/O Procedures /* Receive a Character */ unsigned char ci(void) {while((SCI0SR1&0x20)==0); return SCI0DRL; } Checking RDEF flag

(repeated slide)

Serial I/O Procedure /* Transmit a Character */ void co(unsigned char c) {while((SCI0SR1&80)==0); SCI0DRL=c; } Checking TDRE flag