Re: A86: Instruction set question?
[Prev][Next][Index][Thread]
Re: A86: Instruction set question?
O.K. Sya Im making a looping functions which loads a label to hl.
ld hl,Labels
I then want hl to go to that label and load other address.
Do I do this
Labels:
.db Page1 ;This is the label
.db Page2
Then how do I load Page1 to hl?
That way I can just load hl with one label (Labels) and have a loop do the
rest.
Andres
----------
> >Is this possible:
> >
> >ld hl,(hl)
>
> Not that I know of. You can load 16-bit registers from a fixed address,
but
> as far as I know, you can't do it from a register pointer address. But I
> could be wrong (Heck, I only got this calculator 3 days ago, and I've
never
> owned a TI calculator before).
>
> >Also when I load a label to hl:
> >
> >ld hl,Label
> >
> >Label:
> > .db 3
> > .db 48,0
> >
> >The actual value os HL is $XXXX for some address, right?
> >Does (HL) equal 3?
> Yes. HL is the address of Label, and (HL) is the byte at the address in
HL
> (i.e. 3)
>
> >Thanks for answering my stupid questions,
> Hey, you've got to start somewhere...
>
> --Joshua Grams