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

📄 dspbird.asm

📁 DSP串口模拟IO之SPI接口LED显示完整代码
💻 ASM
📖 第 1 页 / 共 3 页
字号:
;***************************************************************
;* TMS320C54x ANSI C Codegen                      Version 3.70 *
;* Date/Time created: Tue Jun 20 17:39:39 2006                 *
;***************************************************************
	.mmregs
FP	.set	AR7
	.c_mode
	.file	"dspbird.cpp"

	.sect	".const"
	.align	1
_SREG:
	.field  	0,16			; _SREG @ 0
	.sect	".text"
	.sym	_SREG,_SREG, 24, 3, 16, __TI_SREG

	.sect	".const"
	.align	1
_McBSP0:
	.field  	32,16			; _McBSP0 @ 0
	.sect	".text"
	.sym	_McBSP0,_McBSP0, 24, 3, 16, __TI_McBSP0

	.sect	".const"
	.align	1
_McBSP1:
	.field  	64,16			; _McBSP1 @ 0
	.sect	".text"
	.sym	_McBSP1,_McBSP1, 24, 3, 16, __TI_McBSP1

	.sect	".const"
	.align	1
_TIMER0:
	.field  	36,16			; _TIMER0 @ 0
	.sect	".text"
	.sym	_TIMER0,_TIMER0, 24, 3, 16, __TI_TIMER

	.sect	".const"
	.align	1
_TIMER1:
	.field  	48,16			; _TIMER1 @ 0
	.sect	".text"
	.sym	_TIMER1,_TIMER1, 24, 3, 16, __TI_TIMER
	.global	_IOXF
	.bss	_IOXF,1,0,0
	.sym	_IOXF,_IOXF, 2, 2, 16
	.global	_SystemRamTest
	.bss	_SystemRamTest,1,0,0
	.sym	_SystemRamTest,_SystemRamTest, 14, 2, 16
	.global	_Sys
	.bss	_Sys,1,0,0
	.sym	_Sys,_Sys, 8, 2, 16, _SystemObj
	.global	_Led
	.bss	_Led,1,0,0
	.sym	_Led,_Led, 8, 2, 16, _LedObj

	.sect	".cinit"
	.align	1
	.field  	1,16
	.field  	_count$1+0,16
	.field  	0,16			; _count$1 @ 0
	.sect	".text"
	.bss	_count$1,1,0,0
	.sym	_count,_count$1, 4, 3, 16

	.sect	".cinit"
	.align	1
	.field  	1,16
	.field  	_ledcount$2+0,16
	.field  	0,16			; _ledcount$2 @ 0
	.sect	".text"
	.bss	_ledcount$2,1,0,0
	.sym	_ledcount,_ledcount$2, 4, 3, 16

	.sect	".const"
	.align	1
_LedTab$3:
	.field  	65472,16			; _LedTab$3[0] @ 0
	.field  	65529,16			; _LedTab$3[1] @ 16
	.field  	65444,16			; _LedTab$3[2] @ 32
	.field  	65456,16			; _LedTab$3[3] @ 48
	.field  	65433,16			; _LedTab$3[4] @ 64
	.field  	65426,16			; _LedTab$3[5] @ 80
	.field  	65410,16			; _LedTab$3[6] @ 96
	.field  	65528,16			; _LedTab$3[7] @ 112
	.field  	65408,16			; _LedTab$3[8] @ 128
	.field  	65424,16			; _LedTab$3[9] @ 144
	.field  	65416,16			; _LedTab$3[10] @ 160
	.field  	65411,16			; _LedTab$3[11] @ 176
	.field  	65478,16			; _LedTab$3[12] @ 192
	.field  	65441,16			; _LedTab$3[13] @ 208
	.field  	65414,16			; _LedTab$3[14] @ 224
	.field  	65422,16			; _LedTab$3[15] @ 240
	.sect	".text"
	.sym	_LedTab,_LedTab$3, 60, 3, 256,, 16
;	d:\ti\c5400\cgtools\bin\acp500.exe --embedded_c++ --no_inlining -D_DEBUG -Id:/ti/c5400/bios/include -Id:/ti/c5400/rtdx/include -Id:/ti/c5400/cgtools/include --keep_unneeded_types --i_output_file C:\DOCUME~1\liu\LOCALS~1\Temp\TI3320_2 --template_info_file C:\DOCUME~1\liu\LOCALS~1\Temp\TI3320_3 --object_file D:/dspbird/Debug/dspbird.obj --opt_shell 12 dspbird.cpp -g -k -pe -pi -frD:/dspbird/Debug -d_DEBUG -mn -ms -id:/ti/c5400/bios/include -id:/ti/c5400/rtdx/include -id:/ti/c5400/cgtools/include 
	.sect	".text"
	.global	_main
	.sym	_main,_main, 36, 2, 0
	.func	267

