wiki:802.11/wlan_exp/log/entry_types

Version 2 (modified by murphpo, 10 years ago) (diff)

--

802.11 Reference Design: Event Log Entry Types

The 802.11 Reference Design logging framework is designed to record log entries of arbitrary length and type. The MAC code in CPU High is responsible for defining the log entry types and populating each log entry at run time.

The reference code for CPU High defines a number of useful log entry types and implements logging of many run time events, including all Tx and Rx activity. The entry types defined in the reference implementation are listed below.

Users can define new log entry types or modify existing types to support their experiment. The requirements for this are documented below.

Reference Design Entry Types

NODE_INFO

Details about the node hardware and its configuration. Node info values are static after boot.

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at time of log entry creation
node_type uint32 Node type as 4 byte value: [b0 b1 b2 b3]:
b0: Always 0x00
b1: Always 0x01 for 802.11 ref design nodes
b2: CPU High application: 0x1 = AP, 0x2 = STA
b3: CPU Low application: 0x1 = DCF
node_id uint32 Node ID, as set during wlan_exp init
hw_generation uint32 WARP hardware generation: 3 for WARP v3
wn_ver uint32 WARPnet version, as packed bytes [0 major minor rev]
fpga_dna uint64 DNA value of node FPGA
serial_num uint32 Serial number of WARP board
wlan_exp_ver uint32 wlan_exp version, as packed values [(u8)major (u8)minor (u16)rev]
wlan_max_associations uint32 Maximum number of wireless associations allowed by node
wlan_log_max_size uint32 Maximum size in bytes of node's event log
wlan_mac_addr uint64 Node MAC address, 6 bytes in lower 48-bits of u64
wlan_max_stats uint32 Maximum number of statistics structs maintained by node
ltg_resolution uint32 Minimum interval in microseconds of LTG schedules

EXP_INFO

Header for generic experiment info entries created by the user application. The payload of the EXP_INFO entry is not described by the Python entry type. User code must access the payload in the binary log data directly.

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at time of log entry creation
info_type uint16 Exp info type (arbitrary value supplied by application
length uint16 Exp info length (describes arbitrary payload supplied by application

STATION_INFO

Information about an 802.11 association. At the AP one STATION_INFO is created for each associated STA and is logged whenever the STA association state changes. At the STA one STATION_INFO is logged whenever the STA associaiton state changes.

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at time of log entry creation
mac_addr 6uint8 MAC address of associated device
aid uint16 Association ID (AID) of device
host_name 20uint8 String hostname (19 chars max), taken from DHCP DISCOVER packets
flags uint32 Association state flags: ???
rx_last_timestamp uint64 Microsecond timer value at time of last successful Rx from device
rx_last_seq uint16 Sequence number of last packet received from device
rx_last_power int8 Rx power in dBm of last packet received from device
rx_last_rate uint8 PHY rate index in [1:8] of last packet received from device
tx_phy_rate uint8 Current PHY rate index in [1:8] for new transmissions to device
tx_phy_antenna_mode uint8 Current PHY antenna mode in [1:4] for new transmissions to device
tx_phy_power int8 Current Tx power in dBm for new transmissions to device
tx_phy_flags uint8 Flags for Tx PHY config for new transmissions to deivce
tx_mac_num_tx_max uint8 Maximum number of transmissions (original Tx + re-Tx) per MPDU to device
tx_mac_flags uint8 Flags for Tx MAC config for new transmissions to device
padding uint16

NODE_TEMPERATURE

Fields:

Field Name DataType Description
timestamp uint64
node_id uint32
serial_num uint32
temp_current uint32
temp_min uint32
temp_max uint32

WN_CMD_INFO

Record of a WARPnet / wlan_exp command received by the node. The full command payload is logged, including any (possibly personal-info-carrying) parameters like MAC addresses.

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at time of log entry creation
command uint32 WARPnet / wlan_exp command ID
src_id uint16 Node ID of device sending command
num_args uint16 Number of arguments supplied in command
args 10uint32 Command arguments

TIME_INFO

Record of a time base event at the node. This log entry is used to enable parsing of log data recored before and after changes to the node's microsecond timer. This entry also allows a wlan_exp controler to write the current absolute time to the node log without affecting the node's timer value. This enables adjustment of log entry timestamps to real timestamps in post-proessing.

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at time of log entry creation
time_id uint32 Random ID value included in wlan_exp TIME_INFO command; used to find common entries across nodes
reason uint32 Reason code for TIME_INFO log entry creation
new_time uint64 New value of microsecond timer value; 0xFFFFFFFFFFFFFFFF if timer was not changed
abs_time uint64 Absolute time in microseconds-since-epoch; 0xFFFFFFFFFFFFFFFF if unknown

RX_DSSS

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at PHY Rx start
length uint16 Length of payload in bytes
rate uint8 PHY rate index, in [1:8]
power int8 Rx power in dBm
fcs_result uint8 Checksum status, 0 = no errors
pkt_type uint8 Packet type: 1 = other data, 2 = encapsulated Ethernet, 3 = LTG, 11 = management, 21 = control
chan_num uint8 Channel (center frequency) index
ant_mode uint8 Antenna mode: [1,2,3,4] for SISO Rx on RF [A,B,C,D]
rf_gain uint8 AGC RF gain setting: [1,2,3] for [0,15,30]dB gain
bb_gain uint8 AGC BB gain setting: [0:31] for approx [0:63]dB gain
flags uint16 Bit OR'd flags: 0x1 = Rx was duplicate of previous Rx
mac_payload_len uint32
mac_payload 24uint8

TX

Fields:

Field Name DataType Description
timestamp uint64
time_to_accept uint32
time_to_done uint32
uniq_seq uint64
num_tx uint8
tx_power int8
chan_num uint8
rate uint8
length uint16
result uint8
pkt_type uint8
ant_mode uint8
queue_id uint8
padding 2uint8
mac_payload_len uint32
mac_payload 24uint8

TX_LOW

Fields:

Field Name DataType Description
timestamp uint64
uniq_seq uint64
rate uint8
ant_mode uint8
tx_power int8
flags uint8
tx_count uint8
chan_num uint8
length uint16
num_slots uint16
cw uint16
pkt_type uint8
padding 3uint8
mac_payload_len uint32
mac_payload 24uint8

TXRX_STATS

Fields:

Field Name DataType Description
timestamp uint64
last_timestamp uint64
mac_addr 6uint8
associated uint8
padding uint8
data_num_rx_bytes uint64
data_num_tx_bytes_success uint64
data_num_tx_bytes_total uint64
data_num_rx_packets uint32
data_num_tx_packets_success uint32
data_num_tx_packets_total uint32
data_num_tx_packets_low uint32
mgmt_num_rx_bytes uint64
mgmt_num_tx_bytes_success uint64
mgmt_num_tx_bytes_total uint64
mgmt_num_rx_packets uint32
mgmt_num_tx_packets_success uint32
mgmt_num_tx_packets_total uint32
mgmt_num_tx_packets_low uint32

RX_OFDM

Fields:

Field Name DataType Description
timestamp uint64 Microsecond timer value at PHY Rx start
length uint16 Length of payload in bytes
rate uint8 PHY rate index, in [1:8]
power int8 Rx power in dBm
fcs_result uint8 Checksum status, 0 = no errors
pkt_type uint8 Packet type: 1 = other data, 2 = encapsulated Ethernet, 3 = LTG, 11 = management, 21 = control
chan_num uint8 Channel (center frequency) index
ant_mode uint8 Antenna mode: [1,2,3,4] for SISO Rx on RF [A,B,C,D]
rf_gain uint8 AGC RF gain setting: [1,2,3] for [0,15,30]dB gain
bb_gain uint8 AGC BB gain setting: [0:31] for approx [0:63]dB gain
flags uint16 Bit OR'd flags: 0x1 = Rx was duplicate of previous Rx
chan_est (64,2)i2
mac_payload_len uint32
mac_payload 24uint8