build_project
Compile a LASAL CLASS 2 project or download it to a PLC, with optional background jobs that return a jobId to poll for completion.
Instructions
Compile the CLASS 2 project or download it to the PLC. Compilation kills CLASS 2 IDE. Download pings the PLC first. Supports async: true — the call then returns immediately with a jobId and you MUST poll check_job_status until it reports status completed/failed (the result is delivered there).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| async | No | Run in the background: returns { status: 'pending', jobId } — poll with check_job_status. Default false. | |
| action | Yes | 'compile' builds the project; 'download' transfers it to the PLC. | |
| options | No | Compile mode (compile only). RebuildAll is safest; BuildChanges is faster for incremental work. | RebuildAll |
| lcp_path | No | Absolute path to the .lcp file. Omit to use the selected project. | |
| timeout_s | No | Timeout in seconds for compile or download. Omit for default (600s). | |
| connection | No | Connection string (e.g. 'TCPIP:192.168.1.100') or address-book name (download only). Omit to use the connection saved in the .lss file. | |
| add_loader_anyway | No | Force loader download even if the target OS already has a compatible loader (download only). Default: auto — the loader is sent for local LARS/loopback targets, skipped otherwise. Set false to disable, true to force. |