diff --git a/data/index.html b/data/index.html
new file mode 100644
index 0000000..9878ae4
--- /dev/null
+++ b/data/index.html
@@ -0,0 +1,11 @@
+
+
+
+
+
+ Test
+
+
+ Your advert could be placed here
+
+
diff --git a/platformio.ini b/platformio.ini
index 07919a5..35735e1 100644
--- a/platformio.ini
+++ b/platformio.ini
@@ -14,4 +14,4 @@ board = lolin_s2_mini
framework = arduino
lib_deps =
hideakitai/ArtNet @ ^0.8.0
- someweisguy/esp_dmx @ ^4.1.0
\ No newline at end of file
+ me-no-dev/ESP Async WebServer@^1.2.4
\ No newline at end of file
diff --git a/src/main.cpp b/src/main.cpp
index f703549..e10e20c 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1,10 +1,9 @@
-// Art-Net DMX Interface Demo
-// 2024-10-17 Patrick Schwarz
-
#include
// #include
#include "ESPDMX.h"
+#include
+#include
// WiFi stuff
const char *ssid = "artnet";
@@ -13,6 +12,8 @@ const IPAddress ip(192, 168, 1, 201);
const IPAddress gateway(192, 168, 1, 1);
const IPAddress subnet(255, 255, 255, 0);
+AsyncWebServer server(80);
+
// Art-Net stuff
ArtnetWiFi artnet;
// const String target_ip = "192.168.1.200";
@@ -28,7 +29,7 @@ void setup()
{
// Serial console
- // Serial.begin(115200);
+ Serial.begin(9600);
// WiFi stuff
// WiFi.begin(ssid, pwd);
@@ -89,6 +90,17 @@ void setup()
Serial.print(", size = ");
Serial.print(size);
Serial.println(")");*/ });
+
+ if (!SPIFFS.begin(true))
+ {
+ Serial.println("An Error has occurred while mounting SPIFFS");
+ return;
+ }
+
+ server.serveStatic("/", SPIFFS, "/").setDefaultFile("index.html");
+
+ server.begin();
+ Serial.println("Server started!");
}
void loop()