Skip to main content
Glama
cyberomusubi

CO2 Sensor MCP Server

by cyberomusubi

センサーデバイス用MCPサーバー

このプロジェクトは、Claude Desktop で使用するために設計された Node.js アプリケーションです。CO2 センサーデバイスをシミュレートし、デバイスとやり取りするための JSON-RPC サーバーを提供します。このアプリケーションは、シミュレーションモードとリアルモードの両方で実行でき、リアルモードでは USB 経由で Raspberry Pi Pico に接続して CO2 レベルを読み取ります。

特徴

  • シミュレーション モードでランダムな CO2 レベルを持つ CO2 センサー デバイスをシミュレートします。

  • USB 経由で Raspberry Pi Pico に接続し、実際の CO2 レベルを読み取ります。

  • JSON-RPC 経由でデバイス情報、センサー データ、ネットワーク ステータスを提供します。

  • MQTT にデータを公開し、WiFi を再接続し、MQTT を再接続するコマンドをサポートします (一部の機能はモック化されています)。

Related MCP server: CoinGecko

インストール

このアプリケーションを実行するには、お使いのマシンにNode.jsがインストールされている必要があります。Node.jsがインストールされていない場合は、公式ウェブサイトからダウンロードできます。

  1. リポジトリをクローンします。

  2. npm を使用して依存関係をインストールします。

    npm install

構成

claude_desktop_config.jsonファイルがサーバーを実行するために正しく設定されていることを確認してください。設定例:

{
  "mcpServers": {
    "CO2 sensor": {
      "command": "node",
      "args": [
        "...mcp-server-for-sensor-device/index.js"
      ],
      "env": {}
    }
  }
}

使用法

サーバーを起動するには、次のコマンドを実行します。

node index.js

JSON-RPCメソッド

initialize

サーバーを初期化し、サーバーの機能を返します。

shutdown

サーバーをシャットダウンします。

resources/list

利用可能なリソースを一覧表示します。

resources/read

指定されたリソースを読み取ります。

tools/list

利用可能なツールを一覧表示します。

tools/call

指定されたツールを呼び出します。

DeviceState クラス

DeviceStateクラスはデバイスの状態をシミュレートし、デバイス情報、センサーデータ、ネットワークステータスを取得するためのメソッドを提供します。また、Raspberry Pi Picoへの接続を処理し、CO2レベルを読み取ります。

方法

  • getDeviceInfo() : デバイス情報を返します。

  • getSensorData() : センサー データを返します。

  • getNetworkStatus() : ネットワークステータスを返します (モック機能)。

  • publishToMQTT() : MQTT へのデータの公開をシミュレートします (モック機能)。

  • reconnectWiFi() : WiFi への再接続をシミュレートします (モック機能)。

  • reconnectMQTT() : MQTT への再接続をシミュレートします (モック機能)。

ログ記録

アプリケーションは、CO2 レベルやその他の情報をユーザーのホーム ディレクトリにあるログ ファイル ( co2_level.log ) に記録します。

ライセンス

このプロジェクトは MIT ライセンスに基づいてライセンスされています。

F
license - not found
Not graded
quality - not tested
D
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    A beginner-friendly MCP-inspired JSON-RPC server built with Node.js, offering basic client-server interaction through an 'initialize' capabilities handshake and an 'echo' function.
    3
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A powerful and flexible Node.js Express server that provides a comprehensive interface to the CoinGecko cryptocurrency data API. This server supports both the free public API and the Pro API with automatic fallback.
    6
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A Node.js Express server that provides access to CoinGecko's cryptocurrency data through a comprehensive API interface, supporting both free and Pro APIs with automatic fallback functionality.
    1
    MIT

View all related MCP servers

Related MCP Connectors

  • Hive MCP server implementing the EIP-712 over USB/DMK ledger-bridge integration spec…

  • MCP server for understanding Javascript internals from ECMAScript specification.

  • A TypeScript MCP server for Home Assistant, enabling programmatic management of entities, automati…

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/cyberomusubi/MCP-Server-for-sensor-device'

If you have feedback or need assistance with the MCP directory API, please join our Discord server