Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MQTT not appearing #1457

Closed
patrol420 opened this issue Dec 28, 2018 · 30 comments
Closed

MQTT not appearing #1457

patrol420 opened this issue Dec 28, 2018 · 30 comments

Comments

@patrol420
Copy link

  • Arduino Core version
  • ESPurna version 1.13.3
  • Flash mode dout
  • Device brand, model and version generic lightbulb tw3eys wifi chip with esp8266

Tools used
win10 and ide 1.8.7

ive flashed 1 of these already and everything was seemless. this one i cannot seem to get the MQTT option to appear in web menu. ive probly built it 20 times trying different things in hardware.h for mqtt support. but nothing works. output on seriel on startup says
[000674] [MQTT] Async ENABLED, SSL DISABLED, Autoconnect ENABLED
[000687] [THINGSPEAK] Async ENABLED, SSL DISABLED
seems to be on but not appearing. any ideas

@xoseperez
Copy link
Owner

Maybe a problem in the web image? Are there any javascript errors in the browser?

@patrol420
Copy link
Author

doesnt seem to be, if i flash the latest bin for lc02 i get every option in the menu... im i correct in thinking that if i was to compile the latest source with the hardware selected i should have mqtt default. i remove // before mqtt support in arduino.h and still same thing.

@xoseperez
Copy link
Owner

MQTT is enabled by default in all builds. So you should have this. You can also check if you are receiving a mqttVisible key via web sockets on the browser (using the network inspector).

@kakaki
Copy link

kakaki commented Dec 28, 2018

I have similar problem with Schedule, ntp and Sensors menus - they are not showing - got 2 identical BW-SHP2 - one is on 1.13.1 - working fine with all options visible in menu, other was upgraded to 1.13.3.
In web sockets there is no info to set ntpVisible, shdVisible and sensorsVisible.

Same problem is on other devices updated to 1.13.3.

zrzut ekranu 2018-12-28 o 19 40 49
zrzut ekranu 2018-12-28 o 19 41 04

@patrol420
Copy link
Author

I have similar problem with Schedule, ntp and Sensors menus - they are not showing - got 2 identical BW-SHP2 - one is on 1.13.1 - working fine with all options visible in menu, other was upgraded to 1.13.3.
In web sockets there is no info to set ntpVisible, shdVisible and sensorsVisible.

Same problem is on other devices updated to 1.13.3.

zrzut ekranu 2018-12-28 o 19 40 49
zrzut ekranu 2018-12-28 o 19 41 04

going off what you said, i just flashed 1.13.1 and it works perfect first go. dam i spent 4 hours on it yesterday just flashing it, shes held up to atleast 100 flashs lol

@xoseperez xoseperez added the bug label Dec 29, 2018
@xoseperez xoseperez added this to the 1.13.4 milestone Dec 29, 2018
@mcspr
Copy link
Collaborator

mcspr commented Dec 30, 2018

What lwip version are you using (v1, v2, low memory, high bandwidth)? Assuming it is self-built from "win10 and ide 1.8.7"
Can you check with this version of ESPAsyncWebServer lib?
Or this, basing on platformio.ini pinned version. Only needed if using webui on iOS

@kakaki
Copy link

kakaki commented Dec 30, 2018

Thanks, it helps, was using version 1.2.0 from git - it's newer than version in archive, add's message eques.
me-no-dev/ESPAsyncWebServer@bed4146

@reaper7
Copy link
Contributor

reaper7 commented Dec 31, 2018

I have the same issue with unvisible menus for mqtt, shedule, ntp...
arduino 1.8.7, win10, lwip high bandwidth, ESPAsyncWebServer current git version

espurna from master branch (1.13.3) works OK
espurna from dev branch (1.13.4-dev) works but without mqtt,schedule,ntp in webmenu

I don't change any external libs, only espurna versions

@xoseperez
Copy link
Owner

