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.

[参考译文] TMS320F2800156-Q1:写入操作时的 Fashapi 问题

Guru**** 2484615 points
Other Parts Discussed in Thread: C2000WARE

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

https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/1440929/tms320f2800156-q1-fashapi-issue-with-write-operation

器件型号:TMS320F2800156-Q1
Thread 中讨论的其他器件:C2000WARE

工具与软件:

你(们)好

我们使用 F280015x 进行产品开发。

我们需要执行闪存写入操作。 但是、FlashAPI 有问题。

需要写入的数据是在 RAM 中分配的、其中地址以奇数开头、例如0x9001。 (数据地址、而不是闪存扇区地址、闪存地址为 Bzero_Sector 117_start  0x0009D400U)

奇怪的是,它会将起始地址为0x9000的数据写入闪存扇区。

对此问题的任何建议?

下面是闪存写入函数:

地址为0x9d400、pbuffer 的地址为0x8d77、uLength 为1。

#pragma CODE_SECTION(Flash_Write, ".TI.ramfunc")
void Flash_Write(uint32_t Address, uint16_t* pBuffer, uint16_t uLength)
{
    uint32 u32Index = 0;
    uint16_t i = 0;
    uint16_t uRetryCnt = 0;
    Fapi_StatusType  oReturnCheck = Fapi_Status_Success;
    Fapi_FlashStatusType  oFlashStatus;
//    Fapi_FlashStatusWordType  oFlashStatusWord;

    //
    // Program data using "DataOnly" option and ECC using "EccOnly" option.
    //
    // When DataOnly option is used, Flash API will program only the data
    // portion in Flash at the address specified.
    //

此致

箭头

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

    您好 Arrow、

    数据地址应采用128位对齐方式。 使用 align (8)指令或参考 c2000ware 中的示例代码。

    谢谢、此致、

    Rajeshwary