Closed Hansta98 closed 4 years ago
Oops, i think i builtin a bug while last update...let me fix this
It is fixed now, please download updated Switch.ino example. Thanks for pointing this out!
Perfect, you are the best Thank you verry much Keep it up!
Hey guys, don
t ask me why, I am a newbie in SinricPro, but it seems like my WemosD1 mini isn
t able to enter in my local WIFI-area. Compiling and uploading a sketch on it works well, after it appears the buildin LED and blinks in tact (about 5Hz). If I now open the serial monitor I get this report(again and again): What does is mean??Exception (28): epc1=0x4021483e epc2=0x00000000 epc3=0x00000000 excvaddr=0x000000c0 depc=0x00000000
ctx: cont sp: 3ffffb90 end: 3fffffc0 offset: 01a0 3ffffd30: 3ffffe30 000000c0 3ffffd90 40212e35
3ffffd40: 00000000 4023bf17 3ffed69c 00000022
3ffffd50: 3ffe8304 00000022 3ffffe30 40216e1a
3ffffd60: 3ffefd17 3ffe8874 00000009 3ffedde0
3ffffd70: 3ffe8de0 3ffe8de0 3ffefa07 3ffe8898
3ffffd80: 00000000 3ffe8897 3ffffe30 4021724b
3ffffd90: 00000000 ffffffff 00000000 00000000
3ffffda0: 3ffee5d0 00000022 00302073 00000001
3ffffdb0: 00000000 0000304f 4023f927 3ffede88
3ffffdc0: 3ffedec0 4023ff90 3ffedd94 00000000
3ffffdd0: 00fed750 4023f89c 3ffed69c 00000012
3ffffde0: 4023d918 4023d8ec 00000000 00000012
3ffffdf0: 3fffff60 3fffff30 0000000c 3ffe8304
3ffffe00: 4023de68 00000009 00000001 4023ff90
3ffffe10: 4023d895 3ffed818 00000002 3ffeef00
3ffffe20: 3ffeedd0 3ffe8304 00000040 402147ed
3ffffe30: 3fffff02 3ffe8514 0000001d ffff0208
3ffffe40: 3ffffee0 0000003f 3ffe885d 00000001
3ffffe50: 3ffef60c 40205378 3ffe885d 3ffe885d
3ffffe60: 40205555 40205531 3ffe8867 4020555b
3ffffe70: 33584e47 44353236 6f430043 63656e6e
3ffffe80: 676e6974 feefef00 feefeffe 4020ade8
3ffffe90: 3ffffee1 00000000 3358002e 4020cf01
3ffffea0: 3ffffee1 00000008 3ffeedd0 40214830
3ffffeb0: 3fffff60 3fffff30 00000008 00000001
3ffffec0: 3ffeedd0 00000008 3ffffee0 4020aaa8
3ffffed0: 80e33400 3fe4d205 00000008 4020ad98
3ffffee0: 6e6e6f63 65746365 0a0d2164 4669575b
3ffffef0: 203a5d69 412d5049 65726464 69207373
3fffff00: 44352073 4e375154 465a5648 40100a00
3fffff10: 4020cf99 feefeffe feefeffe feefeffe
3fffff20: 3fffff60 3fffff30 00000008 4020d2ab
3fffff30: 401052a9 0009bad0 000000c0 000000a8
3fffff40: 00000001 0000009d 3ffeed90 00000001
3fffff50: 3ffe8874 3fffff80 3fffff30 3fffff60
3fffff60: 9d01a8c0 00ffffff fe01a8c0 3ffeef00
3fffff70: 3fffdad0 3ffeed90 3ffeedd0 40201b5c
3fffff80: 40210a28 9d01a8c0 00000000 3ffeef00
3fffff90: 3fffdad0 00000000 3ffeedd0 40204821
3fffffa0: feefeffe feefeffe 3ffeeec0 4020bff0
3fffffb0: feefeffe feefeffe 3ffe8530 40100ce9
<<<stack<<< ⸮⸮⸮!⸮@ȅ⸮
To understand what I did, I post the sketch below
`#ifdef ENABLE_DEBUG
define DEBUG_ESP_PORT Serial
define NODEBUG_WEBSOCKETS
define NDEBUG
endif
include
ifdef ESP8266
include
endif
ifdef ESP32
include
include
include
define WIFI_SSID "GNX1000DQ"
define WIFI_PASS "TD7DTZ7NKLZF"
define APP_KEY "a521bac6-c522-4aad-9f5a-3e8dd446bgg6"
define APP_SECRET "35oc0c2f-4b22-4085-b7dc-8d5afd9dce9d-b4de63d6-d56c-41dd-b54x-2858105ed8bd"
define BAUD_RATE 9600
define SWITCH_ID "5e4da6097a70145df3855555"
define LED_PIN 20
bool myPowerState = false;
bool onPowerState(const String &deviceId, bool &state) { Serial.printf("device %s turned %s\r\n", deviceId.c_str(), state ? "on" : "off"); myPowerState = state; digitalWrite(LED_PIN, myPowerState?LOW:HIGH); return true;
} void setupWiFi() {
Serial.printf("\r\nWifi: Connecting"); WiFi.begin(WIFI_SSID, WIFI_PASS);
while (WiFi.status() != WL_CONNECTED) { Serial.printf("."); delay(250); } IPAddress localIP = WiFi.localIP(); Serial.printf("connected!\r\nWiFi: IP-Address is %s\r\n", localIP[0], localIP[1], localIP[2], localIP[3]); } void setupSinricPro() {
SinricProSwitch& mySwitch = SinricPro[SWITCH_ID];
mySwitch.onPowerState(onPowerState);
SinricPro.onConnected([](){ Serial.printf("Connected to SinricPro\r\n"); });
SinricPro.onDisconnected([](){ Serial.printf("Disconnected from SinricPro\r\n"); }); SinricPro.begin(APP_KEY, APP_SECRET); } void setup() { pinMode(LED_PIN, OUTPUT); digitalWrite(LED_PIN, HIGH); Serial.begin(BAUD_RATE); Serial.printf("\r\n\r\n"); setupWiFi(); setupSinricPro(); } void loop() { SinricPro.handle(); }`
It would be verry nice if someone could help me on finding the error Thanks in the meantime