{"id":26556723,"url":"https://github.com/yudaikitamura/mcpx","last_synced_at":"2026-02-01T12:01:00.646Z","repository":{"id":283127480,"uuid":"950620380","full_name":"YudaiKitamura/McpX","owner":"YudaiKitamura","description":"McpX is a library for communicating with Mitsubishi Electric PLCs using the MC protocol. It features a simple and easy-to-use API, allowing you to communicate without worrying about MC protocol details. It runs on various platforms, including Linux, Windows, and macOS.","archived":false,"fork":false,"pushed_at":"2025-12-20T04:25:16.000Z","size":6725,"stargazers_count":34,"open_issues_count":2,"forks_count":6,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-12-22T12:49:02.685Z","etag":null,"topics":["csharp","dotnet","mcprotocol","melsec","melsec-communication-protocol","mitsubishi","mxcomponent","plc","slmp","visualbasic"],"latest_commit_sha":null,"homepage":"https://yudaikitamura.github.io/McpX/","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/YudaiKitamura.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"YudaiKitamura"}},"created_at":"2025-03-18T12:48:12.000Z","updated_at":"2025-12-21T16:33:28.000Z","dependencies_parsed_at":null,"dependency_job_id":"a5d50498-9de8-4496-bff1-8c8ae9b3674b","html_url":"https://github.com/YudaiKitamura/McpX","commit_stats":null,"previous_names":["yudaikitamura/mcpx"],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/YudaiKitamura/McpX","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YudaiKitamura%2FMcpX","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YudaiKitamura%2FMcpX/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YudaiKitamura%2FMcpX/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YudaiKitamura%2FMcpX/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/YudaiKitamura","download_url":"https://codeload.github.com/YudaiKitamura/McpX/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YudaiKitamura%2FMcpX/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28977644,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-01T11:31:13.034Z","status":"ssl_error","status_checked_at":"2026-02-01T11:30:25.558Z","response_time":56,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csharp","dotnet","mcprotocol","melsec","melsec-communication-protocol","mitsubishi","mxcomponent","plc","slmp","visualbasic"],"created_at":"2025-03-22T11:25:17.110Z","updated_at":"2026-02-01T12:01:00.641Z","avatar_url":"https://github.com/YudaiKitamura.png","language":"C#","funding_links":["https://github.com/sponsors/YudaiKitamura"],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"docfx/images/mcpx_ogp.png\" alt=\"logo\" /\u003e\n\u003cbr\u003e\n\u003cp\u003e\n  \u003cimg alt=\"Downloads\" src=\"https://img.shields.io/nuget/dt/McpX\" /\u003e\n  \u003cimg alt=\"Version\" src=\"https://img.shields.io/badge/version-0.6.0-blue\" /\u003e\n  \u003cimg alt=\".NET 7.0+\" src=\"https://img.shields.io/badge/.NET-7.0+-blueviolet\" /\u003e\n  \u003cimg alt=\".NET 8.0+\" src=\"https://img.shields.io/badge/.NET-8.0+-purple\" /\u003e\n  \u003cimg alt=\".NET 9.0+\" src=\"https://img.shields.io/badge/.NET-9.0+-indigo\" /\u003e\n  \u003cimg alt=\".NET Core 2.0+\" src=\"https://img.shields.io/badge/.NET_Core-2.0+-darkgreen\" /\u003e\n  \u003cimg alt=\".NET Framework 4.6.1+\" src=\"https://img.shields.io/badge/.NET_Framework-4.6.1+-teal?logo=windows\" /\u003e\n  \u003cimg alt=\"License\" src=\"https://img.shields.io/badge/license-MIT-brightgreen.svg\" /\u003e\n  \u003ca href=\"https://flatt.tech/oss/gmo/trampoline\" target=\"_blank\"\u003e\u003cimg src=\"https://flatt.tech/assets/images/badges/gmo-oss.svg\" height=\"24px\"/\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp\u003e\n  \u003ca href=\"README_JA.md\"\u003e日本語\u003c/a\u003e | \u003ca href=\"README.md\"\u003eEnglish\u003c/a\u003e\n\u003c/p\u003e\n\n**McpX is a library for communicating with Mitsubishi Electric PLCs using the MC protocol.**  \nIt features a simple and easy-to-use API, allowing you to communicate without worrying about MC protocol details.  \nIt runs on various platforms, including Linux, Windows, and macOS.\n\n## Installation\n### .NET CLI\n```sh\ndotnet add package McpX\n```\n### Package Manager(Visual Studio)\n```sh\nPM\u003e NuGet\\Install-Package McpX\n```\n\n## Example Usage \n```csharp\nusing McpXLib;\nusing McpXLib.Enums;\n\n// Connect to PLC by specifying IP and port\nusing (var mcpx = new McpX(\"192.168.12.88\", 10000))\n{\n    // Read 7000 points starting from M0\n    bool[] mArr = mcpx.BatchRead\u003cbool\u003e(Prefix.M, \"0\", 7000);\n    \n    // Read 7000 words starting from D1000\n    short[] dArr = mcpx.BatchRead\u003cshort\u003e(Prefix.D, \"1000\", 7000);\n\n    // Write 1234 to D0 and 5678 to D1 as signed 32-bit integers\n    mcpx.BatchWrite\u003cint\u003e(Prefix.D, \"0\", [1234, 5678]);\n}\n```\n[C# and Visual Basic samples are available here.](https://github.com/YudaiKitamura/McpX/tree/main/Example)\n\n## Supported Commands\n\n| Name                         | Description                                                            | Synchronous Method                                      | Asynchronous Method                                              |\n|------------------------------|------------------------------------------------------------------------|---------------------------------------------------------|------------------------------------------------------------------|\n| **Single Read**              | Reads a single value from the specified device.                        | `Read\u003cT\u003e(Prefix prefix, string address)`                | `ReadAsync\u003cT\u003e(Prefix prefix, string address)`                   |\n| **Single Write**             | Writes a single value to the specified device.                         | `Write\u003cT\u003e(Prefix prefix, string address, T value)`     | `WriteAsync\u003cT\u003e(Prefix prefix, string address, T value)`         |\n| **Batch Read**               | Reads multiple consecutive values starting from the specified address. | `BatchRead\u003cT\u003e(Prefix prefix, string address, ushort length)` | `BatchReadAsync\u003cT\u003e(Prefix prefix, string address, ushort length)` |\n| **Batch Write**              | Writes an array of values to consecutive device addresses.             | `BatchWrite\u003cT\u003e(Prefix prefix, string address, T[] values)`   | `BatchWriteAsync\u003cT\u003e(Prefix prefix, string address, T[] values)` |\n| **Random Read**              | Reads values from non-consecutive word and double-word addresses.     | `RandomRead\u003cT1, T2\u003e((Prefix, string)[] wordAddresses, (Prefix, string)[] doubleWordAddresses)` | `RandomReadAsync\u003cT1, T2\u003e((Prefix, string)[] wordAddresses, (Prefix, string)[] doubleWordAddresses)` |\n| **Random Write**             | Writes values to non-consecutive word and double-word addresses.      | `RandomWrite\u003cT1, T2\u003e(...)`                              | `RandomWriteAsync\u003cT1, T2\u003e(...)`                                 |\n| **Monitor Registration**     | Registers devices to monitor.                                          | `MonitorRegist((Prefix, string)[] wordAddresses, (Prefix, string)[] doubleWordAddresses)` | `MonitorRegistAsync((Prefix, string)[] wordAddresses, (Prefix, string)[] doubleWordAddresses)` |\n| **Monitor Read**             | Reads the latest values from registered monitoring devices.            | `Monitor\u003cT1, T2\u003e(...)`                                  | `MonitorAsync\u003cT1, T2\u003e(...)`                                     |\n| **Remote Password Lock/Unlock** | Automatically locks the PLC with the specified remote password when the instance is created and unlocks it when disposed. | `McpX(string ip, int port, string? password = null)`   | –                                                                |\n\n## Supported Protocols\n- TCP\n- UDP\n- 3E frame (binary code)\n- 3E frame (ASCII code)\n- 4E frame (binary code)\n- 4E frame (ASCII code)\n\n## Roadmap\n- [x] ~~3E frame (ASCII code) support~~\n- [x] ~~4E frame (binary code) support~~\n- [x] ~~4E frame (ASCII code) support~~\n- [x] ~~UDP support~~\n\n## Changelog\n- [CHANGELOG.md](./CHANGELOG.md)\n\n## Related\n- [mcpx-mcp-server](https://github.com/YudaiKitamura/mcpx-mcp-server) An MCP(Model Context Protocol) server that enables real-time access to Mitsubishi Electric PLC devices from generative AI.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyudaikitamura%2Fmcpx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyudaikitamura%2Fmcpx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyudaikitamura%2Fmcpx/lists"}