Expand description
plceye - PLC Code Smell Detector
Open source static analyzer for PLC files that detects code smells and potential issues in PLC programs.
§Supported Formats
- L5X - Rockwell Automation Studio 5000
- PLCopen XML - IEC 61131-3 standard exchange format
§Supported Smells
- unused_tags - Tags defined but never used
- undefined_tags - Tags referenced but not defined
- empty_routines - Routines with no logic
§CLI Usage
# Analyze a file
plceye project.L5X
# With custom config
plceye --config plceye.toml project.L5XRe-exports§
pub use analysis::ProjectAnalysis;pub use analysis::ParseStats;pub use analysis::analyze_controller;pub use analysis::PlcopenAnalysis;pub use analysis::PlcopenStats;pub use analysis::analyze_plcopen_project;pub use l5x;pub use plcopen;
Modules§
- analysis
- Project analysis module.
Structs§
- Empty
Routines Config - Configuration for empty routine detection.
- General
Config - General configuration settings.
- Loaded
Project - A loaded project with its format-specific data.
- Report
- Report containing all detected smells.
- Smell
- A single detected code smell.
- Smell
Config - Main configuration for the smell detector.
- Smell
Detector - Main smell detector that runs all enabled detectors.
- Undefined
Tags Config - Configuration for undefined tag detection.
- Unused
Tags Config - Configuration for unused tag detection.
Enums§
- Config
Error Kind - Kinds of configuration errors.
- Error
- Error types for the smell detector.
- File
Format - Detected file format.
- L5xParse
Error Kind - Kinds of L5X parse errors.
- Severity
- Severity level of a detected smell.
- Smell
Kind - Kind of code smell detected.
Type Aliases§
- Result
- Result type alias for smell operations.