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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
07/09/02 00:30
Read: times


 
#25488 - Sending serial info (bit banging?)
I'm still trying to figure out routines for controlling this ADC of mine. I guess I'm dumb. Regardless, assuming I wanted to send one byte of information without using a serial port, only regular IO pins, how would one do this?

For example, If I wanted to send 11110000
out on port 1.0, and 1.1 was used as a serial clock, I *could* :

setb p1.0 (the first 1 in the byte)
acall clock
setb p1.0
acall clock
setb p1.0
acall clock
setb p1.0
acall clock
clr p1.0
acall clock
clr p1.0
acall clock
clr p1.0
acall clock
clr p1.0
acall clock

endloop:
jmp endloop

clock:
setb p1.1 (these two lines pulse the serial
clr p1.1 ADC clock)
ret

Now, while this would work for sending one byte out, what if the byte I was sending was different? There *has* to be an easier way to send a byte out.

-Still learning ASM in Oklahoma

List of 20 messages in thread
TopicAuthorDate
Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
RE: Sending serial info (bit banging?)            01/01/70 00:00      
Eric            01/01/70 00:00      
RE: Eric            01/01/70 00:00      
RE: Eric            01/01/70 00:00      
other            01/01/70 00:00      
RE: other            01/01/70 00:00      

Back to Subject List