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

📄 sound.asm

📁 凌阳61单片机实现的多功能电子琴源程序代码
💻 ASM
字号:
// GCC for SUNPLUS u'nSP version 1.0.21-3
// Command: C:\PROGRA~1\Sunplus\UNSPID~1.0\cc1.exe C:\DOCUME~1\w\LOCALS~1\Temp\ccgTaaaa.i -fkeep-inline-functions -quiet -dumpbase sound.c -mglobal-var-iram -gstabs -Wall -o .\Debug/sound.asm
	.external __sn_func_ptr_sec

// gcc2_compiled.:

.debug
	.dw '.stabs "D:/hyc/organ/",0x64,0,3,',0,0,offset Ltext0,seg Ltext0,0x0d,0x0a
.code
.debug
	.dw '.stabs "D:/hyc/organ/sound.c",0x64,0,3,',0,0,offset Ltext0,seg Ltext0,0x0d,0x0a
.code
.code
Ltext0:
.debug
	.dw '.stabs "int:t1=r1;-32768;32767;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "char:t2=r2;0;127;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "long int:t3=r3;-2147483648;2147483647;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "unsigned int:t4=r4;0;65535;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "long unsigned int:t5=r5;0;4294967295;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "long long int:t6=r6;-2147483648;2147483647;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "long long unsigned int:t7=r7;0;4294967295;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "short int:t8=r8;-32768;32767;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "short unsigned int:t9=r9;0;65535;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "signed char:t10=r10;-32768;32767;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "unsigned char:t11=r11;0;65535;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "float:t12=r1;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "double:t13=r1;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "long double:t14=r1;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "complex int:t15=s2real:1,0,16;imag:1,16,16;;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "complex float:t16=r16;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "complex double:t17=r17;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "complex long double:t18=r18;2;0;",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "void:t19=19",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "Key_code:G1",32,0,0,',0,0,offset _Key_code,seg _Key_code,0x0d,0x0a
.CODE
.debug
	.dw '.stabs "Key_Delay:G11",32,0,0,',0,0,offset _Key_Delay,seg _Key_Delay,0x0d,0x0a
.CODE
.code
.debug
	.dw '.stabs "sound:F19",36,0,0,',0,0,offset _sound,seg _sound,0x0d,0x0a
.CODE
.public _sound
_sound:	.proc
.debug
	.dw '.stabn 0x44,0,24,',0,0
	.dd LM1-_sound
	.dw 0x0d,0x0a
.code
LM1:
	// total=4, vars=4
	// frame_pointer_needed: 1
	push bp to [sp]
	sp-=4
	bp=sp+1

	R1=BP+7
	[bp+3]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,25,',0,0
	.dd LM2-_sound
	.dw 0x0d,0x0a
.code
LM2:
LBB2:
.debug
	.dw '.stabn 0x44,0,26,',0,0
	.dd LM3-_sound
	.dw 0x0d,0x0a
.code
LM3:
	call _Key_Get	// call with return value
	[_Key_code]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,27,',0,0
	.dd LM4-_sound
	.dw 0x0d,0x0a
.code
LM4:
	R1=[_Key_code]	// QImode move
	CMP R1,0	// QImode test
	NSJZ L3	//QImode EQ
.debug
	.dw '.stabn 0x44,0,29,',0,0
	.dd LM5-_sound
	.dw 0x0d,0x0a
.code
LM5:
	R1=[_Key_code]	// QImode move
	[SP--]=R1	// QImode move
	call _KeyDataChange	// call with return value
	SP = SP + 1	//SP
	[_Key_Delay]=R1	// QImode move
L3:
.debug
	.dw '.stabn 0x44,0,31,',0,0
	.dd LM6-_sound
	.dw 0x0d,0x0a
.code
LM6:
	R1=[_Key_Delay]	// QImode move
	CMP R1,0	// QImode test
	NSJZ L4	//QImode EQ
.debug
	.dw '.stabn 0x44,0,33,',0,0
	.dd LM7-_sound
	.dw 0x0d,0x0a
.code
LM7:
	R1=0	// QImode move
	[BP]=R1	// QImode move
L5:
	R1=[BP]	// QImode move
	CMP R1,254	// QImode compare
	NSJNG L8	//QImode LE
	pc=L4	// Indirect jump
L8:
.debug
	.dw '.stabn 0x44,0,35,',0,0
	.dd LM8-_sound
	.dw 0x0d,0x0a
.code
LM8:
	R1=0	// QImode move
	[28714]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,36,',0,0
	.dd LM9-_sound
	.dw 0x0d,0x0a
