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.

CCS/66AK2H12: Adding Ethernet IP to an existing ARM application

Part Number: 66AK2H12
Other Parts Discussed in Thread: SYSBIOS

Tool/software: Code Composer Studio

Goal: Add Ethernet support to an existing application running on one of the ARM processors on my EVM 66AK2H

I have built and successfully run the example programs:

  • Hello Example (from TI Resource Explorer Classic : 66AK2H12 : Arm : GNU : Generic )
  • NIMU_emacExample_EVMK2H_armBiosExampleProject (from the pdk_k2hk_4_0_6\packages\pdkProjectCreate.bat process.

Both example programs compile, run and test as expected. It it the first Hello Example to which I want to add networking as a test to understand the steps involved. My goal is to send simple UDP messages on time to start with.

I have installed ndk_2_25_01_11 and I am trying to exactly follow the clear instructions in the TI Network Developer's Kit (NDK) v2.25. (www.ti.com/.../spru523j.pdf).

In that guide (dated as Revised January 2016) Section 1.6.1 Adding NDK Support to an Existing Application has the steps but I encounter several problems:

Step 4. Check the boxes next to the most recently installed versions of the NDK and NDK Network Support Package products. I do not have a NDK Network Support Package product. I found and downloaded nsp_1_10_03_15.zip and place the extracted nsp_1_10_03_15 under my c:\ti directory but still it is not available in CCS to select under Products.

Step 9. I don’t think I see the EVM Ethernet devices so I leave this as None.

When I try to build the above I get a lot of link errors such as:

C:\ti\ndk_2_25_01_11\packages\ti\ndk\netctrl\lib\netctrl_min.aa15fg(netctrl.oa15fg): In function `NC_SystemOpen':

/db/vtree/library/trees/ndk/ndk-j08/src/ti/ndk/netctrl/netctrl.c:97: undefined reference to `_mmInit'

/db/vtree/library/trees/ndk/ndk-j08/src/ti/ndk/netctrl/netctrl.c:111: undefined reference to `mmZeroInit'

If I compare the NDK settings in XGCONF for both the Hello example and the working network example, the working example does not have EMAC enabled yet it is an EMAC example.

The NIMU_emacExample_EVMK2H_armBiosExampleProject contains a multitude of source files, some generated, many csl sources, etc. The TI Network Developer's Kit (NDK) v2.25 document Section 3.1 Configuring the NDK with XGCONF indicates that:

The XGCONF configuration automatically performs the following actions for you: 

• Generates C code to create and populate a configuration database. 

• Generates C code to act as the network scheduling function and to perform network activity. 

I don’t see any code generated.

So my initial questions are:

1) Do I need a NSP?  (It would seem not since the NIMU_ema works)

2) Given that I clearly must have all the source required to enable IP on my EVM, how do I add it to the Hello Example? What is the guide missing?

3) Why doesn’t the XGCONF show IP and UDP enabled for the NIMU_emacExample_EVMK2H_armBiosExampleProject when they must be since it works? (I can ping the example when it is running).

Thanks,

Mike

Goal: Add Ethernet support to an existing application running on one of the ARM processors on my EVM 66AK2H

I have built and successfully run the example programs:

- Hello Example (from TI Resource Explorer Classic : 66AK2H12 : Arm : GNU : Generic )

- NIMU_emacExample_EVMK2H_armBiosExampleProject (from the pdk_k2hk_4_0_6\packages\pdkProjectCreate.bat process.

Both example programs compile, run and test as expected. It it the first Hello Example to which I want to add networking as a test to understand the steps involved. My goal is to send simple UDP messages on time to start with.

I have installed ndk_2_25_01_11 and I am trying to exactly follow the clear instructions in the TI Network Developer's Kit (NDK) v2.25. (http://www.ti.com/lit/ug/spru523j/spru523j.pdf).

In that guide (dated as –Revised January 2016) Section 1.6.1 Adding NDK Support to an Existing Application has the steps but I encounter several problems:

Step 4. Check the boxes next to the most recently installed versions of the NDK and NDK Network Support Package products. I do not have a NDK Network Support Package product. I found and downloaded nsp_1_10_03_15.zip and place the extracted nsp_1_10_03_15 under my c:\ti directory but still it is not available in CCS to select under Products.

Step 9. I don’t think I see the EVM Ethernet devices so I leave this as None.

When I try to build the above I get a lot of link errors such as:

C:\ti\ndk_2_25_01_11\packages\ti\ndk\netctrl\lib\netctrl_min.aa15fg(netctrl.oa15fg): In function `NC_SystemOpen':

/db/vtree/library/trees/ndk/ndk-j08/src/ti/ndk/netctrl/netctrl.c:97: undefined reference to `_mmInit'

/db/vtree/library/trees/ndk/ndk-j08/src/ti/ndk/netctrl/netctrl.c:111: undefined reference to `mmZeroInit'

If I compare the NDK settings in XGCONF for both the Hello example and the working network example, the working example does not have EMAC enabled yet it is an EMAC example.

The NIMU_emacExample_EVMK2H_armBiosExampleProject contains a multitude of source files, some generated, many csl sources, etc. The TI Network Developer's Kit (NDK) v2.25 document Section 3.1 Configuring the NDK with XGCONF indicates that:

The XGCONF configuration automatically performs the following actions for you:

• Generates C code to create and populate a configuration database.

• Generates C code to act as the network scheduling function and to perform network activity.

I don’t see any code generated.

So my initial questions are:

1) Do I need a NSP? (It would seem not since the NIMU_ema works)

