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

📄 boot_img.asm

📁 DSP自带的USB2。0控制器
💻 ASM
字号:
;**********************************************************************************
;
;	File Name   : boot_img.asm
;     Project     : C55x Peripheral Test Program Suite
;	Author      : MH 
;
;	Version     : 1.1
;
;	Date        : 16 May 2001
; 	Update      : 
;
;	Description : Simple test code to test 5509 bootloader with even/odd
;                   start address and with even/odd section length. The code
;                   jumps through four sections in a loop and toggles the XF
;                   pin to inidate the coe section being executed
;                   
;**********************************************************************************
            .mmregs
            
            .C54CM_off
            .CPL_off
            .ARMS_off

            .def   start


;**********************************************************************************
;     Allocate sections for stacks
;**********************************************************************************

stk_len     .set     100h
STACK       .usect   "stack",  stk_len
SSTACK      .usect   "sstack", stk_len

;**********************************************************************************

            .sect    ".sec1"

start:

    AMOV    #(STACK + stk_len), XSP         ; setup stack
    MOV     #(SSTACK + stk_len), SSP        ; and system stack pointer
    
    BCLR    C54CM
    BSET    FRCT
    BCLR    SXMD
    BSET    SATA
    BSET    SMUL
    BCLR    XF                              ; clear xf
    MOV     #8, CSR                         ; load single instr repeat count

;**********************************************************************************
;    toggle xf 1 time
;**********************************************************************************

L1: RPT     CSR
    NOP
    BSET    XF
    NOP
    BCLR    XF
    B       L2                              ; go to sec2
    
idle1:
    B       idle1    
    
;**********************************************************************************
;    toggle xf 2 times
;**********************************************************************************

            .sect    ".sec2"

L2: RPT     CSR
    NOP
    MOV     #1, BRC0                         ; load blk instr repeat count 
    RPTBLOCAL  L3
    BSET    XF
    NOP
    BCLR    XF
L3: NOP        
    B       L4                               ; go to sec3
    
idle2:
    B       idle2
    
;**********************************************************************************
;    toggle xf 3 times
;**********************************************************************************

            .sect    ".sec3"

L4: RPT     CSR
    NOP
    NOP
    MOV     #2, BRC0                          ; load blk instr repeat count 
    RPTBLOCAL  L5
    BSET    XF
    NOP
    BCLR    XF
L5: NOP        
    B       L6                               ; go to sec4
    
idle3:
    B       idle3    
    
;**********************************************************************************
;    toggle xf 4 times
;**********************************************************************************

            .sect    ".sec4"

L6: RPT     CSR
    NOP
    MOV     #3, BRC0                          ; load blk instr repeat count 
    RPTBLOCAL  L7
    BSET    XF
    NOP
    BCLR    XF
L7: NOP        
    B       L1                                ; go back to sec1 
    
idle4:
    B       idle4

⌨️ 快捷键说明

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