From: Kate J. on 22 Jun 2010 17:05 Update: there is a very straightforward way to pass data between an m-file and a C-MEX s-function: Within my gui’s m-file code, I use assignin(‘base’, varName, handles.VarName) and evalin(‘base’,’VarName’) calls to pass variables to and get variables from the Matlab workspace. Within my C-MEX s-function code, I use calls to the mexGetVariable(“base”,”varName” ) and mexPutVariable(“base”,”varName”,varname_ptr) calls to get variables from and pass variables to the Matlab workspace.
|
Pages: 1 Prev: Best way to pass info to/from Matlab/GUIDE & Simulink? Next: Graphing |