Hi,
New to ARM and I don't understand why following doesn't work.
Using Cortex-M3,uVision I get the error 'Expecting constant expression'
ADD R1,R2,R3,ASR R4
All instruction references I can find give the form 'ADD Rd,Rn, <Operand2>' and listed under 'Operand2' is 'Rm LSL Rs' so the 'ASR R4' should be legal.
Any help to clear this up would be appreciated.
Thanks
Cortex-M3: ARMv7-M Architecture with Thumb-2 ISA
Assembler Syntax for ADD instruction:
ADD{S}<c><q> {<Rd>,} <Rn>, <Rm> {,<shift>} <c> Condition <q> Qualifier <Rd> Destination register <Rn> Register that contains the first operand. <Rm> Register that is optionally shifted and used as the second operand <shift> Optional shift applied to value read from <Rm>: LSL #<n> | LSR #<n> | ASR #<n> | ROR #<n> | RRX
Example:
ADD R1,R2,R3,ASR #4
Thanks for that, guess my CORDIC won’t be as fast as I thought it could be now.