GWASL MOVE.B

Anything QL Software or Programming Related.
Post Reply
User avatar
Whopper
Over Heated PSU
Posts: 126
Joined: Tue Oct 24, 2017 4:04 pm

GWASL MOVE.B

Post by Whopper »

Hi All,

Hopefully this question isn't quite as stupid as the last one.

I am using the GWASL assembler for a project. I wish to code a line thus- " move.b #$ac,(i2c_clk)"

Where there is also a line -

"i2c_clk equ $1c1c0"

Now this works using EASy68K, and seems legal when I decode the operand in the documentation and 68000 code manuals I have. It just doesn't work in GWASL.

Do I need to change the "move.b", or will I have to use GWASS?

Thanks for reading,


Whopper


You woke me for THAT!!!
User avatar
tofro
Font of All Knowledge
Posts: 2685
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: GWASL MOVE.B

Post by tofro »

Whopper wrote:Hi All,

Hopefully this question isn't quite as stupid as the last one.

I am using the GWASL assembler for a project. I wish to code a line thus- " move.b #$ac,(i2c_clk)"

Where there is also a line -

"i2c_clk equ $1c1c0"
What you want to use is absolute long addressing mode, apparently. Thus, the parentheses around the address (i2c_clk) are wrong. proper 68000 code doesn't have parentheses around addresses, only around register+index (like in "20(a6,index)".

Leave off the parentheses and all should be fine.

While most other programming languages perfectly accept arbitrary parentheses anywhere (Easy68k seems to do as well), GWSASS seems to be a bit pickier here.

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
Post Reply