10.3.3 PHY-DATA.indication
This data indication callback executes the function set by the upper layer at the initialization of the PL360 Host Controller (see Setting Callbacks). It is called when a frame is received. The format of the function is:
typedef void (*pf_data_indication_t)(rx_msg_t *px_msg);
The information is reported in the following structure:
typedef struct rx_msg {
uint32_t ul_evm_header_acum;
uint32_t ul_evm_payload_acum;
uint32_t ul_rx_time;
uint16_t us_evm_header;
uint16_t us_evm_payload;
uint16_t us_data_len;
enum mod_schemes uc_scheme;
enum mode_types uc_mod_type;
enum header_types uc_header_type;
uint8_t uc_rssi_avg;
uint8_t uc_cinr_avg;
uint8_t uc_cinr_min;
uint8_t uc_ber_soft;
uint8_t uc_ber_soft_max;
uint8_t uc_nar_bnd_percent;
uint8_t uc_imp_percent;
uint8_t *puc_data_buf;
} rx_msg_t;
Fields of the structure:
ul_evm_header_acum | Accumulated EVM for header |
ul_evm_payload_acum | Accumulated EVM for payload |
ul_rx_time | Instant when frame was received (start of frame), referred to the internal 1 μs PHY counter |
us_evm_header | EVM for header |
us_evm_payload | EVM for payload |
us_data_len | Length of the received data, in bytes |
uc_scheme | Modulation scheme of the received message (related constants defined in PHY-DATA.request) |
uc_mod_type | PRIME mode type of the received message (related constants defined in PHY-DATA.request) |
uc_header_type | Header Type of the received message (related constants defined below) |
uc_rssi_avg | RSSI in dBµV |
uc_cinr_avg | Average CINR in dB with uQ6.2 format and -10 dB offset (0x00: -10 dB; 0x01: -9.75 dB; 0xFF: 53.75 dB) |
uc_cinr_min | Minimum CINR in dB with uQ6.2 format and -10 dB offset |
uc_ber_soft | Average Soft BER |
uc_ber_soft_max | Maximum Soft BER |
uc_nar_bnd_percent | Percentage of carriers affected by narrow band noise, multiplied by 512 |
uc_imp_percent | Percentage of symbols affected by impulsive noise, multiplied by 256 |
puc_data_buf | Pointer to data buffer containing received frame |
Related constants affecting above parameters:
/* ! \name Header types */
enum header_types {
PHY_HT_GENERIC = 0,
PHY_HT_PROMOTION = 1,
PHY_HT_BEACON = 2,
};