LZ: Testing HL


[Prev][Next][Index][Thread]

LZ: Testing HL



I need a way to test if all the bits in hl are set, similar to how 
one would test if all bits in hl were clear.


What i mean is, well you can do
    ld  a,h
    or  l
and that will return zero if hl = 0.


what i need is a way to test if all the bits are 1, similar to the 
method above.  Can i use "and" or "xor" for this?


BTW: I know i could load de with 65535, or $FFFF, and then call 
CP_HL_DE, but i need something that would take the same amount of 
time.  (Yes, it needs to be somewhat percise timing, i'm sending 
kinda serial data out the link port).


Can anyone help?


TIA,


____
~Keith
FFNP69C@PRODIGY.COM