Can you build the web interface images using gulp command? Check this wiki page: https://github.com/xoseperez/espurna/wiki/WebInterface

@xoseperez
Copy link
Owner

I have rebuilt and commit the webUI images, maybe you can also do a git pull, rebuild and flash.

@mcspr
Copy link
Collaborator

mcspr commented Jan 4, 2019

arduino 1.8.7, win10, lwip high bandwidth, ESPAsyncWebServer current git version

my bet it is related to #1300. current git of espasyncwebserver limits the buffer of sent ws messages by 8. that buffer is kept until the client receives them and windows is inherently slow at that.
+ as confirmed by @kakaki, rolling back a version helps

there is a workaround by doing request-response for module configuration, that way client will send N config requests and receive N config responses back, bu i have not tried it with lwip1 builds.

@reaper7
Copy link
Contributor

reaper7 commented Jan 8, 2019

@mcspr - I have not tried the older version of espasyncwebserver yet
because I use the latest version in several other projects.

I build 1.13.3(working) and 1.13.4-dev(not working) with the same espasyncwebserver(current master version),
so ... something has changed inside espurna when it comes to using a web server.

@mcspr
Copy link
Collaborator

mcspr commented Jan 8, 2019

@reaper7 which is strange, because I just tried building 1.13.3 in IDE with ESPAsyncWebServer master and still have shedule, ntp missing (maybe something else too).
[045297] [MAIN] Support: ALEXA API BROKER BUTTON DEBUG_SERIAL DEBUG_TELNET DEBUG_WEB DOMOTICZ HOMEASSISTANT LED MDNS_SERVER MQTT NTP SCHEDULER TELNET TERMINAL THINGSPEAK WEB

$ wscat --no-color --connect 192.168.4.2/ws
< {"weblog":"[203763] [WEBSOCKET] #2 connected, ip: 192.168.4.3, url: /ws\n"}
< {"maxNetworks":5,"wifiScan":true,"wifi":[{"ssid":"HELLO","pass":"THERE","ip":"192.168.4.2","gw":"192.168.4.1","mask":"255.255.255.0","dns":"192.168.4.1"}]}
< {"telnetVisible":1,"telnetSTA":true}
< {"webMode":0,"app_name":"ESPURNA","app_version":"1.13.3","app_build":"2019-01-08 11:15:18","manufacturer":"NODEMCU","chipid":"35A259","mac":"2C:3A:E8:35:A2:59","bssid":"...","channel":6,"device":"LOLIN","hostname":"ESPURNA-35A259","network":"HELLO","deviceip":"192.168.4.2","sketch_size":465600,"free_size":2678784,"sdk":"1.5.3(aec24ac9)","core":"2.3.0","heap":18768,"uptime":203,"rssi":-52,"loadaverage":1,"vcc":2732,"now":1546946382,"btnDelay":500,"webPort":80,"wsAuth":true,"cmdVisible":1}
< {"dbgVisible":1}
< {"apiVisible":1,"apiEnabled":false,"apiKey":"","apiRealTime":false,"apiRestFul":true}
< {"relayStatus":[true],"relayConfig":[{"gpio":12,"type":0,"reset":153,"boot":2,"pulse":0,"pulse_ms":0,"group":"","group_inv":0,"on_disc":0}],"relayVisible":1}
< {"ledVisible":1,"ledMode0":1}
< {"mqttVisible":1,"mqttStatus":true,"mqttEnabled":true,"mqttServer":"192.168.4.1","mqttPort":"1883","mqttUser":"","mqttClientID":"","mqttPassword":"","mqttKeep":300,"mqttRetain":true,"mqttQoS":0,"mqttTopic":"{hostname}","mqttUseJson":false}

@reaper7
Copy link
Contributor

reaper7 commented Jan 8, 2019

my arduino settings looks like this:

ide

  • used libs:
