请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
器件型号:TM4C123GH6PM 主题中讨论的其他器件:TM4C123、
您好!
我正在查看我在 tm4c123平台上打印浮点值的选项。 我已将 printf 支持设置为完整版、并将堆栈大小设置为1024、但下面的语句:
sprintf(debug_buffer, "%f", 1.123f); UARTprintf("%s", debug_buffer); UARTprintf("\r\n");
在 sprintf 下崩溃。
我查看了 sensorhub 中的示例、并针对各种浮点打印目的实现了我自己的 Ftoa。 但我需要一种通用的方法来实现它、我在 GCC 中成功地使用它、但在 CCS 上遇到问题。
是否可以使用 CCS 在 tm4c123gh下午6点对 float 提供完整的 printf 支持、以及我需要打开什么?
此致、
CAN