WARP Project Forums - Wireless Open-Access Research Platform

You are not logged in.

#1 2021-Apr-17 06:54:32

amirsepahi
Member
Registered: 2020-Dec-09
Posts: 8

Ethernet Encapsulation and De-encapsulation

Hi,
I want to send a packet from PC1 connected to AP via ETH A to PC2 connected to station via ETH A, wirelessly.

So based on the WARP document, we want to encapsulate an ethernet frame to an 802.11 frame in AP and send it to the station.
I want to add a 10 bits field to the first part of the data of the  ethernet frame and then push it to the 802.11 frame like what you see in this link. (http://warpproject.org/trac/wiki/802.11 … k/EthEncap).

I think I should add this 10 bits field somewhere in wlan_eth_encap(); inside wlan_mac_eth_util.c. I could see llc header is added in this function, but actually I do not know how could I add my 10 bits field at the beginning of data immediately after the LLC IP/ARP type.
So my first question is how can I access the data part of ethernet frame inside wlan_eth_encap() function.

Furthermore, since I want to see the data part of received 802.11frame  on the STA, I need to be able to access the data part of 802.11 frame to see if I can see my added 10 bits field there. So could you please let me know how could I read the data part of received 802.11 frame in STA. I think I should read it inside mpdu_rx_process() function but I do not know how to do that.


I have tried different ways to add my 10 bits field but I was not successful. I would be so grateful if you could help me.

Thanks

Offline

 

#2 2021-Apr-19 15:53:16

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5155

Re: Ethernet Encapsulation and De-encapsulation

I cannot guide you on the specific changes necessary to implement your custom behaviors. The functions you mention have access to the Tx/Rx packets in memory. You will need to study this code you want to modify, then build and test your modifications.

Offline

 

#3 2021-Apr-22 14:52:18

amirsepahi
Member
Registered: 2020-Dec-09
Posts: 8

Re: Ethernet Encapsulation and De-encapsulation

I was reading your replies to these questions (https://www.warpproject.org/forums/view … hp?id=2897) and (https://www.warpproject.org/forums/view … hp?id=1994) to figure out create and send my ethernet frames. However, the syntax is different in the latest version that I am using. Could you please guide me how and where should I create my ethernet frame in the C code of latest version of 802.11 reference design?
(I am looking at wlan_axi_ethernet_intr.c and w3_eth.c files right now to figure out how could I do that)   

Thanks!

Last edited by amirsepahi (2021-Apr-22 14:52:58)

Offline

 

Board footer