-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathMelvana.ino
75 lines (49 loc) · 1.87 KB
/
Melvana.ino
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
// Core here
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#define MDNSSERVICE
// --------------------------- ODD Defines for Debuging ----------------------------
//#define DEBUG_YES
//#define HEAP_TIMER
//#define STAGING
//#define WIP // This is work in progress... so probably will break things...
//#define USE_COLOUR_OPERATORS This doesn't work
// -----------------------------------------------------------------------------------
#include <ESP8266WiFi.h>
#include <WiFiUdp.h>
#ifdef MDNSSERVICE
#include <ESP8266mDNS.h>
#endif
#include <ESP8266WebServer.h>
#include <PubSubClient.h>
#include <EEPROM.h>
#include <SimpleTimer.h>
#include "eeprom_writeanything.h"
#include "F_Strings.h"
#define cache ICACHE_FLASH_ATTR
#ifdef DEBUG_YES
#define Debug(x) Serial.print(x)
#define Debugln(x) Serial.println(x)
#define Debugf(...) Serial.printf(__VA_ARGS__)
#define Debugflush Serial.flush
#else
#define Debug(x) {}
#define Debugln(x) {}
#define Debugf(...) {}
#define Debugflush {}
#endif
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
// Plugin stuff below here
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#include <NeoPixelBus.h>
#include <E131.h>
#include "enumerates.h"
#define HSL_FLOAT
#define GAMMA_CORRECTION
#define ESPUARTWS2812 // USE UART to drive pixels, required until bitbanging is fixed.
#define ANIMATION_LIMIT 250 // limit for number of pixels where animations work.. otherwise it crashes.
#define MINIMUM_REFRESH 30 // minimum update frequency for WS2812