;***************************************************************
;* FUNCTION DEF: _main                                         *
;***************************************************************
_main:
	.line	2
        PSHM      AR1
	.line	3
 rsbx intm
	.line	4
L1:    
	.line	6
 nop
	.line	8
 nop
	.line	10
        LD        *(_IOXF),A            ; |276| 
        BC        L2,AEQ                ; |276| 
        ; branch occurs ; |276| 
	.line	11
        MVDM      *(_SREG),AR1
        NOP
        ORM       #8192,*AR1(7)         ; |277| 
	.line	12
        B         L3                    ; |278| 
        ; branch occurs ; |278| 
L2:    
	.line	14
        MVDM      *(_SREG),AR1
        NOP
        ANDM      #57343,*AR1(7)        ; |280| 
L3:    
	.line	16
 IDLE 1
	.line	17
        B         L1                    ; |283| 
        ; branch occurs ; |283| 
	.endfunc	284,000000400h,1


	.sect	".text"
	.global	_Timer0Isr
	.sym	_Timer0Isr,_Timer0Isr, 32, 2, 0
	.func	286

;***************************************************************
;* FUNCTION DEF: _Timer0Isr                                    *
;***************************************************************
_Timer0Isr:
	.line	1
        NOP
        PSHM      AL
        PSHM      AH
        PSHM      AG
        PSHM      BL
        PSHM      BH
        PSHM      BG
        PSHM      AR0
        PSHM      AR1
        PSHM      AR2
        PSHM      AR3
        PSHM      AR4
        PSHM      AR5
        PSHM      AR6
        PSHM      AR7
        PSHM      FP
        PSHM      BK
        PSHM      T
        PSHM      ST0
        PSHM      ST1
        PSHM      BRC
        PSHM      PMST
        PSHM      RSA
        PSHM      REA
        ANDM      #32063,*(ST1)
        ORM       #16384,*(ST1)
        ANDM      #-4,*(PMST)
        LDM       SP,A
        ANDM      #-2,*(SP)
        NOP
        NOP
        PSHM      AL
        FRAME     #-3
	.line	4
        ADDM      #1,*(_count$1)        ; |289| 
	.line	5
        SSBX      SXM
        LD        #1000,A
        SUB       *(_count$1),A         ; |290| 
        BC        L6,AGT                ; |290| 
        ; branch occurs ; |290| 
	.line	6
        ST        #0,*(_count$1)        ; |291| 
	.line	7
        LD        *(_IOXF),A            ; |292| 
        LD        #0,B
        STM       #0,AR1
        BC        L4,AEQ                ; |292| 
        ; branch occurs ; |292| 
        STM       #1,AR1
L4:    
        BANZ      L5,*AR1               ; |292| 
        ; branch occurs ; |292| 
        LD        #1,B
