- execute
main()
and choose "Simulation" as environment
- See also CPM documentation
- MATLAB
- Build a
Config
object (e.g.,config
) withconfig.environment = Environment.CpmLab
- Run
main(config, vehicle_ids = [<<active vehicle ids>>])
- Build a
- Lab Control Center
- Set middleware period
- Deploy without script name and with deactivated distributed deployment
- Wait for middleware to show up (note: sometimes not all NUCs register; experiment might work anyways)
- Start timer
- Note: No HLC will show up as online, since we kill the process responsible for the heartbeat on the NUCs
Matlab Parallel Computation Toolbox doesn't support debugging. However, you can select the config by executing main.m and activate parallel computation in the UI. The scenario will be written to the disk. Afterwards, you can open a Matlab for every vehicle and execute main_distributed(i_vehicle)
within each.
- If you encounter problems like
"MATLAB has experienced a low-level graphics error, and may not have drawn correctly."
, close Matlab and restart again by usingmatlab -softwareopengl
. - If you run into problems with the standard c++ library libstdc++ try one of the ways described here: https://de.mathworks.com/matlabcentral/answers/329796-issue-with-libstdc-so-6 . "1. Renaming the libstdc++.so.6 library file so that MATLAB cannot find it and is forced to use the system's version of the library." worked for me.
- NUCs do not run as expected?
- Sometimes lab software is missing on the NUCs. Make sure that the software is built on the main PC. Then execute
bash autostart/lab_update.bash
in the home directory of the NUC to pull the software to the NUC. Cancel when loop is running. - Tip: Monitor execution from NUC 1 (
tail -F dev/lcc_script_logs/tmux_script.txt
)
- Sometimes lab software is missing on the NUCs. Make sure that the software is built on the main PC. Then execute