Skip to content

Commit

Permalink
ESP32C3 support
Browse files Browse the repository at this point in the history
  • Loading branch information
rojer committed Aug 6, 2022
1 parent cb995cd commit 00fb9e8
Show file tree
Hide file tree
Showing 3 changed files with 108 additions and 104 deletions.
35 changes: 0 additions & 35 deletions include/esp32/esp32_wifi.h

This file was deleted.

40 changes: 40 additions & 0 deletions mos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,46 @@ conds:

- when: mos.platform == "esp32"
apply:
sources:
- src/esp32xx
libs:
- location: https://github.com/mongoose-os-libs/lwip
config_schema:
- ["wifi.ap.bandwidth_20mhz", "b", false, {title: "enable 20MHz bandwidth AP operation"}]
- ["wifi.ap.protocol", "s", "BGN", {title: "802.11 Wi-Fi Protocol for AP Mode, defaults to BGN, can be any combination of BGNLR. Note LR only works between 2 ESP32 devices."}]
- ["wifi.sta_ps_mode", "i", 0, {title: "Power save mode for station: 0 - none, 1 - min, 2 - max."}]
- ["wifi.sta.protocol", "s", "BGN", {title: "802.11 Wi-Fi Protocol for STA Mode, defaults to BGN, can be any combination of BGNLR. Note LR only works between 2 ESP32 devices."}]
- ["wifi.sta.listen_interval_ms", "i", 0, {title: "DTIM Listen Interval (ms)"}]
cdefs:
MGOS_WIFI_ENABLE_AP_STA: 1
build_vars:
ESP_IDF_EXTRA_COMPONENTS: >
${build_vars.ESP_IDF_EXTRA_COMPONENTS}
esp_wifi wpa_supplicant
ESP_IDF_SDKCONFIG_OPTS: >
${build_vars.ESP_IDF_SDKCONFIG_OPTS}
CONFIG_WIFI_ENABLED=y
CONFIG_ESP32_WIFI_SW_COEXIST_ENABLE=n
CONFIG_ESP32_WIFI_STATIC_RX_BUFFER_NUM=4
CONFIG_ESP32_WIFI_DYNAMIC_RX_BUFFER_NUM=16
CONFIG_ESP32_WIFI_STATIC_TX_BUFFER=n
CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER=y
CONFIG_ESP32_WIFI_TX_BUFFER_TYPE=1
CONFIG_ESP32_WIFI_DYNAMIC_TX_BUFFER_NUM=16
CONFIG_ESP32_WIFI_NVS_ENABLED=y
CONFIG_ESP32_WIFI_RX_BA_WIN=4
CONFIG_ESP_PHY_CALIBRATION_AND_DATA_STORAGE=y
CONFIG_ESP_PHY_INIT_DATA_IN_PARTITION=n
conds:
- when: build_vars.MGOS_LWIP_ENABLE_IPV4_NAT == "1"
apply:
config_schema:
- ["wifi.ap.ipv4_nat_enable", "b", false, {title: "Enable IPv4 NAT"}]

- when: mos.platform == "esp32c3"
apply:
sources:
- src/esp32xx
libs:
- location: https://github.com/mongoose-os-libs/lwip
config_schema:
Expand Down
Loading

0 comments on commit 00fb9e8

Please sign in to comment.