Hi I need to send data continuously from matlab workspace to simulink, I am reading a mobile sensor and need the readings to be instantly sent to simulink , so the readings are the inputs to simulate a hardware model connected with matlab through arduino.

 채택된 답변

Walter Roberson
Walter Roberson 2017년 1월 23일

0 개 추천

You will always have a latency and maximum throughput in receiving signals and making them available to Simulink.
I am not clear as to why you are not using the Simulink Android sensor blocks ?

댓글 수: 6

Noor Zeid
Noor Zeid 2017년 1월 23일
편집: Walter Roberson 2017년 1월 24일
thank you so much for answering, I have trouble in downloading the simulink support package to android, and I need the orientation sensor measurement which I don't think there is a block for it in the toolbox.
to be clear about what I am asking for, https://www.youtube.com/watch?v=bfbWrSec16k&list=LL2D_8DMrBhYJWhy2RqtPV8A&index=11 I have followed this video procedure but instead of using flight gear I am simulating my own model and I did it successfully, but when I am replacing my model with a hardware model which is connected to matlab by arduino using external mode, an error appeared from the evalin command saying that evalin function are not suitable with code generation!
so I have replaced the function block with three constants and I need a way to keep these constant values changing continuously ! I have tried set_param but it is too slow.
Would the gyroscope block be acceptable for orientation?
Are you able to install the support package on your PC? But then you have trouble getting the support package to communicate with the Android? Have you turned on USB debugging on the android? https://www.mathworks.com/examples/simulink/mw/android_product-androidusageexample-working-with-android-8482-devices-block-library#4
Hi I have installed the support package and turned on the USB debugging but the matlab is not detecting my device( samsung galaxy s6 edge)! any suggestion please? the hardware pane only shows the s4 and tab 2 options thanks
Which MATLAB release are you using? The hardware support package only supported the S4 and Tab 2 in the original release, but it was enhanced to all Galaxy and Nexus devices a couple of releases ago.
I am using matlab 2015b release
Ah, the upgrade to support all Galaxy was in R2016a; https://www.mathworks.com/help/supportpkg/android/release-notes.html
You could try installing from the "Get Support Package" link at https://www.mathworks.com/hardware-support/android-programming-simulink.html to see if you get the newer version.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Modeling에 대해 자세히 알아보기

질문:

2017년 1월 22일

댓글:

2017년 2월 16일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by