Użycie biblioteki ArduinoJson-5.11.2 w wersji 5.11.2 z folderu: C:\PROGRAMY\arduino_projekty\libraries\ArduinoJson-5.11.2 
Użycie biblioteki eeprom_rotate w wersji 0.9.2 z folderu: C:\PROGRAMY\arduino_projekty\libraries\eeprom_rotate 
Użycie biblioteki EEPROM w wersji 1.0 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\EEPROM 
Użycie biblioteki ESPAsyncTCP w wersji 1.2.0 z folderu: C:\PROGRAMY\arduino_projekty\libraries\ESPAsyncTCP 
Użycie biblioteki embedis w wersji 1.2.0 z folderu: C:\PROGRAMY\arduino_projekty\libraries\embedis 
Użycie biblioteki ESPAsyncWebServer w wersji 1.2.0 z folderu: C:\PROGRAMY\arduino_projekty\libraries\ESPAsyncWebServer 
Użycie biblioteki ESP8266WiFi w wersji 1.0 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266WiFi 
Użycie biblioteki justwifi w wersji 2.0.2 z folderu: C:\PROGRAMY\arduino_projekty\libraries\justwifi 
Użycie biblioteki debounceevent w wersji 2.0.4 z folderu: C:\PROGRAMY\arduino_projekty\libraries\debounceevent 
Użycie biblioteki ESP8266mDNS w wersji 1.2 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\ESP8266mDNS 
Użycie biblioteki Ticker w wersji 1.0 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\Ticker 
Użycie biblioteki async-mqtt-client w wersji 0.8.2 z folderu: C:\PROGRAMY\arduino_projekty\libraries\async-mqtt-client 
Użycie biblioteki Time w wersji 1.5 z folderu: C:\PROGRAMY\arduino_projekty\libraries\Time 
Użycie biblioteki NtpClient w wersji 2.5.0 z folderu: C:\PROGRAMY\arduino_projekty\libraries\NtpClient 
Użycie biblioteki ArduinoOTA w wersji 1.0 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\ArduinoOTA 
Użycie biblioteki Hash w wersji 1.0 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\Hash 
Użycie biblioteki DNSServer w wersji 1.1.1 z folderu: C:\PROGRAMY\Arduino\hardware\esp8266com\esp8266\libraries\DNSServer 
  • the same custom settings (custom.h) for espurna 1.13.3(master) and 1.13.4(dev):
#define ITEAD_SONOFF_T1_3CH
#define MY_HOME                     "myhome"
#define MY_ROOM                     "myroom"
#define MY_HOSTNAME                 "sonofft13151"
#define RELAY_BOOT_MODE             2                                           // 0 - off, 1 - on, 2 - same
#define LED1_MODE                   LED_MODE_FINDME

#define WIFI1_SSID                  "somessid"
#define WIFI1_PASS                  "somepass"

#define ADMIN_PASS                  "somewebpass"                               // Default password (WEB, OTA, WIFI SoftAP)

#define HOSTNAME                    MY_HOSTNAME

#define MQTT_TOPIC                  MY_HOME"/"MY_ROOM"/"MY_HOSTNAME"/"

#define WIFI_FALLBACK_APMODE        0                                           // Fallback to AP mode if no STA connection
#define USE_PASSWORD                0

#define TELNET_SUPPORT              0                                           // Enable telnet support by default (3.34Kb)
#define TERMINAL_SUPPORT            0                                           // Enable terminal commands (0.97Kb)

#define WEB_SUPPORT                 1                                           // Enable web support (http, api, 121.65Kb)
#define WEB_EMBEDDED                1                                           // Build the firmware with the web interface embedded in
#define WEB_FORCE_PASS_CHANGE       0

#define DEBUG_SERIAL_SUPPORT        0                                           // Enable serial debug log
#define DEBUG_UDP_SUPPORT           0                                           // Enable UDP debug log
#define DEBUG_TELNET_SUPPORT        0                                           // Enable telnet debug log (will only work if TELNET_SUPPORT is also 1)
#define DEBUG_WEB_SUPPORT           0                                           // Enable web debug log (will only work if WEB_SUPPORT is also 1)

