⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 test.asm

📁 汇编语言与C51的相互调用简介,能给以一定的提示!
💻 ASM
字号:
;add the "_" is because of this function get some pamerate in
;add the "_?" is because of this function is reentrantalbe
;add nothing before the function assert there is no pamerate


	EXTRN CODE(?C_STARTUP)


	;some one said this function is necessary,but i think this function assert is not necessary

;	EXTRN CODE(_?CTOA)	;the code is realize in the *.c file

	EXTRN CODE(_CTOA)


PUBLIC  _ATOC			;some othe *.c file will call this function

;byte        R7		R5	R3	R1
;DoubleByte  R7R6	R5R4	R3R2	R1R0

;R7R6	R7 is the low byte
;	R6 is the high byte

;	EXTRN DATA(DDDD)


	ORG 0020H

_ATOC:	MOV A,R7
	MOV B,R6

	MOV B,R5
	MOV A,R4
	
;	LCALL _?CTOA
	LCALL _CTOA

	MOV A,#40H
	MOV R7,#30H
	MOV R6,A
	RET


	END

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -