A89: Re: btst (ON_topic)


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

A89: Re: btst (ON_topic)




see below...
----------
> De : S43R80@aol.com
> A : assembly-89@lists.ticalc.org
> Objet : A89: btst (ON_topic)
> Date : jeudi 20 janvier 2000 23:28
>
>
> anyone have any ideas why this my cause an error: 16 bit relocations are
> unsupported upon being assembled?
>
> test_if_even:
>         move.w #old_x_status,d6

I think you should try
move.w old_x_status,d6

In fact, old_x_status is the value, and old_x_status(pc) is the address...

>         move.w #old_y_status,d7
>
>         btst.w #0,d6   
>         beq x_is_even           
> x_is_odd:
>         btst.w #0,d7   
>         beq print_black
>         bra print_white
> x_is_even:
>         btst.w #0,d7   
>         beq print_white
>         bra print_black
>
> ...
> ...
> etc
> ...
> ...
> old_x_status dc.w 0
> old_y_status dc.w 0
>
> before this I tried using:
> test_if_even:
>         btst.w #0,old_x_status   
>         beq x_is_even           
> x_is_odd:
>         btst.w #0,old_y_status   
>         beq print_black
>         bra print_white
> x_is_even:
>         btst.w #0,old_y_status   
>         beq print_white
>         bra print_black
>
> ...but it never seemed to NEVER goto the print_black routine...so I thought
> maybe I had to use a register or something w/ btst...
> the old_x/y_status numbers range from x: 0 to 7  //////  y: 0 to -7...and it
> seems like it never detects any number to be odd or something...
>
> ...Steven
>


Follow-Ups: