mirror of https://github.com/lumapu/ahoy.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
743 B
33 lines
743 B
|
|
#include "Arduino.h"
|
|
|
|
#include <ESP8266WiFi.h>
|
|
#include <DNSServer.h>
|
|
#include <ESP8266WebServer.h>
|
|
#include <Ticker.h>
|
|
|
|
#include <ESP8266HTTPUpdateServer.h>
|
|
#include "app.h"
|
|
|
|
app myApp;
|
|
|
|
//-----------------------------------------------------------------------------
|
|
void setup() {
|
|
// AP name, password, timeout
|
|
myApp.setup("ESP AHOY", "esp_8266", 15);
|
|
|
|
// TODO: move to HmRadio
|
|
attachInterrupt(digitalPinToInterrupt(myApp.getIrqPin()), handleIntr, FALLING);
|
|
}
|
|
|
|
|
|
//-----------------------------------------------------------------------------
|
|
void loop() {
|
|
myApp.loop();
|
|
}
|
|
|
|
|
|
//-----------------------------------------------------------------------------
|
|
ICACHE_RAM_ATTR void handleIntr(void) {
|
|
myApp.handleIntr();
|
|
}
|
|
|