{"id":25965,"library":"mticp-npm","title":"MTICP Node.js Wrapper","description":"Node.js wrapper for the mticp transpiler, a command-line tool for converting MTI Skipper Sheet projects (.skip) into IEC 61131-3 compatible formats including Structured Text (ST), Ladder Logic (LD), and XML. Version 1.0.13 is the latest stable release, published in March 2026. It wraps a precompiled C# executable and provides cross-platform support for Node.js >=14. This package is specialized for industrial PLC programming workflows, particularly for Montgomery Technology, Inc. devices, differentiating from general-purpose transpilers by focusing on the proprietary Skipper Sheet format.","status":"active","version":"1.0.13","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","IEC","Structured Text","Ladder Logic","LD","ST","PLC","MTI"],"install":[{"cmd":"npm install mticp-npm","lang":"bash","label":"npm"},{"cmd":"yarn add mticp-npm","lang":"bash","label":"yarn"},{"cmd":"pnpm add mticp-npm","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Package does not provide ESM exports; CommonJS require is required. No default export.","wrong":"import { runMticp } from 'mticp-npm';","symbol":"runMticp","correct":"const { runMticp } = require('mticp-npm');"}],"quickstart":{"code":"const { runMticp } = require('mticp-npm');\n\nasync function convertSkip() {\n  try {\n    const output = await runMticp([\n      'action=toiec',\n      'src=./project.skip',\n      'dst=./output/'\n    ]);\n    console.log('Conversion successful:', output);\n  } catch (err) {\n    console.error('Conversion failed:', err);\n  }\n}\n\nconvertSkip();","lang":"javascript","description":"Shows how to call runMticp with async/await to convert a Skipper Sheet file to IEC Structured Text."},"warnings":[{"fix":"Use const { runMticp } = require('mticp-npm'); instead of import { runMticp } from 'mticp-npm';","message":"Package does not support ES modules (ESM). Use require() instead of import.","severity":"gotcha","affected_versions":">=1.0"},{"fix":"Ensure each argument is a string in the format 'key=value'.","message":"All arguments must be provided as strings in the array. Incorrect types or malformed arguments may cause the binary to fail silently.","severity":"gotcha","affected_versions":">=1.0"},{"fix":"Update to version 1.0.12 or later via npm install mticp-npm@latest.","message":"Versions 1.0.11 and earlier had issues with compiling Skipper Sheets with multiple PLCs. Upgrade to 1.0.12+.","severity":"breaking","affected_versions":"<1.0.12"},{"fix":"Reinstall the package to ensure platform-specific binaries are downloaded.","message":"The wrapper expects the binary to be present in bin/ directory. If binaries are missing, the call will fail.","severity":"gotcha","affected_versions":">=1.0"},{"fix":"Ensure the device IP is correctly specified in 'dst' for 'sendxml' action.","message":"The 'sendxml' action may require network access and specific device configuration; it is not a simple file conversion.","severity":"deprecated","affected_versions":">=1.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run 'npm install mticp-npm' in your project directory.","cause":"Package not installed or not found in node_modules.","error":"Error: Cannot find module 'mticp-npm'"},{"fix":"Use 'const { runMticp } = require('mticp-npm');' instead of 'import { runMticp } from 'mticp-npm';'","cause":"Incorrect import style; using ESM import syntax instead of CommonJS require.","error":"TypeError: runMticp is not a function"},{"fix":"Reinstall the package: 'npm install mticp-npm'. If using a custom install, ensure binaries are present.","cause":"The mticp binary is not found in the expected bin/ directory.","error":"mticp error: Error: spawn mticp ENOENT"},{"fix":"Check that each argument is a string like 'action=toiec' and required keys (action, src, dst) are provided.","cause":"Arguments array contains malformed or missing key-value pairs.","error":"UnhandledPromiseRejection: Error: Invalid arguments"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}