English
Language : 

CC78K0S Datasheet, PDF (341/520 Pages) NEC – C Compiler Ver.1.30 or Later Language
CHAPTER 11 EXTENDED FUNCTIONS
ASM Statements
#asm, #endasm
_ _asm
(b) _ _asm
(C source)
#pragma asm
int a, b;
void
}
main ( ) {
_ _ asm(“\tmovw ax, _a\t;ax <- a”);
_ _ asm(“\tmovw _b, ax\t;b <- ax”);
(Assembler source)
@@CODE CSEG
_main:
movw ax, _a
movw _b, ax
ret
END
;ax <- a
;b <- ax
COMPATIBILITY
• With a C compiler that supports #asm, modify the program according to the format specified by the C
compiler.
• If the target device is different, modify the assembler source part of the program.
User’s Manual U14872EJ1V0UM
341