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.

Testing External Memory

Other Parts Discussed in Thread: CCSTUDIO

I have a 6713dsk and would like to write a program to test the external memory.

Has anyone done this before?

How do I access the external memory? Do I have to configure the EMIF first, or can I just write tomemory using a pointer?

I have some ideas about algorithms to use, I just need help getting started.

Thanks

Lester

  • There is an app note on the Power-On Self Test which comes burned into the C6713/C6416 DSKs. This tests many of the features on the board including the external memory.

    You will definitely need to program the EMIF before attempting to communicate with the memory. Once configured, the test could be something as simple as a pointer.

  • I'm reading the docs on setting up the EMIF and the PLL's etc. Is there a document somewhere that shows what all needs to be done to get the chip up and running. Also is there any example code for the Pll's, EMIF, etc?

     

  • If you have the DS6713 Board Support package (it comes on a CD with the DSK) you should actually already have a POST project. By default it would be in the \examples\dsk6713\bsl\post folder.

    Additionally you can find some PLL/EMIF configuration code in the GEL file (\cc\gel folder).

  • Thanks, I did not see the post folder, I have been in the tutorials, not the examples.

    I tried to build the post example and it failed. The output is below, any ideas?

    ------------------------------  post.pjt - Debug  ------------------------------
    [post.tcf] "C:\CCStudio_v3.3\bios_5_31_02\xdctools\tconf" -b -Dconfig.importPath="C:/CCStudio_v3.3/bios_5_31_02/packages"  post.tcf

    [boot.asm] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -g -q -fr"./Debug" -i"." -i"C:/CCStudio_v3.3/c6000/dsk6713/include" -d"_DEBUG" -d"CHIP_6713" -ml3 -ms3 -mv6710 -@"Debug.lkf" "boot.asm"

    [post.c] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -g -q -fr"./Debug" -i"." -i"C:/CCStudio_v3.3/c6000/dsk6713/include" -d"_DEBUG" -d"CHIP_6713" -ml3 -ms3 -mv6710 -@"Debug.lkf" "post.c"

    [postcfg.s62] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -g -q -fr"./Debug" -i"." -i"C:/CCStudio_v3.3/c6000/dsk6713/include" -d"_DEBUG" -d"CHIP_6713" -ml3 -ms3 -mv6710 -@"Debug.lkf" "postcfg.s62"

    [postcfg_c.c] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -g -q -fr"./Debug" -i"." -i"C:/CCStudio_v3.3/c6000/dsk6713/include" -d"_DEBUG" -d"CHIP_6713" -ml3 -ms3 -mv6710 -@"Debug.lkf" "postcfg_c.c"

    [Linking...] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -@"Debug.lkf"
    <Linking>

    undefined                        first referenced
     symbol                              in file
    ---------                        ----------------
    _IRQ_clear                       C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_read                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _IRQ_disable                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _TIMER_close                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_close                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _EDMA_config                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _TIMER_getEventId                C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _TIMER_open                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_open                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _EDMA_close                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _EDMA_open                       C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _TIMER_start                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_start                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_rrdy                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _IRQ_globalEnable                C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _IRQ_globalDisable               C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _EDMA_intTest                    C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _IRQ_map                         C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _TIMER_config                    C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_config                    C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_xrdy                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _MCBSP_write                     C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    _IRQ_enable                      C:\\CCStudio_v3.3\\examples\\dsk6713\\bsl\\post\\Debug\\post.obj
    >>   error: symbol referencing errors - './Debug/post.out' not built

    >> Compilation failure

    Build Complete,
      2 Errors, 0 Warnings, 0 Remarks.

  • Sure, this should be an easy one :)

    All of these symbols are part of the Chip Support Library. BIOS 4.90.xx actually included CSL support inside the GUI. This was dropped in BIOS 5.xx due to a number of problems (both functional and scalable) so you need to add it manually to your project. To do this simply add the csl6713.lib to your project (\c6000\csl\lib).

  • Thanks, I added the csldm713.lib and now it works. I'm looking through the code and trying to see where the EMIF and PLL's are set up. There is a call to "DSK6713_init" and I see that in the .h file but I can;t find the source for it. Is this where the setup occurs, or is it done in the post.tcf file?

    A note in the code says to see the "6713 DSK help file under Software/Examples" where can I find the help file? The CCS help file has a doc on the tutorials, but not the examples.

  • This is DSK BSL stuff. It all comes in the Board Support Package provided from Spectrum Digital. This should have been part of the install that comes on the CD you get with the DSK.

    lester davis said:
    A note in the code says to see the "6713 DSK help file under Software/Examples" where can I find the help file? The CCS help file has a doc on the tutorials, but not the examples.
    I am not sure about this. This may be on the CD as well so I would try checking there.

  • I finally found the help file, but it is not any help. It just has a very brief description of what the program does. It has no details at all. I'm still trying tofigure out how the EMIF and PLL's get set up.

  • lester davis said:
    I finally found the help file, but it is not any help. It just has a very brief description of what the program does. It has no details at all. I'm still trying tofigure out how the EMIF and PLL's get set up.

    Inside post.c the main function calls DSK6713_init() which initializes the EMIF and PLL. This function is found inside the dsk6713.c file which is a part of the BSL. Look in the \C6000\dsk6713\lib\dsk6713bsl folder.

  • Thanks, that is what I'm looking for.

     

  • How do I get output to stdout?

    I have #include <stdio.h>

    and in

    main()
    {
    //    puts("post example started\n");
        printf("post example started\n");
        DSK6713_init();
        /* Set initial LED state */

    ...

    but neither puts or printf seems to work. Is there something else I need to setup?

    I'm looking at the hello1 tutorial and I don't see them doing anything else.

     

    Thanks

     

     

  • Make sure that you have included the RTS library and that your stack and heap sizes are sufficiently large. If not using DSP/BIOS you can configure stack/heap either in the Project->Build Options or inside the linker command file.

  • If I add rts6700.lib to the project I get

    [Linking...] "C:\CCStudio_v3.3\C6000\cgtools\bin\cl6x" -@"Debug.lkf"
    <Linking>
    >>   error: symbol _c_int00 is defined multiple times: boot.obj
                (C:\\CCStudio_v3.3\\C6000\\cgtools\\lib\\rts6700.lib) and boot.o67
                (C:/CCStudio_v3.3/bios_5_31_02/packages/ti/bios/lib/bios.a67)
    >>   error: symbol __stack is defined multiple times: boot.obj
                (C:\\CCStudio_v3.3\\C6000\\cgtools\\lib\\rts6700.lib) and boot.o67
                (C:/CCStudio_v3.3/bios_5_31_02/packages/ti/bios/lib/bios.a67)
    >>   error: errors in input - ./Debug/post.out not built

    >> Compilation failure

    Build Complete,
      4 Errors, 0 Warnings, 0 Remarks.

     

    I tried searching for c_int00 to see if I could tell where it was duplicated but it is not in source code.

    Any ideas?

     

    Searching for 'c_int00'...
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\cc_build_Debug.log ...
    Line 14:    >>   error: symbol _c_int00 is defined multiple times: boot.obj
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\post.cdb ...
    Line 689:        prop _cint00Str :: "-u_c_int00 %24t/* link with alternate boot.obj */%0t\n"
    Line 3967:        param function :: @_c_int00
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\post.cdb.Fri_Dec_19_16.03.29_2008 ...
    Line 663:        prop _cint00Str :: "-u_c_int00 %24t/* link with alternate boot.obj */%0t\n"
    Line 3649:        param function :: @_c_int00
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\postcfg.h62 ...
    Line 38:        .global    _c_int00
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\postcfg.s62 ...
    Line 560:        .asg _c_int00, _function
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\TEMPtcf60A.cdb ...
    Line 689:        prop _cint00Str :: "-u_c_int00 %24t/* link with alternate boot.obj */%0t\n"
    Line 3967:        param function :: @_c_int00
    In file C:\CCStudio_v3.3\examples\dsk6713\bsl\post_Ringo\Debug\postcfg.obj ...
    Line 58:   
    10 occurrence(s) have been found.

  • c_int00 is included in the RTS. If you are getting multiple definition errors you probably have the RTS included elsewhere. Check the build options or the command file for something like "-l rts6700.lib"

  • The postcfg.cmd file has -lrts6700.lib in it so I'm assuming that is the duplicate def problem.

    As far as the stdout not working, I'm using dsp/bios and looking at the mem options. The Stack size (MAUUs) is set to 0x0400 and "No dynamic Heaps"  is checked. Is this correct? what should the settings be?

    Thanks

  • lester davis said:

    As far as the stdout not working, I'm using dsp/bios and looking at the mem options. The Stack size (MAUUs) is set to 0x0400 and "No dynamic Heaps"  is checked. Is this correct? what should the settings be?

    You will need a Dynamic Heap.  Please uncheck the "No dynamic Heap" option in the MEM - Memory Section Manager Properties.
    You will then need to highlight a memory region, such as SDRAM and open its properties.
    Check "create a heap in this memory" and click OK.
    Go back to MEM - Memory Section Memory Properties and choose SDRAM for "Segment For malloc() / free()" and for "Segment For DSP/BIOS Objects" and click OK.

    EDIT : added choose SDRAM for "Segment For DSP/BIOS Objects" requirement.