Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
10/04/01 06:38
Read: times


 
#15416 - how to use port i/o
Hi,
I have a rather basic question.
I want to use a single pin as a bidirectional i/o line. (Half duplex communication).

I am using an ATMEL AT89LS8252
(with 8K Flash and 2k EEPROM).
Is it possible to use a single pin
(Say P1.0 ) as the i/o line.
More specifically, if I want to put
a pin in input mode do I have to set the latch bit to 1. (Say ORL P1,#0FF)
Does it not send a 1 on the output line? Also is there a way I can put the i/o line(ping p1.0) in tri-state?

I would be very thankful if any of you could clarify these doubts.
Thank you,
Ravi.

PS: The Data sheet for the chip that I downloaded from Atmel is only 31 pages long. I want to know if there is a more detailed document explaining port operations etc.,
I also would like to know the list of instructions which read from the pin instead of latch. So far I could only think of only
MOV C,P1.0 and
MOV A,P1


List of 6 messages in thread
TopicAuthorDate
How can I use bit memory?            01/01/70 00:00      
RE: How can I use bit memory?            01/01/70 00:00      
RE: How can I use bit memory?            01/01/70 00:00      
RE: How can I use bit memory?            01/01/70 00:00      
how to use port i/o            01/01/70 00:00      
RE: How can I use bit memory?            01/01/70 00:00      

Back to Subject List