This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] MSP430G2553-Q1:如何在 Code Composer Studio9.3.0.00012的项目中添加 stdio 支持?

Guru**** 2208020 points
Other Parts Discussed in Thread: MSP430G2553
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/msp-low-power-microcontrollers-group/msp430/f/msp-low-power-microcontroller-forum/1132851/msp430g2553-q1-how-to-add-stdio-support-in-project-from-code-composer-stuido9-3-0-00012

器件型号:MSP430G2553-Q1
主题中讨论的其他器件:MSP430G2553

尊敬的 TI

   要添加对 printf 或 sprintf 的支持、我必须在工程(BlinkLED 示例工程)中添加 stdio.h。

   下面是我已经执行的步骤:

   (1)添加#include ,并在 main.c 中添加代码:printf("Hello");

   (2)在菜单:project->property->build->MSP430 Linker->Basic 选项中将堆大小和堆栈大小设置为512

   (3)清理和构建

然后、错误显示为:

"./lnk_msp430g2553.cmd"、第90行:错误#10099-D:程序将无法装入可用内存。 对齐方式运行".bss"大小为0xAA 的定位失败。 可用存储器范围:
RAM 大小:0x200未使用:0x70最大孔:0x70
"./lnk_msp430g2553.cmd"、第91行:错误#10099-D:程序不能放入可用内存中。 对".data"大小为0xFC 运行定位失败。 可用存储器范围:
RAM 大小:0x200未使用:0x70最大孔:0x70
"./lnk_msp430g2553.cmd"、第100行:错误#10099-D:程序不能放入可用内存中。 对".CIO"大小为0x120的段运行定位失败。 可用存储器范围:

我阅读 了 MSP430优化 C/C++编译器 v21.6.0.LTS、在7.2.1章中、我阅读:  

cl430 main.c --run_linker --heap_size=400 --library=rts430_eabi.lib --output_file=main.out

我是否错过了项目配置中的某个内容? 情况紧急,请帮助我,谢谢。

BR

Johnson