#undef NTP_SUPPORT
#define NTP_SUPPORT                 1                                           // Build with NTP support by default (6.78Kb)

#undef MQTT_SUPPORT
#define MQTT_SUPPORT                1                                           // MQTT support (22.38Kb async, 12.48Kb sync)
#undef MQTT_ENABLED
#define MQTT_ENABLED                1                                           // Do not enable MQTT connection by default
#define MQTT_AUTOCONNECT            1                                           // If enabled and MDNS_SERVER_SUPPORT=1 will perform an autodiscover and
#define MQTT_SERVER                 "somemqttserv"                              // Default MQTT broker address
#define MQTT_USER                   "somemqttuser"                              // Default MQTT broker usename
#define MQTT_PASS                   "somemqttpass"                              // Default MQTT broker password
#define MQTT_RETAIN                 true                                        // MQTT retain flag
#define MQTT_QOS                    0                                           // MQTT QoS value for all messages
#define MQTT_USE_JSON               0                                           // Group messages in a JSON body

#define HOMEASSISTANT_SUPPORT       1                                           // Build with home assistant support (if MQTT, 1.64Kb)
#define HOMEASSISTANT_ENABLED       1                                           // Integration not enabled by default
#define HOMEASSISTANT_PREFIX        MY_HOME                                     // Default MQTT prefix

#define DOMOTICZ_SUPPORT            0                                           // Build with domoticz (if MQTT) support (1.72Kb)
#define THINGSPEAK_SUPPORT          0                                           // Enable Thingspeak support by default (2.56Kb)
#define ALEXA_SUPPORT               0                                           // Enable Alexa support by default (10.84Kb)
  • sonoff web interface with 1.13.3 master image:

1133master

  • and with 1.13.4dev image:

1134dev

@mcspr
Copy link
Collaborator

mcspr commented Jan 12, 2019

@reaper7 Thank you for providing config!

As to difference between 1.13.3 and 1.13.4-dev:
If you are using Chrome, you can check web inspector to see that it sends exactly 9 ws messages on 1.13.3. Which fits in above limit, because first is acked immediately while 8 are still queued.
1.13.4-dev revamps relay config to send more ws messages, which results in 12 messages that no longer fit the queue fully.
And this could be safely mitigated by not using latest commit to the master of ESPAsyncWebServer. Queue limit added seems arbitrary, as it based on amount of messages and not their size, and can safely be avoided here.

I think i am going to do the proposed workaround to avoid possible issues like this (+ there would be nicer api to fetch module config after the initial one)

edit: oops, wrong mention

@reaper7
Copy link
Contributor

reaper7 commented Jan 12, 2019

@mcspr - thanks for explaining :)
I'm new espurna user, I did not know this repo deeply yet. (compared to tasmota, it's damn fast, I'm going to stay with this project)

You understand that I would like to have and use one version of the external library like ESPAsyncWebServer for all "my" projects.
so...every possible improvement will be appreciated.

@daxkamala
Copy link

Hooray! And thanks for the pointers.
I just changed line 30 in AsyncWebSocket.h (#define WS_MAX_QUEUED_MESSAGES) from 8 to 16 and all the menus returned.
This file will be under your libraries, ESPAsyncWebServer-Master in my case.
Everything else seems to work fine now.

@reaper7
Copy link
Contributor

reaper7 commented Jan 25, 2019

@daxkamala - I checked and it works :)

@mcspr
Copy link
Collaborator

mcspr commented Feb 4, 2019

