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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
05/15/06 10:39
Modified:
  05/15/06 10:45

Read: times


 
#116206 - >256 byte long table
Responding to: ???'s previous message
;assuming A=number of element (any clr acc.7 needed is performed already etc.)
   mov   b,#3   ;3 bytes per table element
   mul   ab
   mov   dpl,a
   mov   a,b
   add   a,#HIGH(Table)
   mov   dph,a
   mov   a,#LOW(Table)
   jmp   @a+dptr

or the same in a more brutal incarnation:
   mov   dptr,#HIGH(Table)+256*LOW(Table)
   mov   b,#3   ;3 bytes per table element
   mul   ab
   xch   a,dpl
   add   a,b
   xch   a,dph
   jmp   @a+dptr

Have fun!

Jan Waclawek


List of 17 messages in thread
TopicAuthorDate
interrupt table copy            01/01/70 00:00      
   optimisation            01/01/70 00:00      
      yes i had that in mind but...            01/01/70 00:00      
         No P2 worries            01/01/70 00:00      
            thanks for making this clear!            01/01/70 00:00      
   single chip solutions            01/01/70 00:00      
      Ofcourse            01/01/70 00:00      
         Why does it need optimising?            01/01/70 00:00      
            Not necessarily!            01/01/70 00:00      
               are you sure this is OK?            01/01/70 00:00      
                  THANKS!            01/01/70 00:00      
                     >256 byte long table            01/01/70 00:00      
                        I'll give it a go...            01/01/70 00:00      
                           worked!            01/01/70 00:00      
                        Re: >256 byte long table            01/01/70 00:00      
                           not quite this issue            01/01/70 00:00      
   issue resolved            01/01/70 00:00      

Back to Subject List