GNU assembler does not support c-style preprocessing directives.
(has this been documented? ...can't remember)
However, you can use 'gcc' for this purposes if you want to
write any preprocessing and includes directives.
1. make sure your file has suffix '.S' (not actually necessary, but looks
better :)
2. run 'msp430-gcc [options] -x assembler-with-cpp -D_GNU_ASSEMBLER_ file.S'
(actually -x assembler-with-cpp is not necessary and -D_GNU_ASSEMBLER_ is
necessary only if you want to include standard includes)
3. Have fun.
Please note, that gcc will run likner unless -c flag specified.
So, in your example you have to write '#define SP R1'.
(SP=1 is not the thing which can be applied to msp430 gas, yet avr's one can
handle this.)
~d
On Thursday 19 December 2002 12:41, Oleg Skydan wrote:
> Hi All,
>
> Can I write a pice of code like this:
>
> SP=R1 or #define SP R1
>
>
> move 16(SP),R10
>
>
> msp430-as said:
>
> fpp.S:170: Error: unknown operator 16(SP). Did you mean X(Rn) or
> #[hl][hl][oi](CONST) ?
>
> Any suggestings ?
>
> Thanks, Oleg.
--
/********************************************************************
("`-''-/").___..--''"`-._ (\ Dimmy the Wild UA1ACZ
`6_ 6 ) `-. ( ).`-.__.`) Enterprise Information Sys
(_Y_.)' ._ ) `._ `. ``-..-' Nevsky prospekt, 20 / 44
_..`--'_..-_/ /--'_.' ,' Saint Petersburg, Russia
(il),-'' (li),' ((!.-' +7 (812) 3468202, 5585314
********************************************************************/