This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

MACRO

Hello,
May I know if the code as shown below works?

--------------------------------------------
#pragma src
void main(void){
#pragma asm
myMacro MACRO
MOV R1, #01
MOV R2, #02
MOV R3, #03
ENDM
#pragma endasm

#pragma asm
#define myMacroFunc() myMacro
#pragma endasm

#pragma asm
myMacroFunc()
#pragma endasm
}
---------------------------------------------

regards,

  • The short answer is: no.

    The slightly long answer is: as you are a beginner, I think you should start somewhere else!

    More helpfully: what exactly is it that you want to achieve?

    In the meantime: welcome to the forum and good luck.

    BTW: this is a professional forum, please use your real name.