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
I've successfully got WiFi to work on an Feather Huzzah ESP8266, but am unable to get MQTT to work. The publish example consistently throws an LoadStoreAlignmentCause error.
The stacktrace is
Exception 9: LoadStoreAlignmentCause: Load or store to an unaligned address
PC: 0x4020269a: WiFiClient::WiFiClient() at ./Library/Arduino15/packages/esp8266/hardware/esp8266/3.0.1/cores/esp8266/Print.h line 46
EXCVADDR: 0x00000017
Decoding stack results
0x40203424: HardwareSerial::write(unsigned char const*, unsigned int) at ./Library/Arduino15/packages/esp8266/hardware/esp8266/3.0.1/cores/esp8266/HardwareSerial.h line 193
0x40203a3c: Print::write(char const*) at ./Library/Arduino15/packages/esp8266/hardware/esp8266/3.0.1/cores/esp8266/Print.h line 59
0x40201634: Ubidots::Ubidots(char*) at ./Documents/Arduino/libraries/ubidots-mqtt-esp-master/src/UbidotsESPMQTT.cpp line 39
0x402010c0: setup() at ./Documents/Arduino/sketch_wifi/sketch_wifi.ino line 48
0x40204d54: loop_wrapper() at ./Library/Arduino15/packages/esp8266/hardware/esp8266/3.0.1/cores/esp8266/core_esp8266_main.cpp line 198
Here's the console output, with debug for WIFI enabled. Any thoughts much appreciated!!!
I switched to the ubidots-esp8266 client yesterday, and finally managed to get it to work. However I also had to downgrade the board to 2.7.4 (due to issues on the mac with the 3.0.0 and later version.) Connecting via HTTP still resulted in an exception, but switching to TCP in the client finally worked.
Per the README for ubidots-esp8266 client, using TCP will switch to the ESP8266's native secure client, so I wonder if there's a bug in the WiFi or TCP/IP stack related modules. You may want to look at downgrading those modules if that's possible.
One area that looked odd to me is the initialization of the class in the ubidots-mqtt-esp module; in the constructor Ubidots::Ubidots(char* token), the byte array returned by macAddress() is copied using strcopy. The returned 6 bytes are binary and not necessarily zero-terminated, so using strcopy can cause problems. (Assuming memory layout isn't too different on the arduino from other systems, you're likely to hit a zero somewhere on the heap before an invalid address.) However changing that code didn't make a difference. I do think that ought to be fixed though - there's a few examples with a mac2String() function being used in other code for arduino that convert that same binary mac address to a valid string - typically octets separated by ':'.
Hi,
I've successfully got WiFi to work on an Feather Huzzah ESP8266, but am unable to get MQTT to work. The publish example consistently throws an LoadStoreAlignmentCause error.
The stacktrace is
Here's the console output, with debug for WIFI enabled. Any thoughts much appreciated!!!
The text was updated successfully, but these errors were encountered: