Skip to content

Commit dd9f8bf

Browse files
committed
feat(wifi): chip esp32c5 eco2 support wifi
1 parent 4ba9e7f commit dd9f8bf

File tree

55 files changed

+388
-314
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+388
-314
lines changed

components/esp_phy/esp32c5/phy_init_data.c

Lines changed: 201 additions & 201 deletions
Large diffs are not rendered by default.

components/esp_rom/esp32c5/ld/esp32c5.rom.net80211.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ wifi_get_macaddr = 0x40000bc4;
6565
wifi_rf_phy_disable = 0x40000bc8;
6666
wifi_rf_phy_enable = 0x40000bcc;
6767
wifi_is_started = 0x40000bd0;
68-
sta_input = 0x40000bd4;
68+
/*sta_input = 0x40000bd4;*/
6969
sta_rx_eapol = 0x40000bd8;
7070
sta_reset_beacon_timeout = 0x40000bdc;
7171
sta_get_beacon_timeout = 0x40000be0;

components/esp_rom/esp32c5/ld/esp32c5.rom.pp.ld

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ lmacRecycleMPDU = 0x40000cc0;
7474
lmacRxDone = 0x40000cc4;
7575
lmacSetTxFrame = 0x40000cc8;
7676
lmacTxDone = 0x40000ccc;
77-
lmacTxFrame = 0x40000cd0;
77+
/*lmacTxFrame = 0x40000cd0;*/
7878
lmacDisableTransmit = 0x40000cd4;
7979
lmacDiscardFrameExchangeSequence = 0x40000cd8;
8080
lmacProcessCollision = 0x40000cdc;
@@ -116,7 +116,7 @@ pm_local_tsf_process = 0x40000d68;
116116
pm_set_beacon_filter = 0x40000d6c;
117117
/*pm_is_in_wifi_slice_threshold = 0x40000d70;*/
118118
pm_is_waked = 0x40000d74;
119-
pm_keep_alive = 0x40000d78;
119+
/*pm_keep_alive = 0x40000d78;*/
120120
pm_on_beacon_rx = 0x40000d7c;
121121
pm_on_data_rx = 0x40000d80;
122122
pm_on_data_tx = 0x40000d84;
@@ -144,7 +144,7 @@ pm_tx_data_process = 0x40000dd8;
144144
pm_is_twt_awake = 0x40000ddc;
145145
pm_enable_twt_keep_alive = 0x40000de0;
146146
pm_twt_on_tsf_timer = 0x40000de4;
147-
pm_twt_process = 0x40000de8;
147+
/*pm_twt_process = 0x40000de8;*/
148148
pm_is_twt_start = 0x40000dec;
149149
pm_twt_set_target_wdev_time = 0x40000df0;
150150
pm_twt_set_target_tsf = 0x40000df4;
@@ -175,10 +175,10 @@ ppEmptyDelimiterLength = 0x40000e54;
175175
ppEnqueueRxq = 0x40000e58;
176176
ppEnqueueTxDone = 0x40000e5c;
177177
ppGetTxframe = 0x40000e60;
178-
ppMapTxQueue = 0x40000e64;
178+
/*ppMapTxQueue = 0x40000e64;*/
179179
ppProcTxSecFrame = 0x40000e68;
180180
ppProcessRxPktHdr = 0x40000e6c;
181-
ppProcessTxQ = 0x40000e70;
181+
/*ppProcessTxQ = 0x40000e70;*/
182182
ppRecordBarRRC = 0x40000e74;
183183
ppRecycleAmpdu = 0x40000e78;
184184
ppRecycleRxPkt = 0x40000e7c;
@@ -230,7 +230,7 @@ rcampduuprate = 0x40000f30;
230230
rcClearCurAMPDUSched = 0x40000f34;
231231
rcClearCurSched = 0x40000f38;
232232
rcClearCurStat = 0x40000f3c;
233-
rcGetSched = 0x40000f40;
233+
/*rcGetSched = 0x40000f40;*/
234234
rcLowerSched = 0x40000f44;
235235
rcSetTxAmpduLimit = 0x40000f48;
236236
rcTxUpdatePer = 0x40000f4c;
@@ -270,7 +270,7 @@ wdev_mac_special_reg_store = 0x40000fd0;
270270
wdev_mac_wakeup = 0x40000fd4;
271271
wdev_mac_sleep = 0x40000fd8;
272272
wDev_ProcessFiq = 0x40000fdc;
273-
wDev_ProcessRxSucData = 0x40000fe0;
273+
/*wDev_ProcessRxSucData = 0x40000fe0;*/
274274
wdevProcessRxSucDataAll = 0x40000fe4;
275275
wdev_csi_len_align = 0x40000fe8;
276276
wDev_IndicateBeaconMemoryFrame = 0x40000fec;
@@ -483,7 +483,7 @@ tsf_hal_get_counter_value = 0x40001524;
483483
***************************************/
484484

485485
/* Functions */
486-
pm_enable_max_idle_timer = 0x400015b8;
486+
/*pm_enable_max_idle_timer = 0x400015b8;*/
487487
pm_beacon_offset_is_enabled = 0x400015bc;
488488
pm_beacon_offset_is_sampling = 0x400015c0;
489489
pm_beacon_offset_add_total_counter = 0x400015c4;

components/esp_wifi/include/esp_private/esp_wifi_he_private.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,8 @@ esp_err_t esp_test_clr_rx_ctrls(void);
198198
esp_err_t esp_test_get_rx_ctrls(esp_test_rx_ctrl_t* rx);
199199

200200
void hal_set_tx_pwr(wifi_phy_rate_t rate, int8_t max_pwr);
201-
int8_t hal_get_tx_pwr(wifi_phy_rate_t rate);
201+
void esp_wifi_disable_obss_narrow_bw_ru(bool disable);
202+
void esp_wifi_set_bmfmee_nsts(bool he, uint8_t bmfmee_sts);
202203

203204
#ifdef __cplusplus
204205
}

components/esp_wifi/include/esp_private/esp_wifi_he_types_private.h

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD
2+
* SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -245,6 +245,11 @@ typedef struct {
245245
uint32_t rx_ndpa;
246246
uint32_t rx_reset_rxbase_cnt;
247247
uint32_t rx_base_null_cnt;
248+
uint32_t vht_mu[64][4];
249+
uint32_t vht_mu_noeb;
250+
uint32_t vht_mu_stbc;
251+
uint32_t vht_mu_retry[64][4];
252+
uint16_t vht_mu_mcs[64][4][12];
248253
} esp_test_rx_statistics_t; //140 bytes
249254

250255
#else
@@ -366,6 +371,8 @@ typedef struct {
366371
uint16_t tb_cca_cancel;
367372
uint16_t tb_sifs_abort;
368373
uint16_t tb_pwr_outof_range;
374+
uint16_t vht_bfrpt;
375+
uint16_t polled_vht_bfrpt;
369376
} esp_test_hw_tb_statistics_t; //14 bytes
370377

