LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can we use RS422 serial port communication in LabView.???

Solved!
Go to solution

I found many articles about serial port but all of them are Regarding about RS232 and Rs485 , But i cant found any articles about RS422 serial communication with Labview

By The way  i followed the same way and create a VI in LabView But while Executing That VI it shows an error like 

 

"" 

Possible reason(s):

LabVIEW: An input parameter is invalid. For example if the input is a path, the path might contain a character not allowed by the OS such as ? or @.
=========================
NI-488: Command requires GPIB Controller to be Controller-In-Charge.""

 

can any one please help me .???

0 Kudos
Message 1 of 42
(7,501 Views)

Hi arun,

 

create a VI in LabView But while Executing That VI it shows an error like

Ok, so there is an error in YOUR VI.

As long as you hide your VI from us you will have to debug it on your own!

 

Can we use RS422 serial port communication

As long as you get a COM port in the device manager you will be able to use VISA functions with it…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 42
(7,492 Views)

Thank you for responding , i dont have any problem to show my code please take a look on the following attachment 

 

i installed all the drivers and NI-visa also , And in the NI-MAX  detect my port as COM23

0 Kudos
Message 3 of 42
(7,483 Views)

Regarding RS-422, as long as it shows up as a COM port, it will code exactly the same as RS-232.


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
Message 4 of 42
(7,481 Views)

Yeah , it detected as COM port, Thats why i followed the procedure but at the end while executing the code it shows errors as i mentioned in the code 

The attachment consist of my VI please take a look

0 Kudos
Message 5 of 42
(7,473 Views)

You don't have any of the error wires connected.  Which function or subVI is throwing the error?  Do you have the com port correctly entered?  I don't see any com port saved as default in your VISA control.

 

You have a major flaw in your program in that you use the Bytes at Port method, and you don't have any wait function between the writing of your command and the reading of the response.  Your Bytes at Port is likely zero because you haven't given any time for the device to respond with a message.

0 Kudos
Message 6 of 42
(7,467 Views)

What device are you trying to talk with (make and model)?  Based on the error description you gave, I would think you did not specify the VISA session correctly before running the VI.  Even then, what is teh baud rate supposed to be?  What is the message protocol?


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 7 of 42
(7,461 Views)

Hi Arun,

 

apart from error handling you should also close a serial port when you finish your VI…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 8 of 42
(7,450 Views)

@ranvensFan  i installed everything perfectly and wires are connected according to the tutorial 

 

please look at the following screenshots may you get  my problem exactly 

Download All
0 Kudos
Message 9 of 42
(7,399 Views)

just look at the attachment , you may get what is the exact problem i am facing @crossrulz

0 Kudos
Message 10 of 42
(7,398 Views)