Parallel Input/Output

Slides:



Advertisements
Similar presentations
The 8051 MicroController In this module, we will be discussing the MCS-51 family of microcontroller, in particular the 8051, which is the generic IC representative.
Advertisements

Week10 Boolean Instructions on the Boolean Instructions  Boolean (or Bit) addressable capability is unique to the 8051  Enables efficient handling.
PROGRAMMABLE PERIPHERAL INTERFACE -8255
TK2633 Introduction to Parallel Data Interfacing DR MASRI AYOB.
Embedded System Spring, 2011 Lecture 9: I/O Programming Eng. Wazen M. Shbair.
CHAPTER 4 I/O PORT PROGRAMMING. I/O Port Pins The four 8-bit I/O ports P0, P1, P2 and P3 each uses 8 pins All the ports upon RESET are configured as input,
Interfacing ADC to 8051.
Practical Session No. 10 Input &Output (I/O). I/O Devices Input/output (I/O) devices provide the means to interact with the “outside world”. An I/O device.
In a not gate, if the input is on(1) the output is off (0) and vice versa.
Parallel Ports of PC Methods of interfacing Examples.
ECE/CS-352: Embedded Microcontroller Systems Embedded Microcontroller Systems.
1 EKT 225 MICROCONTROLLER I CHAPTER 3 I/O PORT PROGRAMMING.
Khaled A. Al-Utaibi  Intel Peripheral Controller Chips  Basic Description of the 8255  Pin Configuration of the 8255  Block Diagram.
Embedded Systems Design 1 Lecture Set 6 I/O Ports.
Computer Sensing and Control How is binary related to what we are trying to accomplish in electronics? The PC GadgetMaster II uses binary to communicate.
Dr. Rabie A. Ramadan Al-Azhar University Lecture 6
Basic I/O Interface A Course in Microprocessor
Teachers Name : Suman Sarker Telecommunication Technology Subject Name : Microcontroller & Embedded System Subject Code : 6871 Semester : 7th Department.
Input/Output Interface Circuits and LSI Peripheral Devices
CoE3DJ4 Digital Systems Design Hardware summary. Microprocessors vs. Microcontrollers Microprocessors are single-chip CPU used in microcomputers Microcontrollers.
Basic Architecture Lecture 15. In general, if the number of bits is n, then the number of different combinations of 0s and 1s that can be made is 2 n.
Input/Output 2 What is I/O? How we get the CPU to communicate with devices From the computer’s point of view, it’s just 1’s and 0’s Gets interpreted.
Logic Gates It’s Only Logical. Logic Gates Are the switches that computers and similar devices use. They hold their state until something changes. Are.
8051 Micro controller. Architecture of 8051 Features of 8051.
COMPILERS CLASS 22/7,23/7. Introduction Compiler: A Compiler is a program that can read a program in one language (Source) and translate it into an equivalent.
DESIGN OF SEQUENTIAL CIRCUITS by Dr. Amin Danial Asham.
Intel 8051 Another family of microcontroller is the Intel 8051 family. The basic 8051 microcontroller has four parallel input/output ports, port 0, 1,
Microcontroller Intel 8051 [I/O Ports]. Pin out of the 8051 –40 pin package –32 pins are used for the 4 ports. –V CC / V SS –ALE Address Latch Enable.
Projects 8051.
PROGRAMMABLE PERIPHERAL INTERFACE -8255
ENEE 440 Chapter PPI 8255 Register Select -CS A1 A0 REGISTER R/W PORT A R/W PORT B R/W PORT C R/W CR W 1 X X8255 NOT.
8051 Micro Controller. Microcontroller versus general-purpose microprocessor.
Programming PIC 16F84A in Assembly. PIC16F84 pin-out and required external components.
Intel 8255A PPI EEE 365 [FALL 2014] LECTURE ATANU K SAHA BRAC UNIVERSITY.
Revision questions CENG2400 v.14b 1 CENG2400 Revision, Question 1 A system has an ARM processor with a 32-bit General Purpose Input Output (GPIO) module.
Serial I/O Port.
Embedded Microcontroller Systems
PROGRAMMABLE PERIPHERAL INTERFACE -8255
CHAPTER ADDRESSING MODES.
Everybody.
Interfacing I/O Devices
Embedded Microcontroller Systems
For further information
Diagram of microprocessor interface with IO devices
IPCOWALA INSTITUTE OF ENGINEERING & TECHNOLOGY-DHARMAJ
BY: Adam sHEERES-Paulicpulle
Programmable Interval Timer
Hardware Source: ttp:// under
8085 microprocessor.
8085 Interrupts.
Introduction to Micro Controllers & Embedded System Design I/O Processing and Serial Port Operation Department of Electrical & Computer Engineering Missouri.
Data Processing Instructions
Source: Serial Port Source:
Interfacing Memory Interfacing.
Memory Organisation Source: under
PROGRAMMABLE PERIPHERAL INTERFACE -8255
Timer.
(Electrical Engg 6th Semester)
Memory organization On- chip memory Off-chip memory
4-Bit Counter Spencer Canavan.
Parallel communication interface 8255
AT28C17 EEPROM By: Ethan Peterson.
The centronics port Interfacing to a PC.
First Design Key board R L S.
Hardware Source: ttp:// under
Source: Serial Port Source:
Keypad Source: under under
Open Education Resource-OER on Microprocessor 8085 Instruction Set By Dr. S. N. Sampat, Team leader Ms. R. P. Merchant, Member Mr. A. K. Bilakhia, Member.
CHAPTER 4 I/O PORT PROGRAMMING.
Source: Serial Port Source:
Presentation transcript:

Parallel Input/Output

The basic 8051 microcontroller has four 8-bit ports, P0, P1, P2 and P3.

Port Address P0 80H P1 90H P2 A0H P3 B0H

Pinout All pins on all the ports (32 pins) can be used as either inputs or outputs

Initialization of port pins Output ports (Does NOT need to be initialized) To use a port pin as an output requires no initialization. You simply write to the port. For example, SETB P1.5 sends a logic 1 to P1 bit 5; MOV P0, A sends the data in the accumulator to P0. Input ports (Needs to be initialized) To initialize a port pin as an input we must first write a logic 1 to that pin. SETB P3.2 sets P3 pin 2 as an input; MOV P2, #0FFH initializes each pin of P2 as an input.

A comment on initialization is important It is important when initialising a port pin on the 8051 to write a comment stating this, otherwise it is difficult to know whether data is being sent out to the port pin, or the port pin is being initialised for input. For example, the code should be written something like: MOV P2, #0FFH ; initialising P2, all pins, as inputs

Why must a logic 1 be written to the port pin to make it an input pin?

Writing to a port

Read from a port

Read from a port

Typical programming for input/output ports ; Used as output ports: don’t have to be initialized SETB P3.5 ; set pin 5 of port 3 MOV P1, #4AH ; sending data 4AH to port 1 MOV P2, A ; send whatever data is in the accumulator to port 2 ; Used as input ports: must be initialized SETB P1.0 ; initialize pin 0 of port 1 as an input pin MOV P2, #FFH ; initialize pins of port 2 as inputs MOV C, P1.0 ; Read state on pin 0 of port 1 to the carry MOV R3, P2 ; Read datum on port 2 into R3