I'm working on an image processing project which employs rasberry pi. I have written the code in matlab using image processing toolbox and computer vision. Can i make a standalone executable application and dump it in the pi?

2 views (last 30 days)
Or can i convert this matlab code to any other language which is suited for rasberry pi(pyhton)???

Answers (2)

M.Khan
M.Khan on 7 Jan 2016
If your MATLAB code generates portable C code, you can create standalone executable on Raspberry Pi. Here are the steps:
  • Use MATLAB coder to generate portable C Code
  • Use packNGo to generate zip folder
  • Transfer the zip folder to your target hardware (Raspberry Pi)
  • Create makefile and build executable on Raspberry Pi
Here is the list of Image Processing Toolbox functions that explains whether the function generates portable C code: http://www.mathworks.com/help/images/list-of-supported-functions-with-usage-notes.html
Here is the list of Computer Vision System Toolbox functions that explains whether the function generates portable C code: http://www.mathworks.com/help/vision/ug/code-generation-support-usage-notes-and-limitations-for-functions-classes-and-system-objects.html
HTH,
Mohammad.
  2 Comments
Walter Roberson
Walter Roberson on 7 Jan 2016
Note: MATLAB Coder and MATLAB Compiler are available for Academic license and for Professional / Commercial license, but not for Student Version or Home license. MATLAB Coder is a fairly expensive product, about $US8000 for the Professional license.
However, if you go through the Simulink route, then all current licenses of MATLAB (including Student Version) that have Simulink can generate and deploy to the Raspberry Pi without requiring MATLAB Coder.
Martin Florek
Martin Florek on 12 Jul 2016
Hello M.Khan and all Excuse me, and someone has implemented the process but remained only in theory? I try to run demo "Code Generation for Face Tracking with PackNGo", but I had problems with paths. But this is another problem that I have removed. Now I want to know how to create a Makefile for Raspberry Pi, since the code generator create files which need dll and lib? Probably I need to have installed OpenCV on RPI, too. {.so (shared object) matlab/embedded coder does not support?}. I use Win PC. Thank you for your help, support, advice and time.

Sign in to comment.


Walter Roberson
Walter Roberson on 7 Jan 2016
Edited: Walter Roberson on 7 Jan 2016
The Raspberry Pi cannot run .exe produced by MATLAB Compiler.
If you tweak your code and package it into a Simulink MATLAB Function Block then it can potentially be deployed to the raspberry using the Simulink facilities.
  1 Comment
Apoorv Lokhande
Apoorv Lokhande on 30 Jun 2016
Hi Walter,
Can you provide any examples on how to package a code into MATLAB Function block. I am working on this Thingpeak Project and have developed a code for the same but I am not able to generate the car counter block in the model given.
May you please help me?
Thank you, Apoorv

Sign in to comment.

Categories

Find more on Computer Vision Toolbox in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!