Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
110 changes: 110 additions & 0 deletions build.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
Warning! `src_filter` configuration option in section [env:esp32dev] is deprecated and will be removed in the next release! Please use `build_src_filter` instead
Processing esp32dev (board: esp32dev; platform: https://github.com/tasmota/platform-espressif32/releases/download/2023.06.02/platform-espressif32.zip; framework: arduino)
--------------------------------------------------------------------------------
Library Manager: Installing SPI
Verbose mode can be enabled via `-v, --verbose` option
*** use existing my_config.h ***
Installing node packages
npm ci

added 68 packages, and audited 69 packages in 633ms

13 packages are looking for funding
run `npm fund` for details

found 0 vulnerabilities
npm run build

> wled@0.16.0-alpha build
> node tools/cdata.js


## ## ## ###### ######
## ## ## ## ## ## ##
## ## ## ## ###### ## ##
## ## ## ## ## ## ##
## ## ###### ###### ######
build script for web UI

Web UI is already built
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 (2023.6.2) > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 2.0.9
- tool-esptoolpy @ 1.40602.0 (4.6.2)
- tool-mklittlefs @ 1.203.210628 (2.3)
- tool-mkspiffs @ 2.230.0 (2.30)
- toolchain-xtensa-esp32 @ 8.4.0+2021r2-patch5
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ strict
Found 46 compatible libraries
Scanning dependencies...
Dependency Graph
|-- AsyncTCP @ 3.4.7
|-- AnimatedGIF @ 1.4.7
|-- GifDecoder @ 1.1.0+sha.bc3af18
|-- esp_dmx @ 3.1.1+sha.47db25d8
|-- FastLED @ 3.6.0
|-- IRremoteESP8266 @ 2.8.2
|-- NeoPixelBus @ 2.8.4+sha.a0919d1
|-- ESPAsyncWebServerWLED @ 2.4.2+sha.39b830c
|-- AsyncMqttClient @ 0.9.0
|-- QuickEspNow @ 0.8.1+sha.193e991
|-- audioreactive
|-- SD_MMC @ 2.0.0
|-- SD @ 2.0.0
|-- SPI @ 2.0.0
|-- ESPmDNS @ 2.0.0
|-- Wire @ 2.0.0
|-- Update @ 2.0.0
|-- ArduinoOTA @ 2.0.0
|-- EEPROM @ 2.0.0
|-- DNSServer @ 2.0.0
|-- Ethernet @ 2.0.0
|-- LittleFS @ 2.0.0
|-- WiFi @ 2.0.0
|-- NeoESP32RmtHI
|-- ESP32 Async UDP @ 2.0.0
|-- WebServer @ 2.0.0
Building in release mode
Compiling .pio/build/esp32dev/usermods/FSEQ/register_usermod.cpp.o
Compiling .pio/build/esp32dev/src/bus_manager.cpp.o
Compiling .pio/build/esp32dev/src/button.cpp.o
Compiling .pio/build/esp32dev/src/cfg.cpp.o
Compiling .pio/build/esp32dev/src/colors.cpp.o
Compiling .pio/build/esp32dev/src/dmx_input.cpp.o
Compiling .pio/build/esp32dev/src/dmx_output.cpp.o
Compiling .pio/build/esp32dev/src/e131.cpp.o
Compiling .pio/build/esp32dev/src/file.cpp.o
Compiling .pio/build/esp32dev/src/hue.cpp.o
In file included from usermods/FSEQ/usermod_fpp.h:3,
from usermods/FSEQ/register_usermod.cpp:1:
usermods/FSEQ/usermod_fseq.h:38:12: error: 'SPIClass' does not name a type; did you mean 'class'?
inline SPIClass spiPort = SPIClass(VSPI);
^~~~~~~~
class
In file included from .pio/libdeps/esp32dev/FastLED/src/FastLED.h:75,
from wled00/colors.h:9,
from wled00/bus_manager.cpp:25:
.pio/libdeps/esp32dev/FastLED/src/fastspi.h:157:23: note: #pragma message: No hardware SPI pins defined. All SPI access will default to bitbanged output
# pragma message "No hardware SPI pins defined. All SPI access will default to bitbanged output"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from usermods/FSEQ/usermod_fpp.h:3,
from usermods/FSEQ/register_usermod.cpp:1:
usermods/FSEQ/usermod_fseq.h: In member function 'void UsermodFseq::reinit_SD_SPI()':
usermods/FSEQ/usermod_fseq.h:147:5: error: 'spiPort' was not declared in this scope
spiPort.begin(configPinSourceClock, configPinPoci, configPinPico, configPinSourceSelect);
^~~~~~~
usermods/FSEQ/usermod_fseq.h:147:5: note: suggested alternative: 'udpPort'
spiPort.begin(configPinSourceClock, configPinPoci, configPinPico, configPinSourceSelect);
^~~~~~~
udpPort
*** [.pio/build/esp32dev/usermods/FSEQ/register_usermod.cpp.o] Error 1
========================== [FAILED] Took 6.31 seconds ==========================

Environment Status Duration
------------- -------- ------------
esp32dev FAILED 00:00:06.313
==================== 1 failed, 0 succeeded in 00:00:06.313 ====================
117 changes: 117 additions & 0 deletions usermods/FSEQ/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
# ✨ Usermod FSEQ ✨

> **Created by: Andrej Chrcek**

Welcome to the **Usermod FSEQ** project! This innovative module empowers your WLED setup by enabling FSEQ file playback from an SD card, complete with a sleek web UI and UDP remote control. Dive into a world where creativity meets functionality and transform your lighting experience.

# SWEB UI http://yourIP/sd/ui

# SD & FSEQ Usermod for WLED

This usermod adds support for playing FSEQ files from an SD card and provides a web interface for managing SD files and controlling FSEQ playback via HTTP and UDP. It also supports configurable SPI pin settings for SD SPI. The usermod exposes several HTTP endpoints for file management and playback control.

---

## Features

- **FSEQ Playback:** Play FSEQ files from an SD card.
- **Web UI:** Manage SD files (list, upload, delete) and control FSEQ playback.
- **UDP Synchronization:** Remote control via UDP packets.
- **Configurable SPI Pins:** SPI pin assignments are configurable through WLED’s configuration JSON.

---

## Installation

### 1. Configure PlatformIO

Add the following configuration to your `platformio_override.ini` (or `platformio.ini`) file:

```ini
[env:esp32dev_V4]
build_flags =
-D WLED_USE_SD_SPI
-D USERMOD_FPP
-D USERMOD_FSEQ
-I wled00/src/dependencies/json
; optional:
; -D WLED_DEBUG


### 2. Update the WLED Web Interface (Optional)

To integrate the new FSEQ functionality into the WLED UI, add a new button to the navigation area in your `wled00/data/index.htm` file. For example:

<!-- New button for SD & FSEQ Manager -->
<button onclick="window.location.href=getURL('/fsequi');">
<i class="icons">&#xe0d2;</i>
<p class="tab-label">Fseq</p>
</button>

### 3. Modify usermods_list.cpp

Register the FSEQ usermod by adding the following lines to `usermods_list.cpp`. Ensure no conflicting modules are included:

```cpp
#ifdef USERMOD_FSEQ
#include "../usermods/FSEQ/usermod_fseq.h"
#endif

#ifdef USERMOD_FSEQ
UsermodManager::add(new UsermodFseq());
#endif

// Remove or comment out any conflicting SD card usermod:
// //#include "../usermods/sd_card/usermod_sd_card.h"
// //#ifdef SD_ADAPTER
// //UsermodManager::add(new UsermodSdCard());
// //#endif

Comment on lines +41 to +69
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Documentation contradicts maintainer feedback on usermod architecture.

Based on the PR objectives summary, maintainers have requested:

  1. No main menu button (lines 41-50): Usermods should expose their HTTP handler and link from the Info dialog, not add buttons to the main menu.
  2. New usermod format (lines 51-69): The PR should follow the new usermod setup with library.json and avoid editing usermods_list.cpp.

The current documentation instructs users to modify index.htm and usermods_list.cpp, which conflicts with the requested architecture. Consider updating the documentation to:

  • Remove instructions for adding the main menu button
  • Document the new usermod registration approach (if implemented)
  • Add library.json configuration details

HTTP Endpoints

The following endpoints are available:
• GET /sd/ui
Description: Returns an HTML page with the SD & FSEQ Manager interface.
Usage: Open this URL in a browser.
• GET /sd/list
Description: Displays an HTML page listing all files on the SD card, with options to delete files and a form to upload new files.
Usage: Access this URL to view the SD file list.
• POST /sd/upload
Description: Handles file uploads to the SD card using a multipart/form-data POST request.
Usage: Use a file upload form or an HTTP client.
• GET /sd/delete
Description: Deletes a specified file from the SD card. Requires a query parameter path indicating the file path.
Usage: Example: /sd/delete?path=/example.fseq.
• GET /fseq/list
Description: Returns an HTML page listing all FSEQ files (with .fseq or .FSEQ extensions) on the SD card. Each file includes a button to play it.
Usage: Open this URL in a browser to view and interact with the file list.
• GET /fseq/start
Description: Starts playback of a selected FSEQ file. Requires a file query parameter and optionally a t parameter (time offset in seconds).
Usage: Example: /fseq/start?file=/animation.fseq&t=10.
• GET /fseq/stop
Description: Stops the current FSEQ playback and clears the active playback session.
Usage: Send an HTTP GET request to stop playback.
• GET /fseqfilelist
Description: Returns a JSON list of all FSEQ files found on the SD card.
Usage: Open this URL or send an HTTP GET request to retrieve the file list.


Configurable SPI Pin Settings

The default SPI pin assignments for SD SPI are defined as follows:

#ifdef WLED_USE_SD_SPI
int8_t UsermodFseq::configPinSourceSelect = 5;
int8_t UsermodFseq::configPinSourceClock = 18;
int8_t UsermodFseq::configPinPoci = 19;
int8_t UsermodFseq::configPinPico = 23;
#endif

These values can be modified via WLED’s configuration JSON using the addToConfig() and readFromConfig() methods. This allows you to change the pin settings without recompiling the firmware.

Summary

The SD & FSEQ Usermod for WLED enables FSEQ file playback from an SD card with a full-featured web UI and UDP synchronization for remote control. With configurable SPI pin settings, this usermod integrates seamlessly into WLED, providing additional functionality without modifying core code.

For further customization or support, please refer to the project documentation or open an issue on GitHub.

Loading