TMS320f2802最简汇编模板

1 楼
大家好!新人报道!
刚上传两个关于TMS320f2802最简汇编模板的文件,如有需要,请下载,不要豆币的哦!
2017-05-18 14:19:47
gegewu_005
2 楼
回复:1楼
无语,上传的文档竟然没有通过审核!
2017-05-18 14:32:35
gegewu_005
3 楼

MEMORY
{
PAGE 0: /* Program Memory */
/* Memory (RAM/FLASH/OTP) blocks can be moved to PAGE1 for data allocation */

RAML0 : origin = 0x008000, length = 0x001000 /* on-chip RAM block L0 */
OTP : origin = 0x3D7800, length = 0x000400 /* on-chip OTP */
FLASHD : origin = 0x3F0000, length = 0x002000 /* on-chip FLASH */
FLASHC : origin = 0x3F2000, length = 0x002000 /* on-chip FLASH */
FLASHA : origin = 0x3F6000, length = 0x001F80 /* on-chip FLASH */
CSM_RSVD : origin = 0x3F7F80, length = 0x000076 /* Part of FLASHA. Program with all 0x0000 when CSM is in use. */
BEGIN : origin = 0x3F7FF6, length = 0x000002 /* Part of FLASHA. Used for "boot to Flash" bootloader mode. */
CSM_PWL : origin = 0x3F7FF8, length = 0x000008 /* Part of FLASHA. CSM password locations in FLASHA */
ROM : origin = 0x3FF000, length = 0x000FC0 /* Boot ROM */
RESET : origin = 0x3FFFC0, length = 0x000002 /* part of boot ROM */
VECTORS : origin = 0x3FFFC2, length = 0x00003E /* part of boot ROM */

PAGE 1 : /* Data Memory */
/* Memory (RAM/FLASH/OTP) blocks can be moved to PAGE0 for program allocation */
/* Registers remain on PAGE1 */

RAMM0 : origin = 0x000000, length = 0x000400 /* on-chip RAM block M0 */
BOOT_RSVD : origin = 0x000400, length = 0x000080 /* Part of M1, BOOT rom will use this for stack */
RAMM1 : origin = 0x000480, length = 0x000380 /* on-chip RAM block M1 */
FLASHB : origin = 0x3F4000, length = 0x002000 /* on-chip FLASH */
}

/* Allocate sections to memory blocks.
Note:
codestart DSP28_CodeStartBranch.asm涓殑鐢ㄦ埛瀹氫箟閮ㄥ垎鐢ㄤ簬鍦ㄥ紩瀵煎埌闂瓨鏃堕噸瀹氬悜浠g爜鎵цramfuncs鐢ㄦ埛瀹氫箟閮ㄥ垎瀛樺偍灏嗕粠闂瓨澶嶅埗鍒癛AM鐨勫嚱鏁�
*/
SECTIONS
{
/* Allocate program areas: */
.cinit : > FLASHA PAGE = 0
.pinit : > FLASHA, PAGE = 0
.text : > FLASHD PAGE = 0
codestart : > BEGIN PAGE = 0
ramfuncs : LOAD = FLASHD,
RUN = RAML0,
LOAD_START(_RamfuncsLoadStart),
LOAD_END(_RamfuncsLoadEnd),
RUN_START(_RamfuncsRunStart),
PAGE = 0

csmpasswds : > CSM_PWL PAGE = 0
csm_rsvd : > CSM_RSVD PAGE = 0
/* Allocate uninitalized data sections: */
.stack : > RAMM0 PAGE = 1
.ebss : > RAMM1 PAGE = 1
.esysmem : > RAMM1 PAGE = 1

/* Initalized sections go in Flash */
/* For SDFlash to program these, they must be allocated to page 0 */
.econst : > FLASHA PAGE = 0
.switch : > FLASHA PAGE = 0

/* Allocate IQ math areas: */
IQmath : > FLASHC PAGE = 0 /* Math Code */
IQmathTables : > ROM PAGE = 0, TYPE = NOLOAD /* Math Tables In ROM */

/* .reset is a standard section used by the compiler. It contains the */
/* the address of the start of _c_int00 for C Code. /*
/* When using the boot ROM this section and the CPU vector */
/* table is not needed. Thus the default type is set here to */
/* DSECT */
.reset : > RESET, PAGE = 0, TYPE = DSECT
vectors : > VECTORS PAGE = 0, TYPE = DSECT

}

/*
//===========================================================================
// End of file.
//===========================================================================
*/

2017-05-18 14:38:55
gegewu_005
4 楼
.global _c_int00
.sect .reset
.text
_c_int00:
SETC OBJMODE ;设置为TMS320F28x模式
MOVZ DP, #0x1c0 ;DP.[9,0]=448;DP.[15,10]=0
MOV @0x29, #0x0068 ;
EDIS ;禁止访问受保护的寄存器
LB 0x3f3604 ;跳转到
MOVL XAR4, #0x000c00

my_loop:
LB my_loop

2017-05-18 14:39:08