Simulink external mode works fine but normal mode doesn't, when controlling a motor
조회 수: 3 (최근 30일)
이전 댓글 표시
Hello everyone! So I'm using Simulink to write a model that is run on Beaglebone Black (BBB) using the Embedded Code Support Package for Beaglebone Black Hardware (v.19.1.1) so that I can control a motor.
I want to run the model executable (.elf file) on boot of the BBB, so that I don't need to have it connected to a PC. For this, it needs to be built on normal mode, because it will run independently from the PC, so everything will be on the board (please someone correct me if I'm wrong!).
When connected to a PC, I can deploy and run the code on the hardware on external mode just fine, however, when I run in normal mode, there is a lot of instability. This instability is also present if I simply run the model exectuable directly on the BBB by ssh with PuTTy.
So my question is: why is there a difference between normal and external mode, namely, external mode works fine and normal mode doesn't? From other threads I've seen, it's usually the other way around, so I haven't been able to find anyone with this problem.
Please tell me which files you would like to see, in case there are any. Thank you!
댓글 수: 0
답변 (1개)
Abhilash Padma
2019년 7월 30일
Here you are feeding data to the model which is running on Beaglebone Black. External mode works better than normal mode because External mode creates a communication service on the host computer and hardware board. The two services establish a communication channel between the Simulink engine and generated code deployed on the hardware board. In normal mode, the algorithm runs in Simulink and the I/O drivers run in a separate Windows kernel mode process that maintains the real-time clock.
Refer the following links for more information:
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!