arch/esp32: Re-organise shared functions and options for ESP32 Wireless code
- Introduce the ESP32_WIFI option to replace the broader ESP32_WIRELESS option. ESP32_WIRELESS is used by both WIFI and BLE. - Move common functions from esp32_wifi_adapter to esp32_wireless. - Change the order of including the external libraries to avoid undefined references. Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
This commit is contained in:
parent
770147ffe3
commit
4ccedb176e
@ -481,6 +481,13 @@ config ESP32_WIRELESS
|
||||
---help---
|
||||
Enable Wireless support
|
||||
|
||||
config ESP32_WIFI
|
||||
bool "Wi-Fi"
|
||||
default n
|
||||
select ESP32_WIRELESS
|
||||
---help---
|
||||
Enable Wi-Fi support
|
||||
|
||||
config ESP32_BLE
|
||||
bool "BLE"
|
||||
default n
|
||||
@ -519,7 +526,7 @@ endmenu # ESP32 Peripheral Selection
|
||||
config ESP32_WIFI_BT_COEXIST
|
||||
bool "Wi-Fi and BT coexist"
|
||||
default n
|
||||
depends on ESP32_WIRELESS && ESP32_BLE
|
||||
depends on ESP32_WIFI && ESP32_BLE
|
||||
|
||||
menu "Memory Configuration"
|
||||
|
||||
@ -1191,7 +1198,7 @@ config ESP32_ETH_PHY_ADDR
|
||||
endmenu # ESP32_EMAC
|
||||
|
||||
menu "Wi-Fi configuration"
|
||||
depends on ESP32_WIRELESS
|
||||
depends on ESP32_WIFI
|
||||
|
||||
choice
|
||||
prompt "ESP32 Wi-Fi mode"
|
||||
@ -1327,7 +1334,7 @@ choice EXAMPLE_POWER_SAVE_MODE
|
||||
bool "maximum modem"
|
||||
endchoice
|
||||
|
||||
endmenu # ESP32_WIRELESS
|
||||
endmenu # ESP32_WIFI
|
||||
|
||||
menu "BLE Configuration"
|
||||
depends on ESP32_BLE
|
||||
|
@ -206,10 +206,19 @@ distclean::
|
||||
|
||||
INCLUDES += $(shell $(INCDIR) "$(CC)" $(ARCH_SRCDIR)$(DELIM)chip$(DELIM)esp-wireless-drivers-3rdparty$(DELIM)include)
|
||||
INCLUDES += $(shell $(INCDIR) "$(CC)" $(ARCH_SRCDIR)$(DELIM)chip$(DELIM)esp-wireless-drivers-3rdparty$(DELIM)include$(DELIM)esp32)
|
||||
CHIP_CSRCS += esp32_wlan.c esp32_wifi_utils.c esp32_wifi_adapter.c
|
||||
|
||||
EXTRA_LIBPATHS += -L $(ARCH_SRCDIR)$(DELIM)chip$(DELIM)esp-wireless-drivers-3rdparty$(DELIM)libs$(DELIM)esp32
|
||||
EXTRA_LIBS += -lcore -lrtc -lnet80211 -lpp -lsmartconfig -lespnow -lphy -lwpa_supplicant
|
||||
EXTRA_LIBS += -lphy -lrtc
|
||||
|
||||
# Wireless interfaces.
|
||||
|
||||
CHIP_CSRCS += esp32_wireless.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_ESP32_WIFI),y)
|
||||
CHIP_CSRCS += esp32_wlan.c esp32_wifi_utils.c esp32_wifi_adapter.c
|
||||
EXTRA_LIBS += -lcore -lnet80211 -lpp -lsmartconfig -lespnow -lwpa_supplicant
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_ESP32_BLE),y)
|
||||
CHIP_CSRCS += esp32_ble_adapter.c esp32_ble.c
|
||||
@ -218,8 +227,3 @@ EXTRA_LIBS += -lbtdm_app
|
||||
EXTRA_LIBS += -lcoexist
|
||||
endif
|
||||
endif
|
||||
|
||||
# Wireless interfaces.
|
||||
|
||||
CHIP_CSRCS += esp32_wireless.c
|
||||
endif
|
||||
|
@ -98,10 +98,10 @@
|
||||
#define ESP32_MAX_PRIORITY 5
|
||||
#define ESP32_PRIO_INDEX(p) ((p) - ESP32_MIN_PRIORITY)
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
# define ESP32_WIRELESS_RESERVE_INT (1 << ESP32_CPUINT_MAC)
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
# define ESP32_WIFI_RESERVE_INT (1 << ESP32_CPUINT_MAC)
|
||||
#else
|
||||
# define ESP32_WIRELESS_RESERVE_INT 0
|
||||
# define ESP32_WIFI_RESERVE_INT 0
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_BLE
|
||||
@ -170,7 +170,7 @@ static uint32_t g_intenable[CONFIG_SMP_NCPUS];
|
||||
*/
|
||||
|
||||
static uint32_t g_cpu0_freeints = ESP32_CPUINT_PERIPHSET &
|
||||
(~ESP32_WIRELESS_RESERVE_INT &
|
||||
(~ESP32_WIFI_RESERVE_INT &
|
||||
~ESP32_BLE_RESERVE_INT);
|
||||
#ifdef CONFIG_SMP
|
||||
static uint32_t g_cpu1_freeints = ESP32_CPUINT_PERIPHSET;
|
||||
@ -460,7 +460,7 @@ void up_irqinitialize(void)
|
||||
|
||||
g_irqmap[XTENSA_IRQ_TIMER0] = IRQ_MKMAP(0, ESP32_CPUINT_TIMER0);
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
g_irqmap[ESP32_IRQ_MAC] = IRQ_MKMAP(0, ESP32_CPUINT_MAC);
|
||||
#endif
|
||||
|
||||
@ -479,7 +479,7 @@ void up_irqinitialize(void)
|
||||
|
||||
/* Reserve CPU0 interrupt for some special drivers */
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
g_cpu0_intmap[ESP32_CPUINT_MAC] = CPUINT_ASSIGN(ESP32_IRQ_MAC);
|
||||
xtensa_enable_cpuint(&g_intenable[0], 1 << ESP32_CPUINT_MAC);
|
||||
#endif
|
||||
|
@ -2460,90 +2460,6 @@ static int32_t wifi_phy_update_country_info(const char *country)
|
||||
return -1;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_read_mac
|
||||
*
|
||||
* Description:
|
||||
* Read MAC address from efuse
|
||||
*
|
||||
* Input Parameters:
|
||||
* mac - MAC address buffer pointer
|
||||
* type - MAC address type
|
||||
*
|
||||
* Returned Value:
|
||||
* 0 if success or -1 if fail
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int32_t esp_read_mac(uint8_t *mac, esp_mac_type_t type)
|
||||
{
|
||||
uint32_t regval[2];
|
||||
uint8_t tmp;
|
||||
uint8_t *data = (uint8_t *)regval;
|
||||
uint8_t crc;
|
||||
int i;
|
||||
|
||||
if (type > ESP_MAC_BT)
|
||||
{
|
||||
wlerr("Input type is error=%d\n", type);
|
||||
return -1;
|
||||
}
|
||||
|
||||
regval[0] = getreg32(MAC_ADDR0_REG);
|
||||
regval[1] = getreg32(MAC_ADDR1_REG);
|
||||
|
||||
crc = data[6];
|
||||
for (i = 0; i < MAC_LEN; i++)
|
||||
{
|
||||
mac[i] = data[5 - i];
|
||||
}
|
||||
|
||||
if (crc != esp_crc8(mac, MAC_LEN))
|
||||
{
|
||||
wlerr("Failed to check MAC address CRC\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (type == ESP_MAC_WIFI_SOFTAP)
|
||||
{
|
||||
tmp = mac[0];
|
||||
for (i = 0; i < 64; i++)
|
||||
{
|
||||
mac[0] = tmp | 0x02;
|
||||
mac[0] ^= i << 2;
|
||||
|
||||
if (mac[0] != tmp)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (i >= 64)
|
||||
{
|
||||
wlerr("Failed to generate SoftAP MAC\n");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
if (type == ESP_MAC_BT)
|
||||
{
|
||||
tmp = mac[0];
|
||||
for (i = 0; i < 64; i++)
|
||||
{
|
||||
mac[0] = tmp | 0x02;
|
||||
mac[0] ^= i << 2;
|
||||
|
||||
if (mac[0] != tmp)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
mac[5] += 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_wifi_read_mac
|
||||
*
|
||||
@ -4294,98 +4210,6 @@ static int esp_freq_to_channel(uint16_t freq)
|
||||
return 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Functions needed by libphy.a
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_dport_access_reg_read
|
||||
*
|
||||
* Description:
|
||||
* Read register value safely in SMP
|
||||
*
|
||||
* Input Parameters:
|
||||
* reg - Register address
|
||||
*
|
||||
* Returned Value:
|
||||
* Register value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR esp_dport_access_reg_read(uint32_t reg)
|
||||
{
|
||||
return getreg32(reg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_enter_critical
|
||||
*
|
||||
* Description:
|
||||
* Enter critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* None
|
||||
*
|
||||
* Returned Value:
|
||||
* CPU PS value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR phy_enter_critical(void)
|
||||
{
|
||||
irqstate_t flags;
|
||||
|
||||
flags = enter_critical_section();
|
||||
|
||||
return flags;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_exit_critical
|
||||
*
|
||||
* Description:
|
||||
* Exit from critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* level - CPU PS value
|
||||
*
|
||||
* Returned Value:
|
||||
* None
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
void IRAM_ATTR phy_exit_critical(uint32_t level)
|
||||
{
|
||||
leave_critical_section(level);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_printf
|
||||
*
|
||||
* Description:
|
||||
* Output format string and its arguments
|
||||
*
|
||||
* Input Parameters:
|
||||
* format - format string
|
||||
*
|
||||
* Returned Value:
|
||||
* 0
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int phy_printf(const char *format, ...)
|
||||
{
|
||||
#ifdef CONFIG_DEBUG_WIRELESS_INFO
|
||||
va_list arg;
|
||||
|
||||
va_start(arg, format);
|
||||
vsyslog(LOG_INFO, format, arg);
|
||||
va_end(arg);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Functions needed by libnet80211.a
|
||||
****************************************************************************/
|
||||
|
@ -61,8 +61,6 @@ extern "C"
|
||||
# define ESP32_WLAN_DEVS 2
|
||||
#endif
|
||||
|
||||
#define MAC_LEN (6)
|
||||
|
||||
/* Needed to fix coex_adapter_funcs_t definition */
|
||||
|
||||
#define CONFIG_IDF_TARGET_ESP32 1
|
||||
|
@ -33,6 +33,7 @@
|
||||
|
||||
#include "esp32_wifi_adapter.h"
|
||||
#include "esp32_wifi_utils.h"
|
||||
#include "esp32_wireless.h"
|
||||
#include "espidf_wifi.h"
|
||||
|
||||
/****************************************************************************
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include "xtensa.h"
|
||||
#include "hardware/esp32_soc.h"
|
||||
#include "hardware/esp32_dport.h"
|
||||
#include "hardware/esp32_emac.h"
|
||||
#include "esp32_wireless.h"
|
||||
#include "esp_phy_init.h"
|
||||
#include "phy_init_data.h"
|
||||
@ -46,10 +47,11 @@ static inline void phy_digital_regs_load(void);
|
||||
* Extern Functions declaration
|
||||
****************************************************************************/
|
||||
|
||||
extern uint8_t esp_crc8(const uint8_t *p, uint32_t len);
|
||||
extern void coex_bt_high_prio(void);
|
||||
extern void phy_wakeup_init(void);
|
||||
extern void phy_close_rf(void);
|
||||
extern void phy_dig_reg_backup(bool init, uint32_t *regs);
|
||||
extern uint8_t phy_dig_reg_backup(bool init, uint32_t *regs);
|
||||
extern int register_chipv7_phy(const esp_phy_init_data_t *init_data,
|
||||
esp_phy_calibration_data_t *cal_data,
|
||||
esp_phy_calibration_mode_t cal_mode);
|
||||
@ -115,6 +117,102 @@ static inline void phy_digital_regs_load(void)
|
||||
}
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Functions needed by libphy.a
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_dport_access_reg_read
|
||||
*
|
||||
* Description:
|
||||
* Read register value safely in SMP
|
||||
*
|
||||
* Input Parameters:
|
||||
* reg - Register address
|
||||
*
|
||||
* Returned Value:
|
||||
* Register value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR esp_dport_access_reg_read(uint32_t reg)
|
||||
{
|
||||
return getreg32(reg);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_enter_critical
|
||||
*
|
||||
* Description:
|
||||
* Enter critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* None
|
||||
*
|
||||
* Returned Value:
|
||||
* CPU PS value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR phy_enter_critical(void)
|
||||
{
|
||||
irqstate_t flags;
|
||||
|
||||
flags = enter_critical_section();
|
||||
|
||||
return flags;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_exit_critical
|
||||
*
|
||||
* Description:
|
||||
* Exit from critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* level - CPU PS value
|
||||
*
|
||||
* Returned Value:
|
||||
* None
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
void IRAM_ATTR phy_exit_critical(uint32_t level)
|
||||
{
|
||||
leave_critical_section(level);
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_printf
|
||||
*
|
||||
* Description:
|
||||
* Output format string and its arguments
|
||||
*
|
||||
* Input Parameters:
|
||||
* format - format string
|
||||
*
|
||||
* Returned Value:
|
||||
* 0
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int phy_printf(const char *format, ...)
|
||||
{
|
||||
#ifdef CONFIG_DEBUG_WIRELESS_INFO
|
||||
va_list arg;
|
||||
|
||||
va_start(arg, format);
|
||||
vsyslog(LOG_INFO, format, arg);
|
||||
va_end(arg);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp32_phy_enable_clock
|
||||
*
|
||||
@ -181,9 +279,90 @@ void esp32_phy_disable_clock(void)
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
* Name: esp_read_mac
|
||||
*
|
||||
* Description:
|
||||
* Read MAC address from efuse
|
||||
*
|
||||
* Input Parameters:
|
||||
* mac - MAC address buffer pointer
|
||||
* type - MAC address type
|
||||
*
|
||||
* Returned Value:
|
||||
* 0 if success or -1 if fail
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int32_t esp_read_mac(uint8_t *mac, esp_mac_type_t type)
|
||||
{
|
||||
uint32_t regval[2];
|
||||
uint8_t tmp;
|
||||
uint8_t *data = (uint8_t *)regval;
|
||||
uint8_t crc;
|
||||
int i;
|
||||
|
||||
if (type > ESP_MAC_BT)
|
||||
{
|
||||
wlerr("Input type is error=%d\n", type);
|
||||
return -1;
|
||||
}
|
||||
|
||||
regval[0] = getreg32(MAC_ADDR0_REG);
|
||||
regval[1] = getreg32(MAC_ADDR1_REG);
|
||||
|
||||
crc = data[6];
|
||||
for (i = 0; i < MAC_LEN; i++)
|
||||
{
|
||||
mac[i] = data[5 - i];
|
||||
}
|
||||
|
||||
if (crc != esp_crc8(mac, MAC_LEN))
|
||||
{
|
||||
wlerr("Failed to check MAC address CRC\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (type == ESP_MAC_WIFI_SOFTAP)
|
||||
{
|
||||
tmp = mac[0];
|
||||
for (i = 0; i < 64; i++)
|
||||
{
|
||||
mac[0] = tmp | 0x02;
|
||||
mac[0] ^= i << 2;
|
||||
|
||||
if (mac[0] != tmp)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (i >= 64)
|
||||
{
|
||||
wlerr("Failed to generate SoftAP MAC\n");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
if (type == ESP_MAC_BT)
|
||||
{
|
||||
tmp = mac[0];
|
||||
for (i = 0; i < 64; i++)
|
||||
{
|
||||
mac[0] = tmp | 0x02;
|
||||
mac[0] ^= i << 2;
|
||||
|
||||
if (mac[0] != tmp)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
mac[5] += 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp32_phy_disable
|
||||
*
|
||||
|
@ -27,6 +27,10 @@
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include "xtensa_attr.h"
|
||||
|
||||
#include "espidf_wifi.h"
|
||||
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
@ -39,10 +43,29 @@
|
||||
#define CONFIG_MAC_BB_PD 0
|
||||
#define SOC_COEX_HW_PTI 0
|
||||
|
||||
#define MAC_LEN (6)
|
||||
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_read_mac
|
||||
*
|
||||
* Description:
|
||||
* Read MAC address from efuse
|
||||
*
|
||||
* Input Parameters:
|
||||
* mac - MAC address buffer pointer
|
||||
* type - MAC address type
|
||||
*
|
||||
* Returned Value:
|
||||
* 0 if success or -1 if fail
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int32_t esp_read_mac(uint8_t *mac, esp_mac_type_t type);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp32_phy_enable
|
||||
*
|
||||
@ -107,4 +130,72 @@ void esp32_phy_enable_clock(void);
|
||||
|
||||
void esp32_phy_disable_clock(void);
|
||||
|
||||
/****************************************************************************
|
||||
* Functions needed by libphy.a
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: esp_dport_access_reg_read
|
||||
*
|
||||
* Description:
|
||||
* Read register value safely in SMP
|
||||
*
|
||||
* Input Parameters:
|
||||
* reg - Register address
|
||||
*
|
||||
* Returned Value:
|
||||
* Register value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR esp_dport_access_reg_read(uint32_t reg);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_enter_critical
|
||||
*
|
||||
* Description:
|
||||
* Enter critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* None
|
||||
*
|
||||
* Returned Value:
|
||||
* CPU PS value
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
uint32_t IRAM_ATTR phy_enter_critical(void);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_exit_critical
|
||||
*
|
||||
* Description:
|
||||
* Exit from critical state
|
||||
*
|
||||
* Input Parameters:
|
||||
* level - CPU PS value
|
||||
*
|
||||
* Returned Value:
|
||||
* None
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
void IRAM_ATTR phy_exit_critical(uint32_t level);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: phy_printf
|
||||
*
|
||||
* Description:
|
||||
* Output format string and its arguments
|
||||
*
|
||||
* Input Parameters:
|
||||
* format - format string
|
||||
*
|
||||
* Returned Value:
|
||||
* 0
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int phy_printf(const char *format, ...) printflike(1, 2);
|
||||
|
||||
#endif /* __ARCH_XTENSA_SRC_ESP32_ESP32_WIRELESS_H */
|
||||
|
@ -24,7 +24,7 @@
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
|
||||
#include <queue.h>
|
||||
#include <assert.h>
|
||||
@ -1873,4 +1873,4 @@ int esp32_wlan_softap_initialize(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* CONFIG_ESP32_WIRELESS */
|
||||
#endif /* CONFIG_ESP32_WIFI */
|
||||
|
@ -40,7 +40,7 @@ extern "C"
|
||||
#define EXTERN extern
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
@ -82,7 +82,7 @@ int esp32_wlan_sta_initialize(void);
|
||||
int esp32_wlan_softap_initialize(void);
|
||||
#endif
|
||||
|
||||
#endif /* CONFIG_ESP32_WIRELESS */
|
||||
#endif /* CONFIG_ESP32_WIFI */
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -46,7 +46,7 @@ extern "C"
|
||||
* Public Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
|
||||
/****************************************************************************
|
||||
* Name: board_wlan_init
|
||||
@ -62,7 +62,7 @@ extern "C"
|
||||
|
||||
int board_wlan_init(void);
|
||||
|
||||
#endif /* CONFIG_ESP32_WIRELESS */
|
||||
#endif /* CONFIG_ESP32_WIFI */
|
||||
|
||||
#undef EXTERN
|
||||
#if defined(__cplusplus)
|
||||
|
@ -48,7 +48,7 @@ ifeq ($(CONFIG_ESP32_SPIFLASH),y)
|
||||
CSRCS += esp32_board_spiflash.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_ESP32_WIRELESS),y)
|
||||
ifeq ($(CONFIG_ESP32_WIFI),y)
|
||||
CSRCS += esp32_board_wlan.c
|
||||
endif
|
||||
|
||||
|
@ -28,8 +28,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_EXAMPLE_POWER_SAVE_MIN_MODEM=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
|
@ -36,6 +36,7 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
|
@ -69,6 +69,7 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SMARTFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_BT_COEXIST=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_EXAMPLE_POWER_SAVE_MIN_MODEM=y
|
||||
|
@ -45,8 +45,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HOST_MACOS=y
|
||||
CONFIG_IDLETHREAD_STACKSIZE=3072
|
||||
|
@ -33,7 +33,7 @@ CONFIG_DRIVERS_WIRELESS=y
|
||||
CONFIG_ESP32_APP_FORMAT_MCUBOOT=y
|
||||
CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT_DL_BUFFER_SIZE=4096
|
||||
CONFIG_EXPERIMENTAL=y
|
||||
|
@ -27,7 +27,7 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_EXAMPLES_MQTTC=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
|
@ -34,9 +34,9 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIFI_STATION_SOFTAP_COEXISTENCE=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_EXAMPLES_DHCPD=y
|
||||
CONFIG_EXPERIMENTAL=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
|
@ -49,7 +49,7 @@ CONFIG_ESP32_IRAM_HEAP=y
|
||||
CONFIG_ESP32_RTC_HEAP=y
|
||||
CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_EXPERIMENTAL=y
|
||||
CONFIG_FS_LITTLEFS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
|
@ -23,18 +23,9 @@ CONFIG_ARCH_XTENSA=y
|
||||
CONFIG_BOARD_LOOPSPERMSEC=16717
|
||||
CONFIG_BUILTIN=y
|
||||
CONFIG_DEBUG_ASSERTIONS=y
|
||||
CONFIG_DEBUG_ERROR=y
|
||||
CONFIG_DEBUG_FEATURES=y
|
||||
CONFIG_DEBUG_FULLOPT=y
|
||||
CONFIG_DEBUG_INFO=y
|
||||
CONFIG_DEBUG_MM=y
|
||||
CONFIG_DEBUG_MM_ERROR=y
|
||||
CONFIG_DEBUG_MM_WARN=y
|
||||
CONFIG_DEBUG_NET=y
|
||||
CONFIG_DEBUG_NET_ERROR=y
|
||||
CONFIG_DEBUG_NET_WARN=y
|
||||
CONFIG_DEBUG_SYMBOLS=y
|
||||
CONFIG_DEBUG_WARN=y
|
||||
CONFIG_DEFAULT_TASK_STACKSIZE=4096
|
||||
CONFIG_DEV_URANDOM=y
|
||||
CONFIG_DRIVERS_IEEE80211=y
|
||||
@ -43,8 +34,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_IDLETHREAD_STACKSIZE=3072
|
||||
CONFIG_INIT_ENTRYPOINT="nsh_main"
|
||||
|
@ -34,8 +34,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_EXAMPLES_HELLO=y
|
||||
CONFIG_EXAMPLES_WEBSERVER=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
|
@ -28,8 +28,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
CONFIG_HAVE_CXXINITIALIZE=y
|
||||
|
@ -75,7 +75,7 @@
|
||||
# include "esp32_ble.h"
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
# include "esp32_board_wlan.h"
|
||||
#endif
|
||||
|
||||
@ -285,7 +285,7 @@ int esp32_bringup(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
ret = board_wlan_init();
|
||||
if (ret < 0)
|
||||
{
|
||||
|
@ -27,8 +27,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_EXAMPLE_POWER_SAVE_MIN_MODEM=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
|
@ -32,7 +32,7 @@ CONFIG_DRIVERS_WIRELESS=y
|
||||
CONFIG_ESP32_APP_FORMAT_MCUBOOT=y
|
||||
CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT_DL_BUFFER_SIZE=4096
|
||||
CONFIG_EXPERIMENTAL=y
|
||||
|
@ -26,8 +26,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
CONFIG_HAVE_CXXINITIALIZE=y
|
||||
|
@ -69,7 +69,7 @@
|
||||
# include "esp32_ble.h"
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
# include "esp32_board_wlan.h"
|
||||
#endif
|
||||
|
||||
@ -176,7 +176,7 @@ int esp32_bringup(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
ret = board_wlan_init();
|
||||
if (ret < 0)
|
||||
{
|
||||
|
@ -28,8 +28,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_EXAMPLE_POWER_SAVE_MIN_MODEM=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
|
@ -33,7 +33,7 @@ CONFIG_DRIVERS_WIRELESS=y
|
||||
CONFIG_ESP32_APP_FORMAT_MCUBOOT=y
|
||||
CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT=y
|
||||
CONFIG_EXAMPLES_MCUBOOT_UPDATE_AGENT_DL_BUFFER_SIZE=4096
|
||||
CONFIG_EXPERIMENTAL=y
|
||||
|
@ -27,8 +27,8 @@ CONFIG_ESP32_SPIFLASH=y
|
||||
CONFIG_ESP32_SPIFLASH_SPIFFS=y
|
||||
CONFIG_ESP32_STORAGE_MTD_SIZE=0x80000
|
||||
CONFIG_ESP32_UART0=y
|
||||
CONFIG_ESP32_WIFI=y
|
||||
CONFIG_ESP32_WIFI_SAVE_PARAM=y
|
||||
CONFIG_ESP32_WIRELESS=y
|
||||
CONFIG_FS_PROCFS=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
CONFIG_HAVE_CXXINITIALIZE=y
|
||||
|
@ -68,7 +68,7 @@
|
||||
# include "esp32_ble.h"
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
# include "esp32_board_wlan.h"
|
||||
#endif
|
||||
|
||||
@ -210,7 +210,7 @@ int esp32_bringup(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
ret = board_wlan_init();
|
||||
if (ret < 0)
|
||||
{
|
||||
|
@ -75,7 +75,7 @@
|
||||
# include "esp32_ble.h"
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
# include "esp32_board_wlan.h"
|
||||
#endif
|
||||
|
||||
@ -208,7 +208,7 @@ int esp32_bringup(void)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ESP32_WIRELESS
|
||||
#ifdef CONFIG_ESP32_WIFI
|
||||
ret = board_wlan_init();
|
||||
if (ret < 0)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user