s60sc / ESP32-CAM_MJPEG2SD

ESP32 Camera motion capture application to record JPEGs to SD card as AVI files and stream to browser as MJPEG. If a microphone is installed then a WAV file is also created. Files can be uploaded via FTP or downloaded to browser.
GNU Affero General Public License v3.0
855 stars 209 forks source link

wifi keeps auto disconnecting, and reconnecting #355

Closed ChandrachurMaitra closed 7 months ago

ChandrachurMaitra commented 7 months ago

Hi, I've been using this code for a few weeks and suddenly I am getting some errors, one of them is when I first switch on the esp32 Cam then it connects to my mobile hotspot using the SSID and password given to it and after the connection and proper timeZone selection I disconnected the esp32 from my mobile hotspot [basically I switched off the hotspot] and was using the 192.168.4.1 IP to connect to the cam and to watch to stream footage. And it was working fine for let's say 12 hours and then suddenly when when I switched on the hotspot again then I don't know what happened but the 192.168.4.1 IP was showing a new page when we have to either enter the Router SSID and Password or we can do the OTA upload [there was written for the data folder ] and the I entered the ssid and pass but the esp32 cam just connecting and reconnecting to my hotspot and even after this incident "THE DEFAULT ESP-CAM-MJPEG_143AF1BD9E7C" access point isn't showing anymore, so what's going wrong???? {Note Im using esp32 S camera module with PIR sensor, and using an smps 5 volts for powering it}

here are the errors those I got:: [00:00:00.514 logSetup] =============== ESP-CAM_MJPEG 9.5 =============== [00:00:00.525 printResetReason] Power on reset [00:00:00.525 printWakeupReason] Wakeup by reset [00:00:00.602 infoSD] SD card type SDHC, Size: 7.4GB [00:00:00.603 listFolder] Sketch size 1.5MB [00:00:00.903 listFolder] File: /data/configs.txt, size: 0 bytes [00:00:00.903 listFolder] SD_MMC: 4.0GB used [00:00:00.904 loadConfig] Load config [00:00:00.922 ERROR @ prefs.cpp:461] Failed to load file /data/configs.txt [00:00:00.924 deleteFolderOrFile] Deleting : /data [00:00:00.924 deleteFolderOrFile] Folder /data contents [00:00:00.938 deleteFolderOrFile] FILE : /data/configs.txt Size : 0 bytes deleted [00:00:00.946 deleteFolderOrFile] Folder /data deleted [00:00:36.379 checkConfigFile] Created /data/configs.txt from local store [00:00:36.586 prepCam] Camera init OK for model OV2640 on board CAMERA_MODEL_AI_THINKER [00:00:36.586 WARN retrieveConfigVal] Key framesize not set [00:00:36.847 setWifiSTA] Wifi Station IP from DHCP ........[00:00:40.523 onWiFiEvent] WiFi Station disconnected ..[00:00:41.858 WARN startWifi] SSID Butterfly unable to connect [00:00:41.860 startPing] Started ping monitoring - On [00:00:41.864 startWebServer] Starting web server on port: 80 [00:00:41.864 startWebServer] Remote server certificates not checked [00:00:41.874 startSustainTasks] Started 1 HTTP sustain tasks [00:00:41.875 prepUpload] File uploads will use FTP server [00:00:41.885 prepTelegram] Telegram not being used [00:00:41.946 prepRecording] To record new AVI, do one of: [00:00:41.946 prepRecording] - press Start Recording on web page [00:00:41.946 prepRecording] - move in front of camera

[00:00:41.956 setup] Camera model OV2640 on board CAMERA_MODEL_AI_THINKER ready @ 20MHz [00:00:41.967 checkMemory] Free: heap 107028, block: 81908, min: 104704, pSRAM 1517635 [00:00:41.967 loop] =============== Total tasks: 16 ===============

[00:00:43.590 onWiFiEvent] WiFi Station disconnected [00:00:46.861 resetWatchDog] WatchDog started using task: ping [00:00:46.861 WARN pingTimeout] Failed to ping gateway, restart wifi ... [00:00:46.871 setWifiSTA] Wifi Station IP from DHCP .......[00:00:49.989 onWiFiEvent] WiFi Station disconnected ...[00:00:51.880 WARN startWifi] SSID Butterfly unable to connect [00:00:54.469 startWifi] Wifi stats for Butterfly - signal strength: -55 dBm; Encryption: WPA2_PSK; channel: 6 [00:01:16.860 WARN pingTimeout] Failed to ping gateway, restart wifi ... [00:01:16.860 setWifiSTA] Wifi Station IP from DHCP .......[00:01:20.185 onWiFiEvent] WiFi Station disconnected ...[00:01:21.868 WARN startWifi] SSID Butterfly unable to connect

s60sc commented 7 months ago

see readme