LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA byte count

In a vi, I am using VISA write to check the byte count at port (I send 32 to VISA write).
When I was in LV 6.1 I did not have any issue. I am now working on LV 7.0 and sometimes I did have 10 bytes at port instead of 8 expected. This is a RS232 connection.
Since I am doing a loop to check that it is 8 bytes, it is then failing.
 
0 Kudos
Message 1 of 6
(3,465 Views)

Hello Quimper,

If you use the same program without any modification, you should receive the same response.
Just be careful because the VIs like "Serial Port Write" and "Serial Port Read" do not exist any more in LabVIEW 7.
That's why, I suggest you to use VISA functions.

Regards,

Sanaa T
National Instruments

Message 2 of 6
(3,392 Views)

Hi quimper,

Are you sending or receiving control characters? such as '\r\n', for instance?

Ray

Message 3 of 6
(3,379 Views)

Hello Ray,

I do not receive control character, I am only receiving a frame.

regards,

Quimper.

0 Kudos
Message 4 of 6
(3,328 Views)

Hello Sanaa T and Ray,

I have finally resolved the issue thanks to your help: This is in "Configure serial Port" vi: I put "Enable termination Char" to false (true by default).

I though that I was only receiving data frame from the interface board I am using, but obviously, this is not the case.

Now, the byte count is correct and do not see anymore failures.

Thanks again for your help, I very much appreciate it.

Regards,

Quimper.

Message 5 of 6
(3,302 Views)

Hi quimper,

Thanks for your reply.  I was thinking about this yesterday and picking my brains at what else it could be 😉

Glad to read that you solved it.  😄

Happy New Year!

Ray

Message 6 of 6
(3,280 Views)