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.

EMIF16问题

各位大虾,我想通过EMIF16将外接FPGA输出的信号传给DSP,但是以前没用到过EMIF,虽然看了一些资料但是还是没有太多头绪,请问下能不能提供个EMIF的例程?万分感谢!!!

  • C66X EMIF测试例程:http://www.deyisupport.com/question_answer/dsp_arm/c6000_multicore/f/53/t/6242.aspx

  • 你好Andy Yin,

    我试了一下你提供的例程,编译之后出现了跟原帖一样的问题.

    Description Resource Path Location Type
    identifier "CSL_EMIF16_AWCCR_CE0WAIT_MASK" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 117 C/C++ Problem
    identifier "CSL_EMIF16_AWCCR_CE0WAIT_SHIFT" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 117 C/C++ Problem
    identifier "CSL_EMIF16_CFG_REGS" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 23 C/C++ Problem
    identifier "CSL_EMIF16_NANDFCTL_CE0NAND_MASK" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 132 C/C++ Problem
    identifier "CSL_EMIF16_NANDFCTL_CE0NAND_SHIFT" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 132 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGDEL_MASK" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 124 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGDEL_SHIFT" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 124 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGMDEN_MASK" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 126 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGMDEN_SHIFT" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 126 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGSIZE_MASK" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 125 C/C++ Problem
    identifier "CSL_EMIF16_PMCR_CE0PGSIZE_SHIFT" is undefined KeyStone_EMIF16_Init.c /EMIF/common line 125 C/C++ Problem
    identifier "CSL_PSC_LPSC_VUSR" is undefined KeyStone_HyperLink_Init.c /EMIF/common line 43 C/C++ Problem
    identifier "CSL_PSC_LPSC_VUSR" is undefined KeyStone_HyperLink_Init.c /EMIF/common line 116 C/C++ Problem

  • 如原帖所说,该例程是基于C6614,如果使用C6678的话,两者底层CSL的一些宏定义不一样,你需要在C6678 CSL中找到相应的宏替代。

  • Andy Yin1你好,

    我将csl宏定义更正,现在这部分没报错了(我将CE0改成CS2,这样对应正确么?比如CSL_EMIF16_AWCCR_CE0WAIT_SHIFT改成CSL_EMIF16_AWCCR_CS2WAIT_SHIFT,另外其他参数比如程序中的i也需要改么?)

    现在我的程序仍有错误,如下所示

    Description Resource Path Location Type
    identifier "DEVICE_EMIF_NAND_ALE_OFFSET" is undefined flash_nand.c /EMIF/src/FLASH line 456 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_CLE_OFFSET" is undefined flash_nand.c /EMIF/src/FLASH line 451 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_DATA_OFFSET" is undefined flash_nand.c /EMIF/src/FLASH line 465 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_DATA_OFFSET" is undefined flash_nand.c /EMIF/src/FLASH line 507 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_DATA_OFFSET" is undefined flash_nand.c /EMIF/src/FLASH line 526 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_TIMEOUT" is undefined flash_nand.c /EMIF/src/FLASH line 122 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_TIMEOUT" is undefined flash_nand.c /EMIF/src/FLASH line 149 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_TIMEOUT" is undefined flash_nand.c /EMIF/src/FLASH line 285 C/C++ Problem
    identifier "DEVICE_EMIF_NAND_TIMEOUT" is undefined flash_nand.c /EMIF/src/FLASH line 377 C/C++ Problem
    struct "<unnamed>" has no field "NFECCCE0" flash_nand.c /EMIF/src/FLASH line 615 C/C++ Problem

    但是比如我去源码中找,比如第一个提示错误NAND_ALE_OFFSET,因为调用了flash_nand.h, 所以是定义了的,能直接跳到

    #define NAND_ALE_OFFSET     DEVICE_EMIF_NAND_ALE_OFFSET, 但是为什么还会提示错误?

    谢谢解答。