I used GCC-AVR to compile an example, but there are some errors as in the following. The errors are of the same types. I felt that the compiler cannot substitute the definitions to the variables.So I tried to directly substitute r16 to x1 at the first error. The corresponding error then vanishes after compilation.
Could anyone suggest me how to make the substitutions possible? Do I need to set compilation options in the makefile? Thanks!
#define x1 r16 #define x2 r17 #define shift r18 #define cnt r19 #define x3 r20 #define x4 r21 .text .global SIG_INTERRUPT0 .type SIG_INTERRUPT0, @function SIG_INTERRUPT0: push x1;