LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Serial Communication ERROR

Hello

 

I am a complete beginner with Labview. My task is to control a device which is on COM-Port 4

 

It has the following properties:

Fluktuation10111_0-1626967149857.png

I know how the device normally responds to Input, in MATLAB i simply send the string "!0XFFFFFFFFFFFFFFFF" and when i read the output i get the response "Data shifted, output latched, flags are cleared"

 

However, when i implement this in Labview i get the Error (from my Communication Device)

Fluktuation10111_1-1626967647342.png

Note that these are two separate lines, but in Labviews i need to read twice to display this entire message (for some reason)

 

and this error (from the error channel): 0x3FFF0006 (https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P8BmSAK&l=de-DE)

 

As i understand it the amount of transmitted data is equal to the requested amount of data, but there is more data, as a result i get a FIFO overflow, which also is a error message i get: "ERROR in UART-RX-Callback: FIFO overflow" and then " FIFO is now empty, flags are cleared"

 

Here is a screenshot of my VI (the file is also included) 

 

Fluktuation10111_2-1626968111921.png

Does anyone have an idea why i get this I/O error?

 

 

 

0 Kudos
Message 1 of 4
(1,837 Views)

 


@Fluktuation10111 wrote:

Does anyone have an idea why i get this I/O error?

 


Probably because you are using "Bytes At Port".

 

I suggest you watch this video VIWeek 2020/Proper way to communicate over serial

========================
=== Engineer Ambiguously ===
========================
Message 2 of 4
(1,821 Views)

@Fluktuation10111 wrote:

I know how the device normally responds to Input, in MATLAB i simply send the string "!0XFFFFFFFFFFFFFFFF" and when i read the output i get the response "Data shifted, output latched, flags are cleared"

 


I'm new myself but I think I'm working on a similar problem.If anyone on here corrects me, listen to them (I know I will).

It might be that the message your trying to communicate is supposed to be in binary and as a result the device isn't getting the message you think it is and therefore isn't sending the response you normally get in MATLAB.

 

I working though something similar right now so I don't have the answer but here are the materials I've gathered.

----------------------------------------------------------------------------------------------------

NI Link

https://root.cerhttps://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019MGcSAM&l=en-USn/

 

A good, though very old, forum link.

https://forums.ni.com/t5/LabVIEW/Writing-binary-data-on-serial-port/td-p/3086?profile.language=en

 

The video RTSLVU posted. (It's a great video. As a LabVIEW beginner I absolutely love that video.)

 

And Rapidtables has several good binary/hex/ASCII/etc. converters that I like to use with large strings.

----------------------------------------------------------------------------------------------------

 

Good luck. I'll be monitoring this post as well to learn from what anyone else puts down.


___________________________________________________________________________________________________________________________________________________
Upgraded from intern to undergrad automation engineer. Attempting to explain to my employer why I need official training…. since I’m the groups only automation engineer.

I tried. I really did.
0 Kudos
Message 3 of 4
(1,795 Views)

What device are you trying to communicate with?  Do you have the specifications on the command structure?  I really need a lot more information like the protocol in order to give any actual advice.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 4
(1,780 Views)