Deprecated: Function get_magic_quotes_gpc() is deprecated in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 99

Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 619

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1169

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176
8000 GitHub - Ezeliam/controlador_LED: Control de LEDs con ESP8266 + WebSocket
Nothing Special   »   [go: up one dir, main page]

Skip to content

Ezeliam/controlador_LED

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚀 Control de LEDs con ESP8266 + WebSocket

Un sistema de control remoto para tiras de LEDs NeoPixel (WS2812B) mediante una interfaz web usando WebSocket. El ESP8266 actúa como servidor web y WebSocket, permitiendo intercalar entre 2 colores de LEDs individualmente o en grupo, con persistencia de estado.

🌟 Características principales

  • ✅ Control individual o grupal de LEDs
  • ✅ Persistencia del estado (los LEDs mantienen su color después de reiniciar)
  • ✅ Interfaz web responsive
  • ✅ Comunicación en tiempo real con WebSocket
  • ✅ Fácil configuración WiFi

📦 Hardware Requerido

  • Placa ESP8266 (NodeMCU, Wemos D1 Mini, etc.)
  • Tira de LEDs NeoPixel (WS2812B) - (en este ejemplo se usaron 144 LEDs)
  • Fuente de alimentación adecuada
  • Resistencia de 330-470Ω y capacitor de 1000µF (recomendados para protección)

🛠️ Configuración del ESP8266

📋 Requisitos

  • Arduino IDE
  • Board ESP8266 instalada (usar Boards Manager)
  • Bibliotecas necesarias:
    • ESP8266WiFi
    • WebSockets
    • ArduinoJson
    • Adafruit NeoPixel
    • ESP8266mDNS

⚙️ Pasos de instalación

  1. Clonar este repositorio
  2. Abrir ESP8266_LED_Controller/Microcontrolador/ESP8266.ino en Arduino IDE
  3. Modificar las variables en base a lo que uses en el código ESP8266.ino:
    const char* ssid = "TU_SSID";
    const char* password = "TU_PASSWORD";
    #define LED_PIN "TU_PIN"
    #define LED_COUNT "NUMERO_LEDS"
    #define JSON_SIZE "TAMAÑO_JSON" (calcular alrededor de 20 bytes por LED, siempre redondear para arriba el resultado)
  4. Subir el codigo a la placa ESP8266
  5. Modificar las variables en base a lo que uses en el código:
    FrontEnd/src/app.jsx
    const leds = Array.from({ length: "NUMERO_LEDS" }, (_, i) => i);
    FrontEnd\src\WebSocketContext.js
    details: [
     "Asegúrese de estar conectado al mismo router que el microcontrolador.",
     "Red: TP-LINK_FE90", //red que use en el momento
     "Contraseña: 67992980", //lo mismo
     "Asegúrese de que el microcontrolador esté encendido.",
     "Recargue la página para volver a intentar la conexión."
     ]
    

🛠️ Configuración del archivo del FrontEnd

📋 Requisitos

  • Editor de Código de preferencia
  • Node.js
  • Navegador web (internet explorer no)
  • Un padre nuestro (opcional)

⚙️ Pasos de instalación

  1. Descarga Node.js si no lo tenés
  2. Descargar todas las dependencias necesarias:
    • react-scripts
    • react-dom
    • express
  3. conecta tu pc al mismo internet que el microcontrolador
  4. usa npm start o npm run build para empaquetarlo
  5. opcional en caso de usar el npm run build: usa el inicio.bat como acceso directo para ejecutar el programa, cambiando la direccion en "serve "C:\users\usuario\documents\gestorled\build"" segun donde guardes el build

🚩 Cosas a tener en cuenta

En base a mi experiencia programandolo es importante tener en cuenta los siguientes puntos:

  • Usar routers de 2.4Ghz de frecuencia, no funciona con aquellos de 5Ghz

  • Por alguna razón con algunas tiras de LED la señal de luz verde era luz roja y viceversa, actualmente no sé por qué ocurría pero si te sucede lo mismo puedes modificar la parte grafica de los botones para no tener que modificar el codigo del microcontrolador y subirlo devuelta en él

  • Originalmente este codigo estaba pensado para ESP32, y si cambian las dependencias a las necesarias para esta, en teoria deberia funcionar, sin embargo en la práctica nunca me funcionó, tal vez a ustedes si prueban les salga

🤝 Contribuciones

¡PRs y sugerencias son bienvenidas!

📄 Licencia: MIT

Creado por Liam Di Cerbo (GitHub)

Releases

No releases published

Packages

No packages published
0