myDevicesIoT/Cayenne-MQTT-ESP

ESP32-Wrover Random Reset

Closed this issue · 4 comments

I am attaching to the Cayenne network and passing data but it appears I am missing an exception handler...

Here is the error
-------------------Serial Monitor------------------------
ets Jun 8 2016 00:22:57

rst:0xc (SW_CPU_RESET),boot:0x3e (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:1
load:0x3fff0018,len:4
load:0x3fff001c,len:956
load:0x40078000,len:0
load:0x40078000,len:13076
entry 0x40078a58
[D][WiFiGeneric.cpp:293] _eventCallback(): Event: 2 - STA_START
[D][WiFiGeneric.cpp:293] _eventCallback(): Event: 4 - STA_CONNECTED
[D][WiFiGeneric.cpp:293] _eventCallback(): Event: 7 - STA_GOT_IP
Guru Meditation Error: Core 0 panic'ed (IllegalInstruction)
. Exception was unhandled.
Register dump:
PC : 0x4011b649 PS : 0x00060730 A0 : 0x80113a9d A1 : 0x3ffd4880
A2 : 0x3ffc6d54 A3 : 0x00000000 A4 : 0x00000005 A5 : 0x1e000107
A6 : 0x00000020 A7 : 0x00000001 A8 : 0x3ffc1cc8 A9 : 0x00000000
A10 : 0x3ffd33a0 A11 : 0x00060021 A12 : 0x800850f8 A13 : 0x3ffc0540
A14 : 0x00000003 A15 : 0x00060023 SAR : 0x00000020 EXCCAUSE: 0x00000000
EXCVADDR: 0x00000000 LBEG : 0x4000c2e0 LEND : 0x4000c2f6 LCOUNT : 0xffffffff

Backtrace: 0x4011b649:0x3ffd4880 0x40113a9a:0x3ffd48b0 0x40113fac:0x3ffd48f0 0x401142f5:0x3ffd4920 0x401194ba:0x3ffd4950

Rebooting...

-------------------End Monitor--------------------------
-------------------Decoder-------------------------------------------------------------
0x4011b649: rcReachRetryLimit at ?? line ?
0x40113a9a: lmacTxFrame at ?? line ?
0x40113fac: lmacProcessAckTimeout at ?? line ?
0x401142f5: lmacProcessTxComplete at ?? line ?
0x401194ba: ppTask at ?? line ?
---------------------------------------------------Code---------------------------------
#include "CayenneMQTTESP32.h"

bool WiFiFound = 1, NetworkFound = 1;

const char* ssid = "xxxxxxxxxx";
const char* wifiPassword = "xxxxxxxxxxxxxxxxxx";
const char* DevID = "xxxxxxxxxxxxxxxx";

//Cayenne Authentication
char username[] = "xxxxxxxxxxxxxxxxxxxx";
char password[] = "xxxxxxxxxxxxxxxxxxxxxxxxxx";
char clientID[] = "xxxxxxxxxxxxxxxxxxxxxxxx";

int ledPinRED = GPIO_NUM_0;
int ledPinGRN = GPIO_NUM_2;
int ledPinBLU = GPIO_NUM_4;

void setup() {
Serial.begin(115200);
ledSetup();
Cayenne.begin(username, password, clientID, ssid, wifiPassword);
}

int value = 0;

void loop() {
Cayenne.loop();
}

// Default function for sending sensor data at intervals to Cayenne.
// You can also use functions for specific channels, e.g CAYENNE_OUT(1) for sending channel 1 data.
CAYENNE_OUT_DEFAULT()
{
// Write data to Cayenne here. This example just sends the current uptime in milliseconds on virtual channel 0.
Cayenne.virtualWrite(0, millis());
// Some examples of other functions you can use to send data.
Cayenne.celsiusWrite(1, 22.0);
//Cayenne.luxWrite(2, 700);
//Cayenne.virtualWrite(3, 50, TYPE_PROXIMITY, UNIT_CENTIMETER);
}

// Default function for processing actuator commands from the Cayenne Dashboard.
// You can also use functions for specific channels, e.g CAYENNE_IN(1) for channel 1 commands.
CAYENNE_IN_DEFAULT()
{
CAYENNE_LOG("Channel %u, value %s", request.channel, getValue.asString());
//Process message here. If there is an error set an error message using getValue.setError(), e.g getValue.setError("Error message");
}

//Initialize Status LED's
void ledSetup() {
pinMode(ledPinRED, OUTPUT);
pinMode(ledPinGRN, OUTPUT);
pinMode(ledPinBLU, OUTPUT);
digitalWrite(ledPinRED, LOW);
digitalWrite(ledPinGRN, LOW);
digitalWrite(ledPinBLU, LOW);
}
---------------------------------------------End Code----------------------------------

This issue may be an issue with the espif arduino library for the ESP32 the debug shot is for the libpp.a file in the esp32.

Yeah, that could be a bug in the ESP32 board package. If you try with an example sketch that just makes a WiFi connection to a server and doesn't use the Cayenne library do you still get the error? If so, you might try opening an issue at https://github.com/espressif/arduino-esp32/issues.

It does happen even with a standard WiFi connection. We can close this issue here.

Unfortunately I think they still are having some silicon issues that need resolved.

Okay, thanks for checking. I'll close this issue.