キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 

Problem with the sending and reception of data from Labview to Matlab.

Hello, I have a problem with my code. I have a function that sends data from Labview to Matlab to perform some calculation on Matlab, but the data that Matlab receives is always zeros. I don't know why, how can I solve this problem? Please help me!!!

0 件の賞賛
メッセージ1/10
4,287件の閲覧回数
You need to post your code of you want help in debugging it.
0 件の賞賛
メッセージ2/10
4,275件の閲覧回数

I've posted all the necessary files. Variables tau1 and tau2 send zeros. In the third document it can be seen the data received by matlab.

すべてをダウンロード
0 件の賞賛
メッセージ3/10
4,253件の閲覧回数

Hello Estibaly,

 

Thanks for using NI Discussion Forums, ¿could you create an Error Indicator and connect it to the Error Out Terminal and share the result with us?

Another thins I would like you to do is to create an indicator of the variable and share with us the output value in order to compare it with the MATLAB value.

 

Best regards.

David P.
National Instruments
Applications Engineer
www.ni.com/soporte
0 件の賞賛
メッセージ4/10
4,202件の閲覧回数

Hello, I did what you say. The Labview indicator has the same value in "tau1" andt "tau2" but in Matlab it is very small, near to zero. This happens also with another variable "tempsReel" which is an integer like the other. I did a little modification in the Labview and matlab code, I posted it with this message.

 

Thank you so much.

Estibaly Hernández.

すべてをダウンロード
0 件の賞賛
メッセージ5/10
4,188件の閲覧回数

What is the value of "tau1" and "tau2" on LabVIEW?

What are the data type of "tau1" and "tau2" on LabVIEW and MATLAB?

 

Best regards.

David P.
National Instruments
Applications Engineer
www.ni.com/soporte
0 件の賞賛
メッセージ6/10
4,167件の閲覧回数

Hello, the value of tau1=2 and tau2=4. the type is interger in the two code.

Thank you

0 件の賞賛
メッセージ7/10
4,150件の閲覧回数

Hello, it's a Signed Integer or an Unsigned Integer? How many bits has the Integer? How have you declared it on MATLAB?

David P.
National Instruments
Applications Engineer
www.ni.com/soporte
0 件の賞賛
メッセージ8/10
4,143件の閲覧回数

It's a signed integer with 64 bits. I declared like this tau1=int64(tau1).

Thank you.

0 件の賞賛
メッセージ9/10
4,109件の閲覧回数
But your image shows that the LabVIEW values are being coerced to integers in the matlab script so your definitions do not match.
0 件の賞賛
メッセージ10/10
4,099件の閲覧回数