2) Given that I clearly must have all the source required to enable IP on my EVM, how do I add it to the Hello Example? What is the guide missing?

3) Why doesn’t the XGCONF show IP and UDP enabled for the NIMU_emacExample_EVMK2H_armBiosExampleProject when they must be since it works? (I can ping the example when it is running).

  • Hi,

    I've notified the sw team. Their feedback will be posted here.

    Best Regards,
    Yordan
  • Hi,

    You don't need NSP. If you want to use NDK to send UDP packets, for the NIMU_emacExample_EVMK2H_armBiosExampleProject, you can ping it. There is also some Windows test application under ndk_2_2x_xx_xx\packages\ti\ndk\winapps. You can run it from a Windows machine, the NDK will send UDP packets to the PC during the test.

    Regards, Eric
  • No you misunderstood my question. I know the NIMU EMAC example works. I stated that I had it and it worked. I am trying to follow the directions in the NDK to add the capability to ARM examples that do not yet have the support. I am trying to add to the Hello Example. Please re-read my initial question.
    Mike
    PS - thanks for the clarification on NSP. I will delete what I downloaded. (Why is it in the guide?)
  • Hello. Any additional pointers on adding NDK to the Hello Example? I could really use some help. Getting networking operational is one of the risk factors we are evaluating to determine if SYS/BIOS will work for our project or not.
    Kind regards, Mike
  • Hi,

    The "Hello" I believe is just a simple SYSBIOS example to print out "Hello World" to the CCS console. If you want to using NDK for transmitting packets, I believe what you need is to use the NIMU example you already tried, then add a printf of "Hello world" instead of adding NIMU into Hello example. "Hello world" is just a code skeleton. Not sure if I understood your correctly.

    Regards, Eric
  • Thanks for the return Eric. I need to be able to add NDK to an existing project. I am using the Hello Example just as a test case. I think it is unreasonable to try and begin with the NIMU example as the starting point for our project. It makes much more sense to start a new project and then add the stuff we'll need doesn't? We are going to need USB serial, USB FATfs, PCIe, networking, etc. Each of those has their own example (I hope) in the PDK. We can't start with all the examples. The TI Network Developer's Kit (NDK) v2.25 document clearly talks about adding NDK to an existing project and that is what I want, need, to do.
    Mike
  • Hi,

    In your case, it is to add NDK NIMU into an existing project. Or how to merge several SYSBIOS projects together into one, we have an example www.ti.com/.../sprac93.pdf on AM572x. You can follow the same idea.

    Regards, Eric
  • I don't want to merge in the NIMU example. That example does things I don't want, need or care to explore. Why is it so difficult to add the NDK to a project like the document says? What is wrong with the document? It is versioned to match the NDK. It is relatively recent. Is it that difficult to add NDK?