用LPC2134做的程序,需要分散加载,以下两种方式都是参考书上写的,但都有问题,请周工祥解,多谢!
ROM_LOAD 0x00000000 { ROM_EXEC 0x00000000 { Startup.o (vectors, +First) *.o (+RO) }
IRAM 0x40000000 { Startup.o (MyStacks) * (+RW,+ZI) }
HEAP +0 UNINIT { Startup.o (Heap) }
STACKS 0x40004000 UNINIT { Startup.o (Stacks) }
ROM_DATA1 0x00008000 { flash.o (+RO)
}
ROM_DATA2 0x00010000 { maincheck.o(+RO) ourCommand.o(+RO) command.o(+RO) }
} 这个加载文件可以编译通过,但执行时出现,取数据终止;
另外的方式写的加载文件编译时出错 ROM_LOAD1 0x00008000 { ROM_DATA1 0x00008000 { flash.o (+RO)
}
}
ROM_LOAD2 0x00010000 { ROM_DATA2 0x00010000 { maincheck.o(+RO) ourCommand.o(+RO) command.o(+RO) }
}
ROM_LOAD 0x00000000 { ROM_EXEC 0x00000000 { Startup.o (vectors, +First) *.o (+RO) }
IRAM 0x40000000 { Startup.o (MyStacks) * (+RW,+ZI) }
HEAP +0 UNINIT { Startup.o (Heap) }
STACKS 0x40004000 UNINIT { Startup.o (Stacks) }
}
|