.code
LM9:
	R1=BP	// QImode move
	R2=BP+1
	R3=R2	// QImode move
	R1=[R3]	// QImode move
	[28695]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,37,',0,0
	.dd LM10-_sound
	.dw 0x0d,0x0a
.code
LM10:
	R1=BP	// QImode move
	R2=BP+1
	R4=R2	// QImode move
	R1=[R4]	// QImode move
	[28694]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,38,',0,0
	.dd LM11-_sound
	.dw 0x0d,0x0a
.code
LM11:
	R1=BP	// QImode move
	R2=BP+2
	R1=0	// QImode move
	R3=R2	// QImode move
	[R3]=R1	// QImode move
L9:
	R1=BP	// QImode move
	R2=BP+2
	R4=R2	// QImode move
	R1=[R4]	// QImode move
	CMP R1,[_Key_Delay]	// QImode compare
	NSJB L11	//QImode LTU
	pc=L10	// Indirect jump
L12:
L11:
	R1=BP	// QImode move
	R2=BP+2
	R3=BP	// QImode move
	R1=BP+2
	R2=BP	// QImode move
	R3=BP+2
	R4=R3	// QImode move
	R2=[R4]	// QImode move
	R3=R2+1
	R2=R1	// QImode move
	[R2]=R3	// QImode move
	pc=L9	// Indirect jump
L10:
.debug
	.dw '.stabn 0x44,0,39,',0,0
	.dd LM12-_sound
	.dw 0x0d,0x0a
.code
LM12:
	R1=BP	// QImode move
	R2=BP+1
	R3=R2	// QImode move
	R1=[R3]	// QImode move
	CMP R1,0	// QImode test
	NSJNZ L13	//QImode NE
.debug
	.dw '.stabn 0x44,0,40,',0,0
	.dd LM13-_sound
	.dw 0x0d,0x0a
.code
LM13:
	R1=BP	// QImode move
	R2=BP+1
	R1=(-32768)	// QImode move
	R4=R2	// QImode move
	[R4]=R1	// QImode move
	pc=L14	// Indirect jump
L13:
.debug
	.dw '.stabn 0x44,0,41,',0,0
	.dd LM14-_sound
	.dw 0x0d,0x0a
.code
LM14:
	R1=BP	// QImode move
	R2=BP+1
	R1=0	// QImode move
	R3=R2	// QImode move
	[R3]=R1	// QImode move
L14:
.debug
	.dw '.stabn 0x44,0,42,',0,0
	.dd LM15-_sound
	.dw 0x0d,0x0a
.code
LM15:
	R1=1	// QImode move
	[28690]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,33,',0,0
	.dd LM16-_sound
	.dw 0x0d,0x0a
.code
LM16:
L7:
	R1=[BP]	// QImode move
	R2=R1+1
	[BP]=R2	// QImode move
	pc=L5	// Indirect jump
L6:
L4:
.debug
	.dw '.stabn 0x44,0,47,',0,0
	.dd LM17-_sound
	.dw 0x0d,0x0a
.code
LM17:
	R1=1	// QImode move
	[28690]=R1	// QImode move
.debug
	.dw '.stabn 0x44,0,49,',0,0
	.dd LM18-_sound
	.dw 0x0d,0x0a
.code
LM18:
LBE2:
.debug
	.dw '.stabn 0x44,0,49,',0,0
	.dd LM19-_sound
	.dw 0x0d,0x0a
.code
LM19:
L2:

	sp+=4
	pop bp from [sp]
	retf
	.endp	// end of sound

.debug
	.dw '.stabn 0xc0,0,0,',0,0
	.dd LBB2-_sound
	.dw 0x0d,0x0a
.code
.debug
	.dw '.stabs "i:1",128,0,0,0',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "j:1",128,0,0,1',0x0d,0x0a
.CODE
.debug
	.dw '.stabs "m:1",128,0,0,2',0x0d,0x0a
.CODE
.debug
	.dw '.stabn 0xe0,0,0,',0,0
	.dd LBE2-_sound
	.dw 0x0d,0x0a
.code
.debug
	.dw '.stabf ',0,0
	.dd LME1-_sound
	.dw 0x0d,0x0a
.code
LME1:
.code
.debug
	.dw '.stabs "KeyDataChange:F4",36,0,0,',0,0,offset _KeyDataChange,seg _KeyDataChange,0x0d,0x0a