I forgot to update here that #1387 should have a fix for this.
(see https://help.github.com/articles/checking-out-pull-requests-locally/)

Note that webui needs to be rebuilt using gulp

@mcspr
Copy link
Collaborator

mcspr commented Feb 21, 2019

@reaper7 @daxkamala can you verify changes in #1387 ?
without modifying WS_MAX_QUEUED_MESSAGES value of ESPAsyncWebServer

pre-built webui headers (replace code\espurna\static\*.h):
webui.zip

@reaper7
Copy link
Contributor

reaper7 commented Feb 21, 2019

@mcspr - not yet, I will try during the weekend. (if arduino will reconcile with python ;) )
How I can quickly import your changes (#1387)?
As I understand that they are not yet merged to the branch dev?

@mcspr
Copy link
Collaborator

mcspr commented Feb 21, 2019

@reaper7 two options:

  1. https://help.github.com/articles/checking-out-pull-requests-locally/
  2. slightly more involved. in the espurna git repo directory:
$ git remote add mcspr https://github.com/mcspr/espurna
$ git fetch mcspr compact-ws
$ git checkout -b compact-ws mcspr/compact-ws

or, if you do not want to modify your files, instead of checkout:

$ git worktree add -b compact-ws compact-ws mcspr/compact-ws
# compact-ws/ directory will now contain files from PR

@reaper7
Copy link
Contributor

reaper7 commented Feb 21, 2019

@mcspr - looks wery well!
for me almost everything works as it should...
with one small exception -> SWITCHES (SONOFF T1 (3) )
Switches bookmark shows 11 ?!?! switches, without numbers:
schowek01

I always use the same custom config:

/*
my devices:
0 sonoff rf bridge  192.168.0.150
1 sonoff t1 3ch     192.168.0.151
2 sonoff t1 3ch     192.168.0.152
3 sonoff t1 3ch     192.168.0.153
4 sonoff t1 3ch     192.168.0.154
5 sonoff t1 3ch     192.168.0.155
6 sonoff rf         192.168.0.156
7 sonoff rf         192.168.0.157
8 sonoff s20        192.168.0.158
9 sonoff s20        192.168.0.159
*/

#define SEL_DEVICE 1

#if SEL_DEVICE == 0
  #define ITEAD_SONOFF_RFBRIDGE
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonoffbr150"
  #define RELAY_BOOT_MODE             0                                         // 0 - off, 1 - on, 2 - same
  #define LED1_MODE                   LED_MODE_RELAY
  #define WIFI1_IP                    "192.168.0.150"
#elif SEL_DEVICE == 1
  #define ITEAD_SONOFF_T1_3CH
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonofft13151"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
  #define LED1_MODE                   LED_MODE_FINDME
  #define WIFI1_IP                    "192.168.0.151"
#elif SEL_DEVICE == 6
  #define ITEAD_SONOFF_RF
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonoffrf156"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
  #define LED1_MODE                   LED_MODE_FINDME
  #define WIFI1_IP                    "192.168.0.156"
#elif SEL_DEVICE == 7
  #define ITEAD_SONOFF_RF
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonoffrf157"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
  #define LED1_MODE                   LED_MODE_FINDME
  #define WIFI1_IP                    "192.168.0.157"
#elif SEL_DEVICE == 8
  #define ITEAD_S20
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonoffs20158"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
//  #define LED1_MODE                   LED_MODE_FINDME
  #define LED1_MODE                   LED_MODE_MQTT
  #define WIFI1_IP                    "192.168.0.158"
#elif SEL_DEVICE == 9
  #define ITEAD_S20
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "sonoffs20159"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
//  #define LED1_MODE                   LED_MODE_FINDME
  #define LED1_MODE                   LED_MODE_MQTT
  #define WIFI1_IP                    "192.168.0.159"
#elif SEL_DEVICE == 99
//  #define ARILUX_AL_LC11
//  #define ITEAD_SONOFF_IFAN02
//  #define ITEAD_BNSZ01
  #define ITEAD_SONOFF_TH
  #define MY_ROOM                     "salon"
  #define MY_HOSTNAME                 "espurnatest"
  #define RELAY_BOOT_MODE             2                                         // 0 - off, 1 - on, 2 - same
//  #define LED1_MODE                   LED_MODE_FINDME
  #define LED1_MODE                   LED_MODE_MQTT
  #define WIFI1_IP                    "192.168.0.199"
  
//  #define LIGHT_USE_RGB               1
//  #define LIGHT_USE_GAMMA             1
  #define LIGHT_USE_WHITE             1
  #define LIGHT_USE_CCT               1
#else
  #define ESPURNA_CORE
#endif

#define WIFI1_SSID                  "SomeSSID"
#define WIFI1_PASS                  "SomePASS"
#define WIFI2_SSID                  WIFI1_SSID
#define WIFI2_PASS                  WIFI1_PASS

#if defined(WIFI1_IP)
  #define WIFI1_GW                  "192.168.0.254"
  #define WIFI1_MASK                "255.255.255.0"
  #define WIFI1_DNS                 "192.168.0.254"
  #define WIFI2_IP                  WIFI1_IP
  #define WIFI2_GW                  WIFI1_GW
  #define WIFI2_MASK                WIFI1_MASK
  #define WIFI2_DNS                 WIFI1_DNS
#endif

#define ADMIN_PASS                  "SomeAdminPass"                                  // Default password (WEB, OTA, WIFI SoftAP)

#if defined(ESPURNA_CORE)

  #define WIFI_FALLBACK_APMODE        1                                         // Fallback to AP mode if no STA connection
  #define USE_PASSWORD                1

#else

  #define MY_HOME "myhome"

  #if defined(MY_ROOM) && defined(MY_HOSTNAME)
    #define HOSTNAME                    MY_HOSTNAME
    #define MQTT_TOPIC                  MY_HOME "/" MY_ROOM "/" MY_HOSTNAME "/"
  #else
    #define MQTT_TOPIC                  MY_HOME "/"
  #endif

  #define WIFI_FALLBACK_APMODE        0                                         // Fallback to AP mode if no STA connection
  #define USE_PASSWORD                0

  #define TELNET_SUPPORT              0                                         // Enable telnet support by default (3.34Kb)
  #define TERMINAL_SUPPORT            0                                         // Enable terminal commands (0.97Kb)

  #define WEB_SUPPORT                 1                                         // Enable web support (http, api, 121.65Kb)
  #define WEB_EMBEDDED                1                                         // Build the firmware with the web interface embedded in
  #define WEB_FORCE_PASS_CHANGE       0

  #define DEBUG_SERIAL_SUPPORT        0                                         // Enable serial debug log
  #define DEBUG_UDP_SUPPORT           0                                         // Enable UDP debug log
  #define DEBUG_TELNET_SUPPORT        0                                         // Enable telnet debug log (will only work if TELNET_SUPPORT is also 1)
  #define DEBUG_WEB_SUPPORT           0                                         // Enable web debug log (will only work if WEB_SUPPORT is also 1)

  #undef NTP_SUPPORT
  #define NTP_SUPPORT                 1                                         // Build with NTP support by default (6.78Kb)
  #define NTP_SERVER                  "myhome.lan"

  #undef MQTT_SUPPORT
  #define MQTT_SUPPORT                1                                         // MQTT support (22.38Kb async, 12.48Kb sync)
  #undef MQTT_ENABLED
  #define MQTT_ENABLED                1                                         // Do not enable MQTT connection by default
  #define MQTT_AUTOCONNECT            1                                         // If enabled and MDNS_SERVER_SUPPORT=1 will perform an autodiscover and
  #define MQTT_SERVER                 "rpi"                                     // Default MQTT broker address
  #define MQTT_USER                   "mqttuser"                              // Default MQTT broker usename
  #define MQTT_PASS                   "mqttpass"                              // Default MQTT broker password
  #define MQTT_RETAIN                 true                                      // MQTT retain flag
  #define MQTT_QOS                    0                                         // MQTT QoS value for all messages
  #define MQTT_USE_JSON               0                                         // Group messages in a JSON body

  #define HOMEASSISTANT_SUPPORT       1                                         // Build with home assistant support (if MQTT, 1.64Kb)
  #define HOMEASSISTANT_ENABLED       1                                         // Integration not enabled by default
  #define HOMEASSISTANT_PREFIX        MY_HOME                                   // Default MQTT prefix

  #define DOMOTICZ_SUPPORT            0                                         // Build with domoticz (if MQTT) support (1.72Kb)
  #define THINGSPEAK_SUPPORT          0                                         // Enable Thingspeak support by default (2.56Kb)
  #define ALEXA_SUPPORT               0                                         // Enable Alexa support by default (10.84Kb)

#endif

@xoseperez
Copy link
Owner

Just merged #1387 which solves this issue within ESPurna. Anyway it will be interesting to have some different approach to this on AsyncWebSocket class...

@mcspr
Copy link
Collaborator

mcspr commented Feb 21, 2019

@reaper7 i think you were missing correct webui. courtesy of Xose, dev now has prebuilt ones, so just git pull will do. i do not see the bug you describing rn with a test device

@xoseperez
Copy link
Owner

Yes, I think web UI images should be created for every new feature committed. It's not obvious you have to build them too otherwise.

@reaper7
Copy link
Contributor

reaper7 commented Feb 22, 2019

You're probably right, I'll check it in the evening again :)

