500) {this.resized=true; this.width=500; this.alt='这是一张缩略图,点击可放大。\n按住CTRL,滚动鼠标滚轮可自由缩放';this.style.cursor='hand'}" onclick="if(!this.resized) {return true;} else {window.open('http://u.dianyuan.com/bbs/u/70/414871223522103.jpg?x-oss-process=image/watermark,g_center,image_YXJ0aWNsZS9wdWJsaWMvd2F0ZXJtYXJrLnBuZz94LW9zcy1wcm9jZXNzPWltYWdlL3Jlc2l6ZSxQXzQwCg,t_20');}" onmousewheel="return imgzoom(this);">
板子是TI的2407,上面的截图是load program时弹出的提示框,cmd文件的page 0如下:
PAGE 0 : VECS : origin =0h , length =40h /* VECTORS */
PVECS : origin =40h, length =70h
PROG : origin = 1010h , length = 6000h
开始烧不进去,提示0x1000h处有问题,于是小弟把prog的起始地址改为0x1010h,希望能略过有问题的地址,改后如上图,还是提示这个地址有问题.
请教高手,如何解决,谢谢
[求助] 2407载入程序的问题
全部回复(7)
正序查看
倒序查看
现在还没有回复呢,说说你的想法
@namin
高手帮忙啊
供参考
MEMORY
{
PAGE 0 : VECS : origin =8000h , length = 0040h /* PROGRAM */
PVECS : origin =8044h , length = 0100h /* Peripheral Interrupt Vectors */
PROG : origin = 8144h , length = 0500h
/* FLASH on Chip*/
PAGE 1 : MMRS : origin = 0000h ,length = 005Fh /* MMRS*/
B2 : origin = 0060h ,length = 0020h/* DARAM B2 BLOCK*/
B01 : origin = 0200h ,length = 0080h/* DARAM B0 BLOCK*/
B02 : origin = 0280h ,length = 0080h
B11 : origin = 0300h ,length = 0080h/* DARAM B1 BLOCK*/
B12 : origin = 0380h ,length = 0080h
SARAM1 : origin = 0800h ,length = 0080h/* SARAM BLOCK*/
SARAM3 : origin = 0900h ,length = 0100h/* SARAM BLOCK*/
SARAM5 : origin = 0A00h ,length = 0200h/* SARAM BLOCK*/
SARAM7 : origin = 0C00h ,length = 0080h/* SARAM BLOCK*/
SARAM9 : origin = 0D00h ,length = 0300h/* SARAM BLOCK*/
}
MEMORY
{
PAGE 0 : VECS : origin =8000h , length = 0040h /* PROGRAM */
PVECS : origin =8044h , length = 0100h /* Peripheral Interrupt Vectors */
PROG : origin = 8144h , length = 0500h
/* FLASH on Chip*/
PAGE 1 : MMRS : origin = 0000h ,length = 005Fh /* MMRS*/
B2 : origin = 0060h ,length = 0020h/* DARAM B2 BLOCK*/
B01 : origin = 0200h ,length = 0080h/* DARAM B0 BLOCK*/
B02 : origin = 0280h ,length = 0080h
B11 : origin = 0300h ,length = 0080h/* DARAM B1 BLOCK*/
B12 : origin = 0380h ,length = 0080h
SARAM1 : origin = 0800h ,length = 0080h/* SARAM BLOCK*/
SARAM3 : origin = 0900h ,length = 0100h/* SARAM BLOCK*/
SARAM5 : origin = 0A00h ,length = 0200h/* SARAM BLOCK*/
SARAM7 : origin = 0C00h ,length = 0080h/* SARAM BLOCK*/
SARAM9 : origin = 0D00h ,length = 0300h/* SARAM BLOCK*/
}
0
回复
提示
@yangzhouxia
供参考MEMORY{PAGE0:VECS:origin=8000h,length=0040h/*PROGRAM*/PVECS:origin=8044h,length=0100h /*PeripheralInterruptVectors*/PROG:origin=8144h,length=0500h/*FLASHonChip*/PAGE1:MMRS:origin=0000h,length=005Fh/*MMRS*/B2:origin=0060h,length=0020h/*DARAMB2BLOCK*/B01:origin=0200h,length=0080h/*DARAMB0BLOCK*/B02:origin=0280h,length=0080hB11:origin=0300h,length=0080h/*DARAMB1BLOCK*/B12:origin=0380h,length=0080hSARAM1:origin=0800h,length=0080h/*SARAMBLOCK*/SARAM3:origin=0900h,length=0100h/*SARAMBLOCK*/SARAM5:origin=0A00h,length=0200h/*SARAMBLOCK*/SARAM7:origin=0C00h,length=0080h/*SARAMBLOCK*/SARAM9:origin=0D00h,length=0300h/*SARAMBLOCK*/}
请教一下
你的cmd 是不是使用的外部存储器?
现在我想用外部存储器,原来的cmd文件是
MEMORY
{
PAGE 0 : VECS : origin = 0h , length = 40h /* 程序复位 */
PVECS: origin = 44h , length = 70h /* 外围模块中断向量 */
PROG : origin = 1000h , length = 6000h
PAGE 1 : MMRS : origin = 0h , length = 060h
B2 : origin = 0060h , length = 020h
B0B1 : origin = 0200h , length = 200h
SARAM : origin = 800h , length = 800 h
}
SECTIONS
{
.reset : { } > VECS PAGE 0 /* 复位中断向量表 */
.vectors : { } > VECS PAGE 0 /* 中断向量表 */
.pvecs : { } > PVECS PAGE 0 /* 外围模块中断向量表 */
.text : { } > PROG PAGE 0 /* 代码 */
.switch : { } > PROG PAGE 0
.data : { } > PROG PAGE 0
.cinit : { } > PROG PAGE 0
.const : { } > SARAM PAGE 1
.bss : { } > SARAM PAGE 1 /* 块 B2 */
.stack : { } > SARAM PAGE 1 /* 堆栈-40个单元 */
.sysmem : { } > SARAM PAGE 1
.reg240x : { } > MMRS PAGE 1
.firldb : { } > B0B1 PAGE 1
.firfilt : { } > SARAM PAGE 1
.fircoef : { } > SARAM PAGE 1
}
我把page0 的 PROG的起始地址改为 8000h,然后编译可以通过,运行不出波形.
对cmd还不是很明白,请高手指点
你的cmd 是不是使用的外部存储器?
现在我想用外部存储器,原来的cmd文件是
MEMORY
{
PAGE 0 : VECS : origin = 0h , length = 40h /* 程序复位 */
PVECS: origin = 44h , length = 70h /* 外围模块中断向量 */
PROG : origin = 1000h , length = 6000h
PAGE 1 : MMRS : origin = 0h , length = 060h
B2 : origin = 0060h , length = 020h
B0B1 : origin = 0200h , length = 200h
SARAM : origin = 800h , length = 800 h
}
SECTIONS
{
.reset : { } > VECS PAGE 0 /* 复位中断向量表 */
.vectors : { } > VECS PAGE 0 /* 中断向量表 */
.pvecs : { } > PVECS PAGE 0 /* 外围模块中断向量表 */
.text : { } > PROG PAGE 0 /* 代码 */
.switch : { } > PROG PAGE 0
.data : { } > PROG PAGE 0
.cinit : { } > PROG PAGE 0
.const : { } > SARAM PAGE 1
.bss : { } > SARAM PAGE 1 /* 块 B2 */
.stack : { } > SARAM PAGE 1 /* 堆栈-40个单元 */
.sysmem : { } > SARAM PAGE 1
.reg240x : { } > MMRS PAGE 1
.firldb : { } > B0B1 PAGE 1
.firfilt : { } > SARAM PAGE 1
.fircoef : { } > SARAM PAGE 1
}
我把page0 的 PROG的起始地址改为 8000h,然后编译可以通过,运行不出波形.
对cmd还不是很明白,请高手指点
0
回复
提示
@namin
请教一下你的cmd是不是使用的外部存储器?现在我想用外部存储器,原来的cmd文件是MEMORY{PAGE0: VECS:origin=0h,length=40h /* 程序复位*/PVECS:origin= 44h,length=70h /*外围模块中断向量*/PROG:origin=1000h,length=6000hPAGE1: MMRS:origin=0h,length=060h B2:origin=0060h,length= 020h B0B1:origin=0200h,length= 200h SARAM:origin=800h,length= 800h }SECTIONS{ .reset :{}>VECS PAGE0/*复位中断向量表*/ .vectors:{}>VECS PAGE0/*中断向量表*/ .pvecs :{}>PVECS PAGE0/*外围模块中断向量表*/ .text :{}>PROG PAGE0/*代码*/ .switch :{}>PROG PAGE0 .data :{}>PROG PAGE0 .cinit :{}>PROG PAGE0 .const :{}>SARAM PAGE1 .bss :{}>SARAM PAGE1/*块B2*/ .stack :{}>SARAM PAGE1/*堆栈-40个单元*/ .sysmem :{}>SARAM PAGE1 .reg240x:{}>MMRS PAGE1 .firldb :{}>B0B1 PAGE1 .firfilt:{}>SARAM PAGE1 .fircoef:{}>SARAM PAGE1}我把page0的PROG的起始地址改为8000h,然后编译可以通过,运行不出波形.对cmd还不是很明白,请高手指点
在使用外部存储器做仿真使用时,CMD文件不需要改变.和烧录FLASH 的CMD 用的是同一个
0
回复
提示