Smart Bulb Control via MCP Server With Claude

by Arpitmahajan123

325 downloads Not rated yet

About

This project creates an MCP server using Node.js and TypeScript to autonomously control a smart bulb via UDP communication. It integrates with AI interfaces like ChatGPT or Claude, enabling seamless, anonymous, and automated lighting control with color and brightness adjustments.

Explore

- Turn bulb on/off via AI or command-line input.

- Set RGB color dynamically.

- Adjust brightness using dimming percentage.

- AI Integration with MCP for automated routines.

Install dependencies with pnpm install, build the TypeScript project with pnpm build, then run the server with npm start. Ensure the smart bulb is connected to the same network and configured with the correct IP address and UDP port. The server exposes MCP tools (e.g., turn_on, set_color) that AI clients can invoke.

- Node.js: For writing the UDP client.

- TypeScript: Ensures type-safe, scalable code.

- NPM: Package manager for installing dependencies.

- MCP SDK: Official SDK for building MCP servers.

- dgram module: Node’s built-in module for UDP sockets.

This project demonstrates how to build an MCP (Machine Control Protocol). server using Node.js and TypeScript to autonomously control a smart bulb using AI-driven commands. It enables seamless, anonymous, and automated smart lighting management through UDP communication and AI interfaces like ChatGPT or Claude.
No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.