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.

Questions about ICSS and Ethernet

Other Parts Discussed in Thread: SYSBIOSEquipment:
Board: ICE v2, CCSv6 vs. 6.0.1.00040,
TI XDS100v2 USB Emulator,
Windows7,
am335x_sysbios_ind_sdk_1.1.0.5
NDK 2.24.1.18
NDK's NSP 1.10.2.09
SYSBIOS 6.40.3.39
Compiler TI v5.1.9


Hello everyone,

for quite a while I am struggling for a solution to send and receive TCP/IP data via ICSS while everything else shall be done by the Cortex A8 core.

So far with little success.

My hope is to get some pointers from this forum as I assume that others may have the same problem.

Here are some questions:

1. EthernetIp_adapter example for ICEv2 board
This example is said to use 'normal' TCP/IP. But somehow I could not find code that does the data transfer.
I have removed all the ethernetip dependent code to obtain a 'standalone switch'. (There is a description what to remove.)

1.1 Firmware
TaskPruss() loads PRU0_FIRMWARE and PRU1_FIRMWARE to PRU0 and PRU1. Ok so far.
But this code consists of 2 arrays containing binary data.
What is that firmware responsible for and how to use it?
Is there a document that explains what it does?

1.2 APIs
Obviously I can apply the APIs from the AM335x_ICSS_Switch_Driver_API_Guide to this firmware.
(http://processors.wiki.ti.com/index.php/AM335x_ICSS_Switch_Driver_API_Guide#Introduction)
Some of the functions are used in the example ethernetip_adapter.
Is my understanding correct that the firmware sends and receives data continuously and one can send data by using TxPacket()?
Where would I specify the destination IP address?
What is the maximum for lengthOfPacket?
How many packets can I send to one queue?
How many queues are there?
Can I send blocks of data that belong to one big buffer to different queues?
How would I send a broadcast message?

These are just some questions.
What would be helpful is either a document that explains the usage or/and a well documented example that demonstrates data transfer.
(NDK does not support SITARA yet.)
The example does not necessarily need to be with TI-RTOS, but definitely without Linux!

Can anybody provide some pointers.
Any comment is very much appreciated!

Thank you!

Regards,
Martin H.
  • Hello,

    Martin H. said:
    1. EthernetIp_adapter example for ICEv2 board
    This example is said to use 'normal' TCP/IP. But somehow I could not find code that does the data transfer.
    I have removed all the ethernetip dependent code to obtain a 'standalone switch'. (There is a description what to remove.)

    'Normal' TCP/IP transfer can be achieved by NDK stack. In the ethernet_ip example, we use these features to communicate via TCP/UDP. You can find details on how to transfer data via sockets in the NDK guide. In the end, the application has a lower layer in ICSS(forwarding, cut through etc.), and rest is in ARM(TCP/IP stack, application).

    Martin H. said:
    1.1 Firmware

    Using the API guide, you can communicate with the firmware. The source code is not available to the public.

    I'll get back to you on 1.2. But my understanding is that Tx_packet is used to send out a raw packet. The data is upto you(unless you frame the data by NDK).

    Regards,
    Vinesh

  • The Firmware design document is not available for public. Please contact your local TI support for more info.

    Regards,
    Vinesh
  • Hi Vinesh,

    so you mean I should not use the APIs from the "am335xPruReferenceGuide" but the NDK functions instead?

    Can the NDK be used  without using TI-RTOS?

    I got the impression it can not. Is that correct?

    In the EthernetIp_adapter example all the network code should be somewhere in EIPMain(), shouldn't it?

    All that looks like 'network'is the function SO_Open_Session().

    But I could not find a definition of SO_Open_Session(), just the prototype in user_api.h.

    I tried fdOpenSession() instead, but that returned with 0 (error).

    Do you have a suggestion what I might be missing?

    Thank you.

    Regards,

    Martin H.

  • Hi Martin,

          The ethernetip adapter can run over the low latency cut-thru switch implementation on ICSS  using NDK as TCP/IP stack. So once you strip the Ethernet/IP layer (from your post i guess you have already done it ),you get a Switch application. 

    The ICSS Switch driver for NDK  (built along with os_driver) enables the application/ NDK  stack  to communicate with PRU firmware.

    Now on your questions

    so you mean I should not use the APIs from the "am335xPruReferenceGuide" but the NDK functions instead?

    In order to get basic TCP/IP functionality it is not required.

    Can the NDK be used  without using TI-RTOS?

    No

    In the EthernetIp_adapter example all the network code should be somewhere in EIPMain(), shouldn't it?

    Currently the network code is part of the ethernetip library. For more info refer

    Regards,

    Prajith

  • Hi Prajith,
    thanks for your response.

    I assume that most of us would have preferred to see the source code instead of using a library. I mean the usage of connect(), bind(), socket() etc. in a 'living' example code.

    But anyway, at least I know that I am on the right way.

    It would be great if the next NSP package would come with an example for SITARA.

    Thank you!

    Kind regards,
    Martin H.