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.

[参考译文] TMS320F28235:在 F28235#39;s 源 OCDE 上将一些浮点定义更改为定点浮点定义是否存在任何问题?

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

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/724531/tms320f28235-are-there-any-problem-by-changing-some-float-definition-to-fixed-one-on-f28235-s-source-ocde

器件型号:TMS320F28235
主题中讨论的其他器件:C2000WARE

您好专家、

我的客户正在使用 F28235。 由于此内核是定点的、因此不应使用它们更改了源代码中"float"的内容。

我想让你们看看其中是否有任何风险。

第一个更改:C:\ti\c2000Ware_1_00_05_00\device_support\F2823x\con\source\DSP2823x_CpuTimers.c

将下面 API 中的"float"改为"UINT32"。

ConfigCpuTimer (struct CPUTIME_VARS *定时器、浮点频率、浮点周期)

第二个更改:C:\ti\c2000\C2000Ware_1_00_05_00\device_support\F2823x\headers\include\DSP2823x_CpuTimers.h

将结构 CPUTIME_VARS 中的"float"更改为"UINT32"。

struct CPUTIME_VARS{
   volatile struct CPUTIME_regs *寄存器 Addr;
   uint32   InterruptCount;
   浮点  CPUFreqInMHz;
   浮点  PeriodInUSec;
};

谢谢!

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。
    您好,

    看起来不错。
    只有这样做才会限制可馈入 ConfigCpuTimer() API 的值范围。
    只能设置整数 CPU 频率和周期。

    此致。