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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
05/03/06 11:36
Read: times


 
#115446 - think of it like a clock
Responding to: ???'s previous message
Andy Neil said:
The assumption being, of course, that Cyrille is actually talking about an 8051 instruction...

Sticking with that assumption, think of it like a good, old-fashioned analogue clock:

If you wind an analogue clock back to 00:00 (or 12:00, if you prefer), and then wind it back (ie, dcrement it) by another minute, you will end up at 23:59 (or 11:59).

Similarly decrementing a byte value of 0x00 will usually give you a byte value of 0xFF.

If you think of 0xFF as a 2's complement number, then it's -1 - which is exactly what you'd expect after subtracting one from zero!

It all makes sense, really...




List of 24 messages in thread
TopicAuthorDate
DEC 0H ?            01/01/70 00:00      
   dec            01/01/70 00:00      
   How you figure its memory location zero?            01/01/70 00:00      
      Because            01/01/70 00:00      
         assumption...            01/01/70 00:00      
            think of it like a clock            01/01/70 00:00      
   i think it's bible time            01/01/70 00:00      
   ASSUME = ASS U ME read and head.            01/01/70 00:00      
      but the answer will still be in "the bib            01/01/70 00:00      
      It's in the title!            01/01/70 00:00      
         rely on history            01/01/70 00:00      
            exceptions?            01/01/70 00:00      
               not exactly that ...            01/01/70 00:00      
            DEC R6 ! (8051 chip)            01/01/70 00:00      
               the description of the DEC instruction            01/01/70 00:00      
                  Good! Erick            01/01/70 00:00      
                     why work from print            01/01/70 00:00      
                        I do !            01/01/70 00:00      
                           Surely that's justification enough.            01/01/70 00:00      
                           I did not suggest that            01/01/70 00:00      
                              I did not suggest that ! ....            01/01/70 00:00      
                     Think about an ordometer            01/01/70 00:00      
                        control apps            01/01/70 00:00      
                           In decimal mode ...            01/01/70 00:00      

Back to Subject List