Hey guys so I know for ldi (load immediate) that the addressing mode is set to immediate and for the st instruction the addressing mode is set to index. However, I have no idea what they are for the others so I am curious as to what they are!
Thanks :)
The addressing modes are explained in the instruction set, in the first few pages. Look in the table of instructions to see the operands for the instruction to determine the addressing mode. The mode is indicated by the arguments to the assembly instruction.
For example, LD
had several different ways of operating, depending on the arguments. One of them is LD Rd,X
where d
is the number of a register, such as LD R3,X
. LD R3,-Z
does something else (although both are indirect addressing).
RJMP k
is relative addressing, jumping to PC + k + 1.
ADD Rr,Rd
is direct register addressing. The result is contained in Rd.