11#ifndef _PHY_RF_PARAMS_H_
12#define _PHY_RF_PARAMS_H_
15#define NRF_WIFI_RF_PARAMS_SIZE 200
16#define NRF_WIFI_RF_PARAMS_CONF_SIZE 42
17#define NUM_PCB_LOSS_OFFSET 4
19#ifdef CONFIG_NRF700X_RADIO_TEST
20#define NRF_WIFI_DEF_RF_PARAMS "007077003F032424001000002800323500000C0008087D8105010071630300EED501001F6F00003B350100F52E0000E35E0000B7B6000066EFFEFFB5F60000896200007A840200E28FFCFF080808080408120100000000A1A10178000000080050003B020726181818181A120A140E0600"
21#define MAX_TX_PWR_SYS_TEST 30
22#define MAX_TX_PWR_RADIO_TEST 24
24#define NRF_WIFI_DEF_RF_PARAMS "007077003F032424001000002800323500000CF008087D8105010071630300EED501001F6F00003B350100F52E0000E35E0000B7B6000066EFFEFFB5F60000896200007A840200E28FFCFF080808080408120100000000A1A10178000000080050003B020726181818181A120A140E0600"
28#define NRF_WIFI_PHY_CALIB_FLAG_RXDC 1
29#define NRF_WIFI_PHY_CALIB_FLAG_TXDC 2
30#define NRF_WIFI_PHY_CALIB_FLAG_TXPOW 0
31#define NRF_WIFI_PHY_CALIB_FLAG_TXIQ 8
32#define NRF_WIFI_PHY_CALIB_FLAG_RXIQ 16
33#define NRF_WIFI_PHY_CALIB_FLAG_DPD 32
34#define NRF_WIFI_PHY_CALIB_FLAG_ENHANCED_TXDC 64
36#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_RXDC (1<<16)
37#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXDC (2<<16)
38#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXPOW (0<<16)
39#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXIQ (0<<16)
40#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_RXIQ (0<<16)
41#define NRF_WIFI_PHY_SCAN_CALIB_FLAG_DPD (0<<16)
43#define NRF_WIFI_DEF_PHY_CALIB (NRF_WIFI_PHY_CALIB_FLAG_RXDC |\
44 NRF_WIFI_PHY_CALIB_FLAG_TXDC |\
45 NRF_WIFI_PHY_CALIB_FLAG_RXIQ |\
46 NRF_WIFI_PHY_CALIB_FLAG_TXIQ |\
47 NRF_WIFI_PHY_CALIB_FLAG_TXPOW |\
48 NRF_WIFI_PHY_CALIB_FLAG_DPD |\
49 NRF_WIFI_PHY_CALIB_FLAG_ENHANCED_TXDC |\
50 NRF_WIFI_PHY_SCAN_CALIB_FLAG_RXDC |\
51 NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXDC |\
52 NRF_WIFI_PHY_SCAN_CALIB_FLAG_RXIQ |\
53 NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXIQ |\
54 NRF_WIFI_PHY_SCAN_CALIB_FLAG_TXPOW |\
55 NRF_WIFI_PHY_SCAN_CALIB_FLAG_DPD)
58#define NRF_WIFI_DEF_PHY_TEMP_CALIB (NRF_WIFI_PHY_CALIB_FLAG_RXDC |\
59 NRF_WIFI_PHY_CALIB_FLAG_TXDC |\
60 NRF_WIFI_PHY_CALIB_FLAG_RXIQ |\
61 NRF_WIFI_PHY_CALIB_FLAG_TXIQ |\
62 NRF_WIFI_PHY_CALIB_FLAG_TXPOW |\
63 NRF_WIFI_PHY_CALIB_FLAG_DPD)
66#define NRF_WIFI_TEMP_CALIB_PERIOD (1024 * 1024)
67#define NRF_WIFI_TEMP_CALIB_THRESHOLD (40)
68#define NRF_WIFI_TEMP_CALIB_ENABLE 1
71#define NRF_WIFI_DEF_PHY_VBAT_CALIB (NRF_WIFI_PHY_CALIB_FLAG_DPD)
72#define NRF_WIFI_VBAT_VERYLOW (8)
73#define NRF_WIFI_VBAT_LOW (12)
74#define NRF_WIFI_VBAT_HIGH (14)
77#define QFN_PACKAGE_INFO 0x5146
78#define CSP_PACKAGE_INFO 0x4345
83#define PD_ADJUST_VAL 0
86#define RX_GAIN_OFFSET_LB_CHAN 0
87#define RX_GAIN_OFFSET_HB_LOW_CHAN 0
88#define RX_GAIN_OFFSET_HB_MID_CHAN 0
89#define RX_GAIN_OFFSET_HB_HIGH_CHAN 0
92#define SYSTEM_OFFSET_LB 3
93#define SYSTEM_OFFSET_HB_CHAN_LOW 3
94#define SYSTEM_OFFSET_HB_CHAN_MID 3
95#define SYSTEM_OFFSET_HB_CHAN_HIGH 3
103#define QFN_XO_VAL 0x2A
106#define QFN_MAX_TX_PWR_DSSS 0x54
107#define QFN_MAX_TX_PWR_LB_MCS7 0x40
108#define QFN_MAX_TX_PWR_LB_MCS0 0x40
113#define QFN_MAX_TX_PWR_HB_LOW_CHAN_MCS7 0x34
114#define QFN_MAX_TX_PWR_HB_MID_CHAN_MCS7 0x34
115#define QFN_MAX_TX_PWR_HB_HIGH_CHAN_MCS7 0x30
120#define QFN_MAX_TX_PWR_HB_LOW_CHAN_MCS0 0x38
121#define QFN_MAX_TX_PWR_HB_MID_CHAN_MCS0 0x34
122#define QFN_MAX_TX_PWR_HB_HIGH_CHAN_MCS0 0x30
125#define QFN_MAX_CHIP_TEMP 0x43
128#define QFN_MIN_CHIP_TEMP 0x07
134#define QFN_LB_MAX_PWR_BKF_HI_TEMP 0xFC
135#define QFN_LB_MAX_PWR_BKF_LOW_TEMP 0x00
136#define QFN_HB_MAX_PWR_BKF_HI_TEMP 0xF8
137#define QFN_HB_MAX_PWR_BKF_LOW_TEMP 0xFC
142#define QFN_LB_VBT_LT_VLOW 0xFC
143#define QFN_HB_VBT_LT_VLOW 0xF8
148#define QFN_LB_VBT_LT_LOW 0x00
149#define QFN_HB_VBT_LT_LOW 0xFC
155#define CSP_XO_VAL 0x2A
158#define CSP_MAX_TX_PWR_DSSS 0x48
159#define CSP_MAX_TX_PWR_LB_MCS7 0x44
160#define CSP_MAX_TX_PWR_LB_MCS0 0x44
165#define CSP_MAX_TX_PWR_HB_LOW_CHAN_MCS7 0x3C
166#define CSP_MAX_TX_PWR_HB_MID_CHAN_MCS7 0x3C
167#define CSP_MAX_TX_PWR_HB_HIGH_CHAN_MCS7 0x3C
172#define CSP_MAX_TX_PWR_HB_LOW_CHAN_MCS0 0x3C
173#define CSP_MAX_TX_PWR_HB_MID_CHAN_MCS0 0x3C
174#define CSP_MAX_TX_PWR_HB_HIGH_CHAN_MCS0 0x3C
177#define CSP_MAX_CHIP_TEMP 0x43
180#define CSP_MIN_CHIP_TEMP 0x07
186#define CSP_LB_MAX_PWR_BKF_HI_TEMP 0xEC
187#define CSP_LB_MAX_PWR_BKF_LOW_TEMP 0x00
188#define CSP_HB_MAX_PWR_BKF_HI_TEMP 0xFC
189#define CSP_HB_MAX_PWR_BKF_LOW_TEMP 0xF4
194#define CSP_LB_VBT_LT_VLOW 0xFC
195#define CSP_HB_VBT_LT_VLOW 0xEC
200#define CSP_LB_VBT_LT_LOW 0x00
201#define CSP_HB_VBT_LT_LOW 0xF8
399#ifdef CONFIG_NRF700X_RADIO_TEST
401#define MAX_CAPTURE_LEN 16383
402#define MIN_CAPTURE_LEN 0
403#define RX_CAPTURE_TIMEOUT_CONST 11
404#define CAPTURE_DURATION_IN_SEC 600
406enum nrf_wifi_rf_test {
407 NRF_WIFI_RF_TEST_RX_ADC_CAP,
408 NRF_WIFI_RF_TEST_RX_STAT_PKT_CAP,
409 NRF_WIFI_RF_TEST_RX_DYN_PKT_CAP,
410 NRF_WIFI_RF_TEST_TX_TONE,
411 NRF_WIFI_RF_TEST_DPD,
412 NRF_WIFI_RF_TEST_RF_RSSI,
413 NRF_WIFI_RF_TEST_SLEEP,
414 NRF_WIFI_RF_TEST_GET_TEMPERATURE,
415 NRF_WIFI_RF_TEST_XO_CALIB,
416 NRF_WIFI_RF_TEST_XO_TUNE,
417 NRF_WIFI_RF_TEST_MAX,
420enum nrf_wifi_rf_test_event {
421 NRF_WIFI_RF_TEST_EVENT_RX_ADC_CAP,
422 NRF_WIFI_RF_TEST_EVENT_RX_STAT_PKT_CAP,
423 NRF_WIFI_RF_TEST_EVENT_RX_DYN_PKT_CAP,
424 NRF_WIFI_RF_TEST_EVENT_TX_TONE_START,
425 NRF_WIFI_RF_TEST_EVENT_DPD_ENABLE,
426 NRF_WIFI_RF_TEST_EVENT_RF_RSSI,
427 NRF_WIFI_RF_TEST_EVENT_SLEEP,
428 NRF_WIFI_RF_TEST_EVENT_TEMP_MEAS,
429 NRF_WIFI_RF_TEST_EVENT_XO_CALIB,
430 NRF_WIFI_RF_TEST_EVENT_MAX,
434struct nrf_wifi_rf_test_capture_params {
438 unsigned short int cap_len;
441 unsigned short int cap_time;
448 unsigned char capture_status;
457 unsigned char lna_gain;
462 unsigned char bb_gain;
466struct nrf_wifi_rf_test_capture_meas {
483struct nrf_wifi_rf_test_tx_params {
487 signed char tone_freq;
495 unsigned char enabled;
498struct nrf_wifi_rf_test_dpd_params {
500 unsigned char enabled;
504struct nrf_wifi_temperature_params {
508 signed int temperature;
514 unsigned int readTemperatureStatus;
517struct nrf_wifi_rf_get_rf_rssi {
519 unsigned char lna_gain;
520 unsigned char bb_gain;
521 unsigned char agc_status_val;
524struct nrf_wifi_rf_test_xo_calib {
528 unsigned char xo_val;
532struct nrf_wifi_rf_get_xo_value {
536 unsigned char xo_value;
560#ifndef CONFIG_NRF70_2_4G_ONLY
598#define FT_PROG_VER1_2G_DSSS_TXCEIL_BKOFF 0
599#define FT_PROG_VER1_2G_OFDM_TXCEIL_BKOFF 0
600#define FT_PROG_VER1_5G_LOW_OFDM_TXCEIL_BKOFF 0
601#define FT_PROG_VER1_5G_MID_OFDM_TXCEIL_BKOFF 0
602#define FT_PROG_VER1_5G_HIGH_OFDM_TXCEIL_BKOFF 0
603#define FT_PROG_VER2_2G_DSSS_TXCEIL_BKOFF 0
604#define FT_PROG_VER2_2G_OFDM_TXCEIL_BKOFF 0
605#define FT_PROG_VER2_5G_LOW_OFDM_TXCEIL_BKOFF 0
606#define FT_PROG_VER2_5G_MID_OFDM_TXCEIL_BKOFF 0
607#define FT_PROG_VER2_5G_HIGH_OFDM_TXCEIL_BKOFF 0
608#define FT_PROG_VER3_2G_DSSS_TXCEIL_BKOFF 0
609#define FT_PROG_VER3_2G_OFDM_TXCEIL_BKOFF 0
610#define FT_PROG_VER3_5G_LOW_OFDM_TXCEIL_BKOFF 0
611#define FT_PROG_VER3_5G_MID_OFDM_TXCEIL_BKOFF 0
612#define FT_PROG_VER3_5G_HIGH_OFDM_TXCEIL_BKOFF 0
PCB_LOSS_BYTE_OFFSETS
Definition: phy_rf_params.h:347
@ PCB_LOSS_BYTE_5G_BAND3_OFST
Definition: phy_rf_params.h:351
@ PCB_LOSS_BYTE_5G_BAND2_OFST
Definition: phy_rf_params.h:350
@ PCB_LOSS_BYTE_2G_OFST
Definition: phy_rf_params.h:348
@ PCB_LOSS_BYTE_5G_BAND1_OFST
Definition: phy_rf_params.h:349
#define NRF_WIFI_RF_PARAMS_SIZE
PHY init config parameters. These are passed to phy at init.
Definition: phy_rf_params.h:15
RF_PARAMS_OFFSETS
Definition: phy_rf_params.h:315
@ NRF_WIFI_TX_PWR_CEIL_BYTE_OFFSET
Definition: phy_rf_params.h:319
@ NRF_WIFI_VT_DEPEND_PARAMS_BYTE_OFFSET
Definition: phy_rf_params.h:321
@ NRF_WIFI_RX_GAIN_BYTE_OFFSET
Definition: phy_rf_params.h:320
@ NRF_WIFI_PD_ADST_VAL_BYTE_OFFSET
Definition: phy_rf_params.h:317
@ NRF_WIFI_TX_PWR_SYSTM_BYTE_OFFSET
Definition: phy_rf_params.h:318
@ NRF_WIFI_XO_FREQ_BYTE_OFFSET
Definition: phy_rf_params.h:316
MAX_POWER_OFFSETS
Definition: phy_rf_params.h:332
@ NRF_WIFI_MAX_OP_PWR_5GHZ_MID_MCS0
Definition: phy_rf_params.h:340
@ NRF_WIFI_MAX_OP_PWR_DSSS_OFST
Definition: phy_rf_params.h:333
@ NRF_WIFI_MAX_OP_PWR_5GHZ_LB_MCS7
Definition: phy_rf_params.h:336
@ NRF_WIFI_MAX_OP_PWR_5GHZ_HI_MCS7
Definition: phy_rf_params.h:338
@ NRF_WIFI_MAX_OP_PWR_2PT4GHZ_OFDM_MCS7
Definition: phy_rf_params.h:334
@ NRF_WIFI_MAX_OP_PWR_5GHZ_LB_MCS0
Definition: phy_rf_params.h:339
@ NRF_WIFI_MAX_OP_PWR_5GHZ_MID_MCS7
Definition: phy_rf_params.h:337
@ NRF_WIFI_MAX_OP_PWR_2PT4GHZ_OFDM_MCS0
Definition: phy_rf_params.h:335
@ NRF_WIFI_MAX_OP_PWR_5GHZ_HI_MCS0
Definition: phy_rf_params.h:341
#define NRF_WIFI_RF_PARAMS_CONF_SIZE
Definition: phy_rf_params.h:16
EDGE_BACKOFF_OFFSETS
Definition: phy_rf_params.h:369
@ BAND_UNII_1_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:376
@ BAND_UNII_2C_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:385
@ BAND_UNII_2A_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:380
@ BAND_2G_LW_ED_BKF_DSSS_OFST
Definition: phy_rf_params.h:370
@ BAND_UNII_3_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:391
@ BAND_UNII_1_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:377
@ BAND_UNII_3_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:390
@ BAND_UNII_2C_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:386
@ BAND_UNII_2C_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:384
@ BAND_UNII_3_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:389
@ BAND_UNII_4_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:393
@ BAND_UNII_1_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:378
@ BAND_2G_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:371
@ BAND_UNII_2A_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:382
@ BAND_UNII_4_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:395
@ BAND_2G_UW_ED_BKF_DSSS_OFST
Definition: phy_rf_params.h:373
@ BAND_UNII_2C_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:387
@ BAND_2G_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:372
@ BAND_UNII_1_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:379
@ BAND_UNII_2A_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:383
@ BAND_2G_UW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:375
@ BAND_UNII_2A_LW_ED_BKF_HE_OFST
Definition: phy_rf_params.h:381
@ BAND_2G_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:374
@ BAND_UNII_3_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:388
@ BAND_UNII_4_LW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:392
@ NUM_EDGE_BACKOFF
Definition: phy_rf_params.h:396
@ BAND_UNII_4_UW_ED_BKF_HT_OFST
Definition: phy_rf_params.h:394
ANT_GAIN_OFFSETS
Definition: phy_rf_params.h:357
@ ANT_GAIN_2G_OFST
Definition: phy_rf_params.h:358
@ ANT_GAIN_5G_BAND1_OFST
Definition: phy_rf_params.h:359
@ ANT_GAIN_5G_BAND3_OFST
Definition: phy_rf_params.h:361
@ ANT_GAIN_5G_BAND2_OFST
Definition: phy_rf_params.h:360
@ NUM_ANT_GAIN
Definition: phy_rf_params.h:362
ft_prog_ver
Definition: phy_rf_params.h:589
@ FT_PROG_VER1
Definition: phy_rf_params.h:590
@ FT_PROG_VER2
Definition: phy_rf_params.h:591
@ FT_PROG_VER3
Definition: phy_rf_params.h:592
signed char pd_adjt_hb_mid_chan
Definition: phy_rf_params.h:216
signed char pd_adjt_hb_low_chan
Definition: phy_rf_params.h:214
signed char pd_adjt_hb_high_chan
Definition: phy_rf_params.h:218
signed char pd_adjt_lb_chan
Definition: phy_rf_params.h:212
Definition: phy_rf_params.h:210
struct nrf_wifi_pd_adst_val pd_adjust_val
Definition: phy_rf_params.h:302
struct nrf_wifi_temp_volt_depend_params temp_volt_backoff
Definition: phy_rf_params.h:306
struct nrf_wifi_xo_freq_offset xo_offset
Definition: phy_rf_params.h:301
struct nrf_wifi_rx_gain_offset rx_gain_offset
Definition: phy_rf_params.h:305
unsigned char phy_params[200 - 42]
Definition: phy_rf_params.h:307
struct nrf_wifi_tx_pwr_systm_offset syst_tx_pwr_offset
Definition: phy_rf_params.h:303
struct nrf_wifi_tx_pwr_ceil max_pwr_ceil
Definition: phy_rf_params.h:304
unsigned char reserved[6]
Definition: phy_rf_params.h:300
Definition: phy_rf_params.h:299
signed char rx_gain_hb_high_chan
Definition: phy_rf_params.h:266
signed char rx_gain_lb_chan
Definition: phy_rf_params.h:260
signed char rx_gain_hb_low_chan
Definition: phy_rf_params.h:262
signed char rx_gain_hb_mid_chan
Definition: phy_rf_params.h:264
Definition: phy_rf_params.h:258
signed char lb_max_pwr_bkf_hi_temp
Definition: phy_rf_params.h:276
signed char hb_vbt_lt_low
Definition: phy_rf_params.h:290
signed char hb_vbt_lt_vlow
Definition: phy_rf_params.h:286
signed char reserved[4]
Definition: phy_rf_params.h:292
signed char lb_vbt_lt_vlow
Definition: phy_rf_params.h:284
signed char max_chip_temp
Definition: phy_rf_params.h:272
signed char hb_max_pwr_bkf_hi_temp
Definition: phy_rf_params.h:280
signed char lb_max_pwr_bkf_low_temp
Definition: phy_rf_params.h:278
signed char lb_vbt_lt_low
Definition: phy_rf_params.h:288
signed char hb_max_pwr_bkf_low_temp
Definition: phy_rf_params.h:282
signed char min_chip_temp
Definition: phy_rf_params.h:274
Definition: phy_rf_params.h:270
unsigned char max_pwr_5g_low_mcs0
Definition: phy_rf_params.h:564
unsigned char max_pwr_5g_low_mcs7
Definition: phy_rf_params.h:568
unsigned char max_pwr_2g_dsss
Definition: phy_rf_params.h:550
unsigned char max_pwr_5g_high_mcs7
Definition: phy_rf_params.h:584
unsigned char max_pwr_5g_high_mcs0
Definition: phy_rf_params.h:580
unsigned char max_pwr_2g_mcs7
Definition: phy_rf_params.h:558
unsigned char max_pwr_2g_mcs0
Definition: phy_rf_params.h:554
unsigned char max_pwr_5g_mid_mcs0
Definition: phy_rf_params.h:572
unsigned char max_pwr_5g_mid_mcs7
Definition: phy_rf_params.h:576
This structure defines the parameters used to control the max transmit (TX) power in both frequency b...
Definition: phy_rf_params.h:546
signed char max_lb_mcs0_pwr
Definition: phy_rf_params.h:242
signed char max_hb_low_chan_mcs0_pwr
Definition: phy_rf_params.h:250
signed char max_lb_mcs7_pwr
Definition: phy_rf_params.h:240
signed char max_hb_high_chan_mcs0_pwr
Definition: phy_rf_params.h:254
signed char max_hb_mid_chan_mcs7_pwr
Definition: phy_rf_params.h:246
signed char max_hb_low_chan_mcs7_pwr
Definition: phy_rf_params.h:244
signed char max_hb_mid_chan_mcs0_pwr
Definition: phy_rf_params.h:252
signed char max_hb_high_chan_mcs7_pwr
Definition: phy_rf_params.h:248
signed char max_dsss_pwr
Definition: phy_rf_params.h:238
Definition: phy_rf_params.h:236
signed char syst_off_hb_mid_chan
Definition: phy_rf_params.h:230
signed char syst_off_hb_high_chan
Definition: phy_rf_params.h:232
signed char syst_off_hb_low_chan
Definition: phy_rf_params.h:228
signed char syst_off_lb_chan
Definition: phy_rf_params.h:226
Definition: phy_rf_params.h:224
unsigned char xo_freq_offset
Definition: phy_rf_params.h:206
Definition: phy_rf_params.h:205