SlideShare a Scribd company logo
Embedded Systems - I/O Programming
Embedded Systems - I/O Programming
In 8051, I/O operations are done using four ports and 40 pins. The following pin diagram shows the details
In 8051, I/O operations are done using four ports and 40 pins. The following pin diagram shows the details
of the 40 pins. I/O operation port reserves 32 pins where each port has 8 pins. The other 8 pins are
of the 40 pins. I/O operation port reserves 32 pins where each port has 8 pins. The other 8 pins are
designated as V
designated as V , GND, XTAL1, XTAL2, RST, EA (bar), ALE/PROG (bar), and PSEN (bar).
, GND, XTAL1, XTAL2, RST, EA (bar), ALE/PROG (bar), and PSEN (bar).
It is a 40 Pin PDIP (Plastic Dual Inline Package)
It is a 40 Pin PDIP (Plastic Dual Inline Package)
Note
Note − In a DIP package, you can recognize the first pin and the last pin by the cut at the middle of the IC.
− In a DIP package, you can recognize the first pin and the last pin by the cut at the middle of the IC.
The first pin is on the left of this cut mark and the last pin (i.e. the 40
The first pin is on the left of this cut mark and the last pin (i.e. the 40 pin in this case) is to the right of the
pin in this case) is to the right of the
cut mark.
cut mark.
I/O Ports and their Functions
I/O Ports and their Functions
The four ports P0, P1, P2, and P3, each use 8 pins, making them 8-bit ports. Upon RESET, all the ports
The four ports P0, P1, P2, and P3, each use 8 pins, making them 8-bit ports. Upon RESET, all the ports
are configured as inputs, ready to be used as input ports. When the first 0 is written to a port, it becomes
are configured as inputs, ready to be used as input ports. When the first 0 is written to a port, it becomes
an output. To reconfigure it as an input, a 1 must be sent to a port.
an output. To reconfigure it as an input, a 1 must be sent to a port.
Port 0 (Pin No 32 – Pin No 39)
Port 0 (Pin No 32 – Pin No 39)
It has 8 pins (32 to 39). It can be used for input or output. Unlike P1, P2, and P3 ports, we normally
It has 8 pins (32 to 39). It can be used for input or output. Unlike P1, P2, and P3 ports, we normally
connect P0 to 10K-ohm pull-up resistors to use it as an input or output port being an open drain.
connect P0 to 10K-ohm pull-up resistors to use it as an input or output port being an open drain.
cc
cc
th
th
It is also designated as AD0-AD7, allowing it to be used as both address and data. In case of 8031 (i.e.
It is also designated as AD0-AD7, allowing it to be used as both address and data. In case of 8031 (i.e.
ROMless Chip), when we need to access the external ROM, then P0 will be used for both Address and
ROMless Chip), when we need to access the external ROM, then P0 will be used for both Address and
Data Bus. ALE (Pin no 31) indicates if P0 has address or data. When ALE = 0, it provides data D0-D7, but
Data Bus. ALE (Pin no 31) indicates if P0 has address or data. When ALE = 0, it provides data D0-D7, but
when ALE = 1, it has address A0-A7. In case no external memory connection is available, P0 must be
when ALE = 1, it has address A0-A7. In case no external memory connection is available, P0 must be
connected externally to a 10K-ohm pull-up resistor.
connected externally to a 10K-ohm pull-up resistor.
MOV A,#0FFH ;(comments: A=FFH(Hexadecimal i.e. A=1111 1111)
MOV A,#0FFH ;(comments: A=FFH(Hexadecimal i.e. A=1111 1111)
MOV P0,A ;(Port0 have 1's on every pin so that it works as Input)
MOV P0,A ;(Port0 have 1's on every pin so that it works as Input)
Port 1 (Pin 1 through 8)
Port 1 (Pin 1 through 8)
It is an 8-bit port (pin 1 through 8) and can be used either as input or output. It doesn't require pull-up
It is an 8-bit port (pin 1 through 8) and can be used either as input or output. It doesn't require pull-up
resistors because they are already connected internally. Upon reset, Port 1 is configured as an input port.
resistors because they are already connected internally. Upon reset, Port 1 is configured as an input port.
The following code can be used to send alternating values of 55H and AAH to Port 1.
The following code can be used to send alternating values of 55H and AAH to Port 1.
;Toggle all bits of continuously
;Toggle all bits of continuously
MOV A,#55
MOV A,#55
BACK:
BACK:
MOV P2,A
MOV P2,A
ACALL DELAY
ACALL DELAY
CPL A ;complement(invert) reg. A
CPL A ;complement(invert) reg. A
SJMP BACK
SJMP BACK
If Port 1 is configured to be used as an output port, then to use it as an input port again, program it by
If Port 1 is configured to be used as an output port, then to use it as an input port again, program it by
writing 1 to all of its bits as in the following code.
writing 1 to all of its bits as in the following code.
;Toggle all bits of continuously
;Toggle all bits of continuously
MOV A ,#0FFH ;A = FF hex
MOV A ,#0FFH ;A = FF hex
MOV P1,A ;Make P1 an input port
MOV P1,A ;Make P1 an input port
MOV A,P1 ;get data from P1
MOV A,P1 ;get data from P1
MOV R7,A ;save it in Reg R7
MOV R7,A ;save it in Reg R7
ACALL DELAY ;wait
ACALL DELAY ;wait
MOV A,P1 ;get another data from P1
MOV A,P1 ;get another data from P1
MOV R6,A ;save it in R6
MOV R6,A ;save it in R6
ACALL DELAY ;wait
ACALL DELAY ;wait
MOV A,P1 ;get another data from P1
MOV A,P1 ;get another data from P1
MOV R5,A ;save it in R5
MOV R5,A ;save it in R5
Port 2 (Pins 21 through 28)
Port 2 (Pins 21 through 28)
Port 2 occupies a total of 8 pins (pins 21 through 28) and can be used for both input and output
Port 2 occupies a total of 8 pins (pins 21 through 28) and can be used for both input and output
operations. Just as P1 (Port 1), P2 also doesn't require external Pull-up resistors because they are
operations. Just as P1 (Port 1), P2 also doesn't require external Pull-up resistors because they are
already connected internally. It must be used along with P0 to provide the 16-bit address for the external
already connected internally. It must be used along with P0 to provide the 16-bit address for the external
memory. So it is also designated as (A0–A7), as shown in the pin diagram. When the 8051 is connected
memory. So it is also designated as (A0–A7), as shown in the pin diagram. When the 8051 is connected
to an external memory, it provides path for upper 8-bits of 16-bits address, and it cannot be used as I/O.
to an external memory, it provides path for upper 8-bits of 16-bits address, and it cannot be used as I/O.
Upon reset, Port 2 is configured as an input port. The following code can be used to send alternating
Upon reset, Port 2 is configured as an input port. The following code can be used to send alternating
values of 55H and AAH to port 2.
values of 55H and AAH to port 2.
;Toggle all bits of continuously
;Toggle all bits of continuously
MOV A,#55
MOV A,#55
BACK:
BACK:
MOV P2,A
MOV P2,A
ACALL DELAY
ACALL DELAY
CPL A ; complement(invert) reg. A
CPL A ; complement(invert) reg. A
SJMP BACK
SJMP BACK
If Port 2 is configured to be used as an output port, then to use it as an input port again, program it by
If Port 2 is configured to be used as an output port, then to use it as an input port again, program it by
writing 1 to all of its bits as in the following code.
writing 1 to all of its bits as in the following code.
;Get a byte from P2 and send it to P1
;Get a byte from P2 and send it to P1
MOV A,#0FFH ;A = FF hex
MOV A,#0FFH ;A = FF hex
MOV P2,A ;make P2 an input port
MOV P2,A ;make P2 an input port
BACK:
BACK:
MOV A,P2 ;get data from P2
MOV A,P2 ;get data from P2
MOV P1,A ;send it to Port 1
MOV P1,A ;send it to Port 1
SJMP BACK ;keep doing that
SJMP BACK ;keep doing that
Port 3 (Pins 10 through 17)
Port 3 (Pins 10 through 17)
It is also of 8 bits and can be used as Input/Output. This port provides some extremely important signals.
It is also of 8 bits and can be used as Input/Output. This port provides some extremely important signals.
P3.0 and P3.1 are RxD (Receiver) and TxD (Transmitter) respectively and are collectively used for Serial
P3.0 and P3.1 are RxD (Receiver) and TxD (Transmitter) respectively and are collectively used for Serial
Communication. P3.2 and P3.3 pins are used for external interrupts. P3.4 and P3.5 are used for timers T0
Communication. P3.2 and P3.3 pins are used for external interrupts. P3.4 and P3.5 are used for timers T0
and T1 respectively. P3.6 and P3.7 are Write (WR) and Read (RD) pins. These are active low pins, means
and T1 respectively. P3.6 and P3.7 are Write (WR) and Read (RD) pins. These are active low pins, means
they will be active when 0 is given to them and these are used to provide Read and Write operations to
they will be active when 0 is given to them and these are used to provide Read and Write operations to
External ROM in 8031 based systems.
External ROM in 8031 based systems.
P3 Bit
P3 Bit Function
Function Pin
Pin
P3.0
P3.0 RxD
RxD 10
10
P3.1 <
P3.1 < TxD
TxD 11
11
P3.2 <
P3.2 < Complement of INT0
Complement of INT0 12
12
P3.3 <
P3.3 < INT1
INT1 13
13
P3.4 <
P3.4 < T0
T0 14
14
P3.5 <
P3.5 < T1
T1 15
15
P3.6 <
P3.6 < WR
WR 16
16
P3.7 <
P3.7 < Complement of RD
Complement of RD 17
17
Dual Role of Port 0 and Port 2
Dual Role of Port 0 and Port 2
Dual role of Port 0
Dual role of Port 0 − Port 0 is also designated as AD0–AD7, as it can be used for both data and
− Port 0 is also designated as AD0–AD7, as it can be used for both data and
address handling. While connecting an 8051 to external memory, Port 0 can provide both
address handling. While connecting an 8051 to external memory, Port 0 can provide both
address and data. The 8051 microcontroller then multiplexes the input as address or data in
address and data. The 8051 microcontroller then multiplexes the input as address or data in
order to save pins.
order to save pins.
Dual role of Port 2
Dual role of Port 2 − Besides working as I/O, Port P2 is also used to provide 16-bit address bus
− Besides working as I/O, Port P2 is also used to provide 16-bit address bus
for external memory along with Port 0. Port P2 is also designated as (A8– A15), while Port 0
for external memory along with Port 0. Port P2 is also designated as (A8– A15), while Port 0
provides the lower 8-bits via A0–A7. In other words, we can say that when an 8051 is connected
provides the lower 8-bits via A0–A7. In other words, we can say that when an 8051 is connected
to an external memory (ROM) which can be maximum up to 64KB and this is possible by 16 bit
to an external memory (ROM) which can be maximum up to 64KB and this is possible by 16 bit
address bus because we know 216 = 64KB. Port2 is used for the upper 8-bit of the 16 bits
address bus because we know 216 = 64KB. Port2 is used for the upper 8-bit of the 16 bits
address, and it cannot be used for I/O and this is the way any Program code of external ROM is
address, and it cannot be used for I/O and this is the way any Program code of external ROM is
addressed.
addressed.
Hardware Connection of Pins
Hardware Connection of Pins
V
V − Pin 40 provides supply to the Chip and it is +5 V.
− Pin 40 provides supply to the Chip and it is +5 V.
Gnd
Gnd − Pin 20 provides ground for the Reference.
− Pin 20 provides ground for the Reference.
XTAL1, XTAL2 (Pin no 18 & Pin no 19)
XTAL1, XTAL2 (Pin no 18 & Pin no 19) − 8051 has on-chip oscillator but requires external clock
− 8051 has on-chip oscillator but requires external clock
to run it. A quartz crystal is connected between the XTAL1 & XTAL2 pin of the chip. This crystal
to run it. A quartz crystal is connected between the XTAL1 & XTAL2 pin of the chip. This crystal
also needs two capacitors of 30pF for generating a signal of desired frequency. One side of each
also needs two capacitors of 30pF for generating a signal of desired frequency. One side of each
capacitor is connected to ground. 8051 IC is available in various speeds and it all depends on
capacitor is connected to ground. 8051 IC is available in various speeds and it all depends on
cc
cc
this Quartz crystal, for example, a 20 MHz microcontroller requires a crystal with a frequency no
this Quartz crystal, for example, a 20 MHz microcontroller requires a crystal with a frequency no
more than 20 MHz.
more than 20 MHz.
RST (Pin No. 9)
RST (Pin No. 9) − It is an Input pin and active High pin. Upon applying a high pulse on this pin,
− It is an Input pin and active High pin. Upon applying a high pulse on this pin,
that is 1, the microcontroller will reset and terminate all activities. This process is known as
that is 1, the microcontroller will reset and terminate all activities. This process is known as
Power-On Reset
Power-On Reset. Activating a power-on reset will cause all values in the register to be lost. It will
. Activating a power-on reset will cause all values in the register to be lost. It will
set a program counter to all 0's. To ensure a valid input of Reset, the high pulse must be high for
set a program counter to all 0's. To ensure a valid input of Reset, the high pulse must be high for
a minimum of two machine cycles before it is allowed to go low, which depends on the capacitor
a minimum of two machine cycles before it is allowed to go low, which depends on the capacitor
value and the rate at which it charges. (
value and the rate at which it charges. (Machine Cycle
Machine Cycle is the minimum amount of frequency a
is the minimum amount of frequency a
single instruction requires in execution).
single instruction requires in execution).
EA or External Access (Pin No. 31)
EA or External Access (Pin No. 31) − It is an input pin. This pin is an active low pin; upon
− It is an input pin. This pin is an active low pin; upon
applying a low pulse, it gets activated. In case of microcontroller (8051/52) having on-chip ROM,
applying a low pulse, it gets activated. In case of microcontroller (8051/52) having on-chip ROM,
the EA (bar) pin is connected to V
the EA (bar) pin is connected to V . But in an 8031 microcontroller which does not have an on-
. But in an 8031 microcontroller which does not have an on-
chip ROM, the code is stored in an external ROM and then fetched by the microcontroller. In this
chip ROM, the code is stored in an external ROM and then fetched by the microcontroller. In this
case, we must connect the (pin no 31) EA to Gnd to indicate that the program code is stored
case, we must connect the (pin no 31) EA to Gnd to indicate that the program code is stored
externally.
externally.
cc
cc
PSEN or Program store Enable (Pin No 29)
PSEN or Program store Enable (Pin No 29) − This is also an active low pin, i.e., it gets
− This is also an active low pin, i.e., it gets
activated after applying a low pulse. It is an output pin and used along with the EA pin in 8031
activated after applying a low pulse. It is an output pin and used along with the EA pin in 8031
based (i.e. ROMLESS) Systems to allow storage of program code in external ROM.
based (i.e. ROMLESS) Systems to allow storage of program code in external ROM.
ALE or (Address Latch Enable)
ALE or (Address Latch Enable) − This is an Output Pin and is active high. It is especially used
− This is an Output Pin and is active high. It is especially used
for 8031 IC to connect it to the external memory. It can be used while deciding whether P0 pins
for 8031 IC to connect it to the external memory. It can be used while deciding whether P0 pins
will be used as Address bus or Data bus. When ALE = 1, then the P0 pins work as Data bus and
will be used as Address bus or Data bus. When ALE = 1, then the P0 pins work as Data bus and
when ALE = 0, then the P0 pins act as Address bus.
when ALE = 0, then the P0 pins act as Address bus.
I/O Ports and Bit Addressability
I/O Ports and Bit Addressability
It is a most widely used feature of 8051 while writing code for 8051. Sometimes we need to access only 1
It is a most widely used feature of 8051 while writing code for 8051. Sometimes we need to access only 1
or 2 bits of the port instead of the entire 8-bits. 8051 provides the capability to access individual bits of the
or 2 bits of the port instead of the entire 8-bits. 8051 provides the capability to access individual bits of the
ports.
ports.
While accessing a port in a single-bit manner, we use the syntax "SETB X. Y" where X is the port number
While accessing a port in a single-bit manner, we use the syntax "SETB X. Y" where X is the port number
(0 to 3), and Y is a bit number (0 to 7) for data bits D0-D7 where D0 is the LSB and D7 is the MSB. For
(0 to 3), and Y is a bit number (0 to 7) for data bits D0-D7 where D0 is the LSB and D7 is the MSB. For
example, "SETB P1.5" sets high bit 5 of port 1.
example, "SETB P1.5" sets high bit 5 of port 1.
The following code shows how we can toggle the bit P1.2 continuously.
The following code shows how we can toggle the bit P1.2 continuously.
AGAIN:
AGAIN:
SETB P1.2
SETB P1.2
ACALL DELAY
ACALL DELAY
CLR P1.2
CLR P1.2
ACALL DELAY
ACALL DELAY
SJMP AGAIN
SJMP AGAIN
Single-Bit Instructions
Single-Bit Instructions
Instructions
Instructions Function
Function
SETB bit
SETB bit Set the bit (bit = 1)
Set the bit (bit = 1)
CLR bit
CLR bit clear the bit (bit = 0)
clear the bit (bit = 0)
CPL bit
CPL bit complement the bit (bit = NOT bit)
complement the bit (bit = NOT bit)
JB bit, target
JB bit, target jump to target if bit = 1 (jump if bit)
jump to target if bit = 1 (jump if bit)
JNB bit, target
JNB bit, target jump to target if bit = 0 (jump if no bit)
jump to target if bit = 0 (jump if no bit)
JBC bit, target
JBC bit, target jump to target if bit = 1, clear bit (jump if bit, then clear)
jump to target if bit = 1, clear bit (jump if bit, then clear)
Ad

More Related Content

What's hot (20)

Microcontroller 8051 basics (part I)
Microcontroller 8051 basics (part I)Microcontroller 8051 basics (part I)
Microcontroller 8051 basics (part I)
Nilesh Bhaskarrao Bahadure
 
AT89C52 Data sheet
AT89C52 Data sheetAT89C52 Data sheet
AT89C52 Data sheet
Microtech Solutions
 
Ei502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Ei502microprocessorsmicrtocontrollerspart4 8051 MicrocontrollerEi502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Ei502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Debasis Das
 
8051 Microcontroller I/O ports
8051 Microcontroller I/O ports8051 Microcontroller I/O ports
8051 Microcontroller I/O ports
anishgoel
 
1347 Assembly Language Programming Of 8051
1347 Assembly Language Programming Of 80511347 Assembly Language Programming Of 8051
1347 Assembly Language Programming Of 8051
techbed
 
Embedded Systems Project Based Training|Engineering Projects,Summer Training
Embedded Systems Project Based Training|Engineering Projects,Summer TrainingEmbedded Systems Project Based Training|Engineering Projects,Summer Training
Embedded Systems Project Based Training|Engineering Projects,Summer Training
Technogroovy
 
The 8051 microcontroller
The 8051  microcontroller The 8051  microcontroller
The 8051 microcontroller
Avinash Mishra
 
8051 basic programming
8051 basic programming8051 basic programming
8051 basic programming
ANJUSHA R
 
8051 book
8051 book8051 book
8051 book
Jei MAthaajee College of Engineering,ANNA UNIVERSITY
 
Microcontroller 8051 training
Microcontroller 8051 trainingMicrocontroller 8051 training
Microcontroller 8051 training
Pradip Bhandari
 
Intro2 Robotic With Pic18
Intro2 Robotic With Pic18Intro2 Robotic With Pic18
Intro2 Robotic With Pic18
Moayadhn
 
8051 full ppt
8051 full ppt8051 full ppt
8051 full ppt
noor mohamed s Snoormohamedcbe
 
8051 assembly programming
8051 assembly programming8051 assembly programming
8051 assembly programming
sergeiseq
 
Introduction to pic
Introduction to picIntroduction to pic
Introduction to pic
PRADEEP
 
Emb day2 8051
Emb day2 8051Emb day2 8051
Emb day2 8051
shivamarya55
 
8051 microcontroller
8051 microcontroller8051 microcontroller
8051 microcontroller
Jhemi22
 
Microcontroller 8051 By Mitesh kumar
Microcontroller 8051 By Mitesh kumarMicrocontroller 8051 By Mitesh kumar
Microcontroller 8051 By Mitesh kumar
Mitesh Kumar
 
8051 Microcontroller
8051 Microcontroller8051 Microcontroller
8051 Microcontroller
Dr. Ritula Thakur
 
Chp2 introduction to the 68000 microprocessor copy
Chp2 introduction to the 68000 microprocessor   copyChp2 introduction to the 68000 microprocessor   copy
Chp2 introduction to the 68000 microprocessor copy
mkazree
 
I o ports and timers of 8051
I o ports and timers of 8051I o ports and timers of 8051
I o ports and timers of 8051
SARITHA REDDY
 
Ei502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Ei502microprocessorsmicrtocontrollerspart4 8051 MicrocontrollerEi502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Ei502microprocessorsmicrtocontrollerspart4 8051 Microcontroller
Debasis Das
 
8051 Microcontroller I/O ports
8051 Microcontroller I/O ports8051 Microcontroller I/O ports
8051 Microcontroller I/O ports
anishgoel
 
1347 Assembly Language Programming Of 8051
1347 Assembly Language Programming Of 80511347 Assembly Language Programming Of 8051
1347 Assembly Language Programming Of 8051
techbed
 
Embedded Systems Project Based Training|Engineering Projects,Summer Training
Embedded Systems Project Based Training|Engineering Projects,Summer TrainingEmbedded Systems Project Based Training|Engineering Projects,Summer Training
Embedded Systems Project Based Training|Engineering Projects,Summer Training
Technogroovy
 
The 8051 microcontroller
The 8051  microcontroller The 8051  microcontroller
The 8051 microcontroller
Avinash Mishra
 
8051 basic programming
8051 basic programming8051 basic programming
8051 basic programming
ANJUSHA R
 
Microcontroller 8051 training
Microcontroller 8051 trainingMicrocontroller 8051 training
Microcontroller 8051 training
Pradip Bhandari
 
Intro2 Robotic With Pic18
Intro2 Robotic With Pic18Intro2 Robotic With Pic18
Intro2 Robotic With Pic18
Moayadhn
 
8051 assembly programming
8051 assembly programming8051 assembly programming
8051 assembly programming
sergeiseq
 
Introduction to pic
Introduction to picIntroduction to pic
Introduction to pic
PRADEEP
 
8051 microcontroller
8051 microcontroller8051 microcontroller
8051 microcontroller
Jhemi22
 
Microcontroller 8051 By Mitesh kumar
Microcontroller 8051 By Mitesh kumarMicrocontroller 8051 By Mitesh kumar
Microcontroller 8051 By Mitesh kumar
Mitesh Kumar
 
Chp2 introduction to the 68000 microprocessor copy
Chp2 introduction to the 68000 microprocessor   copyChp2 introduction to the 68000 microprocessor   copy
Chp2 introduction to the 68000 microprocessor copy
mkazree
 
I o ports and timers of 8051
I o ports and timers of 8051I o ports and timers of 8051
I o ports and timers of 8051
SARITHA REDDY
 

Similar to Embedded systems io programming (20)

MICROCONTROLLER .pptx
MICROCONTROLLER .pptxMICROCONTROLLER .pptx
MICROCONTROLLER .pptx
ArulMozhie1
 
Port Organization of 8051 .pdf
Port Organization of 8051 .pdfPort Organization of 8051 .pdf
Port Organization of 8051 .pdf
Srikrishna Thota
 
SE PAI Unit 5_IO programming in 8051
SE PAI Unit 5_IO programming in 8051SE PAI Unit 5_IO programming in 8051
SE PAI Unit 5_IO programming in 8051
KanchanPatil34
 
I/O port programming in 8051
I/O port programming in 8051I/O port programming in 8051
I/O port programming in 8051
ssuser3a47cb
 
8051 Microcontroller architecture and operation
8051 Microcontroller architecture and operation8051 Microcontroller architecture and operation
8051 Microcontroller architecture and operation
PuneetChawla25
 
Class7
Class7Class7
Class7
Sai Santosh Praveen
 
8051-Special Purpose Registers and Memory Interface.pptx
8051-Special Purpose Registers and Memory Interface.pptx8051-Special Purpose Registers and Memory Interface.pptx
8051-Special Purpose Registers and Memory Interface.pptx
Raja313746
 
Microcontroller Basics and Architecture of 8051
Microcontroller Basics and Architecture of 8051Microcontroller Basics and Architecture of 8051
Microcontroller Basics and Architecture of 8051
JayDeep769201
 
Microprocessor Techniques and Computer Organisation
Microprocessor Techniques and Computer OrganisationMicroprocessor Techniques and Computer Organisation
Microprocessor Techniques and Computer Organisation
JayDeep769201
 
Basics and Working of 8051 Microprocontroller
Basics and Working of 8051 MicroprocontrollerBasics and Working of 8051 Microprocontroller
Basics and Working of 8051 Microprocontroller
JayDeep769201
 
Working and Internals of 8051 Microcontroller
Working and Internals of 8051 MicrocontrollerWorking and Internals of 8051 Microcontroller
Working and Internals of 8051 Microcontroller
JayDeep769201
 
Introduction to 8051 Microcontroller and its Architecture
Introduction to 8051 Microcontroller and its ArchitectureIntroduction to 8051 Microcontroller and its Architecture
Introduction to 8051 Microcontroller and its Architecture
JayDeep769201
 
Hardware Structures, Addressing Modes, Interrupt Control : 8051
Hardware Structures, Addressing Modes, Interrupt Control : 8051Hardware Structures, Addressing Modes, Interrupt Control : 8051
Hardware Structures, Addressing Modes, Interrupt Control : 8051
JayDeep769201
 
Instruction Set Architecture and Design of Hardware
Instruction Set Architecture and Design of HardwareInstruction Set Architecture and Design of Hardware
Instruction Set Architecture and Design of Hardware
iatt4vn
 
Pin Description of the 8051 along with I/O Interfacing
Pin Description of the 8051 along with I/O InterfacingPin Description of the 8051 along with I/O Interfacing
Pin Description of the 8051 along with I/O Interfacing
iatt4vn
 
Introduction Architecture Addressing Modes
Introduction Architecture Addressing ModesIntroduction Architecture Addressing Modes
Introduction Architecture Addressing Modes
iatt4vn
 
microcontroller intel 8051 pin description
microcontroller intel 8051 pin descriptionmicrocontroller intel 8051 pin description
microcontroller intel 8051 pin description
iatt4vn
 
8051 Hardware Architecture, Addressing Modes, Interfacing
8051 Hardware Architecture, Addressing Modes, Interfacing8051 Hardware Architecture, Addressing Modes, Interfacing
8051 Hardware Architecture, Addressing Modes, Interfacing
iatt4vn
 
8051 Microcontroller -1.pptx
8051 Microcontroller -1.pptx8051 Microcontroller -1.pptx
8051 Microcontroller -1.pptx
veeramaniks
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
Rashmi
 
MICROCONTROLLER .pptx
MICROCONTROLLER .pptxMICROCONTROLLER .pptx
MICROCONTROLLER .pptx
ArulMozhie1
 
Port Organization of 8051 .pdf
Port Organization of 8051 .pdfPort Organization of 8051 .pdf
Port Organization of 8051 .pdf
Srikrishna Thota
 
SE PAI Unit 5_IO programming in 8051
SE PAI Unit 5_IO programming in 8051SE PAI Unit 5_IO programming in 8051
SE PAI Unit 5_IO programming in 8051
KanchanPatil34
 
I/O port programming in 8051
I/O port programming in 8051I/O port programming in 8051
I/O port programming in 8051
ssuser3a47cb
 
8051 Microcontroller architecture and operation
8051 Microcontroller architecture and operation8051 Microcontroller architecture and operation
8051 Microcontroller architecture and operation
PuneetChawla25
 
8051-Special Purpose Registers and Memory Interface.pptx
8051-Special Purpose Registers and Memory Interface.pptx8051-Special Purpose Registers and Memory Interface.pptx
8051-Special Purpose Registers and Memory Interface.pptx
Raja313746
 
Microcontroller Basics and Architecture of 8051
Microcontroller Basics and Architecture of 8051Microcontroller Basics and Architecture of 8051
Microcontroller Basics and Architecture of 8051
JayDeep769201
 
Microprocessor Techniques and Computer Organisation
Microprocessor Techniques and Computer OrganisationMicroprocessor Techniques and Computer Organisation
Microprocessor Techniques and Computer Organisation
JayDeep769201
 
Basics and Working of 8051 Microprocontroller
Basics and Working of 8051 MicroprocontrollerBasics and Working of 8051 Microprocontroller
Basics and Working of 8051 Microprocontroller
JayDeep769201
 
Working and Internals of 8051 Microcontroller
Working and Internals of 8051 MicrocontrollerWorking and Internals of 8051 Microcontroller
Working and Internals of 8051 Microcontroller
JayDeep769201
 
Introduction to 8051 Microcontroller and its Architecture
Introduction to 8051 Microcontroller and its ArchitectureIntroduction to 8051 Microcontroller and its Architecture
Introduction to 8051 Microcontroller and its Architecture
JayDeep769201
 
Hardware Structures, Addressing Modes, Interrupt Control : 8051
Hardware Structures, Addressing Modes, Interrupt Control : 8051Hardware Structures, Addressing Modes, Interrupt Control : 8051
Hardware Structures, Addressing Modes, Interrupt Control : 8051
JayDeep769201
 
Instruction Set Architecture and Design of Hardware
Instruction Set Architecture and Design of HardwareInstruction Set Architecture and Design of Hardware
Instruction Set Architecture and Design of Hardware
iatt4vn
 
Pin Description of the 8051 along with I/O Interfacing
Pin Description of the 8051 along with I/O InterfacingPin Description of the 8051 along with I/O Interfacing
Pin Description of the 8051 along with I/O Interfacing
iatt4vn
 
Introduction Architecture Addressing Modes
Introduction Architecture Addressing ModesIntroduction Architecture Addressing Modes
Introduction Architecture Addressing Modes
iatt4vn
 
microcontroller intel 8051 pin description
microcontroller intel 8051 pin descriptionmicrocontroller intel 8051 pin description
microcontroller intel 8051 pin description
iatt4vn
 
8051 Hardware Architecture, Addressing Modes, Interfacing
8051 Hardware Architecture, Addressing Modes, Interfacing8051 Hardware Architecture, Addressing Modes, Interfacing
8051 Hardware Architecture, Addressing Modes, Interfacing
iatt4vn
 
8051 Microcontroller -1.pptx
8051 Microcontroller -1.pptx8051 Microcontroller -1.pptx
8051 Microcontroller -1.pptx
veeramaniks
 
Microcontroller 8051
Microcontroller 8051Microcontroller 8051
Microcontroller 8051
Rashmi
 
Ad

More from imtiazalijoono (20)

Embedded systems tools & peripherals
Embedded systems   tools & peripheralsEmbedded systems   tools & peripherals
Embedded systems tools & peripherals
imtiazalijoono
 
Importance of reading and its types.
Importance of reading and its types.Importance of reading and its types.
Importance of reading and its types.
imtiazalijoono
 
Negative amplifiers and its types Positive feedback and Negative feedback
Negative amplifiers and its types Positive feedback  and Negative feedbackNegative amplifiers and its types Positive feedback  and Negative feedback
Negative amplifiers and its types Positive feedback and Negative feedback
imtiazalijoono
 
Multistage amplifiers and Name of coupling Name of multistage amplifier
Multistage amplifiers and Name of coupling Name of multistage amplifierMultistage amplifiers and Name of coupling Name of multistage amplifier
Multistage amplifiers and Name of coupling Name of multistage amplifier
imtiazalijoono
 
Loop Introduction for Loop while Loop do while Loop Nested Loops Values of...
Loop Introduction for Loop  while Loop do while Loop  Nested Loops  Values of...Loop Introduction for Loop  while Loop do while Loop  Nested Loops  Values of...
Loop Introduction for Loop while Loop do while Loop Nested Loops Values of...
imtiazalijoono
 
Programming Fundamentals and basic knowledge
Programming Fundamentals and basic knowledge Programming Fundamentals and basic knowledge
Programming Fundamentals and basic knowledge
imtiazalijoono
 
Programming Fundamentals Functions in C and types
Programming Fundamentals  Functions in C  and typesProgramming Fundamentals  Functions in C  and types
Programming Fundamentals Functions in C and types
imtiazalijoono
 
Software Development Software development process
Software Development Software development processSoftware Development Software development process
Software Development Software development process
imtiazalijoono
 
Programming Fundamentals Decisions
Programming Fundamentals  Decisions Programming Fundamentals  Decisions
Programming Fundamentals Decisions
imtiazalijoono
 
C Building Blocks
C Building Blocks C Building Blocks
C Building Blocks
imtiazalijoono
 
Programming Fundamentals Arrays and Strings
Programming Fundamentals   Arrays and Strings Programming Fundamentals   Arrays and Strings
Programming Fundamentals Arrays and Strings
imtiazalijoono
 
Programming Fundamentals and Programming Languages Concepts Translators
Programming Fundamentals and Programming Languages Concepts TranslatorsProgramming Fundamentals and Programming Languages Concepts Translators
Programming Fundamentals and Programming Languages Concepts Translators
imtiazalijoono
 
Programming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages ConceptsProgramming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages Concepts
imtiazalijoono
 
Programming Global variable
Programming Global variableProgramming Global variable
Programming Global variable
imtiazalijoono
 
Array Introduction One-dimensional array Multidimensional array
Array Introduction One-dimensional array Multidimensional arrayArray Introduction One-dimensional array Multidimensional array
Array Introduction One-dimensional array Multidimensional array
imtiazalijoono
 
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
imtiazalijoono
 
Arithmetic and Arithmetic assignment operators
Arithmetic and Arithmetic assignment operatorsArithmetic and Arithmetic assignment operators
Arithmetic and Arithmetic assignment operators
imtiazalijoono
 
INTRODUCTION TO COMPUTER PROGRAMMING
INTRODUCTION TO COMPUTER PROGRAMMINGINTRODUCTION TO COMPUTER PROGRAMMING
INTRODUCTION TO COMPUTER PROGRAMMING
imtiazalijoono
 
COMPUTER PROGRAMMING
COMPUTER PROGRAMMINGCOMPUTER PROGRAMMING
COMPUTER PROGRAMMING
imtiazalijoono
 
COMPUTER PROGRAMMING
COMPUTER PROGRAMMINGCOMPUTER PROGRAMMING
COMPUTER PROGRAMMING
imtiazalijoono
 
Embedded systems tools & peripherals
Embedded systems   tools & peripheralsEmbedded systems   tools & peripherals
Embedded systems tools & peripherals
imtiazalijoono
 
Importance of reading and its types.
Importance of reading and its types.Importance of reading and its types.
Importance of reading and its types.
imtiazalijoono
 
Negative amplifiers and its types Positive feedback and Negative feedback
Negative amplifiers and its types Positive feedback  and Negative feedbackNegative amplifiers and its types Positive feedback  and Negative feedback
Negative amplifiers and its types Positive feedback and Negative feedback
imtiazalijoono
 
Multistage amplifiers and Name of coupling Name of multistage amplifier
Multistage amplifiers and Name of coupling Name of multistage amplifierMultistage amplifiers and Name of coupling Name of multistage amplifier
Multistage amplifiers and Name of coupling Name of multistage amplifier
imtiazalijoono
 
Loop Introduction for Loop while Loop do while Loop Nested Loops Values of...
Loop Introduction for Loop  while Loop do while Loop  Nested Loops  Values of...Loop Introduction for Loop  while Loop do while Loop  Nested Loops  Values of...
Loop Introduction for Loop while Loop do while Loop Nested Loops Values of...
imtiazalijoono
 
Programming Fundamentals and basic knowledge
Programming Fundamentals and basic knowledge Programming Fundamentals and basic knowledge
Programming Fundamentals and basic knowledge
imtiazalijoono
 
Programming Fundamentals Functions in C and types
Programming Fundamentals  Functions in C  and typesProgramming Fundamentals  Functions in C  and types
Programming Fundamentals Functions in C and types
imtiazalijoono
 
Software Development Software development process
Software Development Software development processSoftware Development Software development process
Software Development Software development process
imtiazalijoono
 
Programming Fundamentals Decisions
Programming Fundamentals  Decisions Programming Fundamentals  Decisions
Programming Fundamentals Decisions
imtiazalijoono
 
Programming Fundamentals Arrays and Strings
Programming Fundamentals   Arrays and Strings Programming Fundamentals   Arrays and Strings
Programming Fundamentals Arrays and Strings
imtiazalijoono
 
Programming Fundamentals and Programming Languages Concepts Translators
Programming Fundamentals and Programming Languages Concepts TranslatorsProgramming Fundamentals and Programming Languages Concepts Translators
Programming Fundamentals and Programming Languages Concepts Translators
imtiazalijoono
 
Programming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages ConceptsProgramming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages Concepts
imtiazalijoono
 
Programming Global variable
Programming Global variableProgramming Global variable
Programming Global variable
imtiazalijoono
 
Array Introduction One-dimensional array Multidimensional array
Array Introduction One-dimensional array Multidimensional arrayArray Introduction One-dimensional array Multidimensional array
Array Introduction One-dimensional array Multidimensional array
imtiazalijoono
 
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
NTRODUCTION TO COMPUTER PROGRAMMING Loop as repetitive statement,
imtiazalijoono
 
Arithmetic and Arithmetic assignment operators
Arithmetic and Arithmetic assignment operatorsArithmetic and Arithmetic assignment operators
Arithmetic and Arithmetic assignment operators
imtiazalijoono
 
INTRODUCTION TO COMPUTER PROGRAMMING
INTRODUCTION TO COMPUTER PROGRAMMINGINTRODUCTION TO COMPUTER PROGRAMMING
INTRODUCTION TO COMPUTER PROGRAMMING
imtiazalijoono
 
Ad

Recently uploaded (20)

Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............
19lburrell
 
Search Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo SlidesSearch Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo Slides
Celine George
 
How to Configure Extra Steps During Checkout in Odoo 18 Website
How to Configure Extra Steps During Checkout in Odoo 18 WebsiteHow to Configure Extra Steps During Checkout in Odoo 18 Website
How to Configure Extra Steps During Checkout in Odoo 18 Website
Celine George
 
YSPH VMOC Special Report - Measles Outbreak Southwest US 5-17-2025 .pptx
YSPH VMOC Special Report - Measles Outbreak  Southwest US 5-17-2025  .pptxYSPH VMOC Special Report - Measles Outbreak  Southwest US 5-17-2025  .pptx
YSPH VMOC Special Report - Measles Outbreak Southwest US 5-17-2025 .pptx
Yale School of Public Health - The Virtual Medical Operations Center (VMOC)
 
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
EduSkills OECD
 
How to Use Upgrade Code Command in Odoo 18
How to Use Upgrade Code Command in Odoo 18How to Use Upgrade Code Command in Odoo 18
How to Use Upgrade Code Command in Odoo 18
Celine George
 
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFAMCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
Dr. Nasir Mustafa
 
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
businessweekghana
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
LDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDMMIA 2024 Crystal Gold Lecture 1 BonusLDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDM & Mia eStudios
 
ITI COPA Question Paper PDF 2017 Theory MCQ
ITI COPA Question Paper PDF 2017 Theory MCQITI COPA Question Paper PDF 2017 Theory MCQ
ITI COPA Question Paper PDF 2017 Theory MCQ
SONU HEETSON
 
materi 3D Augmented Reality dengan assemblr
materi 3D Augmented Reality dengan assemblrmateri 3D Augmented Reality dengan assemblr
materi 3D Augmented Reality dengan assemblr
fatikhatunnajikhah1
 
How to Change Sequence Number in Odoo 18 Sale Order
How to Change Sequence Number in Odoo 18 Sale OrderHow to Change Sequence Number in Odoo 18 Sale Order
How to Change Sequence Number in Odoo 18 Sale Order
Celine George
 
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
lsitinova
 
A report on the county distress rankings in NC
A report on the county distress rankings in NCA report on the county distress rankings in NC
A report on the county distress rankings in NC
Mebane Rash
 
Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...
parmarjuli1412
 
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docxPeer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
19lburrell
 
How to Manage Manual Reordering Rule in Odoo 18 Inventory
How to Manage Manual Reordering Rule in Odoo 18 InventoryHow to Manage Manual Reordering Rule in Odoo 18 Inventory
How to Manage Manual Reordering Rule in Odoo 18 Inventory
Celine George
 
Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............
19lburrell
 
Search Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo SlidesSearch Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo Slides
Celine George
 
How to Configure Extra Steps During Checkout in Odoo 18 Website
How to Configure Extra Steps During Checkout in Odoo 18 WebsiteHow to Configure Extra Steps During Checkout in Odoo 18 Website
How to Configure Extra Steps During Checkout in Odoo 18 Website
Celine George
 
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
Launch of The State of Global Teenage Career Preparation - Andreas Schleicher...
EduSkills OECD
 
How to Use Upgrade Code Command in Odoo 18
How to Use Upgrade Code Command in Odoo 18How to Use Upgrade Code Command in Odoo 18
How to Use Upgrade Code Command in Odoo 18
Celine George
 
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFAMCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
MCQS (EMERGENCY NURSING) DR. NASIR MUSTAFA
Dr. Nasir Mustafa
 
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
UPSA JUDGEMENT.pdfCopyright Infringement: High Court Rules against UPSA: A Wa...
businessweekghana
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
LDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDMMIA 2024 Crystal Gold Lecture 1 BonusLDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDMMIA 2024 Crystal Gold Lecture 1 Bonus
LDM & Mia eStudios
 
ITI COPA Question Paper PDF 2017 Theory MCQ
ITI COPA Question Paper PDF 2017 Theory MCQITI COPA Question Paper PDF 2017 Theory MCQ
ITI COPA Question Paper PDF 2017 Theory MCQ
SONU HEETSON
 
materi 3D Augmented Reality dengan assemblr
materi 3D Augmented Reality dengan assemblrmateri 3D Augmented Reality dengan assemblr
materi 3D Augmented Reality dengan assemblr
fatikhatunnajikhah1
 
How to Change Sequence Number in Odoo 18 Sale Order
How to Change Sequence Number in Odoo 18 Sale OrderHow to Change Sequence Number in Odoo 18 Sale Order
How to Change Sequence Number in Odoo 18 Sale Order
Celine George
 
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
UNITED_KINGDOM.pptUNITED_KINGDOM.pptUNITED_KINGDOM.ppt
lsitinova
 
A report on the county distress rankings in NC
A report on the county distress rankings in NCA report on the county distress rankings in NC
A report on the county distress rankings in NC
Mebane Rash
 
Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...
parmarjuli1412
 
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docxPeer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
Peer Assessment_ Unit 2 Skills Development for Live Performance - for Libby.docx
19lburrell
 
How to Manage Manual Reordering Rule in Odoo 18 Inventory
How to Manage Manual Reordering Rule in Odoo 18 InventoryHow to Manage Manual Reordering Rule in Odoo 18 Inventory
How to Manage Manual Reordering Rule in Odoo 18 Inventory
Celine George
 

Embedded systems io programming

  • 1. Embedded Systems - I/O Programming Embedded Systems - I/O Programming In 8051, I/O operations are done using four ports and 40 pins. The following pin diagram shows the details In 8051, I/O operations are done using four ports and 40 pins. The following pin diagram shows the details of the 40 pins. I/O operation port reserves 32 pins where each port has 8 pins. The other 8 pins are of the 40 pins. I/O operation port reserves 32 pins where each port has 8 pins. The other 8 pins are designated as V designated as V , GND, XTAL1, XTAL2, RST, EA (bar), ALE/PROG (bar), and PSEN (bar). , GND, XTAL1, XTAL2, RST, EA (bar), ALE/PROG (bar), and PSEN (bar). It is a 40 Pin PDIP (Plastic Dual Inline Package) It is a 40 Pin PDIP (Plastic Dual Inline Package) Note Note − In a DIP package, you can recognize the first pin and the last pin by the cut at the middle of the IC. − In a DIP package, you can recognize the first pin and the last pin by the cut at the middle of the IC. The first pin is on the left of this cut mark and the last pin (i.e. the 40 The first pin is on the left of this cut mark and the last pin (i.e. the 40 pin in this case) is to the right of the pin in this case) is to the right of the cut mark. cut mark. I/O Ports and their Functions I/O Ports and their Functions The four ports P0, P1, P2, and P3, each use 8 pins, making them 8-bit ports. Upon RESET, all the ports The four ports P0, P1, P2, and P3, each use 8 pins, making them 8-bit ports. Upon RESET, all the ports are configured as inputs, ready to be used as input ports. When the first 0 is written to a port, it becomes are configured as inputs, ready to be used as input ports. When the first 0 is written to a port, it becomes an output. To reconfigure it as an input, a 1 must be sent to a port. an output. To reconfigure it as an input, a 1 must be sent to a port. Port 0 (Pin No 32 – Pin No 39) Port 0 (Pin No 32 – Pin No 39) It has 8 pins (32 to 39). It can be used for input or output. Unlike P1, P2, and P3 ports, we normally It has 8 pins (32 to 39). It can be used for input or output. Unlike P1, P2, and P3 ports, we normally connect P0 to 10K-ohm pull-up resistors to use it as an input or output port being an open drain. connect P0 to 10K-ohm pull-up resistors to use it as an input or output port being an open drain. cc cc th th
  • 2. It is also designated as AD0-AD7, allowing it to be used as both address and data. In case of 8031 (i.e. It is also designated as AD0-AD7, allowing it to be used as both address and data. In case of 8031 (i.e. ROMless Chip), when we need to access the external ROM, then P0 will be used for both Address and ROMless Chip), when we need to access the external ROM, then P0 will be used for both Address and Data Bus. ALE (Pin no 31) indicates if P0 has address or data. When ALE = 0, it provides data D0-D7, but Data Bus. ALE (Pin no 31) indicates if P0 has address or data. When ALE = 0, it provides data D0-D7, but when ALE = 1, it has address A0-A7. In case no external memory connection is available, P0 must be when ALE = 1, it has address A0-A7. In case no external memory connection is available, P0 must be connected externally to a 10K-ohm pull-up resistor. connected externally to a 10K-ohm pull-up resistor. MOV A,#0FFH ;(comments: A=FFH(Hexadecimal i.e. A=1111 1111) MOV A,#0FFH ;(comments: A=FFH(Hexadecimal i.e. A=1111 1111) MOV P0,A ;(Port0 have 1's on every pin so that it works as Input) MOV P0,A ;(Port0 have 1's on every pin so that it works as Input) Port 1 (Pin 1 through 8) Port 1 (Pin 1 through 8) It is an 8-bit port (pin 1 through 8) and can be used either as input or output. It doesn't require pull-up It is an 8-bit port (pin 1 through 8) and can be used either as input or output. It doesn't require pull-up resistors because they are already connected internally. Upon reset, Port 1 is configured as an input port. resistors because they are already connected internally. Upon reset, Port 1 is configured as an input port. The following code can be used to send alternating values of 55H and AAH to Port 1. The following code can be used to send alternating values of 55H and AAH to Port 1. ;Toggle all bits of continuously ;Toggle all bits of continuously MOV A,#55 MOV A,#55 BACK: BACK: MOV P2,A MOV P2,A ACALL DELAY ACALL DELAY CPL A ;complement(invert) reg. A CPL A ;complement(invert) reg. A SJMP BACK SJMP BACK If Port 1 is configured to be used as an output port, then to use it as an input port again, program it by If Port 1 is configured to be used as an output port, then to use it as an input port again, program it by writing 1 to all of its bits as in the following code. writing 1 to all of its bits as in the following code.
  • 3. ;Toggle all bits of continuously ;Toggle all bits of continuously MOV A ,#0FFH ;A = FF hex MOV A ,#0FFH ;A = FF hex MOV P1,A ;Make P1 an input port MOV P1,A ;Make P1 an input port MOV A,P1 ;get data from P1 MOV A,P1 ;get data from P1 MOV R7,A ;save it in Reg R7 MOV R7,A ;save it in Reg R7 ACALL DELAY ;wait ACALL DELAY ;wait MOV A,P1 ;get another data from P1 MOV A,P1 ;get another data from P1 MOV R6,A ;save it in R6 MOV R6,A ;save it in R6 ACALL DELAY ;wait ACALL DELAY ;wait MOV A,P1 ;get another data from P1 MOV A,P1 ;get another data from P1 MOV R5,A ;save it in R5 MOV R5,A ;save it in R5 Port 2 (Pins 21 through 28) Port 2 (Pins 21 through 28) Port 2 occupies a total of 8 pins (pins 21 through 28) and can be used for both input and output Port 2 occupies a total of 8 pins (pins 21 through 28) and can be used for both input and output operations. Just as P1 (Port 1), P2 also doesn't require external Pull-up resistors because they are operations. Just as P1 (Port 1), P2 also doesn't require external Pull-up resistors because they are already connected internally. It must be used along with P0 to provide the 16-bit address for the external already connected internally. It must be used along with P0 to provide the 16-bit address for the external memory. So it is also designated as (A0–A7), as shown in the pin diagram. When the 8051 is connected memory. So it is also designated as (A0–A7), as shown in the pin diagram. When the 8051 is connected to an external memory, it provides path for upper 8-bits of 16-bits address, and it cannot be used as I/O. to an external memory, it provides path for upper 8-bits of 16-bits address, and it cannot be used as I/O. Upon reset, Port 2 is configured as an input port. The following code can be used to send alternating Upon reset, Port 2 is configured as an input port. The following code can be used to send alternating values of 55H and AAH to port 2. values of 55H and AAH to port 2. ;Toggle all bits of continuously ;Toggle all bits of continuously MOV A,#55 MOV A,#55 BACK: BACK: MOV P2,A MOV P2,A ACALL DELAY ACALL DELAY CPL A ; complement(invert) reg. A CPL A ; complement(invert) reg. A SJMP BACK SJMP BACK If Port 2 is configured to be used as an output port, then to use it as an input port again, program it by If Port 2 is configured to be used as an output port, then to use it as an input port again, program it by writing 1 to all of its bits as in the following code. writing 1 to all of its bits as in the following code. ;Get a byte from P2 and send it to P1 ;Get a byte from P2 and send it to P1 MOV A,#0FFH ;A = FF hex MOV A,#0FFH ;A = FF hex MOV P2,A ;make P2 an input port MOV P2,A ;make P2 an input port BACK: BACK: MOV A,P2 ;get data from P2 MOV A,P2 ;get data from P2 MOV P1,A ;send it to Port 1 MOV P1,A ;send it to Port 1 SJMP BACK ;keep doing that SJMP BACK ;keep doing that Port 3 (Pins 10 through 17) Port 3 (Pins 10 through 17)
  • 4. It is also of 8 bits and can be used as Input/Output. This port provides some extremely important signals. It is also of 8 bits and can be used as Input/Output. This port provides some extremely important signals. P3.0 and P3.1 are RxD (Receiver) and TxD (Transmitter) respectively and are collectively used for Serial P3.0 and P3.1 are RxD (Receiver) and TxD (Transmitter) respectively and are collectively used for Serial Communication. P3.2 and P3.3 pins are used for external interrupts. P3.4 and P3.5 are used for timers T0 Communication. P3.2 and P3.3 pins are used for external interrupts. P3.4 and P3.5 are used for timers T0 and T1 respectively. P3.6 and P3.7 are Write (WR) and Read (RD) pins. These are active low pins, means and T1 respectively. P3.6 and P3.7 are Write (WR) and Read (RD) pins. These are active low pins, means they will be active when 0 is given to them and these are used to provide Read and Write operations to they will be active when 0 is given to them and these are used to provide Read and Write operations to External ROM in 8031 based systems. External ROM in 8031 based systems. P3 Bit P3 Bit Function Function Pin Pin P3.0 P3.0 RxD RxD 10 10 P3.1 < P3.1 < TxD TxD 11 11 P3.2 < P3.2 < Complement of INT0 Complement of INT0 12 12 P3.3 < P3.3 < INT1 INT1 13 13 P3.4 < P3.4 < T0 T0 14 14 P3.5 < P3.5 < T1 T1 15 15 P3.6 < P3.6 < WR WR 16 16 P3.7 < P3.7 < Complement of RD Complement of RD 17 17 Dual Role of Port 0 and Port 2 Dual Role of Port 0 and Port 2 Dual role of Port 0 Dual role of Port 0 − Port 0 is also designated as AD0–AD7, as it can be used for both data and − Port 0 is also designated as AD0–AD7, as it can be used for both data and address handling. While connecting an 8051 to external memory, Port 0 can provide both address handling. While connecting an 8051 to external memory, Port 0 can provide both address and data. The 8051 microcontroller then multiplexes the input as address or data in address and data. The 8051 microcontroller then multiplexes the input as address or data in order to save pins. order to save pins. Dual role of Port 2 Dual role of Port 2 − Besides working as I/O, Port P2 is also used to provide 16-bit address bus − Besides working as I/O, Port P2 is also used to provide 16-bit address bus for external memory along with Port 0. Port P2 is also designated as (A8– A15), while Port 0 for external memory along with Port 0. Port P2 is also designated as (A8– A15), while Port 0 provides the lower 8-bits via A0–A7. In other words, we can say that when an 8051 is connected provides the lower 8-bits via A0–A7. In other words, we can say that when an 8051 is connected to an external memory (ROM) which can be maximum up to 64KB and this is possible by 16 bit to an external memory (ROM) which can be maximum up to 64KB and this is possible by 16 bit address bus because we know 216 = 64KB. Port2 is used for the upper 8-bit of the 16 bits address bus because we know 216 = 64KB. Port2 is used for the upper 8-bit of the 16 bits address, and it cannot be used for I/O and this is the way any Program code of external ROM is address, and it cannot be used for I/O and this is the way any Program code of external ROM is addressed. addressed. Hardware Connection of Pins Hardware Connection of Pins V V − Pin 40 provides supply to the Chip and it is +5 V. − Pin 40 provides supply to the Chip and it is +5 V. Gnd Gnd − Pin 20 provides ground for the Reference. − Pin 20 provides ground for the Reference. XTAL1, XTAL2 (Pin no 18 & Pin no 19) XTAL1, XTAL2 (Pin no 18 & Pin no 19) − 8051 has on-chip oscillator but requires external clock − 8051 has on-chip oscillator but requires external clock to run it. A quartz crystal is connected between the XTAL1 & XTAL2 pin of the chip. This crystal to run it. A quartz crystal is connected between the XTAL1 & XTAL2 pin of the chip. This crystal also needs two capacitors of 30pF for generating a signal of desired frequency. One side of each also needs two capacitors of 30pF for generating a signal of desired frequency. One side of each capacitor is connected to ground. 8051 IC is available in various speeds and it all depends on capacitor is connected to ground. 8051 IC is available in various speeds and it all depends on cc cc
  • 5. this Quartz crystal, for example, a 20 MHz microcontroller requires a crystal with a frequency no this Quartz crystal, for example, a 20 MHz microcontroller requires a crystal with a frequency no more than 20 MHz. more than 20 MHz. RST (Pin No. 9) RST (Pin No. 9) − It is an Input pin and active High pin. Upon applying a high pulse on this pin, − It is an Input pin and active High pin. Upon applying a high pulse on this pin, that is 1, the microcontroller will reset and terminate all activities. This process is known as that is 1, the microcontroller will reset and terminate all activities. This process is known as Power-On Reset Power-On Reset. Activating a power-on reset will cause all values in the register to be lost. It will . Activating a power-on reset will cause all values in the register to be lost. It will set a program counter to all 0's. To ensure a valid input of Reset, the high pulse must be high for set a program counter to all 0's. To ensure a valid input of Reset, the high pulse must be high for a minimum of two machine cycles before it is allowed to go low, which depends on the capacitor a minimum of two machine cycles before it is allowed to go low, which depends on the capacitor value and the rate at which it charges. ( value and the rate at which it charges. (Machine Cycle Machine Cycle is the minimum amount of frequency a is the minimum amount of frequency a single instruction requires in execution). single instruction requires in execution). EA or External Access (Pin No. 31) EA or External Access (Pin No. 31) − It is an input pin. This pin is an active low pin; upon − It is an input pin. This pin is an active low pin; upon applying a low pulse, it gets activated. In case of microcontroller (8051/52) having on-chip ROM, applying a low pulse, it gets activated. In case of microcontroller (8051/52) having on-chip ROM, the EA (bar) pin is connected to V the EA (bar) pin is connected to V . But in an 8031 microcontroller which does not have an on- . But in an 8031 microcontroller which does not have an on- chip ROM, the code is stored in an external ROM and then fetched by the microcontroller. In this chip ROM, the code is stored in an external ROM and then fetched by the microcontroller. In this case, we must connect the (pin no 31) EA to Gnd to indicate that the program code is stored case, we must connect the (pin no 31) EA to Gnd to indicate that the program code is stored externally. externally. cc cc
  • 6. PSEN or Program store Enable (Pin No 29) PSEN or Program store Enable (Pin No 29) − This is also an active low pin, i.e., it gets − This is also an active low pin, i.e., it gets activated after applying a low pulse. It is an output pin and used along with the EA pin in 8031 activated after applying a low pulse. It is an output pin and used along with the EA pin in 8031 based (i.e. ROMLESS) Systems to allow storage of program code in external ROM. based (i.e. ROMLESS) Systems to allow storage of program code in external ROM. ALE or (Address Latch Enable) ALE or (Address Latch Enable) − This is an Output Pin and is active high. It is especially used − This is an Output Pin and is active high. It is especially used for 8031 IC to connect it to the external memory. It can be used while deciding whether P0 pins for 8031 IC to connect it to the external memory. It can be used while deciding whether P0 pins will be used as Address bus or Data bus. When ALE = 1, then the P0 pins work as Data bus and will be used as Address bus or Data bus. When ALE = 1, then the P0 pins work as Data bus and when ALE = 0, then the P0 pins act as Address bus. when ALE = 0, then the P0 pins act as Address bus. I/O Ports and Bit Addressability I/O Ports and Bit Addressability It is a most widely used feature of 8051 while writing code for 8051. Sometimes we need to access only 1 It is a most widely used feature of 8051 while writing code for 8051. Sometimes we need to access only 1 or 2 bits of the port instead of the entire 8-bits. 8051 provides the capability to access individual bits of the or 2 bits of the port instead of the entire 8-bits. 8051 provides the capability to access individual bits of the ports. ports. While accessing a port in a single-bit manner, we use the syntax "SETB X. Y" where X is the port number While accessing a port in a single-bit manner, we use the syntax "SETB X. Y" where X is the port number (0 to 3), and Y is a bit number (0 to 7) for data bits D0-D7 where D0 is the LSB and D7 is the MSB. For (0 to 3), and Y is a bit number (0 to 7) for data bits D0-D7 where D0 is the LSB and D7 is the MSB. For example, "SETB P1.5" sets high bit 5 of port 1. example, "SETB P1.5" sets high bit 5 of port 1. The following code shows how we can toggle the bit P1.2 continuously. The following code shows how we can toggle the bit P1.2 continuously. AGAIN: AGAIN: SETB P1.2 SETB P1.2 ACALL DELAY ACALL DELAY CLR P1.2 CLR P1.2 ACALL DELAY ACALL DELAY SJMP AGAIN SJMP AGAIN Single-Bit Instructions Single-Bit Instructions
  • 7. Instructions Instructions Function Function SETB bit SETB bit Set the bit (bit = 1) Set the bit (bit = 1) CLR bit CLR bit clear the bit (bit = 0) clear the bit (bit = 0) CPL bit CPL bit complement the bit (bit = NOT bit) complement the bit (bit = NOT bit) JB bit, target JB bit, target jump to target if bit = 1 (jump if bit) jump to target if bit = 1 (jump if bit) JNB bit, target JNB bit, target jump to target if bit = 0 (jump if no bit) jump to target if bit = 0 (jump if no bit) JBC bit, target JBC bit, target jump to target if bit = 1, clear bit (jump if bit, then clear) jump to target if bit = 1, clear bit (jump if bit, then clear)
  翻译: