So I modified the handler switch code but it fails with this error, allocating memory for RF calibration (when reiniting).
I have tried to change the main rtos stack to 16k but same result. Also tried esp_wifi_set_storage(WIFI_STORAGE_FLASH).
Here's the switch event handler code:
https://gist.github.com/anonymous/46dd1 ... 426d2c1352
And this is my WIFI initialisatio called in app_main()
https://gist.github.com/anonymous/2d023 ... b00369fe2c
And the error I get. At some point router fails and a beacon tiemout happens.
Code: Select all
I (913694) wifi: bcn_timout,ap_probe_send_start
I (916204) wifi: ap_probe_send over, resett wifi status to disassoc
I (916204) wifi: state: run -> init (1)
I (916204) wifi: pm stop, total sleep time: 0/909618396
I (916204) wifi: n:1 0, o:1 1, ap:255 255, sta:1 1, prof:1
I (916214) wifi: Sha desconnectat el wifi, fem un deinit i la resta de inits a veure si es reconnecta
I (916224) wifi: flush txq
I (916224) wifi: stop sw txq
I (916224) wifi: lmac stop hw txq
I (916224) wifi: Deinit lldesc rx mblock:10
I (916234) wifi: wifi firmware version: 403db1d
I (916234) wifi: config NVS flash: enabled
I (916234) wifi: config nano formating: disabled
I (916244) system_api: Base MAC address is not set, read default base MAC address from BLK0 of EFUSE
I (916254) system_api: Base MAC address is not set, read default base MAC address from BLK0 of EFUSE
I (916284) wifi: Init dynamic tx buffer num: 32
I (916284) wifi: Init data frame dynamic rx buffer num: 32
I (916284) wifi: Init management frame dynamic rx buffer num: 32
I (916284) wifi: wifi driver task: 3ffc9368, prio:23, stack:4096
I (916294) wifi: Init static rx buffer num: 10
I (916294) wifi: Init dynamic rx buffer num: 32
I (916304) wifi: wifi power manager task: 0x3ffc9db8 prio: 21 stack: 2560
I (916304) wifi: Setting WiFi configuration SSID Despatx63...
E (916314) phy_init: failed to allocate memory for RF calibration data
abort() was called at PC 0x401207f9 on core 0
Backtrace: 0x40087c54:0x3ffc47a0 0x40087d53:0x3ffc47c0 0x401207f9:0x3ffc47e0 0x400d9802:0x3ffc4800 0x400d9870:0x3ffc4830 0x400da077:0x3ffc4860 0x400ebbea:0x3f fc4880
Rebooting...
ets Jun 8 2016 00:22:57
rst:0xc (SW_CPU_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:0x3fff0018,len:4
load:0x3fff001c,len:5672
load:0x40078000,len:0
ho 12 tail 0 room 4
load:0x40078000,len:13716
entry 0x40078fb4
So what am I doing wrong, I'm not deinit wifi correctly ...?
I've seen many posts with problems with reconnecting to wifi, but not this one of allocating memory..
Any help will be much apreciated.
Thanks.