Real time, Matlab, SpeedGoat, Simulink, read write data, Solution?
21 次查看(过去 30 天)
显示 更早的评论
Hi,I'm using Simulink connected to speedgoat in a real time status. The simulink model includes a user defined block in which along with the main code, there are commands open, close fprintf, fscanf, in order to write/read some numerical data. The model is built correctly, but when the start application button is clicked the following error pops up "external mode open protocol start command failed". So, is there any other way by which we can enjoy write and read data while connected to speedgoat online. Mathwork expers, do you know how to solve this issue?
采纳的回答
Fangjun Jiang
2022-7-14
编辑:Fangjun Jiang
2022-7-14
To store runtime data like "A" in your example, use "Data Store Memory" block in your Simulink model. Use "Data Store Read" and "Data Store Write" block to read and write the data.
To log data for offline use, use "To Workspace" block or utilize signal logging.
7 个评论
Fangjun Jiang
2022-7-14
Data Store Memory block does not support variable size signal. See doc
You could declare the maximum size and fill the un-used with zeros.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Troubleshooting in Simulink Real-Time 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!