LUZMCP
Provides tools to query and change IoT lamp status through the Flask REST API, enabling remote monitoring and control of devices.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@LUZMCPturn on lamp L1 and report the status of both lamps"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
๐ก LUZMCP โ Sistema IoT com MCP Server & PWA
Sistema distribuรญdo para monitoramento e controle remoto de lรขmpadas/dispositivos IoT em tempo real. A arquitetura conecta um Progressive Web App (PWA) moderno, um servidor MCP (Model Context Protocol) para integraรงรฃo com Agentes e LLMs, uma API REST Flask e um microcontrolador simulado no Wokwi executando MicroPython.
๐ฎ Demonstraรงรฃo Online (Teste Agora Mesmo)
Vocรช pode testar todo o sistema funcionando ao vivo sem precisar instalar nada:
Abra o Simulador de Hardware:
๐ Acessar Simulador Wokwi
(Clique no botรฃo verde de Play โถ๏ธ para iniciar a placa e ligar a conexรฃo Wi-Fi).Abra o Painel de Controle (PWA):
๐ Acessar Painel IoT Control (PWA)
(Funciona no computador e no celular. No celular, vocรช pode selecionar "Adicionar ร tela inicial" para instalar como app).Interaja com as Lรขmpadas:
Clique no botรฃo de L1 โ O LED Vermelho no pino GP10 acende na simulaรงรฃo.
Clique no botรฃo de L2 โ O LED Azul no pino GP11 acende na simulaรงรฃo.
Desligue os interruptores no app para apagar as luzes correspondentes.
Related MCP server: Home Assistant MCP Server
๐๏ธ Arquitetura do Sistema
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Clientes โ
โ โข PWA no Celular / Computador (Firebase Hosting) โ
โ โข Agentes de IA / LLMs (Claude, Gemini, Antigravity) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโ
โ โ
(Modo IA / Tools) (Modo Web Direto)
โผ โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโ
โ MCP Server (Py) โ โ API REST Flask (Py) โ
โ Transporte SSE / RPC โโโโโโโโโโโบโ (PythonAnywhere) โ
โโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
Polling HTTP (1s)
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ Raspberry Pi Pico W โ
โ (MicroPython) โ
โโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
Pinos GP10 e GP11
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโโ
โ LEDs L1 (Vermelho) โ
โ LEDs L2 (Azul) โ
โโโโโโโโโโโโโโโโโโโโโโโโโ๐ ๏ธ Tecnologias Utilizadas
Microcontrolador / IoT: Raspberry Pi Pico W simulado no Wokwi, programado em MicroPython com comunicaรงรฃo HTTP via
urequests.Backend: Python / Flask hospedado no PythonAnywhere, com suporte a CORS nativo e gerenciamento de estado dos perifรฉricos.
Camada MCP: Model Context Protocol SDK (
mcp), expondo as ferramentasobter_status_lampadasealterar_status_lampadavia Server-Sent Events (SSE).Frontend / PWA: React 19, Vite, TypeScript, Tailwind CSS e Lucide Icons, hospedado no Firebase Hosting.
๐ Estrutura de Diretรณrios
.
โโโ app.py # API Flask existente com rotas /micro e /comandos
โโโ mcp_server.py # MCP Server expondo Tools IoT via protocolo SSE
โโโ wokwi.txt # Cรณdigo MicroPython para o simulador Wokwi
โโโ firebase.json # Configuraรงรตes de deploy no Firebase Hosting
โโโ pwa/ # Aplicaรงรฃo frontend PWA
โ โโโ src/
โ โ โโโ App.tsx # Lรณgica hรญbrida (MCP + API Direta) e interface
โ โ โโโ main.tsx # Ponto de entrada React
โ โโโ package.json # Dependรชncias do frontend
โ โโโ vite.config.ts # Configuraรงรตes de build e proxy local
โโโ README.md # Documentaรงรฃo do projeto๐ป Como Rodar o Projeto Localmente
1. Prรฉ-requisitos
Python 3.10 ou superior instalado.
Node.js 18 ou superior instalado.
2. Rodando o Servidor MCP (Python)
pip install -r requirements.txt
python mcp_server.pyO servidor MCP inicializarรก ouvindo conexรตes SSE na porta 8080.
3. Rodando o PWA em Desenvolvimento
cd pwa
npm install
npm run devAbra http://localhost:5173 no seu navegador. O frontend conectarรก automaticamente ao MCP Server local via proxy /sse.
๐จโ๐ป Autor
Desenvolvido por Marlon Kipson
GitHub: @marlonkipson95
Repositรณrio: marlonkipson95/LUZMCP
This server cannot be deployed
Maintenance
Related MCP Connectors
The Remote MCP server acts as a standardized bridge between LLM applications (like Claude, ChatGPT, and Cursor) and external services, enabling AI agents to access external tools and resources. Its primary capability is providing a centralized search tool to discover other MCP servers and their respective tools. Unlike local implementations, it runs remotely with OAuth authentication and permission controls for security.
Remote MCP for RunComfy: ComfyUI deployments, hosted models, LoRA training. 31 tools.
Protocol-native energy infrastructure orchestration for AI data centers. Provides 46 MCP tools across 8 grid protocols (IEC-61850, DNP3, Modbus, OCPP, OpenADR, IEEE 2030.5, IEC 60870-5-104, ICCP) with 5 core API primitives: connect, dispatch, settle, comply, and intel. Enables AI agents to programmatically interact with substations, grid interfaces, and energy assets for real-time workload-grid coordination.
Automate 1,000+ services from any MCP-compatible AI agent: build Applets, run actions and queries.
Related MCP Servers
- AlicenseBqualityDmaintenanceLinks IoT devices to AI large models using the MCP and MQTT protocols, enabling natural language control, real-time AI responses, and complex instruction execution for interconnected IoT devices.3371MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to control and monitor Home Assistant smart home devices through natural language interactions. Supports device control, entity state monitoring, history access, and automation generation with both MCP protocol and standalone HTTP REST API modes.1MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to control Home Assistant smart home devices via MCP, with zero external dependencies. Supports calling services, getting states, and looking up service parameters.38 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables control of Philips Hue lights through the Model Context Protocol, providing tools for turning lights on/off, setting brightness and color, and retrieving light status.1Apache 2.0