Attention
These docs are a bit ambitious. The steps described are accurate but IronPLC cannot yet run programs.
Troubleshooting¶
This guide helps you resolve common issues with the IronPLC extension.
Compiler Not Found (E0001)¶
Symptom: Error message “E0001 - Unable to locate IronPLC compiler”
The extension cannot find the ironplcc executable. The extension searches
these locations in order:
Configuration: The path specified in
ironplc.pathsettingEnvironment variable: The
IRONPLCenvironment variableHomebrew (macOS only):
/opt/homebrew/bin/ironplccWindows AppData:
%LOCALAPPDATA%\Programs\IronPLC Compiler\bin\ironplcc.exe
Solutions:
Verify installation: Open a terminal and run
ironplcc --version. If this fails, the compiler is not installed or not in your PATH.Install the compiler: See the Installation guide.
Configure the path manually: If the compiler is installed in a non-standard location, set the
ironplc.pathsetting to the full path of the executable.Check permissions: Ensure the compiler executable has execute permissions.
No Syntax Highlighting¶
Symptom: Structured Text files appear as plain text without colors.
Solutions:
Check file extension: Ensure your file has a
.stor.iecextension.Check language mode: Look at the bottom-right corner of VS Code. It should show “IEC 61131-3” or “Structured Text”. Click it to change the language mode if needed.
Reload the window: Run “Developer: Reload Window” from the Command Palette.
No Diagnostics Appearing¶
Symptom: The extension does not show any errors or warnings, even for invalid code.
Solutions:
Check the compiler is running: Look at the Output panel (View > Output) and select “IronPLC” from the dropdown. You should see startup messages.
Check for E0001: If the compiler was not found, diagnostics will not work. See the “Compiler Not Found” section above.
Enable debug logging: Set
ironplc.logLeveltoDEBUGand check the Output panel for error messages.Check file type: Diagnostics only work for Structured Text files (
.st,.iec), not PLCopen XML files currently.
Extension Not Activating¶
Symptom: The extension appears installed but nothing happens when opening ST files.
Solutions:
Check extension status: Open the Extensions view and find IronPLC. Ensure it shows as enabled, not disabled.
Check for conflicts: Disable other IEC 61131-3 or PLC extensions that might conflict.
View extension logs: Open Help > Toggle Developer Tools, go to the Console tab, and look for messages containing “ironplc”.
Reinstall the extension: Uninstall the extension, reload VS Code, then reinstall it.
Collecting Debug Information¶
When reporting issues, please collect the following information:
Version information:
VS Code version (Help > About)
IronPLC extension version (Extensions view)
Compiler version (run
ironplcc --version)Operating system and version
Enable detailed logging:
{ "ironplc.logLevel": "TRACE", "ironplc.logFile": "/tmp/ironplc-debug.log" }
Reproduce the issue with logging enabled.
Collect logs:
The log file specified above
Output panel content (View > Output > IronPLC)
Developer Tools console (Help > Toggle Developer Tools)
Create an issue on GitHub with:
Steps to reproduce the problem
Expected vs. actual behavior
Version information
Relevant log excerpts
Performance Issues¶
Symptom: The editor is slow or unresponsive when editing ST files.
Solutions:
Check file size: Very large files may cause slowdowns. Consider splitting large programs into multiple files.
Reduce log level: If you have verbose logging enabled, set
ironplc.logLevelback toERROR.Disable file logging: Remove any
ironplc.logFilesetting.Check for loops: The compiler may take longer on code with complex nested structures. Simplify where possible.
Resetting the Extension¶
If all else fails, try a clean reset:
Uninstall the IronPLC extension
Delete the extension’s global storage:
Windows:
%USERPROFILE%\.vscode\extensions\ironplc.*macOS/Linux:
~/.vscode/extensions/ironplc.*
Reload VS Code
Reinstall the extension from the marketplace