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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
09/26/06 11:39
Read: times


 
#125054 - Basic Q about Table Look ups
I have been learning to program with an 8052 chip at work. I have just been having a trival problem while coding my first program.

;the pc will recive a response from the modem between 00h and 07h
;range_check ok
$Modem_response
.
.
;accumulator is loaded with modem response

**It is doing this that my code (mov dptr,#$response_table)
**is copying 0000h into the dptr???.
**could some one please fill in down
**below so i can compare it to what i may have shamefully written

**************************************

;use look up table to determine if modem response is error or
;connected.
;if 00h, jmp $connected
;else jmp $error


**************************************


;modem response table, 00h indicates connected msg, 01h error msg
;eight elements representing the 8 possible modem response msgs

$response_table db 01h,00h,00h,01h,00h,01h,00h,01h


Cheers

List of 7 messages in thread
TopicAuthorDate
Basic Q about Table Look ups            01/01/70 00:00      
   Basic table lookup            01/01/70 00:00      
   well, this should be an exercise for the student            01/01/70 00:00      
   More help please            01/01/70 00:00      
      Why HEX?            01/01/70 00:00      
         It's Place Value again!            01/01/70 00:00      
      Confusion!            01/01/70 00:00      

Back to Subject List