Posted: Sat Apr 21, 2012 11:53 pm
Just use $80xx.w for all hardware references. Leave off all the Fs.
There's no such thing as btst #15.
should be
You could also do
Some assemblers will assume that's what you mean when you try to do bit operations over 7, but it's sloppy programming relying on a questionable assumption by a specific revision of an assembler.
If you plan to use more bits from the register, this would be more proper
There's no such thing as btst #15.
Code: Select all
loop:
btst #15,word_ptr
bne.s loop
Code: Select all
loop:
tst.w word_ptr
bmi.s loop
Code: Select all
loop:
btst #7,hi_byte_of_word_ptr
bne.s loop
If you plan to use more bits from the register, this would be more proper
Code: Select all
loop:
move.w word_ptr,d0
bmi.s loop