04-16-2011 09:05 PM
Hi;
I have a vi in my Labview Project with a MathScript in it. In this MathScript block, I am calling a user-defined m file. However, when I deploy this vi into my real time PXI machine, I am getting a message saying that there are some compiling errors without an error number.
In my application, I set my search paths properly. I also included my user-defined m files in the project and put them under the dependencies folder. I do have RT MathScript. Also, in my user-defined functions, there is no function that MathScript does not recognize. In fact there isn't any complex functions other than sin and cos..Given all these I am wondering if there is anyone out there who can help me figure out where the problem is.
04-18-2011 04:49 PM
Hello,
There are some MathScript Functions that are not supported on RT targets. Perhaps you are using some functions that fit into this category. Below are some links including the LabVIEW Help that list which functions are not supported.
Support for MathScript Functions in Real-Time Applications (MathScript RT Module)
http://zone.ni.com/reference/en-XX/help/371361G-01/lvtextmath/rt_cert_funcs/
Guidelines for Using LabVIEW MathScript in Real-Time Applications
http://digital.ni.com/public.nsf/allkb/203FDAF73DD06746862576D900674744?OpenDocument
Best,
Patricia B.
04-18-2011 07:14 PM
Hi
Thank you so much for the answer. I checked the functions and as it turned out all my functions are recognized by MathScript so there is nothing wrong there. To keep things real simple, I generated an example m file that simply adds up two numbers. I ran the m file with Mathscript Window and it worked just fine. I set my search paths so that Mathscript knows where the m files is. I also included the file in my project so that it appears in my dependencies folder. I named the file properly; the function name is the same as the m file name with a small m extension. When I deployed this very simple file, again I received this message at the end of the deployment "addition.vi loaded with errors on the target and was closed. I don't get the same error when I don't call a user-defined functions so I am sure that the problem comes from the interaction between the user-defined m function and RT Mathscript.
Could yopu please help me what the problem could be. I have been reading all the help files and tried everything but none of them has been of help to me so far.
Kind Regards,
Serdar
04-19-2011 05:45 PM
Hello,
Would you mind posting your project with the target and the .m file you are using so I can take a look? I fou could also send the build spec as well.
Thanks,
Patricia B.
04-19-2011 05:46 PM
Also, what versions of LVRT are you using?