.CODE
.public _KeyDataChange
_KeyDataChange:	.proc
.debug
	.dw '.stabn 0x44,0,62,',0,0
	.dd LM20-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM20:
	// total=0, vars=0
	// frame_pointer_needed: 1
	push bp to [sp]
	bp=sp+1

	R2=BP+3
.debug
	.dw '.stabn 0x44,0,63,',0,0
	.dd LM21-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM21:
	R1=R2	// QImode move
	R3=[R1]	// QImode move
	R1=R3	// QImode move
	R1=R1-17
	CMP R1,119	// QImode compare
	NSJA L38	//QImode GTU
	R3=L39	// QImode move
	R1 = R1 + R3	//addqi3
	R3=R1	// QImode move
	R1=[R3]	// QImode move
	pc=R1	// tablejump
.text
L39:
	.dw L37
	.dw L36
	.dw L38
	.dw L35
	.dw L38
	.dw L38
	.dw L38
	.dw L34
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L33
	.dw L32
	.dw L38
	.dw L31
	.dw L38
	.dw L38
	.dw L38
	.dw L30
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L29
	.dw L28
	.dw L38
	.dw L27
	.dw L38
	.dw L38
	.dw L38
	.dw L26
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L38
	.dw L25
	.dw L24
	.dw L38
	.dw L23
	.dw L38
	.dw L38
	.dw L38
	.dw L22
.code
.debug
	.dw '.stabn 0x44,0,65,',0,0
	.dd LM22-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM22:
L22:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L23:
.debug
	.dw '.stabn 0x44,0,66,',0,0
	.dd LM23-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM23:
	R1=110	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L24:
.debug
	.dw '.stabn 0x44,0,67,',0,0
	.dd LM24-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM24:
	R1=98	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L25:
.debug
	.dw '.stabn 0x44,0,68,',0,0
	.dd LM25-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM25:
	R1=87	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L26:
.debug
	.dw '.stabn 0x44,0,69,',0,0
	.dd LM26-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM26:
	R1=82	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L27:
.debug
	.dw '.stabn 0x44,0,70,',0,0
	.dd LM27-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM27:
	R1=73	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L28:
.debug
	.dw '.stabn 0x44,0,71,',0,0
	.dd LM28-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM28:
	R1=64	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L29:
.debug
	.dw '.stabn 0x44,0,72,',0,0
	.dd LM29-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM29:
	R1=61	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L30:
.debug
	.dw '.stabn 0x44,0,73,',0,0
	.dd LM30-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM30:
	R1=54	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L31:
.debug
	.dw '.stabn 0x44,0,74,',0,0
	.dd LM31-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM31:
	R1=48	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L32:
.debug
	.dw '.stabn 0x44,0,75,',0,0
	.dd LM32-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM32:
	R1=42	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L33:
.debug
	.dw '.stabn 0x44,0,76,',0,0
	.dd LM33-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM33:
	R1=40	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L34:
.debug
	.dw '.stabn 0x44,0,77,',0,0
	.dd LM34-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM34:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L35:
.debug
	.dw '.stabn 0x44,0,78,',0,0
	.dd LM35-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM35:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L36:
.debug
	.dw '.stabn 0x44,0,79,',0,0
	.dd LM36-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM36:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L37:
.debug
	.dw '.stabn 0x44,0,80,',0,0
	.dd LM37-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM37:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L38:
.debug
	.dw '.stabn 0x44,0,81,',0,0
	.dd LM38-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM38:
	R1=0	// QImode move
	[_Key_Delay]=R1	// QImode move
	pc=L21	// Indirect jump
L21:
.debug
	.dw '.stabn 0x44,0,83,',0,0
	.dd LM39-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM39:
	R3=[_Key_Delay]	// QImode move
	R1=R3	// QImode move
	pc=L20	// Indirect jump
.debug
	.dw '.stabn 0x44,0,84,',0,0
	.dd LM40-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM40:
.debug
	.dw '.stabn 0x44,0,84,',0,0
	.dd LM41-_KeyDataChange
	.dw 0x0d,0x0a
.code
LM41:
L20:

	pop bp from [sp]
	retf
	.endp	// end of KeyDataChange

.debug
	.dw '.stabs "Key_code:p4",160,0,0,3',0x0d,0x0a
.CODE
.debug
	.dw '.stabf ',0,0
	.dd LME2-_KeyDataChange
	.dw 0x0d,0x0a
.code
LME2:
.iram
.public _Key_code
_Key_code:
	.dw 0
.iram
.public _Key_Delay
_Key_Delay:
	.dw 0
.external _Key_Get
	.end

⌨️ 快捷键说明

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