WARP Project Forums - Wireless Open-Access Research Platform

You are not logged in.

#1 2018-Sep-21 10:06:25

lizhuqi
Member
Registered: 2017-Oct-17
Posts: 14

Retrieve only the newest log from Warp

Hi,

I am using the WARP 802.11 reference design to get CSI from the log.

Currently, I use a log_get_all_new function to get all the new logs from the last reading. This function will typically return 5~10 logs with latency around 2.5 ms while the warp is running TCP throughput test. I want to only retrieve the most updated log (just one) so that I can get smaller latency for log retrieving.

I think I should customize the source to achieve this. Could you please tell me the place that I should change to implement this functionality.

Best,
Zhuqi

Offline

 

#2 2018-Sep-24 09:30:41

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

Re: Retrieve only the newest log from Warp

A few things:

-Pass the tail_pad=0 argument to n.log_get_all_new(). By default this method does not retrieve the newest bytes from the log data memory to avoid any race between code writing new log entries and the code reading log data. This race only exists for log entries written outside of an interrupt context. All RX_OFDM/RX_DSSS entries are written inside an interrupt context, so if you're only interested in RX entries it is safe to always retrieve the latest log data.

-Reducing the number of RX log entries per poll will not significantly reduce latency. The C code which copies log data into Ethernet packets is fast - the difference in latency for copying 1 or a few RX entries will be small compared to the overall time to poll/retrieve any log data.

-One option to minimize latency from wireless reception to an RX_OFDM entry on your PC would be to implement streaming log data from the node. By default the wlan_exp framework only transmits Ethernet packets in response to commands received from the PC. However it would be possible to generate Ethernet IP/UDP packets asynchronously from the node, then listen for these packets with custom code on the PC. You could insert this functionality in the wlan_mac_high.c mailbox message hander, where it processes "RX_PKT_BUF_READY" from CPU Low, it calls wlan_exp_log_create_rx_entry() to create the RX_OFDM/RX_DSSS log entry. That function returns a pointer to the log entry in DRAM. Your custom code could read that log entry and send it via Ethernet.

Offline

 

Board footer