Skip to content

Commit

Permalink
Webgui with menu
Browse files Browse the repository at this point in the history
  • Loading branch information
esp8266nu committed Jun 30, 2015
1 parent 6c41e55 commit ad51cc3
Show file tree
Hide file tree
Showing 8 changed files with 1,397 additions and 611 deletions.
508 changes: 254 additions & 254 deletions Controller.ino

Large diffs are not rendered by default.

31 changes: 27 additions & 4 deletions ESPEasy.ino
Expand Up @@ -5,11 +5,33 @@
* as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
* of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You received a copy of the GNU General Public License along with this program in file 'COPYING.TXT'.
* You received a copy of the GNU General Public License along with this program in file 'License.txt'.
*
* Source Code : https://sourceforge.net/projects/espeasy/
* Support : http://www.esp8266.nu
* Discussion : http://www.esp8266.nu/forum/
*
* Additional information about licensing can be found at : http://www.gnu.org/licenses
\*************************************************************************************************************************/

// This file incorporates work covered by the following copyright and permission notice:

/****************************************************************************************************************************\
* Arduino project "Nodo" © Copyright 2010..2015 Paul Tonkes
*
* This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty
* of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You received a copy of the GNU General Public License along with this program in file 'License.txt'.
*
* Voor toelichting op de licentievoorwaarden zie : http://www.gnu.org/licenses
* Uitgebreide documentatie is te vinden op : http://www.nodo-domotica.nl
* bugs kunnen worden gelogd op : https://code.google.com/p/arduino-nodo/
* Compiler voor deze programmacode te downloaden op : http://arduino.cc
* Voor vragen of suggesties, mail naar : p.k.tonkes@gmail.com
\*************************************************************************************************************************/

// Simple Arduino sketch for ESP module, supporting:
// Dallas OneWire DS18b20 temperature sensor
// DHT11/22 humidity sensor
Expand Down Expand Up @@ -75,7 +97,7 @@
#define ESP_PROJECT_PID 2015050101L
#define ESP_EASY
#define VERSION 1
#define BUILD 9
#define BUILD 10

#define REBOOT_ON_MAX_CONNECTION_FAILURES 30

Expand Down Expand Up @@ -137,6 +159,7 @@ struct SettingsStruct
byte Subnet[4];
byte Debug;
char Name[26];
byte SyslogLevel;
} Settings;

struct LogStruct
Expand All @@ -157,7 +180,6 @@ unsigned long timerwd;
unsigned int NC_Count = 0;
unsigned int C_Count = 0;
boolean AP_Mode = false;
char ap_ssid[20];
boolean cmd_disconnect = false;
unsigned long connectionFailures;
unsigned long wdcounter=0;
Expand Down Expand Up @@ -208,7 +230,8 @@ void setup()
lcd.print("ESP Easy");

// Setup MQTT Client
MQTTConnect();
if (Settings.Protocol == 2)
MQTTConnect();

syslog((char*)"Boot");
sendSysInfoUDP(3);
Expand Down
704 changes: 704 additions & 0 deletions License.txt

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions Misc.ino
Expand Up @@ -20,6 +20,10 @@ float ul2float(unsigned long ul)
void addLog(char *line)
{
Serial.println(line);

if (Settings.SyslogLevel == 3)
syslog(line);

logcount++;
if (logcount > 9)
logcount=0;
Expand Down
1 change: 1 addition & 0 deletions Serial.ino
Expand Up @@ -442,6 +442,7 @@ void ResetFactory(void)
Settings.Subnet[3] = 0;
Settings.Debug = 0;
strcpy(Settings.Name, DEFAULT_NAME);
Settings.SyslogLevel = 0;
Save_Settings();
WifiDisconnect();
ESP.reset();
Expand Down

0 comments on commit ad51cc3

Please sign in to comment.