@mcspr
Copy link
Collaborator

mcspr commented Feb 22, 2019

Yes, I think web UI images should be created for every new feature committed. It's not obvious you have to build them too otherwise.

True. My main problems are diffs and general repo size effects.

While I was writing this, turns out the diff problem can be easily solved via .gitattributes by treating them as binary blobs:

*.gz.h    -diff -merge
*.gz.h    linguist-generated=true

I would also add a evil check to the CI, comparing generated files to the ones in the commit and fail if they are not the same

ref:
https://help.github.com/en/articles/customizing-how-changed-files-appear-on-github
https://git-scm.com/docs/gitattributes#_marking_files_as_binary

@reaper7
Copy link
Contributor

reaper7 commented Feb 22, 2019

it was a problem with missing correct webui :) mea culpa !
tnx!

@schweini
Copy link

schweini commented Mar 9, 2019

I am still missing the MQTT web interface.

i just did a git pull and the web interface says i'm running ESPURNA 1.13.4-dev on a Sonoff POW R2.
I'm using the library async-mqtt-client-master from the .zip linked to on the wiki page, or PubSubClient 2.7.0.

the relevant parts from my custom.h are:

#define MQTT_ENABLED                1               // Do not enable MQTT connection by default
#define MQTT_USE_JSON               1               // Group messages in a JSON body
#define MQTT_SERVER                 "XXXXXXX"
#define MQTT_USER                   "XXXXXXX"              // Default MQTT broker usename
#define MQTT_PASS                   "XXXXXXXX"              // Default MQTT broker password
#define MQTT_USE_ASYNC              1           // Use AysncMQTTClient (1) or PubSubClient (0)

I have also tried using MQTT_USE_ASYNC 0, but no change.

I also re-compiled everything with an empty custom.h (IIRC, MQTT support is enabled by default?) and still have no MQTT tab.

the config command on the debug console gives me:

{"adminPass":"XXXXX","board":"71","boardName":"ITEAD_SONOFF_POW_R2","btnGPIO0":"0","btnRelay0":"0","cf1GPIO":"13","cfGPIO":"14","cfg":"3","hostname":"ESPURNA-32C104","ledGPIO0":"15","ledLogic0":"1","relayBoot0":"0","relayGPIO0":"12","relayPulse0":"0","relayTime0":"0.00","relayType0":"0","selGPIO":"5","snsResetTS":""}

P.S.: when you guys for example say "try it with 1.13.3" - how can I do that via git?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants