From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

problem with VISA read

dear all,

 

I have a problem with my labview. I need to read a data from spectrophotometer using rs232 and display the data using labview. I have design a few block diagram. the first one is

1.png

 

the problem with this diagram is VISA READ timeout. the second one is

 

2.png

 

when i run this diagram, no error occured but there is ni reading/output reading at the READ BUFFER, supposely, it have to display the value. 

 

im still new with labview..can everyone help me???

 

tq

0 Kudos
Message 1 of 15
(4,348 Views)

You're just trying to read the serial port.  With your instrument, do you need to send a command to it to have it be able to return data?

0 Kudos
Message 2 of 15
(4,343 Views)

im sorry because im not really sure about it. because i refer from the thesis. i followed the instruction exactly as in the thesis.

0 Kudos
Message 3 of 15
(4,336 Views)

A thesis might be good to get a grade in school.  But you are dealing with a real world instrument.  You need to read the manual for that instrument.

0 Kudos
Message 4 of 15
(4,332 Views)

Dont use while loop and use simple error handler and read the error generated. Let me know what is that. Or post the VI in 2011 format.

 

 

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 Kudos
Message 5 of 15
(4,325 Views)

I already read the manual for spectrophotometer. I also ask my lecturer about the instrument. I think there is a problem with my diagram.

0 Kudos
Message 6 of 15
(4,316 Views)

VI file attached. I really hope u can help me with this problem

Download All
0 Kudos
Message 7 of 15
(4,315 Views)

1. Does your instrument use the default settings for the VISA Configure Serial Port.vi? 9600 baud, 8 bit data, no parity, termination character enabled with Line Feed as the termination character,...?

2. What characters does the instrument send with each message?

3. As Ravens Fan has asked, do you need to send a command to the instrument to get it to send data back?

4. Do you get any errors other than the timeout?

5. Do you have other software which can communicate successfully with the instrument?

6. Are you using the correct cable?

7. Does your computer have a built in RS-232 port or are you using an adaptor? Which adaptor?

 

Lynn

0 Kudos
Message 8 of 15
(4,297 Views)

@tk_ghani wrote:

I already read the manual for spectrophotometer. I also ask my lecturer about the instrument. I think there is a problem with my diagram.



And what did the manual say?  What did the lecturer say?

 

There is a problem with your diagram, and that is that it was created without having a clue has to how the instrument works.

 

We can't help you fix your VI because we have no idea how the instrument is supposed to work.  Only you and your lecturer have that information.  There is no more help we can provide until you provide more information.  Perhaps attach a link to the manual, or upload the manual as an attachment.  At least provide the brand and model number of the instrument.

0 Kudos
Message 9 of 15
(4,296 Views)

file attached id the instrument manual. I've asked some one who has been used the instrument. they said there is no command needed. just connect the rs-232, choose the port (eg COM1) and the data will display into the labview. i dont know whether there is somethg wrong with my diagram, the computer or the instrument 

0 Kudos
Message 10 of 15
(4,277 Views)