LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Transferring matlab code to LabVIEW

Is there a way to transfer a matlab code to labVIEW without using mathscript? I am using labview base and don't have the mathscript addon.

0 Kudos
Message 1 of 6
(1,587 Views)

can you compile your Matlab code into a .NET dll using the application builder app (in Matlab)? Here's the official tutorial: https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YGE2CAO

 

 

In case you cannot, and you're using LV 2023 versions, I think you can link the .m files itself from the Connections section of LabVIEW library.

 

I don't have a PC with LabVIEW in it at the moment so if you want, I or someone else can give you a more detailed instruction later

0 Kudos
Message 2 of 6
(1,558 Views)

Do you have the matlab script node  and matlab installed? (not sure if LabVIEW base has that). What's your LabVIEW version?

 

How complicated is the matlab code? Maybe it could be easily rewritten in G.

0 Kudos
Message 3 of 6
(1,501 Views)
0 Kudos
Message 4 of 6
(1,483 Views)

Then why do you need LabVIEW? Logging thermocouple measurements is simple and doesn't need code spread across LabVIEW and MATLAB.

 

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
0 Kudos
Message 5 of 6
(1,479 Views)

@santo_13 wrote:

Then why do you need LabVIEW? Logging thermocouple measurements is simple and doesn't need code spread across LabVIEW and MATLAB.

 


To paraphrase @santo_13, then why do you need Matlab?  If you are planning to use LabVIEW to acquire the data, getting it to also save the data should be a piece of cake.  Since you are getting started with LabVIEW, I recommend "Learn{ing) 10 Functions in NI-DAQmx and handle 80% of your Data Aquisition Applications" (do a Web search for "Learn 10 Functions" and you'll find this excellent summary of DAQmx).  Disregard the first section talking about the (Dreaded) DAQ Assistant.  Your instructor or a fellow student (perhaps from an earlier class) might help you see how simple DAQmx can be.

 

Bob Schor

Message 6 of 6
(1,432 Views)