L5:    
        STL       B,*(_IOXF)
	.line	8
        MVDM      *(_McBSP0),AR1
        NOP
        ST        #14,*AR1(24)          ; |293| 
	.line	9
        MVDM      *(_McBSP0),AR1
        NOP
        XORM      #32,*AR1(25)          ; |294| 
	.line	11
        MVDM      *(_McBSP0),AR1
        NOP
        XORM      #2,*AR1(25)           ; |296| 
	.line	13
        MVDM      *(_McBSP0),AR1
        NOP
        XORM      #8,*AR1(25)           ; |298| 
	.line	16
        MVDM      *(_McBSP0),AR1
        NOP
        XORM      #1,*AR1(25)           ; |301| 
	.line	18
        MVDM      *(_McBSP0),AR1
        NOP
        XORM      #4,*AR1(25)           ; |303| 
	.line	20
        LD        #15,A
        AND       *(_ledcount$2),A      ; |305| 
        STL       A,*SP(0)
        LD        #_Led,A
        CALL      #_LedDisplay__6LedObjFUc ; |305| 
        ; call occurs [#_LedDisplay__6LedObjFUc] ; |305| 
	.line	21
        ADDM      #1,*(_ledcount$2)     ; |306| 
	.line	37
L6:    
	.line	38
        FRAME     #3
        POPM      SP
        NOP
        POPM      REA
        POPM      RSA
        POPM      PMST
        POPM      BRC
        POPM      ST1
        POPM      ST0
        POPM      T
        POPM      BK
        POPM      FP
        POPM      AR7
        POPM      AR6
        POPM      AR5
        POPM      AR4
        POPM      AR3
        POPM      AR2
        POPM      AR1
        POPM      AR0
        POPM      BG
        POPM      BH
        POPM      BL
        POPM      AG
        POPM      AH
        POPM      AL
        RETE
        ; branch occurs
	.endfunc	323,0e39dffc7h,25


	.sect	".text"
	.global	_Timer1Isr
	.sym	_Timer1Isr,_Timer1Isr, 32, 2, 0
	.func	325

;***************************************************************
;* FUNCTION DEF: _Timer1Isr                                    *
;***************************************************************
_Timer1Isr:
	.line	1
        PSHM      AR1
        PSHM      ST0
        PSHM      ST1
        PSHM      PMST
        ANDM      #32063,*(ST1)
        ORM       #16384,*(ST1)
        ANDM      #-4,*(PMST)
        NOP
	.line	2
        MVDM      *(_TIMER1),AR1
        NOP
        ORM       #16,*AR1(2)           ; |326| 
	.line	3
        POPM      PMST
        POPM      ST1
        POPM      ST0
        POPM      AR1
        RETE
        ; branch occurs
	.endfunc	327,021800400h,4


	.sect	".text"
	.global	_Eint0Isr
	.sym	_Eint0Isr,_Eint0Isr, 32, 2, 0
	.func	329

;***************************************************************
;* FUNCTION DEF: _Eint0Isr                                     *
;***************************************************************
_Eint0Isr:
	.line	1
        PSHM      AR1
        PSHM      ST0
        PSHM      ST1
        PSHM      PMST
        ANDM      #32063,*(ST1)
        ORM       #16384,*(ST1)
        ANDM      #-4,*(PMST)
        NOP
	.line	2
        MVDM      *(_McBSP1),AR1
        NOP
        ST        #14,*AR1(8)           ; |330| 
	.line	3
        MVDM      *(_McBSP1),AR1
        NOP
        ORM       #32,*AR1(9)           ; |331| 
	.line	4
        MVDM      *(_SREG),AR1
        NOP
        ST        #1,*AR1(1)            ; |332| 
	.line	5
        POPM      PMST
        POPM      ST1
        POPM      ST0
        POPM      AR1
        RETE
        ; branch occurs
	.endfunc	333,021800400h,4


	.sect	".text"
	.global	_Eint1Isr
	.sym	_Eint1Isr,_Eint1Isr, 32, 2, 0
	.func	335

;***************************************************************
;* FUNCTION DEF: _Eint1Isr                                     *
;***************************************************************
_Eint1Isr:
	.line	1
        PSHM      AR1
        PSHM      ST0
        PSHM      ST1
        PSHM      PMST
        ANDM      #32063,*(ST1)
        ORM       #16384,*(ST1)
        ANDM      #-4,*(PMST)
        NOP
	.line	2
        MVDM      *(_McBSP1),AR1
        NOP
        ST        #14,*AR1(8)           ; |336| 
	.line	3
        MVDM      *(_McBSP1),AR1
        NOP
        ORM       #8,*AR1(9)            ; |337| 
	.line	4
        MVDM      *(_SREG),AR1
        NOP
        ST        #2,*AR1(1)            ; |338| 
	.line	5
        POPM      PMST
        POPM      ST1
        POPM      ST0
        POPM      AR1
        RETE
        ; branch occurs
	.endfunc	339,021800400h,4


	.sect	".text"
	.global	_Eint2Isr
	.sym	_Eint2Isr,_Eint2Isr, 32, 2, 0
	.func	341

;***************************************************************
;* FUNCTION DEF: _Eint2Isr                                     *
;***************************************************************
_Eint2Isr:
	.line	1
        PSHM      AR1
        PSHM      ST0
        PSHM      ST1
        PSHM      PMST
        ANDM      #32063,*(ST1)
        ORM       #16384,*(ST1)
        ANDM      #-4,*(PMST)
        NOP
	.line	2
        MVDM      *(_McBSP1),AR1
        NOP
        ST        #14,*AR1(8)           ; |342| 
	.line	3
        MVDM      *(_McBSP1),AR1
        NOP

⌨️ 快捷键说明

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