NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Passing parameters from LabVIEW vi to TestStand

Solved!
Go to solution

Hallo,

 

I'm struggling with retrieving the value of a vi OUT Parameter of type ASCII string from the basic_serial_write_and_read.vi (http://zone.ni.com/devzone/cda/epd/p/id/2669)

 

I've assigned a Local Variable type string and assigned this expression to the vi OUT parameter "read string".

When running the sequence however, the Local Variable value is not updated! (?)

 

I can see the ASCII string being returned from the UUT on the NI I/O Trace tool.

The basic_serial_write_and_read.vi works OK in LabVIEW.

 

I'm just getting started but can't figure this out. I'd be appreciative of any hints.

 

Cheers

Kech

 

0 Kudos
Message 1 of 4
(5,429 Views)
Solution
Accepted by topic author kech

Step into your VI from TestStand and make sure it is running correctly.  Can you attach some code?


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 2 of 4
(5,427 Views)

Attached are the basci_erial_write _and_read.vi and my play.seq TestStand sequence.

 

When using the ASCII char "@" as string to write value - i get no reply value to the Locals.Local_read Variable, although i see that the UUT replies with a 22 byte long message on the NI I7O Trace tool.

 

How do i convert the vi - so that the string to write and read string parameter type can be used with hex data i.e. 0x40?

 

Download All
0 Kudos
Message 3 of 4
(5,398 Views)

Hi,

 

I've made some progress - with a RS232 loop back test - established that the ASCII string write is being received and passed to the Local Variable Local_read.

 

When connecting my UUT - i've realised that the write Parameter type/ASCII string needs to be send with the following format so that the UUT accepts it as byte hex code. --> "\x01\x04\x30\xCA"

 

The hex byte string i expect from the UUT as protocol responce is (Hex dislay in vi = 010D 3050 FFFF FFFF 0300 1500 59).

 

How do i convert the received ASCII string which i am receiving to a hex-byte code representation  i.e. "\x01\x0D\x30\x50\xFF\xFF\xFF\xFF\x03\x00\x15\x00\x59"  ?

 

thanks in advance

Kech

0 Kudos
Message 4 of 4
(5,371 Views)