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.

Getting NDK to work on a OAMPL137

Other Parts Discussed in Thread: OMAP-L138, OMAP-L137, TMS320C6748, OMAPL138, SYSBIOS, CCSTUDIO

Hi,

     I'm trying to use a Spectrum Digital OMAP-L137 eval board to get the DSP to run some older code and have the ARM collect Ethernet data via NDK and pass data to the DSP. From the descriptions of the latest NDK, I need NSP for the EMAC drivers, but the latest NSP only covers evmOMAPL138 and evm6748 platforms. The download page also says that "For all other devices (DM6437, C6747, OMAPL137, DM648, C6455, etc.) please check the device web page for NSP (Ethernet driver package) updates or download the driver from the NDK 2.00 full package." The NDK 2.00 has a sub-directory of packages\ndk\src\hal\evmomapl137 with source in it but this leads to more questions.

  • Is the HAL layer of the 2.00 release of the 137 the equivalent to the NSP of the 138 in release 2.20?
  • Can I get the ARM side of the OMAPL137 to run the latest NDK and if so how?

Here is my setup:

Code Composer Studio Version: 5.1.0.09000

XDCtools 3.23.00.32

SYS BIOS 6.33.1.25

IPC 1.23.5.40

NDK 2.20.6.35

NDK Network Support 1.10.0.03

XDAIS 7.21.1.07

Any help or examples would be greatly appreciated.

