UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Observer j_ney
Observer
399 Views
Registered: ‎11-26-2017

General UDP PL Ethernet Questions

Jump to solution

Hello, 

I'm fairly new to FPGA programming and know even less about networking and ethernet, so be prepared for some stupid questions.

My current application on the ZCU102 does the following:

- Read image on PS under Linux

- Save image to DRAM

- PL reads DRAM and does some calculations

- PL writes back to DRAM

- PS reads results

- PS sends results over UDP to my laptop

The goal is now to send the results directly from hardware to some UDP/Ethernet core send them to my laptop. Would this give me some improvement in speed because I don't need to save it back in DRAM and read it with software?

There are many ethernet cores in the xilinx ip catalog but I've no idea which one to use and how to connect it.

I think creating udp packets is fairly easy, so maybe I wouldn't even need another ip for that and just do it by myself?

Can you recommend some resources to learn about all this ethernet and networking stuff?

Can the PL be connected to the same physical ethernet adapter on the board as the PS or do I need some additional device?

So I think my main problem is which cores to use and what will be the dataflow from custom-IP to ethernet (AXI-Stream or DMA)

 

Thanks for any help!

 

Best regards

Jonas

0 Kudos
1 Solution

Accepted Solutions
Voyager
Voyager
370 Views
Registered: ‎02-01-2013

Re: General UDP PL Ethernet Questions

Jump to solution

HW guy talking, here, so weigh accordingly...

=====================================

Every time SW doesn't have to touch your data, you save approximately 1 eternity. So, yes: if you encapsulate your data within the PL and send it directly to an Ethernet port, the processing time will be considerably shorter. But that's no easy endeavor for a novice. What you probably want to do, instead, is encapsulate the data, place it somewhere, then let software arrange a single, final DMA of that data to the MAC.

Here are some answers to your other questions:

There are many ethernet cores in the xilinx ip catalog but I've no idea which one to use and how to connect it.

If you instead want the least amount of SW involvement in packet processing (i.e., the Titan-level effort on your part), the most straightforward Ethernet IP to use is the TEMAC: https://www.xilinx.com/support/documentation/ip_documentation/tri_mode_ethernet_mac/v8_2/pg051-tri-mode-eth-mac.pdf

I think creating udp packets is fairly easy, so maybe I wouldn't even need another ip for that and just do it by myself?

You can readily add a UDP header when you pre-pend the rest of the packet headers to the data. If you need to include a correct UDP checksum, however, you'll need to generate that beforehand, which means running the data first through some more hardware to compute the checksum. UDP checksum is often optional, though.

Can you recommend some resources to learn about all this ethernet and networking stuff?

Sorry; nothing concise comes to mind. At this point, for me, that's like answering a question like "can you recommend some resources to learn about the English language?" I'd say Google "802.3", but that would be mean, as it's way too broad a search. Start by reading Wikipedia articles on the subjects. And pack a lunch. You've got a long trek.

Can the PL be connected to the same physical ethernet adapter on the board as the PS or do I need some additional device?

Using the same PSU GEM (and therefore, the same PHY and Ethernet port) is your best route. In an effort like this, the 'hard' part would be merging any software-generated packets (e.g. IP, ICMP, or other packets that you might need to send over that same interface) with the data stream. If you take my suggestion and let SW handle the DMA, you'll be better off.

-Joe G.

 

 
0 Kudos
2 Replies
Voyager
Voyager
371 Views
Registered: ‎02-01-2013

Re: General UDP PL Ethernet Questions

Jump to solution

HW guy talking, here, so weigh accordingly...

=====================================

Every time SW doesn't have to touch your data, you save approximately 1 eternity. So, yes: if you encapsulate your data within the PL and send it directly to an Ethernet port, the processing time will be considerably shorter. But that's no easy endeavor for a novice. What you probably want to do, instead, is encapsulate the data, place it somewhere, then let software arrange a single, final DMA of that data to the MAC.

Here are some answers to your other questions:

There are many ethernet cores in the xilinx ip catalog but I've no idea which one to use and how to connect it.

If you instead want the least amount of SW involvement in packet processing (i.e., the Titan-level effort on your part), the most straightforward Ethernet IP to use is the TEMAC: https://www.xilinx.com/support/documentation/ip_documentation/tri_mode_ethernet_mac/v8_2/pg051-tri-mode-eth-mac.pdf

I think creating udp packets is fairly easy, so maybe I wouldn't even need another ip for that and just do it by myself?

You can readily add a UDP header when you pre-pend the rest of the packet headers to the data. If you need to include a correct UDP checksum, however, you'll need to generate that beforehand, which means running the data first through some more hardware to compute the checksum. UDP checksum is often optional, though.

Can you recommend some resources to learn about all this ethernet and networking stuff?

Sorry; nothing concise comes to mind. At this point, for me, that's like answering a question like "can you recommend some resources to learn about the English language?" I'd say Google "802.3", but that would be mean, as it's way too broad a search. Start by reading Wikipedia articles on the subjects. And pack a lunch. You've got a long trek.

Can the PL be connected to the same physical ethernet adapter on the board as the PS or do I need some additional device?

Using the same PSU GEM (and therefore, the same PHY and Ethernet port) is your best route. In an effort like this, the 'hard' part would be merging any software-generated packets (e.g. IP, ICMP, or other packets that you might need to send over that same interface) with the data stream. If you take my suggestion and let SW handle the DMA, you'll be better off.

-Joe G.

 

 
0 Kudos
Observer j_ney
Observer
361 Views
Registered: ‎11-26-2017

Re: General UDP PL Ethernet Questions

Jump to solution

Thanks for your detailed answer!

I think I have to invest some time to learn about all this stuff. I'll come back if I have more specific questions.

 

0 Kudos