Good afternoon, i have a trouble with my esp32 cam(esp32s).
It can’t connect to my wifi network.
The strangest thing is, that if i share my wifi connection from my phone everything works fine, and esp connects with out any problem. And it doesn’t matter if my phone has mobile internet or wifi connection.
I have also written settings for static ip, 2 day ago wifi was connecting, but from yesterday started my problem.
Does this mean that you’ve specified a static IP address in your sketch, assigned a static IP address in your router or something else.
Simply repeating the same words when asked to clarify EXACTLY what they mean doesn’t help.
Then you should do that before doing anything else.
Well, once you’ve rebooted your router and tested again, if the problem still persisted please post your sketch.
Redact your WiFi credentials and Auth code, but leave your static IP unchanged.
You should also provide details of the IP address range that your router is using for DHCP, and the internal IP address of your router.
When you post your code, ensure that you put triple backticks at the beginning and end of your code, so that it displays correctly.
Triple backticks look like this:
```
Unformatted code will be removed, so use the correct backticks characters (copy and paste from above if necessary).
#define BLYNK_PRINT Serial
#include <WiFi.h>
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "";
// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "";
char pass[] = "";
void setup()
{
// Debug console
Serial.begin(115200);
WiFi.config(IPAddress(192,168,1,145), IPAddress(192,168,1,1), IPAddress(255,255,255,0));
WiFi.begin(ssid,pass);
Blynk.config(auth);
/
}
void loop()
{
Blynk.run();
}
I assume your router is at 192.168.1.1 (a piece of info I asked for, but which you didn’t supply).
If that’s the case then this shouldn’t be true…
Personally, I always specify at least one DNS server on my WiFi.config string, and change my DHCP range so that my static IPs are outside of my DHCP pool to avoid potential conflicts.
Then I suspect your issue has nothing to do with Blynk… as the WiFi connection setup I showed also has nothing to do with Blynk (but can be used with it) and woirks fine for my three ESP32Cam boards (while treating them like basic ESP32’s that is… I haven’t bothered with customising Blynk and webcam options together on that board, yet.)