Closed plin2 closed 3 years ago
Im Logfile steht:
2021-01-23_15-00-08: Time zone set to CET-1CEST,M3.5.0,M10.5.0/3 2021-01-23_15-00-08: ============================================================================================= 2021-01-23_15-00-08: =================================== Main Started ============================================ 2021-01-23_15-00-08: ============================================================================================= 2021-01-23_15-02-50: Time zone set to CET-1CEST,M3.5.0,M10.5.0/3 2021-01-23_15-02-50: ============================================================================================= 2021-01-23_15-02-50: =================================== Main Started ============================================ 2021-01-23_15-02-50: ============================================================================================= 2021-01-23_15-04-30: Time zone set to CET-1CEST,M3.5.0,M10.5.0/3 2021-01-23_15-04-30: ============================================================================================= 2021-01-23_15-04-30: =================================== Main Started ============================================ 2021-01-23_15-04-30: ============================================================================================= 2021-01-23_15-31-27: Time zone set to CET-1CEST,M3.5.0,M10.5.0/3 2021-01-23_15-31-27: ============================================================================================= 2021-01-23_15-31-27: =================================== Main Started ============================================ 2021-01-23_15-31-27: =============================================================================================
Und der serial Monitor gibt folgendes in einer Schleife aus:
rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 0, SPIWP:0xee clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00 mode:DIO, clock div:2 load:0x3fff0030,len:4 load:0x3fff0034,len:7140 load:0x40078000,len:13856 load:0x40080400,len:4052 entry 0x40080688 [0;32mI (58) boot: ESP-IDF 3.40100.200827 2nd stage bootloader[0m [0;32mI (58) boot: compile time 19:51:06[0m [0;32mI (58) boot: chip revision: 1[0m [0;32mI (62) boot_comm: chip revision: 1, min. bootloader chip revision: 0[0m [0;32mI (69) boot.esp32: SPI Speed : 40MHz[0m [0;32mI (74) boot.esp32: SPI Mode : DIO[0m [0;32mI (78) boot.esp32: SPI Flash Size : 4MB[0m [0;33mW (83) boot.esp32: PRO CPU has been reset by WDT.[0m [0;33mW (88) boot.esp32: WDT reset info: PRO CPU PC=0x40084a88[0m [0;33mW (94) boot.esp32: WDT reset info: APP CPU PC=0x4008e7db[0m [0;32mI (100) boot: Enabling RNG early entropy source...[0m [0;32mI (106) boot: Partition Table:[0m [0;32mI (109) boot: ## Label Usage Type ST Offset Length[0m [0;32mI (117) boot: 0 nvs WiFi data 01 02 00009000 00004000[0m [0;32mI (124) boot: 1 otadata OTA data 01 00 0000d000 00002000[0m [0;32mI (132) boot: 2 phy_init RF data 01 01 0000f000 00001000[0m [0;32mI (139) boot: 3 ota_0 OTA app 00 10 00010000 001db000[0m [0;32mI (147) boot: 4 ota_1 OTA app 00 11 001f0000 001db000[0m [0;32mI (155) boot: End of partition table[0m [0;32mI (159) boot_comm: chip revision: 1, min. application chip revision: 0[0m [0;32mI (166) esp_image: segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x4c730 (313136) map[0m [0;32mI (310) esp_image: segment 1: paddr=0x0005c758 vaddr=0x3ffb0000 size=0x038c0 ( 14528) load[0m [0;32mI (318) esp_image: segment 2: paddr=0x00060020 vaddr=0x400d0020 size=0x15f514 (1438996) map[0m [0;32mI (940) esp_image: segment 3: paddr=0x001bf53c vaddr=0x3ffb38c0 size=0x01860 ( 6240) load[0m [0;32mI (944) esp_image: segment 4: paddr=0x001c0da4 vaddr=0x40080000 size=0x00404 ( 1028) load[0m [0;32mI (948) esp_image: segment 5: paddr=0x001c11b0 vaddr=0x40080404 size=0x1ee54 (126548) load[0m [0;32mI (1035) boot: Loaded app from partition at offset 0x10000[0m [0;32mI (1036) boot: Disabling RNG early entropy source...[0m [0;32mI (1036) psram: This chip is ESP32-D0WD[0m [0;32mI (1042) spiram: Found 64MBit SPI RAM device[0m [0;32mI (1045) spiram: SPI RAM mode: flash 40m sram 40m[0m [0;32mI (1051) spiram: PSRAM initialized, cache is in low/high (2-core) mode.[0m [0;32mI (1058) cpu_start: Pro cpu up.[0m [0;32mI (1062) cpu_start: Application information:[0m [0;32mI (1067) cpu_start: Project name: esp32cam-server-only[0m [0;32mI (1073) cpu_start: App version: 0.0.9.3[0m [0;32mI (1078) cpu_start: Compile time: Jan 20 2021 19:48:33[0m [0;32mI (1084) cpu_start: ELF file SHA256: b9ffc04c8ab59a15...[0m [0;32mI (1090) cpu_start: ESP-IDF: 3.40100.200827[0m [0;32mI (1096) cpu_start: Starting app cpu, entry point is 0x40081c30[0m [0;32mI (0) cpu_start: App cpu up.[0m [0;32mI (1988) spiram: SPI SRAM memory test OK[0m [0;32mI (1988) heap_init: Initializing. RAM available for dynamic allocation:[0m [0;32mI (1989) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM[0m [0;32mI (1995) heap_init: At 3FFC2AC8 len 0001D538 (117 KiB): DRAM[0m [0;32mI (2001) heap_init: At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM[0m [0;32mI (2007) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM[0m [0;32mI (2014) heap_init: At 4009F258 len 00000DA8 (3 KiB): IRAM[0m [0;32mI (2020) cpu_start: Pro cpu start user code[0m [0;32mI (2025) spiram: Adding pool of 4096K of external SPI memory to heap allocator[0m [0;32mI (2050) spi_flash: detected chip: generic[0m [0;32mI (2051) spi_flash: flash io: dio[0m [0;32mI (2051) cpu_start: Starting scheduler on PRO CPU.[0m [0;32mI (0) cpu_start: Starting scheduler on APP CPU.[0m [0;32mI (2059) spiram: Reserving pool of 32K of internal memory for DMA/internal allocations[0m Do Reset Camera [0;32mI (2069) gpio: GPIO[32]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 [0m Init Camera [0;32mI (4079) gpio: GPIO[5]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4079) gpio: GPIO[18]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4079) gpio: GPIO[19]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4089) gpio: GPIO[21]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4099) gpio: GPIO[22]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4109) gpio: GPIO[23]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4119) gpio: GPIO[25]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4129) gpio: GPIO[34]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4139) gpio: GPIO[35]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4149) gpio: GPIO[36]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4159) gpio: GPIO[39]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0 [0m [0;32mI (4169) sccb: pin_sda 26 pin_scl 27 [0m [0;32mI (4169) gpio: GPIO[32]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 [0m [0;32mI (4319) camera: Detected OV2640 camera[0m [0;32mI (4319) camera: Allocating 1 frame buffers (150 KB total)[0m [0;32mI (4339) camera: Allocating 150 KB frame buffer in OnBoard RAM[0m [0;32mI (4939) connect_wlan_main: Initializing SD card[0m [0;31mE (4959) sdmmc_common: sdmmc_init_ocr: send_op_cond (1) returned 0x107[0m [0;31mE (4959) connect_wlan_main: Failed to initialize the card (263). Make sure SD card lines have pull-up resistors in place.[0m [0;32mI (4969) server_ota: Start CheckOTAUpdateCheck ...[0m Start CheckOTAUpdateCheck ... [0;32mI (4989) server_ota: SHA-256 for the partition table: : 9d4a2809ae90fb20709a8ca3dd3ac3462e1e73286bcd31b689060c91de06fa3a[0m [0;32mI (5049) server_ota: SHA-256 for bootloader: : 15f52f58b38b015f8d77a7fd637080c32b397905d47e4ca1bf5bbf1c6abe34bf[0m [0;32mI (5779) server_ota: SHA-256 for current firmware: : 9e85de4055be332de6ebd46bca00b10d3bbdb260efcb2c79c0f0bfc418eeb3da[0m CheckOTAUpdate Partition: ESP_OK File is locked: /sdcard/wlan.ini - wait for 1 Logfile opened:
Die beiden Zeilen mit Logfile opended und die nachfolgende enthalten kryptische Zeichen:
Hello @plin2, I had the same failure one time and it was a corupted wlan.ini, because I had it opened on the PC for changing and just pulled out the SD card. Repairing the SD-card (or formating - I don't remember) and configuring wlan.ini again solved the problem.
Best regards, jomjol
current status:
safed files from SD card
formated SD card on a WIndows PC with VFAT32 (hopte that is the expected filesystem, didn't find any hint in the WIki)
copied alls files back, except wlan.ini
copied wlan.ini from github clone and adjusted it again
the first time I booted: still a loop
took a break and tried again, now it seems to be stable
Will see sow things continue ...
When I change the configuration and reboot I end up in a boot loop again. When I unplug from electricity and plug in again, it seems to work.
Strange behaviour. I just uploaded a new rolling and all the test with OTA-update and reboot did work well.
Well, I tried several things, nothing worked and finally looked at the code. I searched for the string 'Logfile opened:' and found it in code/components/jomjol_logfile/ClassLogFile.cpp. In line 68 you print that output before testing if the fopen was ok
pFile = fopen(_fn.c_str(), "a+");
printf("Logfile opened: %s\n", _fn.c_str());
`
if (pFile!=NULL) {`
I guess it would be better to do that after checking the return code. Hopefully that way we will find out the malformed filename.
Screenshot of the relevant serial output:
Hello @plin2,
this line only prints the name of the file to open (printf("Logfile opened: %s\n", _fn.c_str());
). If the file opening failed in the line before, then the pointer pFile will be equal to NULL
, which is then checked in the error handling later on.
As you are the only one, currently reporting this problem, one more thing came to my mind. You wrote some post above, that you format your SD-card with VFAT32. I'm only using FAT32:
Could that be a difference? Could you check this?
Otherwise I I can offer to do a personal meeting, e.g. with skype and we can discuss this a bit easier. Only question is, how to exchange the adresses. I dont't want to publish them here in this public issue. Do you have a chat on iobroker, fhem or openhab?
Best regards, jomjol
After several tests with different devices, SD cards and configs I found out that the SD card was causing the problems. With a fresh card everything works fine.
P.S.: printf("Logfile opened: %s\n", _fn.c_str()) My guess was simply that the garbage that was printed as filename might contain some special characters that cause some damage and crashes the system..
Make sure you have one device at home to test :-)
Ich habe seit heute ganz frisch die erste ESP32-CAM laufen. Ich habe alles konfiguriert. Nach dem Boot wird ein Foto geschossern. Beim nächsten Interval kommt das Device in eine Foto-Schleife (ca. 5 Sekunden-Takt, Licht an, aus) und ist per WLAN nicht mehr zu erreichen.
Ich habe die aktuelle Version 2021-01-21 geflasht.