How to embedding a matlab exe file in android studio? or an alternative to android studio.

조회 수: 3 (최근 30일)
I have a matlab code that I want to generate an exe file out of ,then embedd it into my android studio application, however I have read that embedding a matlab exe file into android studio is not possibe is that true? and if it is what can I do ? what other IDEA software can I use in which I am able to embed a matlab exe file in. Or is there a way i can convert my matlab code into some other language that android studio would be able to interpret.
Please don't hesitate with any suggestion or idea or observation you have.
Thank you in advance.
  댓글 수: 4
Rik
Rik 2020년 10월 23일
The only two solutions I can find are below: either use Coder to generate code that can be compiled for Android, or use Simulink to patch together an app.
Walter Roberson
Walter Roberson 2020년 10월 23일
There is no present solution for embedding MATLAB graphics on Android.
The closest you can get is to use Computer Vision Toolbox to draw lines and words into an image and present the image.
We could perhaps be more specific about possibilities if you talked about what functionality the application would have to have.

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

답변 (2개)

Walter Roberson
Walter Roberson 2020년 10월 21일
편집: Walter Roberson 2020년 10월 21일
It is true.
.exe are in machine language for Intel or AMD x64 systems, but Android phones nearly all use ARM architecture. Also, Android was derived from Linux not Windows.
You can use MATLAB Coder to generate C or C++ code for a subset of MATLAB. The subset does not support graphics.

Sutanu Maiti
Sutanu Maiti 2020년 10월 22일
You can achieve this by using Simulink support package for Android Devices.
There is also an example Detect Boundaries of Objects Within Video Using MATLAB Function Block on Android Device that describes how to write MATLAB code that generates code and deploys on Android device.
Once generated app code is exported to Android Studio, you can modify the Java/xml code (in Android Studio) and run on device (from Android Studio). It will run the Simulink generated Algorithm also under the hood.
  댓글 수: 1
Walter Roberson
Walter Roberson 2020년 10월 22일
Android does not use exe files and the user specifically wants to use exe files for the first part of the question.
For the second part of the question, Simulink models cannot really run MATLAB code: they need a restricted and augmented MATLAB-like language. Sometimes the conversion is easy, sometimes it is difficult. Graphics in particular are quite different.

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

카테고리

Help CenterFile Exchange에서 Modeling에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by