Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

RS232 IO not working

Is there a tutorial that explains how to get serial data in / out, other than loopback_LV5 & 4.vi which don't work?

I am looking for very basic functionality (send and read rs 232 strings) which should work out of the box.  The COM port was tested with Java and with Hyperterm and is fine.

I installed IIOA.exe because I was getting the "measurement & automation explorer or the Instrument I/O Assistant is not installed correctly. Please install these from the Labview Driver CD." error but I still get the error message when I try to use the Instrument IO assistant. 

I played with setting up the VISA / RS232 port then writting and reading but I get error that are not documented (searched google).

I want to switch from Agilent VEE but serial comminucation needs to work and I am not impressed with the crazy hoop you need to go through for basic io.

Please help.
Thank you
-A
0 Kudos
Message 1 of 8
(4,518 Views)

If you want help with an error, you should at least post the error code. Can you verify that you actually have VISA installed? If you open MAX (Measurement & Automation Explorer) and expand the software listing, you should find NI-VISA listed. If it's not there, then you need to install it from your device drivers CD that came with LabVIEW.

You are making a good decision to swithc from VEE.

0 Kudos
Message 2 of 8
(4,511 Views)
Thank you Dennis,
I confirm I have NI-VISA 3.0.1 installed.
Here are the different errors I get (depending on how the program is setup).
- I get "Measurement & Automation Explorer or the Instrument IO assistant not installed correctly. Please install from the Labview Driver CD." When I try to use the Instrument I/O assistant.
    I tested that both are installed. (downloaded and ran IIOA.exe to pc) and I can open MAX no problem. Is there another test to check that IIOA is running?
- After creating a Serial data outup program (works fine in configuring the port), I get: "Error -1073807346 occurred at Property Node in VISA Configure Serial Port (Instr).vi->Serial test 2.vi Possible reason(s): VISA:  (Hex 0xBFFF000E) The given session or object reference is invalid."

Getting these errors resolved seems like the first step, which is why I am looking for know working setup (code and config with possible walkthrough).

Thank you!
-A
0 Kudos
Message 3 of 8
(4,482 Views)

I don't know why the instrument I/O assistant might not be working but the other error usually means you've selected a VISA Resource Name that is not valid or you've left it blank. How did you select the com port? On the VISA Resource Name control, there is a little arrow on the right side of the control. Clicking on that will give you a list of all VISA resources. Your com port(s) should be listed and you should just pick the one you want. It's it's not, then what type of serial port do you have? Some USB->RS-232 converters do not work with VISA.

I don't understand your comment about 'works fine in configuring the port' but then you say that you get the error from VISA Configure Serial Port. You can't have it both ways. You either get an error from configuring the port or you don't.

There are shipping examples of 'working code' with the serial port. Open the example finder and go to the search tab and enter 'serial'. If one of the shipping examples works but your program doesn't, you should attach the VI you've written or a picture of the block diagram and front panel.

0 Kudos
Message 4 of 8
(4,479 Views)
I did selected the port COM1 throught the drop down menu.
I also tried forcing it with an input.

What I mean by not working with Writing bytes to the line is that the configuration block for RS232 excecutes fine (highlighted excecution), but when the Write block is triggered, it gives errors.

I am using the RS232 fine via VISA on VEE (installed on another machine).  I tried labview on it as well and it gave the same errors.

I will try more examples, but doesn't look like something is wrong with the program, more the setup.

Thanks,
-A
0 Kudos
Message 5 of 8
(4,479 Views)
I still don't understand. You quoted the error message as "Error -1073807346 occurred at Property Node in VISA Configure Serial Port " and that means your configuration did not work and now you are saying the write doesn't work. Are you talking about the VISA write? Please post your VI or a picture and show where exactly you are getting this error.
0 Kudos
Message 6 of 8
(4,472 Views)
I just thought of something. Since you had been using VEE and presumably Agilent's version of VISA, did you install NI-VISA or do you still have Agilent's? That might be the reason you are getting error messages from LabVIEW.
0 Kudos
Message 7 of 8
(4,467 Views)
Hello,
 If you are using a "Property node" to configure the flux control, then you must set the flux control in the "VISA config" to "None". I had similar message in this situation recently.

Best regards
Denis
0 Kudos
Message 8 of 8
(4,429 Views)