Thanks,

      John C.

  • Looking at the NDK release 2.0, the hal source (/packages/ti/ndk/src/hal/evmomapl137) file ethdriver.c is using DSP interrupts, and mentions the EMAC which seems to normally be connected to the DSP. So from this I can only assume that the original NDK was only done on the DSP side and not the ARM. Going forward into the newest release of NDK seems to need support of NSP specific to the processor/core(dsp/arm).
    Are there no driver/NSP support for the ARM side of the L137 for the later versions of NDK? If there is none then I need to move on and find a different processor.
    Thanks,
          John C.

  • John,

    Unfortunately we do not have a NSP for the ARM side of the omap-l137. We do have an NSP for the ARM side for the omap-l138. We do have a Linux EMAC driver for the ARM side of the omap-l137.

    Todd

  • Todd,

            Thank you much. Would you have any recommendations on L138 eval boards that would fit with what we are doing? Here is a short list:

    • SYS/BIOS on the DSP side and SYS/BIOS plus NDK on the ARM side (using messages between the two.)
    • Code Composer V5 with JTAG debugging.
    • I'm guessing the L138 is the best option at this point because of NDK support.
    • Is there any SYS/BIOS support for the TMS320C6A617 (the dev boards seem very new.)

    John C.

  • John,

    The OMAP-L138 meets the first two bullets.

    I'm not familiar with TMS320C6A617. Is this the correct part number?

    Todd

  • Todd,

        I guess it is listed as an Integra DSP+ARM Processor, TMS320C6A816x Processor, C6A8167. It's basically a much faster 138 plus some extras. The L138 seems to be popular here and I was curious if anyone had been using the C6A8167 under SYS/BIOS with the NDK.

        Is there a more popular L138 dev board as I only seem to see the OMAP-L138/TMS320C6748 EVM.

    Thanks,

         John C.

  • John,

    While SYS/BIOS is supported on the 814x and 816x, people are generally using Linux on the 816X's ARM (and using it's networking stack & driver).

    Unfortunately, I don't have much exposure what is popular (in regards to development boards). You might post this question on the DaVinci forum.

    Todd

  • John,

    You can trying to use the following ethernet driver for evmomap-l137 board:

    8741.nsp_1_10_00_03.zip

    Nikolay

  • Thanks Todd,

                    I've gone to loading my data into some spare DSP memory as the process of trying to get the ARM running the

    NDK would have taken to long. I thing it would be better in the long run, but unfortunately I did not have the time now.

    John C.

  • Nikolay,

                How would this driver fit into NDK?

    Thanks,

           John C.

  • This archive contains the omapl137 driver for evmomap-l137 board.

    Unpack and place this driver into nsp_1_10 folder (same folder where placed  the omapl138 driver).

    After this, you can use it in the *.cfg file:

    xdc.useModule('ti.drv.omapl137.Emac'); 

    Nikolay

  • Hi,

    I have a similar problem. I created a new thread, but nobody replies to it. This has happened twice, therefore, left with no other choice, I am continuing here only. I also want to run sys bios on DSP and ARM processor of OMAPL137 and ndk on ARM. For this I have downloaded the ethernet driver attached by Nikolay in one of the previous posts. I unpacked it in the same folder as ndk and wrote  xdc.useModule('ti.drv.omapl137.Emac'); in .cfg file. Then I tried to build it, which gives following errors:

    Can anyone please help me in resolving these errors?

    Just for the info: I have taken a simple hello sys/bios example and tried to implement ndk into it using .cfg file. Then I had tried to incorporate the ethernet driver which gives the errors as shown in snapshot.

    Thanks and Best Regards,

    Mini kaushik

  • Mini,

         I understand the frustration of no feedback. We never did try this recommendation as we found that the main reason we were using the DSP (floating point performance) was obtainable using a ARM Cortex A8 or preferably A9. So we went down the ARM path as it had the floating point performance, there seems to be better feedback/support and the price is reasonable.

          I'm sorry I can't help in finding an answer to your current issue but I can say that what you are trying seems reasonable except that the L137/138's don't seem to be popular enough to get support for the NDK (even the newer ARM chips only get a network stack using either StarterWare, the Industrial SDK or Linux.)

    John C.

  • Hi Mini kaushik,

    Do you know which forum you posted your questions about the NDK in?  The NDK is a supported product;  I personally (as well as many of my colleagues) answer questions on the NDK in the BIOS forum almost every day.  I have a feeling that you may have posted in another forum and that your post was never moved to the BIOS forum where we could see it.

    Mini Kaushik said:
    I unpacked it in the same folder as ndk and wrote  xdc.useModule('ti.drv.omapl137.Emac'); in .cfg file. Then I tried to build it, which gives following errors:

    First, please note that the zip file "8741.nsp_1_10_00_03.zip" posted above by Nikolay is not a Texas Instruments product!  I took a quick look at it and it appears that he has modified the evmOMAPL138 NSP product (which is an official product) to work for the evmOMAPL137 board.  While it is OK to do such a thing, it must be noted that we cannot support you with any problems you have with it (or other community modified/created content).  Having said that, I will still provide you with a hint: The undefined symbol errors are most likely happening because the driver libs (from Nikolay's zip) aren't coming into your application. Try removing the "useModule" line from your *.cfg file and then directly link in the driver libraries from Nikolay into your application and rebuild.  You may also need the -x linker option or to play with the link order to get it to work.


    The official drivers for the OMAPL137 board were shipped in the NDK 2.0.0 release (http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/ndk/2_00_00/index_FDS.html).

    If you download/install that, you should be able to find the drivers under:

    ndk_2_0_0\packages\ti\ndk\lib\hal\evmomapl137

    Then you can update your current project to directly link in those libraries.  However, I believe they are only for the DSP side.

    Steve

  • Hi John and Steven,

    Thanks for replying.

    I have linked the libraries and it is now compiled. The problem now is that, I want to run the example HelloWorld delivered with nsp_1_10_01_06 (OMAPL138) on OMAPL137 using ethernet driver of omapl137. The program compiles but does not run correctly. Steven, can you please tell me how can I link the code to old ethernet driver. If I just remove the useModule line from .cfg file, it gives an error of unresolved symbol _NIMUDeviceTable. I tried to copy the related files (csl_emac.c, csl_mdio.c,ethdriver.c and nimu_eth.c) but still the error exists.

    Error:

    It occurs at run time. And after this, it remains in statusupdate as shown in disassembly. Can you please help in solving this problem? Also, I would like to know the difference between elf, coff and arm examples in nsp.

    Thanks and best regards,

    Mini Kaushik

  • Hi again,

    Here is an update, it sometimes run (to some extent). After default MAC address, it displays EMAC up and running + registration successful + network added with the given IP address. But it does not display the link status. Also, I am not able to ping the board because I think the link is not yet established.

    Can you please suggest something in this regard?

    Please have a look at the output at console:

    [C674X_0] Using default MAC address
    [C674X_0] Using MAC Address: 00-08-ee-03-14-99
    [C674X_0] MAC Address = 00-08-ee-03-14-99
    [C674X_0] EMAC should be up and running
    [C674X_0] EMAC has been started successfully
    [C674X_0] Registeration of the EMAC Successful
    [C674X_0] Network Added: If-1:192.168.1.246
    [C674X_0] xc006c204
    A10=0x1 A11=0xc006c2f4
    A12=0x0 A13=0x0
    A14=0xc00b2798 A15=0x0
    A16=0x4 A17=0x0
    A18=0xc004c370 A19=0x40
    A20=0x0 A21=0x0
    A22=0xc007c914 A23=0x0
    A24=0x0 A25=0x2200c6f7
    A26=0x1e231d8 A27=0x1e23100
    A28=0x700 A29=0x100
    A30=0x1e23100 A31=0x0
    B0=0x64 B1=0[C674X_0] x1
    B2=0x1 B3=0xc0091638
    B4=0x800a9060 B5=0xc8
    B6=0x64 B7=0x1
    B8=0x0 B9=0x0
    B10=0xc006c318 B11=0xc004b908
    B12=0x8006c218 B13=0x64
    B14=0xc00b4e30 B15=0xc00b4d70
    B16=0x0 B17=0xc004c290
    B18=0x10000 B19=0x99
    B20=0x69 B21=0xd350a58f
    B22=0xf B23=0x0
    B24=0x961fbbd[C674X_0] a B25=0x10000
    B26=0x0 B27=0xffffffff
    B28=0x1e23100 B29=0x1e23100
    B30=0xffffffff B31=0xc006c52c
    NTSR=0x1020f
    ITSR=0x20f
    IRP=0xc0091528
    SSR=0x0
    AMR=0x0
    RILC=0x0
    ILC=0x0
    Exception at 0x800a9060
    EFR=0x2 NRP=0x800a9060
    Internal exception: IERR=0x1
    Instruction f[C674X_0] etch exception
    ti.sysbios.family.c64p.Exception: line 248: E_exceptionMin: pc = 0xc0091528, sp = 0xc00b4d70.
    To see more exception detail, use ROV or set 'ti.sysbios.family.c64p.Exc[C674X_0] eption.enablePrint = true;'
    xdc.runtime.Error.raise: terminating execution

    Thanks and best regards,

    Mini Kaushik

  • Mini Kaushik,

    Mini Kaushik said:
    Steven, can you please tell me how can I link the code to old ethernet driver.

    You need to download the older NDK 2.0, I believe I linked it above.  That version of the NDK has drivers.  Note that you only need the driver libraries from this release; you should continue using your current NDK version for all other stack libraries.

    Once you've downloaded it, you can add it into your file search path of your project options.  You can see how I did this in the screen shot below.  Start by right clicking on the project in CCS and select "build options."  Then go to C6000 Linker->File Search Path.  Click the green "+" sign to add the library:

    Mini Kaushik said:
    Also, I would like to know the difference between elf, coff and arm examples in nsp.

    ELF and COFF are two different types of compilers.  ARM examples are for the ARM9 processor, as opposed to the C674 DSP core.

    Steve

  • Hi Steven,

    Thanks for your reply.

    I have done as you had mentioned but now I am getting following errors:

    unresolved symbol _BCACHE_invL1pAll, first referenced in C:\CCStudio_v3.3\ndk_2_0_0_0\packages\ti\ndk\lib\hal\evmomapl137\hal_eth_omapl137.lib<ethdriver.o64P>


    unresolved symbol _EMAC_startSwitch, first referenced in C:\CCStudio_v3.3\ndk_2_0_0_0\packages\ti\ndk\lib\hal\evmomapl137\hal_eth_omapl137.lib<ethdriver.o64P>


    unresolved symbol _SEM_post, first referenced in C:\CCStudio_v3.3\ndk_2_0_0_0\packages\ti\ndk\lib\hal\evmomapl137\hal_eth_omapl137.lib<ethdriver.o64P>  

    Is there any other file file missing to resolve these errors?

    Also, did you mention in your previous posts that old ethernet driver delivered with ndk 2_0_0 works only for DSP and not ARM? Did I understand it correct?

    Thanks and Best Regards,

    Mini Kaushik




  • Hi Mini Kaushik,

    Mini Kaushik said:
    Also, did you mention in your previous posts that old ethernet driver delivered with ndk 2_0_0 works only for DSP and not ARM? Did I understand it correct?

    Yes.  That driver is for the DSP side only.  Upon inspecting it further with regards to the errors you are getting, I see that it is also built for BIOS 5.x only (not SYS/BIOS).

    Unfortunately this means that you would need to port the driver to SYS/BIOS and rebuild it.  I have already done this for a different hardware platform, the DSK6455.  I'll attach that driver to this thread. You can diff it against the driver code that's in NDK 2.0 that you have now.

    The changes you need to make should be similar.  Note that in the driver I removed the BCACHE_invL1pAll call entirely.

    Alternatively, you could continue to use Nikolay's driver and request his help via the forum, I just wouldn't be able to help you with issues on that driver.

    Steve

    4353.ethdriver.c

  • Hi Steve,

    As you said, "Unfortunately this means that you would need to port the driver to SYS/BIOS and rebuild it", can you please tell me or give me a related link where it is given how to do this? Well I took your ethernet driver and removed where ever 6455 was written, placed it in C:\CCStudio_v3.3\ndk_2_0_0_0\packages\ti\ndk\src\hal\evmomapl137\eth_omapl137, and tried to compile my code, it still gives me same errors. Please have a look at the snapshot.

    Is it because that we need to rebuild the library? I tried to look in internet and found how to build ndk stack at http://processors.wiki.ti.com/index.php/Rebuilding_the_NDK_Core, but it is for ndk_2_21 and not for ndk 2_20. Is it really this difficult to get it running?

    Thanks and best regards,

    Mini Kaushik

  • Hi Steve,

    I have implemented the changes in ethernet.c for c6747. But I am still not sure how to build it. Can you please help me to proceed further. I am attaching the new ethernet.c for 6747.

    0131.ethdriver.c

    Thanks and best regards,

    Mini

  • Hi Mini,

    You can use your existing project to rebuild the driver code.  Basically, you would remove the linking of the Ethernet driver library from your project, and then add in the driver sources into the project.

    You can do this by first editing the build options of your project to remove the linking of the Ethernet driver.  Then you can add in the driver sources by copying and pasting them into your project.  This will cause the driver code to build as part of your application.

    Steve

  • Hi Steve,

    Thanks for the reply.

    I tried to do as mentioned by you which gives me another error. As I have no clue about the commands written in it, I am uploading the problem without going into much detail myself. I have attached the snapshot which shows the error. It is same ethernet.c which I had uploaded last time. Can you please have a look into it.

    Thanks and Best regards,

    Mini