You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your code works like a charm on ESP32 (except if you try to do a network connection like MQTT client during NTP update, you get a deadlock forever). Yet on ESP8266 I get crashes immediatly:
`First WiFi connection established, starting NTP
NTP started
Crash stack trace:
0x4022d1f7 in esp_try_delay(unsigned int, unsigned int, unsigned int) at ??:?
0x401013fc in malloc at ??:?
0x402682f5 in cnx_update_bss_more at ??:?
0x4021932e in _ZL14hostByNameImplPKcR9IPAddressj14DNSResolveType$part$0 at ESP8266WiFiGeneric.cpp:?
0x4023423c in std::__uniq_ptr_impl<WiFiClient, std::default_delete >::reset(WiFiClient*) at ??:?
0x402195c8 in ESP8266WiFiGenericClass::hostByName(char const*, IPAddress&) at ??:?
0x4021d48a in NTPClient::getTime() at ??:?
0x4010653d in ets_timer_arm_new at ??:?
0x401063f9 in ets_timer_disarm at ??:?
0x40266a33 in sta_input at ??:?
0x4022cfe2 in loop_task(ETSEventTag*) at core_esp8266_main.cpp:?
0x4027fef2 in wifi_get_opmode at ??:?
0x402810d7 in wifi_station_get_connect_status at ??:?
0x40100a49 in millis at ??:?
0x40219dfc in ESP8266WiFiSTAClass::status() at ??:?
0x4021d6e4 in NTPClient::s_getTimeloop(void*) at ??:?
0x4027c5de in esf_buf_recycle at ??:?
0x40100a49 in millis at ??:?
0x402328ec in std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<std::__detail::__variant::__deduce_visit_result ()(Ticker::_static_callback()::{lambda(auto:1&&)#1}&&, std::variant<std::monosta
te, Ticker::callback_ptr_t, std::function<void ()> >&)>, std::integer_sequence<unsigned int, 1u> >::__visit_invoke(Ticker::_static_callback()::{lambda(auto:1&&)#1}, std::variant<std::monostate, Ticker::callback_ptr_t, std::function<
void ()> >) at Ticker.cpp:?
0x4026639e in sta_input at ??:?
0x4021c4e0 in Ticker::_static_callback() at ??:?
0x40246300 in sys_check_timeouts at /local/users/gauchard/arduino/arduino_esp8266/origin/tools/sdk/lwip2/builder/lwip2-src/src/core/timeouts.c:368
0x4027e63c in ets_timer_handler_isr at ??:?
0x4021c518 in Ticker::_attach(std::chrono::duration<unsigned int, std::ratio<1ll, 1000ll> >, bool)::{lambda(void)#1}::_FUN(void*) at Ticker.cpp:?
0x4027e649 in ets_timer_handler_isr at ??:?
0x4027e68e in ets_timer_handler_isr at ??:?
0x4022cfe5 in loop_task(ETSEventTag*) at core_esp8266_main.cpp:?
0x40105c61 in call_user_start_local at ??:?
0x40105c67 in call_user_start_local at ??:?
0x4010139c in umm_init at ??:?
0x4010000d in call_user_start at ??:?
0x401000ac in app_entry_redefinable at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x402398e4 in _strtoul_r at /workdir/repo/newlib/newlib/libc/stdlib/strtoul.c:196
0x40106fb4 in spi_flash_read at ??:?
0x4023ec4a in _scanf_i at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf_i.c:218
0x402398dc in _strtoul_r at /workdir/repo/newlib/newlib/libc/stdlib/strtoul.c:194
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x4023e8b0 in __ssvfscanf_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:412 (discriminator 1)
0x40100030 in _KernelExceptionVector at ??:?
0x4022d108 in yield at ??:?
0x4022e061 in flash_hal_read at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x4027aba2 in pp_attach at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40100420 in ets_post at ??:?
0x401028cc in pp_post at ??:?
0x40279c5f in ppTxPkt at ??:?
0x402636e7 in ieee80211_send_probereq at ??:?
0x40265523 in scan_remove_probe_ssid at ??:?
0x402650f4 in scan_start at ??:?
0x40267764 in cnx_start_handoff_cb at ??:?
0x4010653d in ets_timer_arm_new at ??:?
0x4023e43c in _sungetc_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:183
0x4023e4d0 in __ssrefill_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:230
0x40100420 in ets_post at ??:?
0x401028cc in pp_post at ??:?
0x40105b5f in lmacRxDone at ??:?
0x40100420 in ets_post at ??:?
0x40103453 in rcReachRetryLimit at ??:?
0x40100420 in ets_post at ??:?
0x40103630 in rcReachRetryLimit at ??:?
0x40100420 in ets_post at ??:?
0x40103aea in wDev_ProcessFiq at ??:?
0x4010380c in wDev_ProcessFiq at ??:?
0x40100420 in ets_post at ??:?
0x401063f9 in ets_timer_disarm at ??:?
0x40100420 in ets_post at ??:?
0x40100a49 in millis at ??:?
0x4022e628 in uart_rx_available at ??:?
0x4022e46d in _gettimeofday_r at ??:?
0x4022e480 in _gettimeofday_r at ??:?
0x4022e449 in _gettimeofday_r at ??:?
0x40218776 in RFLink::mainLoop() at ??:?
0x40100420 in ets_post at ??:?
0x40100441 in esp_schedule at ??:?
0x4022d296 in loop_wrapper() at core_esp8266_main.cpp:?
`
More context: using Platform IO with SDK [email protected] (fairly new?)
The text was updated successfully, but these errors were encountered:
Hi,
Your code works like a charm on ESP32 (except if you try to do a network connection like MQTT client during NTP update, you get a deadlock forever). Yet on ESP8266 I get crashes immediatly:
`First WiFi connection established, starting NTP
NTP started
Crash stack trace:
0x4022d1f7 in esp_try_delay(unsigned int, unsigned int, unsigned int) at ??:?
0x401013fc in malloc at ??:?
0x402682f5 in cnx_update_bss_more at ??:?
0x4021932e in _ZL14hostByNameImplPKcR9IPAddressj14DNSResolveType$part$0 at ESP8266WiFiGeneric.cpp:?
0x4023423c in std::__uniq_ptr_impl<WiFiClient, std::default_delete >::reset(WiFiClient*) at ??:?
0x402195c8 in ESP8266WiFiGenericClass::hostByName(char const*, IPAddress&) at ??:?
0x4021d48a in NTPClient::getTime() at ??:?
0x4010653d in ets_timer_arm_new at ??:?
0x401063f9 in ets_timer_disarm at ??:?
0x40266a33 in sta_input at ??:?
0x4022cfe2 in loop_task(ETSEventTag*) at core_esp8266_main.cpp:?
0x4027fef2 in wifi_get_opmode at ??:?
0x402810d7 in wifi_station_get_connect_status at ??:?
0x40100a49 in millis at ??:?
0x40219dfc in ESP8266WiFiSTAClass::status() at ??:?
0x4021d6e4 in NTPClient::s_getTimeloop(void*) at ??:?
0x4027c5de in esf_buf_recycle at ??:?
0x40100a49 in millis at ??:?
0x402328ec in std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<std::__detail::__variant::__deduce_visit_result ()(Ticker::_static_callback()::{lambda(auto:1&&)#1}&&, std::variant<std::monosta
te, Ticker::callback_ptr_t, std::function<void ()> >&)>, std::integer_sequence<unsigned int, 1u> >::__visit_invoke(Ticker::_static_callback()::{lambda(auto:1&&)#1}, std::variant<std::monostate, Ticker::callback_ptr_t, std::function<
void ()> >) at Ticker.cpp:?
0x4026639e in sta_input at ??:?
0x4021c4e0 in Ticker::_static_callback() at ??:?
0x40246300 in sys_check_timeouts at /local/users/gauchard/arduino/arduino_esp8266/origin/tools/sdk/lwip2/builder/lwip2-src/src/core/timeouts.c:368
0x4027e63c in ets_timer_handler_isr at ??:?
0x4021c518 in Ticker::_attach(std::chrono::duration<unsigned int, std::ratio<1ll, 1000ll> >, bool)::{lambda(void)#1}::_FUN(void*) at Ticker.cpp:?
0x4027e649 in ets_timer_handler_isr at ??:?
0x4027e68e in ets_timer_handler_isr at ??:?
0x4022cfe5 in loop_task(ETSEventTag*) at core_esp8266_main.cpp:?
0x40105c61 in call_user_start_local at ??:?
0x40105c67 in call_user_start_local at ??:?
0x4010139c in umm_init at ??:?
0x4010000d in call_user_start at ??:?
0x401000ac in app_entry_redefinable at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x402398e4 in _strtoul_r at /workdir/repo/newlib/newlib/libc/stdlib/strtoul.c:196
0x40106fb4 in spi_flash_read at ??:?
0x4023ec4a in _scanf_i at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf_i.c:218
0x402398dc in _strtoul_r at /workdir/repo/newlib/newlib/libc/stdlib/strtoul.c:194
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x4023e8b0 in __ssvfscanf_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:412 (discriminator 1)
0x40100030 in _KernelExceptionVector at ??:?
0x4022d108 in yield at ??:?
0x4022e061 in flash_hal_read at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x40106fb4 in spi_flash_read at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40100486 in __wrap_spi_flash_read at ??:?
0x40228eac in EspClass::flashRead(unsigned int, unsigned int*, unsigned int) at ??:?
0x4027aba2 in pp_attach at ??:?
0x40228f39 in EspClass::flashRead(unsigned int, unsigned char*, unsigned int) at ??:?
0x40100420 in ets_post at ??:?
0x401028cc in pp_post at ??:?
0x40279c5f in ppTxPkt at ??:?
0x402636e7 in ieee80211_send_probereq at ??:?
0x40265523 in scan_remove_probe_ssid at ??:?
0x402650f4 in scan_start at ??:?
0x40267764 in cnx_start_handoff_cb at ??:?
0x4010653d in ets_timer_arm_new at ??:?
0x4023e43c in _sungetc_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:183
0x4023e4d0 in __ssrefill_r at /workdir/repo/newlib/newlib/libc/stdio/nano-vfscanf.c:230
0x40100420 in ets_post at ??:?
0x401028cc in pp_post at ??:?
0x40105b5f in lmacRxDone at ??:?
0x40100420 in ets_post at ??:?
0x40103453 in rcReachRetryLimit at ??:?
0x40100420 in ets_post at ??:?
0x40103630 in rcReachRetryLimit at ??:?
0x40100420 in ets_post at ??:?
0x40103aea in wDev_ProcessFiq at ??:?
0x4010380c in wDev_ProcessFiq at ??:?
0x40100420 in ets_post at ??:?
0x401063f9 in ets_timer_disarm at ??:?
0x40100420 in ets_post at ??:?
0x40100a49 in millis at ??:?
0x4022e628 in uart_rx_available at ??:?
0x4022e46d in _gettimeofday_r at ??:?
0x4022e480 in _gettimeofday_r at ??:?
0x4022e449 in _gettimeofday_r at ??:?
0x40218776 in RFLink::mainLoop() at ??:?
0x40100420 in ets_post at ??:?
0x40100441 in esp_schedule at ??:?
0x4022d296 in loop_wrapper() at core_esp8266_main.cpp:?
`
More context: using Platform IO with SDK [email protected] (fairly new?)
The text was updated successfully, but these errors were encountered: