-
Notifications
You must be signed in to change notification settings - Fork 7.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use of Ethernet and WiFi AP & STA simulateneously #10850
Comments
In 2.0.17 you can not. For 3.x you can decide which is the default outgoing interface by doing Network.setDefaultInterface(ETH); //outgoing connections go through ETH by default
Network.setDefaultInterface(WiFi.STA); //outgoing connections go through STA by default |
If you switch to ETH as default, make sure that that is done AFTER STA is connected |
Thank you @me-no-dev. If ETH is connected and sending data to HTTP(s) and WiFi is put in AP mode it also stops connecting to internet on ETH. Will it work in this situation the Edit: I have tested this situation, and when the AP is started, or when an user is connected (after IP assignaned) to AP, I have try to call |
AP should not interfere, unless they are both set in the same subnet. |
The AP give to my PC the IP 192.168.4.1, and ethernet obtains the IP 192.168.0.58 from the LAN, so they are not in the same subnet. But when the AP is started and/or when I connect with my PC to the AP and an IP is assigned, the HTTPS connections with WiFiClientSecure stop working. Any ideas? |
@enriquedbelec please provide a test sketch to reproduce the issue |
Hi, Here is a test sketch to reproduce the issue. The sketch starts ETH and waits for link up and get IP. After that it starts performing GET requests to URL. 30 seconds after start sketch, ir starts AP. Here you can note, that the GET request is performed with 200 OK status code, until the AP is started. After the AP is started and also if you connect to AP, the requests can't be performed (log verbose shows a timeout).
|
Board
Custom board
Device Description
Custom board with ESP32 Wroom 16 MB of flash with LAN8710A
Hardware Configuration
ETH_CLK_MODE -> ETH_CLOCK_GPIO17_OUT
ETH_POWER_PIN -> 5
ETH_TYPE -> ETH_PHY_LAN8720
ETH_ADDR -> 0
ETH_MDC_PIN -> 23
ETH_MDIO_PIN -> 18
ETH_CLOCK_PIN -> 17
Version
v2.0.17
IDE Name
VSCode
Operating System
Windows 10
Flash frequency
40 Mhz
PSRAM enabled
no
Upload speed
921600
Description
Hi,
I've checked on Arduino 2.0.17 and 3.1.1 that if you begin Ethernet only it can perform an HTTP connection ok. But if you enable the AP, then the ETH connection drops (can't establish connection).
Is there any way to keep working the ethernet connections while the AP is up? Ídem question with ETH + AP/STA ?
Thanks.
Sketch
// Init Ethernet driver ETH.begin(ETH_ADDR, ETH_POWER_PIN, ETH_MDC_PIN, ETH_MDIO_PIN, ETH_TYPE, ETH_CLK_MODE);
Debug Message
Other Steps to Reproduce
No response
I have checked existing issues, online documentation and the Troubleshooting Guide
The text was updated successfully, but these errors were encountered: