Performance ROS in Simulink
古いコメントを表示
Hello. I launched the "robotROSGetStartedExample.slx" model. I set the simulation time to 20 seconds. On my computer, this very simple model runs for about 6 seconds of real time. To increase the speed, I decided to write an analog of the Publisher block (in the form of an S-function). In its code, in the mdlStart function, I call ros::init. When running the model with the S-function, Matlab returns an error of the "segmentation violation detected" type. Does anyone have any ideas? I use Matlab R2018b, Ubuntu 18.04, ROS Melodic.
2 件のコメント
Abhijeet Gadkari
2020 年 10 月 26 日
編集済み: Abhijeet Gadkari
2020 年 10 月 26 日
Hello Mikhail,
There are multiple reasons this may not work.
- Environment setup required to invoke ROS from S-funciton
- Unmet dependencies of S-function on ROS Melodic installation
- Data-conversion between S-function and ROS C++ messages
Try C++ code-generation instead if you want "real-time" execution of the algorithm.
- Abhijeet
Mikhail
2020 年 10 月 27 日
回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Publishers and Subscribers についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!