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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
04/23/05 14:04
Read: times


 
#92235 - On the right track
Responding to: ???'s previous message
Hi Declan,

OK, you're definitely on the right track now. Still a bit of confusion, though ;-)

The receive sequence starts by the RPC pulling the RxR line low. The controller has to acknowledge this by pulling low the RxA line. Then the controller needs to wait for the RPC to set RxR high again, before reading the data. You have this reversed.

The instruction "MOV A,P2" leaves the ACC with the value of P2, which includes both the data and the status of the control lines. As we're not at all interested in the control lines, we want to mask off their value by AND-ing the ACC with #0Fh, which leaves us with tha data in the low nibble. This we can now store in "Rx_Data".

The second read operation is identical, but here we have to remember that what we've just read is the high nibble of the databyte. This means we have to SWAP nibbles, before adding to "Rx_Data".


I might well be visiting Ireland later this year, so I might well drop by, 'cause I think you owe me a pint ;-))

Regards,
Rob.

List of 13 messages in thread
TopicAuthorDate
Host to RPC byte transfer            01/01/70 00:00      
   leg up            01/01/70 00:00      
   RE: leg up            01/01/70 00:00      
      You've got to be joking!            01/01/70 00:00      
         Receive sequence            01/01/70 00:00      
            why not try it            01/01/70 00:00      
               Simulate            01/01/70 00:00      
            Wrong way round            01/01/70 00:00      
               F.A.O Rob            01/01/70 00:00      
                  On the right track            01/01/70 00:00      
                     Thanks Rob            01/01/70 00:00      
                        Resetting port pins            01/01/70 00:00      
         F.A.O Rob Klein            01/01/70 00:00      

Back to Subject List