371378
typedef struct {
@@ -400,6 +407,7 @@ typedef struct {
400407
uint16_t nrx_err_serv;
401408
uint16_t nrx_err_txover;
402409
uint16_t nrx_err_unsupport;
410+
uint16_t nrx_err_heformat;
403411
uint16_t nrx_htsig_err;
404412
uint16_t nrx_heunsupport;
405413
uint16_t nrx_hesiga_crc;
@@ -410,6 +418,8 @@ typedef struct {
410418
uint32_t rxtxpanic;
411419
uint8_t bf_ndp_timeout;
412420
uint8_t bf_report_err;
421+
uint16_t nrx_vhtunsupport;
422+
uint16_t nrx_vhtsiga_crc;
413423
#endif
414424
} esp_test_hw_rx_statistics_t; //76->80 bytes
415425

@@ -431,6 +441,12 @@ typedef struct {
431441
int bfrp;
432442
int nfrp;
433443
int bar;
444+
int trigger_basic_cnt;
445+
int trigger_basic_id_0_cnt;
446+
int trigger_basic_id_2045_cnt;
447+
int trigger_basic_id_2046_cnt;
448+
int trigger_basic_id_other_cnt;
449+
int bfpoll;
434450
} esp_test_rx_ctrl_t;
435451

436452
typedef enum {

components/esp_wifi/include/esp_wifi.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -774,6 +774,8 @@ esp_err_t esp_wifi_get_bandwidth(wifi_interface_t ifx, wifi_bandwidth_t *bw);
774774
* @attention 4. When device is in STA+softAP mode, this API should not be called when in the scenarios described above
775775
* @attention 5. The channel info set by this API will not be stored in NVS. So If you want to remember the channel used before WiFi stop,
776776
* you need to call this API again after WiFi start, or you can call `esp_wifi_set_config()` to store the channel info in NVS.
777+
* @attention 6. When operating in 5 GHz band, the second channel is automatically determined by the primary channel according to the 802.11 standard.
778+
* Any manually configured second channel will be ignored.
777779
*
778780
* @param primary for HT20, primary is the channel number, for HT40, primary is the primary channel
779781
* @param second for HT20, second is ignored, for HT40, second is the second channel

components/esp_wifi/include/esp_wifi_he_types.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD
2+
* SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -167,6 +167,7 @@ typedef enum {
167167
RX_BB_FORMAT_HE_MU = 5, /**< the reception frame is a HE MU MPDU */
168168
RX_BB_FORMAT_HE_ERSU = 6, /**< the reception frame is a HE ER SU MPDU */
169169
RX_BB_FORMAT_HE_TB = 7, /**< the reception frame is a HE TB MPDU */
170+
RX_BB_FORMAT_VHT_MU = 11, /**< the reception frame is a VHT MU MPDU */
170171
} wifi_rx_bb_format_t;
171172

172173
/**

components/esp_wifi/include/esp_wifi_types_generic.h

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -562,21 +562,24 @@ typedef struct {
562562
uint32_t ft_enabled: 1; /**< Whether FT is enabled for the connection */
563563
uint32_t owe_enabled: 1; /**< Whether OWE is enabled for the connection */
564564
uint32_t transition_disable: 1; /**< Whether to enable transition disable feature */
565-
uint32_t reserved: 26; /**< Reserved for future feature set */
565+
uint32_t reserved1: 26; /**< Reserved for future feature set */
566566
wifi_sae_pwe_method_t sae_pwe_h2e; /**< Configuration for SAE PWE derivation method */
567567
wifi_sae_pk_mode_t sae_pk_mode; /**< Configuration for SAE-PK (Public Key) Authentication method */
568568
uint8_t failure_retry_cnt; /**< Number of connection retries station will do before moving to next AP. scan_method should be set as WIFI_ALL_CHANNEL_SCAN to use this config.
569569
Note: Enabling this may cause connection time to increase in case best AP doesn't behave properly. */
570570
uint32_t he_dcm_set: 1; /**< Whether DCM max.constellation for transmission and reception is set. */
571571
uint32_t he_dcm_max_constellation_tx: 2; /**< Indicate the max.constellation for DCM in TB PPDU the STA supported. 0: not supported. 1: BPSK, 2: QPSK, 3: 16-QAM. The default value is 3. */
572572
uint32_t he_dcm_max_constellation_rx: 2; /**< Indicate the max.constellation for DCM in both Data field and HE-SIG-B field the STA supported. 0: not supported. 1: BPSK, 2: QPSK, 3: 16-QAM. The default value is 3. */
573-
uint32_t he_mcs9_enabled: 1; /**< Whether to support HE-MCS 0 to 9. The default value is 0. */
573+
uint32_t he_mcs9_enabled: 1; /**< Whether to support HE-MCS8 and HE-MCS9. The default value is 0. */
574574
uint32_t he_su_beamformee_disabled: 1; /**< Whether to disable support for operation as an SU beamformee. */
575575
uint32_t he_trig_su_bmforming_feedback_disabled: 1; /**< Whether to disable support the transmission of SU feedback in an HE TB sounding sequence. */
576576
uint32_t he_trig_mu_bmforming_partial_feedback_disabled: 1; /**< Whether to disable support the transmission of partial-bandwidth MU feedback in an HE TB sounding sequence. */
577577
uint32_t he_trig_cqi_feedback_disabled: 1; /**< Whether to disable support the transmission of CQI feedback in an HE TB sounding sequence. */
578-
uint32_t he_reserved: 22; /**< Reserved for future feature set */
579-
uint8_t sae_h2e_identifier[SAE_H2E_IDENTIFIER_LEN]; /**< Password identifier for H2E. this needs to be null terminated string */
578+
uint32_t vht_su_beamformee_disabled: 1; /**< Whether to disable support for operation as an VHT SU beamformee. */
579+
uint32_t vht_mu_beamformee_disabled: 1; /**< Whether to disable support for operation as an VHT MU beamformee. */
580+
uint32_t vht_mcs8_enabled: 1; /**< Whether to support VHT-MCS8. The default value is 0. */
581+
uint32_t reserved2: 19; /**< Reserved for future feature set */
582+
uint8_t sae_h2e_identifier[SAE_H2E_IDENTIFIER_LEN];/**< Password identifier for H2E. this needs to be null terminated string */
580583
} wifi_sta_config_t;
581584

582585
/**

0 commit comments

Comments
 (0)