xoseperez / sonoffsc

Itead Studio SonoffSC custom firmware with MQTT and Domoticz support
GNU General Public License v3.0
104 stars 35 forks source link

Cannot get the ESP code to compile #10

Open jaysuk opened 7 years ago

jaysuk commented 7 years ago

Using the arduino IDE on windows 10. Have all the dependencies included in the arduino library. This is the error I get

C:\Users\live\Downloads\sonoffsc-master\esp8266\sonoffsc\src\sonoffsc\button.ino: In function 'void buttonLoop()':

button:25: error: 'class DebounceEvent' has no member named 'getEvent' uint8_t event = _button.getEvent(); ^ button:27: error: 'EVENT_DOUBLE_CLICK' was not declared in this scope if (event == EVENT_DOUBLE_CLICK) createAP(); ^ button:28: error: 'EVENT_LONG_CLICK' was not declared in this scope if (event == EVENT_LONG_CLICK) ESP.reset(); ^ exit status 1 'class DebounceEvent' has no member named 'getEvent'

Any ideas?

juancreyes commented 7 years ago

Hi,

I am facing same error trying to verify esp8086 set files. I am afraid of button.ino code turned into bug because the Debounce library removed and changed some classes at Jan 25th and likely it misses the proper changes along of button.

[2.0.0] 2017-01-25 Changed:

Regards Juan

jaysuk commented 7 years ago

I managed to compile it with the older debounce library. It now creates an access point that I can connect to but once I log in with the correct credentials, i get an error 404 and cannot go any further to configure the sonoff sc

juancreyes commented 7 years ago

I dont know what can cause 404 error. Each time you press external Button, do you call AP creation, createAP() ? Does the SSID sonoff_endMAC appear on your wifi list and you can authenticate to AP successfully ?

jaysuk commented 7 years ago

The sonoff+Mac address appears. I can navigate to espurna.local and it asks me to login. I use the standard admin and fibonacci login and that's as far as i can get. The sonoff fails to serve any more web pages so i cannot configure it with the correct WiFi info etc

On 14 Mar 2017 6:35 pm, "juancreyes" notifications@github.com wrote:

I dont know what can cause 404 error. Each time you press external Button, do you call AP creation, createAP() ? Does the SSID sonoff_endMAC appear on your wifi list and you can authenticate to AP successfully ?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/xoseperez/sonoffsc/issues/10#issuecomment-286518629, or mute the thread https://github.com/notifications/unsubscribe-auth/ACdJBtA0JYH9ouVK29a63Wd4XVI1lj7tks5rlt3lgaJpZM4MYdFl .

xoseperez commented 7 years ago

Sorry I did not get any notifications on this issue on my email... @jaysuk you are right, compiling against DebounceEvent 1.1 is the way to go, the code is still not compatible with new 2.0 version. @jaysuk Probably you did not flash the filesystem image, so there are no contents to serve. You can check how to do it in the ESPurna repo (same procedure) here: https://bitbucket.org/xoseperez/espurna/wiki/Filesystem.deprecated.md

DasBasti commented 7 years ago

https://github.com/xoseperez/sonoffsc/pull/12 will fix the issue with DebounceEvent