c2000 lf2401a 想用ldiv()函数 cmd文件怎么写
#include "stdlib.h"
void main(void) {
double an=2.0,bn=-10.0,cn=3.0; div_t result = div(an,bn); }
编译 No Errors, 1 Warning
dsplnk example_c.mak TMS320C1x/C2x/C2xx/C5x COFF Linker Version 7.00 Copyright (c) 1987-1999 Texas Instruments Incorporated
>> cannot allocate .text in EXT_PROG (page 0) >> errors in input - example_c.out not built Build Complete, 2 Errors, 1 Warnings.
无法通过.
.cmd文件是否有问题:
-stack 50h
MEMORY { PAGE 0: /* Program Memory */ VECS: org=0h, len=40h /* external SRAM */ EXT_PROG: org=44h len=0FBCh /* external SRAM */ EXTPROG: org=08000h, len=00200h /* external SRAM */ PAGE 1: /* Data Memory */ B2: org=60h, len=20h /* internal DARAM */ B1: org=300h, len=100h /* internal DARAM */ B0: org=200h, len=100h /* internal DARAM */ ExtRam : origin = 0x800, length = 0x200 }
SECTIONS { .text > EXT_PROG PAGE 0 .cinit > EXT_PROG PAGE 0 .switch > EXT_PROG PAGE 0
.const > B0 PAGE 1 .bss > B0 PAGE 1 .stack > B1 PAGE 1 .sysmem > B0 PAGE 1
vectors > VECS PAGE 0 .data > B1 PAGE 1
}
|