[TRNSYS-users] Error with matlab calling

David BRADLEY d.bradley at tess-inc.com
Wed Nov 13 11:02:19 PST 2019


Salma,

  The most common cause of this problem is that the Type155.dll file 
located in your .\Trnsys18\Exe\ directory is not the one for the version 
of Matlab that you are using. Look in the ..\Trnsys18\Exe\DLLs\ 
directory and you'll find various *.zip files containing versions of 
Type155.dll for different versions of Matlab. If you find your Matlab 
version then replace the existing Type155.dll with the one from the 
*.zip file.

  There are a number of other possible causes of this error. It is hard 
to diagnose because a lot of times it has to do with the configuration 
of Matlab and TRNSYS and your computer. Here is the knowledge base that 
we have collected:

•    Avoid the use of the Matlab “clear all” statement. This statement 
has been found to delete all of the data that is being passed from 
TRNSYS to Matlab.
• *Make sure that neither TRNSYS nor Matlab is installed in the 
.\Program Files\ directory.*
• *Make sure that both your user account and the SYSTEM user (a built-in 
Windows user account) have full administrative privileges.*
• *The Type155.dll in your ..\TrnsysXX\Exe directory must match the 
version of Matlab that you are using. DLLs for various Matlab releases 
are located in the ..\TrnsysXX\Exe\DLLs\ directory. If you find your 
version of Matlab there, extract the Type155.dll and place it in 
..\TrnsysXX\Exe, replacing the file that is already in that location. If 
you do not see your version of Matlab in the ..\TrnsysXX\Exe\DLLs\ 
directory please contact your distributor; they can provide you with an 
appropriate version of the file.*
•    Add the path to libeng.dll, which is normally located in 
C:\Matlab\bin\win64, to your windows search path (assuming you installed 
in C:\Matlab, otherwise adapt)
•    To do this, in Control Panel, System, Advanced System Settings, 
Environment variables, edit the Path variable (we recommend that you 
edit the one in System Variables rather than User Variables). Add 
“C:\Matlab\bin\win64;” (without the quotes but with the trailing 
semicolon) at the beginning of the search path. You will notice that 
Matlab has added other subdirectories of C:\Matlab to the path but not 
that one (and you thought TRNSYS was bad…).
•    If you also install the 32-bit version of Matlab you should make 
sure that the win64 directory appears before all other references to 
Matlab in the path. NOTE: some users have found that they need to remove 
all other references to Matlab in the path, regardless of their relative 
placement.
•    Note that if you change the path while the TRNSYS Studio is running 
you will need to restart the TRNSYS Studio.
•    Some users have found it necessary to run the command 
'regmatlabserver' in your Matlab command window. This registers Matlab 
as comserver.

On 11/12/2019 13:01, SALMA LAHMAR via TRNSYS-users wrote:
> Hello
> I need urgent help,
> I use Matlab 2015 64 bit with trnsys 18 I have this erreur : "Your 
> input file uses Type 155 (Calling Matlab). "Type155.dll" was found but 
> could not be loaded. Please make sure that a supported version of 
> Matlab is installed and that Matlab's "bin\win32" folder is on 
> Windows' search path"
> Respectfully
> salma
>>
> _______________________________________________
> TRNSYS-users mailing list
> TRNSYS-users at lists.onebuilding.org
> http://lists.onebuilding.org/listinfo.cgi/trnsys-users-onebuilding.org

-- 
***************************
David BRADLEY
Principal
Thermal Energy Systems Specialists, LLC
3 North Pinckney Street - suite 202
Madison, WI  53703 USA

P:+1.608.274.2577
F:+1.608.278.1475
d.bradley at tess-inc.com

http://www.tess-inc.com
http://www.trnsys.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.onebuilding.org/pipermail/trnsys-users-onebuilding.org/attachments/20191113/6fe29f91/attachment.htm>


More information about the TRNSYS-users mailing list