Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to write to Rs-232 port

We have recently bought a Power meter from Newport (1830-C) that has a RS-232 serial port for computer interface. The problem is:
I am able to control the power meter using using VISA interactive control (plug&Play). But a program written in Labview using simple serial VI's does not seems to work. I am not able to write/read to the serial port using LabVIEW 6.1. I also tried the programs avaiable in examples category on serial communication -- but no use. I am wondering if something trivial I have missed in the whole exercise.
Can someone please tell me what could be the actual problem???
0 Kudos
Message 1 of 4
(3,386 Views)
Can you provide an example vi?
0 Kudos
Message 2 of 4
(3,386 Views)
Hi Rake,
I tried the following programs found in:
National Instruments/LabVIEW 6.1/examples/instr/smplserl
0 Kudos
Message 3 of 4
(3,386 Views)
Hi,
Try the LabVIEW <-> Serial.vi example. You can get to it from Help >> Find Examples >> Hardware Input & Output >> Serial >> LabVIEW <-> Serial.vi

This example uses VISA to talk to the serial port. Make sure that you go to the block diagram and verify that all the settings for VISA Configure Serial Port VI are consistent with your instrument. Things like stop bits, termination, etc need to be considered.

Are you getting any errors? If so, what is it? Make sure that you close the VISA Interactive Control session before you run the LabVIEW VI since you can only have one session open on a port at a time.

Hope this helps.

A Saha
Applications Engineer
National Instruments.
Anu Saha
Academic Product Marketing Engineer
National Instruments
0 Kudos
Message 4 of 4
(3,386 Views)