Start the CarMaker for Simulink session
cm_session_startBrings up a CarMaker for Simulink session when missing: starts MATLAB, opens the Simulink model and CarMaker GUI, and reports ready status or what it is waiting for.
Instructions
Bring up a CarMaker for Simulink session as far as it is missing: start MATLAB (visible, in the project's src_cm4sl folder, engine shared), run cmenv, open the Simulink model and open the CarMaker GUI. Nothing is restarted or closed. Returns ready=true, or ready=false with what it is waiting for: call again until ready. Without a model it opens none and lists models_loaded and models_found to choose from. Many projects need their own setup script before the model compiles: if init_scripts_found lists one, pass it as init.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "cm_session_start"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| init | No | The project's own MATLAB setup script, run once per MATLAB session before the model is opened (default: CM_MATLAB_INIT). A name from init_scripts_found, or a full path | |
| model | No | Simulink model to open: a name on the MATLAB path, a path as listed in models_found, or a full path (default: CM_MODEL) | |
| max_wait_s | No | Longest time to wait in s, at most 50 (larger values are cut to 50); call again if not finished |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||