mirror of
https://github.com/lumapu/ahoy.git
synced 2025-06-14 16:41:38 +02:00
* improved read / save to eep
This commit is contained in:
parent
f1b19bccfe
commit
778f209eb5
7 changed files with 245 additions and 236 deletions
tools/esp8266
34
tools/esp8266/main.cpp
Normal file
34
tools/esp8266/main.cpp
Normal file
|
@ -0,0 +1,34 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
// 2022 Ahoy, https://www.mikrocontroller.net/topic/525778
|
||||
// Creative Commons - http://creativecommons.org/licenses/by-nc-sa/3.0/de/
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
#include "dbg.h"
|
||||
#include "app.h"
|
||||
#include "config.h"
|
||||
|
||||
#include "web.h"
|
||||
|
||||
app myApp;
|
||||
web *mWebInst;
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
IRAM_ATTR void handleIntr(void) {
|
||||
myApp.handleIntr();
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
void setup() {
|
||||
myApp.setup(WIFI_TRY_CONNECT_TIME);
|
||||
mWebInst = new web(&myApp);
|
||||
|
||||
// TODO: move to HmRadio
|
||||
attachInterrupt(digitalPinToInterrupt(myApp.getIrqPin()), handleIntr, FALLING);
|
||||
}
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
void loop() {
|
||||
myApp.loop();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue