Difference between revisions of "How Do I Configure the Matlab Interface?"

From BESA® Wiki
Redirect page
Jump to: navigation, search
(Redirected page to MATLAB Interface#Configuration)
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
#REDIRECT [[MATLAB_Interface#Configuration]]
 +
 
{{BESAInfobox
 
{{BESAInfobox
 
|title = Module information
 
|title = Module information
 
|module = BESA Research Basic or higher
 
|module = BESA Research Basic or higher
|version = 5.2 or higher
+
|version = BESA Research 5.2 or higher
 
}}
 
}}
  
Line 48: Line 50:
 
(Only required after a change of your MATLAB configuration after installation of BESA Research)
 
(Only required after a change of your MATLAB configuration after installation of BESA Research)
  
During the installation process of BESA Research, the program <span style="color:#ff9c00;">ConfigureBesaMatlabInterface.exe</span> (or SetupBesaMatlabInterface.exe) in the BESA Research root folder (C:\Program Files (x86)\BESA\Research_7_0) was executed.
+
During the installation process of BESA Research, the program <span style="color:#ff9c00;">ConfigureBesaMatlabInterface.exe</span> (or SetupBesaMatlabInterface.exe) in the BESA Research root folder (e.g.: '''C:\Program Files (x86)\BESA\Research_7_0''') was executed.
  
 
Run this program '''as administrator''' again when your MATLAB configuration has changed, e.g. after updating your MATLAB version. In the dropdown list, select the MATLAB version that you are using.
 
Run this program '''as administrator''' again when your MATLAB configuration has changed, e.g. after updating your MATLAB version. In the dropdown list, select the MATLAB version that you are using.
Line 54: Line 56:
 
This program performs two operations:
 
This program performs two operations:
 
* It copies the appropriate interface dll file to the BESA Research root folder and renames it to "<span style="color:#ff9c00;">BesaMatlab.dll</span>" (32-bit version) or "<span style="color:#ff9c00;">BesaMatlab64.dll</span>" (64-bit version), and
 
* It copies the appropriate interface dll file to the BESA Research root folder and renames it to "<span style="color:#ff9c00;">BesaMatlab.dll</span>" (32-bit version) or "<span style="color:#ff9c00;">BesaMatlab64.dll</span>" (64-bit version), and
* If you are using a 64-bit version, it creates an entry in <span style="color:#ff9c00;">BESA.ini</span> (C:\Users\Public\Documents\BESA\Research_7_0) as follows:
+
* If you are using a 64-bit version, it creates an entry in [[The Initialization File: BESA.ini|BESA.ini]] (e.g.: '''C:\Users\Public\Documents\BESA\Research_7_0''') as follows:
  
 
<source lang="dos">
 
<source lang="dos">
Line 65: Line 67:
 
[[File:BesaMatlab64Interfaces_01.png|200px]]
 
[[File:BesaMatlab64Interfaces_01.png|200px]]
  
If the installed MATLAB is 64-bit version, please run the program <span style="color:#ff9c00;">BesaMatlab64Interface.exe</span> in the BESA Research root folder (C:\Program Files (x86)\BESA\Research_7_0). If the MATLAB path is set properly, a program window as the screenshot below is shown up without an error message. After that please just close the window.
+
'''Note: This step is not needed from BESA Research 7.1 March 2021.'''
  
[[File:BesaMatlab64Interfaces_02.png|400px]]
+
If the installed MATLAB is 64-bit version, please run the program <span style="color:#ff9c00;">BesaMatlab64Interface.exe</span> in the BESA Research root folder (e.g.: '''C:\Program Files (x86)\BESA\Research_7_0'''). If the MATLAB path is set properly, a program window as the screenshot below is shown up without an error message. After that please just close the window.
  
 +
[[File:BesaMatlab64Interfaces_02.png|400px]]
  
 
== Updating the MATLAB Interface after MATLAB Upgrade ==
 
== Updating the MATLAB Interface after MATLAB Upgrade ==
Line 76: Line 79:
 
# Make sure that in the "'''Path'''" environment variable only the path to one MATLAB version exists.
 
# Make sure that in the "'''Path'''" environment variable only the path to one MATLAB version exists.
 
# Make sure that the correct MATLAB interface dll (<span style="color:#ff9c00;">BesaMatlab.dll</span> (32-bit version) or <span style="color:#ff9c00;">BesaMatlab64.dll</span> (64-bit version)) is installed by starting the tool <span style="color:#ff9c00;">ConfigureBesaMatlabInterface.exe</span> (or SetupBesaMatlabInterface.exe) and selecting the corresponding MATLAB version and architecture.
 
# Make sure that the correct MATLAB interface dll (<span style="color:#ff9c00;">BesaMatlab.dll</span> (32-bit version) or <span style="color:#ff9c00;">BesaMatlab64.dll</span> (64-bit version)) is installed by starting the tool <span style="color:#ff9c00;">ConfigureBesaMatlabInterface.exe</span> (or SetupBesaMatlabInterface.exe) and selecting the corresponding MATLAB version and architecture.
# Run '''CMD (Command Prompt) as administrator''', and then execute the following command <source lang="dos">matlab -regserver</source> (registers MATLAB as a Component Object Model (COM) server).
+
# Run '''CMD (Command Prompt) as administrator''', and then execute the following command <source lang="dos">matlab -regserver</source> ([https://www.mathworks.com/help/matlab/matlab_external/register-matlab-as-automation-server.html registers MATLAB as a Component Object Model (COM) server]).
 
#* Close the CMD window (there should be no error message).
 
#* Close the CMD window (there should be no error message).
 
#* Sometimes if the MATLAB license is connected to a specific user account and the user account does not have administrator rights, it could be problematic to execute that command. In that case, change the corresponding account to an administrator account and then perform the actions again. After that the account could be made to regular user account again.
 
#* Sometimes if the MATLAB license is connected to a specific user account and the user account does not have administrator rights, it could be problematic to execute that command. In that case, change the corresponding account to an administrator account and then perform the actions again. After that the account could be made to regular user account again.
# Run '''CMD (Command Prompt) as NOT administrator''', and then execute the following command <source lang="dos">matlab -automation</source> (Start MATLAB as a Component Object Model (COM) Automation server. MATLAB does not display the splash screen).
+
# Run '''CMD (Command Prompt) as NOT administrator''', and then execute the following command <source lang="dos">matlab -automation</source> ([https://www.mathworks.com/help/matlab/matlab_external/creating-the-server-manually.html Manually create automation server]: start MATLAB as a Component Object Model (COM) Automation server. MATLAB does not display the splash screen).
 
#* Close the CMD and MATLAB Command Window (there should be no error message).
 
#* Close the CMD and MATLAB Command Window (there should be no error message).
  

Latest revision as of 15:40, 6 May 2021