Comments (17)
not sure,
but are they not CONST ?
( fixed lenght / difference lenght)
from esp32-mqtt.
I've done some more troubleshooting and it's not that.
As soon as we get to
INFO("[APP] Start, connect to Wifi network: %s ..\n", WIFI_SSID);
it crashes straight after. It appears to be unrelated to this bit of code (commented it out same result) but I'm an RTOS newb as to what that might be.
from esp32-mqtt.
how you set up your sta (wifi)
from esp32-mqtt.
sorry I don't understand ? Even if I comment out the above line I get the same result.
WIFI_SSID is defined as
#define WIFI_SSID "xxxx"
I've tried replacing WIFI_SSID with "xxxx" in the INFO line above with the same result.
Does this code work for you ?
from esp32-mqtt.
/* station mode!
ESP_ERROR_CHECK( esp_wifi_set_mode(WIFI_MODE_STA) );
wifi_config_t sta_config = {
.sta = {
.ssid = "OneTwoThreeFourFive",
.password = "NoPublicHereNotShow",
.bssid_set = false
}
};
ESP_ERROR_CHECK( esp_wifi_set_config(WIFI_IF_STA, &sta_config) );
ESP_ERROR_CHECK( esp_wifi_start() );
ESP_ERROR_CHECK( esp_wifi_connect() );
*/
/* ap mode */
ESP_ERROR_CHECK( esp_wifi_set_mode(WIFI_MODE_AP) ) ;
wifi_config_t ap_config = {
.ap = {
.ssid = "OneTwoThreeFourFive\0",
.password = "NoPublicHereNotShow",
/*.bssid_set = false,*/
.ssid_len = 0,
/* .channel = WIFI_COUNTRY_EU, */
.authmode = WIFI_AUTH_WPA2_PSK,
/* .ssid_hidden = , */
.max_connection = 10
/* .beacon_interval= */
}
from esp32-mqtt.
https://github.com/tuanpmt/esp32-mqtt/blob/master/main/app_main.c#L112
https://github.com/tuanpmt/esp32-mqtt/blob/master/main/include/user_config.sample.h#L29
sry for confusing
you are right. not sure why this is
the setup for wifi is done in top code example ( esp-idf )
from esp32-mqtt.
Yes exactly, it's crashing after a few lines of printing basically debug info, not much else.
Can you get it to work ?
from esp32-mqtt.
which esp-idf version ( commits nr ) you use?
i know i have one problem with the newest in tcp server
i used the preview version for this.
just in time i can't help you with do on a module,
i am sitting in wrong place, earliest on monday.
from esp32-mqtt.
no worries, thanks (rudi ?) using the latest esp-idf
from esp32-mqtt.
yes ;-) sry
can you test with an early version?
best wishes
rudi ;-)
;-)
ED: i remember me, that the last update on wifi lib have a change ..
from esp32-mqtt.
so I just updated to the latest library files and now get this
[APP] Start, connect to Wifi network: xxx ..
/Users/lakidd1/esp32/esp-idf/components/freertos/./queue.c:603 (xQueueGenericSend)- assert failed!
Guru Meditation Error: Core 0 panic'ed.
Register dump:
PC : Guru Meditation Error of type LoadProhibited occurred on core 0. Exception was unhandled.
Register dump:
PC : 40083b06 PS : 00060033 A0 : 80083d29 A1 : 3ffb6a60
A2 : 00000000 A3 : 00000002 A4 : 00000000 A5 : 00000000
A6 : 3f401158 A7 : 3ff4001c A8 : 0000007d A9 : 3ff4001c
A10 : 3ff4001c A11 : 3f4002f4 A12 : 00000000 A13 : 3ffb6ac0
A14 : 00000000 A15 : 3f40126c SAR : 00000015 EXCCAUSE: 0000001c
EXCVADDR: 00000004 LBEG : 4000c2e0 LEND : 4000c2f6 LCOUNT : 00000000
Rebooting..
Yes, so might need to back an version
thanks
from esp32-mqtt.
can you see a change in your building messages?
( suspicious unknown ) warning..
from esp32-mqtt.
https://github.com/espressif/esp-idf/blob/master/components/freertos/queue.c#L603
from esp32-mqtt.
not sure where the while(1) was removed
9a180aa
perhabs it can be a task error ( not combine with this remove )
..small change in the esp-idf / lib
this is the moment of reboot?
https://github.com/tuanpmt/esp32-mqtt/blob/master/main/app_main.c#L118
from esp32-mqtt.
OK I got it working but it was significant surgery to the existing code.
I took the wifi init code from the http example in esp-idf and replaced the code between L112 and L118. Works now but not sure why...I suspect esp_wifi_set mode and others were throwing exceptions which weren't being handled and now are. @tuanpmt which version of esp-idf did you build this with ?
How to I contribute my changes back (if you want them) ?
Edit: Ah this is all fixed in the dev branch. My bad
from esp32-mqtt.
I had the same issue, in my case the stack depth of a task was to small.
from esp32-mqtt.
@ESP32DE
user need to copy user_config.sample.h
to user_config.local.h
and compile project with some of the information does not want to public (.gitingore will ignore user_config.local.h
)
I'm updating this library work with select
api and outbox queue, but need to try with Arduino for ESP8266 first. As @vanthome said, Please try increasing the stack size
from esp32-mqtt.
Related Issues (20)
- What does t MQTT_MSG_TYPE_PINGRESP mean? HOT 9
- Connection refuse, Unknown reason HOT 1
- Samsung's ARTIK Cloud connect error HOT 1
- not able to connect to hive mqtt HOT 3
- example fails compile, when fixed fails to execute properly HOT 1
- Compilation error - undeclared struct field "reconnect_cb" HOT 5
- Pending Subscription message is overwritten by Publish => subscribe callback is missed HOT 1
- esp32 as server broker
- MQTT cjson HOT 8
- mqtt_stop() sometimes does not work.
- Documentation for MQTT Library by tuanpmt HOT 1
- Client socket being destroyed after unsuccessful read from mqtt_start_receive_schedule() function HOT 2
- Offline Buffer issues trigger watchdog timer error
- Installing library in Eclipse environment
- Connection refused, not authorized HOT 9
- Mqtt_1 HOT 1
- lwt message is blank
- last will
- esp32 constant reboot HOT 1
- Link to new version is 404
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from esp32-mqtt.