Customize the android App created by simulink

7 visualizaciones (últimos 30 días)
Alireza Ghaderi
Alireza Ghaderi el 13 de Mayo de 2020
Comentada: Alireza Ghaderi el 17 de Jul. de 2020
After using Simulink support package for android, I wonder if there is a away to customize the view of this application...
or adding more advanced stuffs such as flight instruments to the app...
Is it possible?

Respuestas (1)

Sutanu Maiti
Sutanu Maiti el 22 de Mayo de 2020
Yes, once generated app code is exported to Android Studio, user can modify the UI (in Android Studio) and run on device (from Android Studio). It will run the Simulink generated Algorithm also under the hood.
ToApp Block and From App Block can be used to access Simulink model data to and from Android App's main activity's java function. User needs to mention the function name (what they write in Java after exporting to Android Studio) in the block mask. Simulink model generated C code then calls those Java functions to give / take data. There are examples Set Position of Bebop Drone on Gazebo Simulator from Android Device Using ROS, And Visualize Sensor Data from Android Device in RViz that uses this workflow to integrate custom java code with 3rd party library along with Simulink model generated code.
  1 comentario
Alireza Ghaderi
Alireza Ghaderi el 17 de Jul. de 2020
Hello Sir
I tried to follow the steps in the link you gave with the latest version of android studio and matlab.
But when i deploy the app to phone, it crashes and wont start... Is there a better guide for this?
and one more question..in the java sources I only found the interface files and views... Where are the computation and processes code...arent they used when java code generation happens?

Iniciar sesión para comentar.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by