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.

[参考译文] TMS320F2.8377万S:为什么即使在包含stdint.h之后,我仍然收到未定义uint8_t的错误消息?

Guru**** 2568585 points


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

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/640835/tms320f28377s-why-do-i-still-get-an-error-message-that-uint8_t-is-undefined-even-after-i-have-included-stdint-h

部件号:TMS320F2.8377万S

为什么在包含stdint.h后仍会收到错误消息,指出uint8_t未定义?

#include "stdint.h"

UINT8_t数据= 0;

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

    您好,Kevin:

    如果打开stdint.h文件,您将了解uint8_t不是受支持的类型。 原因是在C2000 MCU中,16位是最小字长度。 因此,即使包含stdint.h,也不会找到uint8_t的定义 可以使用uint16_t代替uint8_t

    希望这有所帮助

    Ritvik

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

    如果您认为您的问题已解决,请将答案标记为已解决。

    谢谢
    Ritvik