WIFI STA is some very fragile code

enitalp
Posts: 60
Joined: Thu Jan 12, 2017 10:03 pm

WIFI STA is some very fragile code

Postby enitalp » Thu Mar 02, 2017 10:58 pm

I can't seem to stabilise the most common wifi STA code. I have multiple result.
Connect fast and work,
Connect very slow and work
Random very fast hang
Random hang after some time
Ramdom crashes very fast
Random crashes after some time

Random hang after some time, No Crash :

Code: Select all

###########################################################

Launching Wifi Connection

I (169414) wifi: wifi firmware version: 2a22b2d

I (169432) wifi: pp_task_hdl : 3ffce730, prio:23, stack:8192

I (169432) wifi: Init lldesc rx mblock:10

I (169432) wifi: Init lldesc rx ampdu len mblock:7

I (169434) wifi: Init lldesc rx ampdu entry mblock:4

I (169440) wifi: frc2_timer_task_hdl:3ffd4780, prio:22, stack:2048

[0;32mI (169482) phy: phy_version: 325, Feb 15 2017, °LN?˜6:10, 1, 0[0m

I (169483) wifi: mode : sta (24:0a:c4:04:b8:f8)

Event Handler

STA Start

Done Asking for esp_wifi_start and esp_wifi_connect

###########################################################

I (170358) wifi: n:6 0, o:1 0, ap:255 255, sta:6 0, prof:1

I (172348) wifi: state: init -> auth (b0)

I (172350) wifi: state: auth -> assoc (0)

I (173350) wifi: state: assoc -> init (4)

I (173351) wifi: n:6 0, o:6 0, ap:255 255, sta:6 0, prof:1

Event Handler

###########################################################

STA DISCONNECTED Reason : 4

Calling esp_wifi_connect

###########################################################

I (173480) wifi: n:6 0, o:6 0, ap:255 255, sta:6 0, prof:1

I (173481) wifi: state: init -> auth (b0)

I (174481) wifi: state: auth -> init (2)

Event Handler

###########################################################

STA DISCONNECTED Reason : 2

Calling esp_wifi_connect

###########################################################

I (174908) wifi: n:6 0, o:6 0, ap:255 255, sta:6 0, prof:1

I (174909) wifi: state: init -> auth (b0)

ets Jun  8 2016 00:22:57



rst:0x8 (TG1WDT_SYS_RESET),boot:0x17 (SPI_FAST_FLASH_BOOT)

configsip: 0, SPIWP:0x00

clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00

mode:DIO, clock div:1

load:0x3fff0008,len:8

load:0x3fff0010,len:2488

load:0x40078000,len:6920

load:0x40080000,len:252

entry 0x40080034

[0;32mI (779) heap_alloc_caps: Initializing. RAM available for dynamic allocation:[0m

[0;32mI (779) heap_alloc_caps: At 3FFC70E8 len 00018F18 (99 KiB): DRAM[0m

[0;32mI (788) heap_alloc_caps: At 3FFE8000 len 00018000 (96 KiB): D/IRAM[0m

[0;32mI (810) heap_alloc_caps: At 4009A7B4 len 0000584C (22 KiB): IRAM[0m

[0;32mI (830) cpu_start: Pro cpu up.[0m

[0;32mI (842) cpu_start: Single core mode[0m

[0;32mI (854) cpu_start: Pro cpu start user code[0m

Random immediat hang, no crash

Code: Select all

Launching Wifi Connection

I (9142) wifi: wifi firmware version: 2a22b2d

I (9160) wifi: pp_task_hdl : 3ffce730, prio:23, stack:8192

I (9160) wifi: Init lldesc rx mblock:10

I (9160) wifi: Init lldesc rx ampdu len mblock:7

I (9162) wifi: Init lldesc rx ampdu entry mblock:4

I (9167) wifi: frc2_timer_task_hdl:3ffd4780, prio:22, stack:2048

[0;32mI (9200) phy: phy_vð
And i'm still trying to get a Core Dump that make sense for the instant i only get :
A fatal error occurred: Can not add overlapping region [3ffc8b1c..3ffc8c8f] to ELF file. Conflict with existing [3ffc0510..3ffce77f].

Any ideas what is happening ?
Getting frustrated.

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: WIFI STA is some very fragile code

Postby ESP_Angus » Fri Mar 03, 2017 1:32 am

Hi enitalp,

Thanks for letting us know about this.

Can you please post the source code you're running here?

Do you get any warnings about out of date submodules when you run 'make'?


Angus

enitalp
Posts: 60
Joined: Thu Jan 12, 2017 10:03 pm

Re: WIFI STA is some very fragile code

Postby enitalp » Fri Mar 03, 2017 2:55 pm

Strange thing, the more i use my esp32, the less i'm able to use wifi. It's been a few hours since my last successfull connection.
And the more i get garbage in my log.

I Start to suspect highly my hardware, saw a lot of people complaining about the same thing with the SparkFun Thing, Ordered Some brand new esp Wroom32 dev card yesterday evening. Hope to get different result.

Last Log : Instant death.

Code: Select all

E (27033) wifi: esp_wifi_get_mode 774 wifi is not init

tcpip_adapter_init

esp_event_loop_init

esp_wifi_init

I (27035) wifi: wifi firmware version: 2a22b2d

I (27055) wifi: pp_task_hdl : 3ffbc1c4, prio:23, stack:8192

I (27056) wifi: Init lldesc rx mblock:25

I (27056) wifi: Init lldesc rx ampdu len mblock:7

I (27058) wifi: Init lldesc rx ampdu entry mblock:4

esp_wifi_set_storage

esp_wifi_set_mode

###########################################################

Launching Wifi Connection

::esp_wifi_set_config(WIFI_MODE_STA)

::esp_wifi_start

I (27078) wifi: frc2_timer_task_hdl:3ffd3508, prio:22, stack:2048

I (27109) phy: phy_version: 325, Feb 15 2017, 19:06:10, 1, 0

I (27110) wifi: mode : staB’¢Ò‚
éÑÒ‚¢ÒáÒ2áJj¤TÊ•¹Ñ?B…¹‘±•É5RšE
iW,.]C…?:esp_wifi_connect

Done Asking Wifi Connectiont

###########################################################

I (27986) wifi: n:6 0, o:1 0, ap:255 255, sta:6 0, prof:1

I (29977) wifi: state: init -> auth (b0)

I (29982) wifi: state: aÕÑ?RÉ
Íͽ??B‚Jj¤”
	ISʲJº¥™¥ÙšÑ…Ñ•é
Íͽ??jò’Õ¹?BŠ‚Jj¤üets Jun  8 2016 00:22:57



rst:0x8 (TG1WDT_SYS_RESET),boot:0x17 (SPI_FAST_FLASH_BOOT)

configsip: 0, SPIWP:0x00

clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00

mode:DIO, clock div:2

load:0x3fff0008,len:8

load:0x3fff0010,len:2072

load:0x40078000,len:6920

load:0x40080000,len:252

entry 0x40080034

I (884) heap_alloc_caps: Initializing. RAM available for dynamic allocation:

I (885) heap_alloc_caps: At 3FFB3000 len 00005000 (20 KiB): DRAM

I (888) heap_alloc_caps: At 3FFBBB28 len 00002000 (8 KiB): DRAM

I (906) heap_alloc_caps: At 3FFC7040 len 00018FC0 (99 KiB): DRAM

I (923) heap_alloc_caps: At 3FFE8000 len 00018000 (96 KiB): D/IRAM

I (941) heap_alloc_caps: At 4009A748 len 000058B8 (22 KiB): IRAM

I (959) cpu_start: Pro cpu up.

I (968) cpu_start: Single core mode

I (977) cpu_start: Pro cpu start user code
Attached my code.
WiFi_I.rar
(2.32 KiB) Downloaded 531 times

enitalp
Posts: 60
Joined: Thu Jan 12, 2017 10:03 pm

Re: WIFI STA is some very fragile code

Postby enitalp » Fri Mar 03, 2017 8:18 pm

Ok i can confirm 2 things.

I'm not able to use wifi anymore without stalling the esp in the last 8 hours without any code change.
I switched to my second esp32, and 4 secs later was connected to the wifi without any garbage in the log or crash, or stall with the same code. So it's not a code problem but a hardware problem. I've read some people having the same kind of problem using the Sparkfun esp32 thing. It's either a design problem or those board are using a beta version of the esp ?

At least it's not the sdk or my code ;p

Who is online

Users browsing this forum: Bing [Bot] and 277 guests