Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Communicating through a serial port (Error BFF0015)

Hello all,

I literally downloaded the trial version of LabVIEW yesterday, so I am completely new to this.  I am trying to read data from a SuperLogics 8017 analog input module and can't seem to make any progress.  I've read data from other software configured specifically for the modules, so I know I have a good connection.  When I try to read data on the Instrument I/O Assistant, I consistently get error BFFF0015.  The only way I can avoid getting this error is when I open a VISA test panel, go to the Read tab, and set the count to 0, and testing that returns 3FFF0006.

Could my problem be the drivers?  Could I have them installed in a wrong directory?  Is there another way I can use LabVIEW to just read a stream of data through the serial port and then parse it?  I'm sorry if this is a mundane question; this is all brand new to me, and I want to make sure that I can navigate through a trial version before I get the real thing.

Thanks for the help in advance!
0 Kudos
Message 1 of 9
(4,014 Views)

Presumably, you also installed NI-VISA? The error code indicates a timeout and not the missing NI-VISA but in case you didn't, you can get VISA from here. Do you need to send a command to the instrument in order to get data back? If so, are you correctly sending a termination character such as CR or LF?

Besides the special software, have you tried using Hyperterminal? If it doesn't work with that, then maybe you do need to do something special in order to start the data streaming.

p.s. Haven't you seen the information at http://www.superlogics.com/specpage.asp?Items=8017 about the free CD and LabVIEW drivers?

Message Edited by Dennis Knutson on 04-25-2007 09:33 AM

0 Kudos
Message 2 of 9
(4,007 Views)
Dennis,

First, thanks a lot for your help!  I downloaded VISA, and that didn't seem to change anything.  I shouldn't have to send data to get data back.  In that case, should I not need a termination character?

The drivers may be the problem.  I have the CD that you gave me the link to, and it put the drivers in C:\DAQPro\NAP7000v.  Is this the correct directory, or is there somewhere else the drivers should go?
0 Kudos
Message 3 of 9
(3,992 Views)
The drivers can go anywhere. As long as they can find the dll when you load the VIs, that should be enough. Do you get any data when when you use the supplied VIs or are you just having problems with the Instrument I/O Assistant?
0 Kudos
Message 4 of 9
(3,985 Views)
When I open AnalogIn.vi or AnalogIn8.vi, I get Error Code 17: Module ID Error.  So, I guess I'm having more problems than I thought Smiley Indifferent
0 Kudos
Message 5 of 9
(3,982 Views)
I suspect that you have to do a bit more than just run one of the subVIs. All of the demos that I looked at do the OPENCOM function as the very first thing. There could be a lot of things going on in that dll. I didn't see any reference to using a normal terminal emulation program like Hyperterminal in the documents but I could have missed that. One thing you can try is use a program called portmon when you start up the app from the vendor. That will report the serial traffic and give you a clue as to what might be going on behind the scens.
0 Kudos
Message 6 of 9
(3,975 Views)
Hi,

Are you able to read any data when you use a VISA test panel in Measurement and Automation Explorer (MAX)?  Now that you have installed NI VISA, you should be able to read from a built in serial port through MAX.  You mentioned you tried this but you set the count to 0, and received a return of 3FFF00006.  I am including a screenshot of what that means.  When you set the count to 0, you are saying that you want to read 0 bytes on that port.  That message is saying you read in the amount you designated.  If you leave it at the default value, are you able to read any data, or do you still get a timeout?

Regards,

Adam W

Message Edited by Adam W on 04-26-2007 10:56 AM

0 Kudos
Message 7 of 9
(3,957 Views)
Hi Adam,

I can't read any data in MAX.  The only time I don't get a timeout is when I set the count to 0.  Are there other parameters in the VISA setup that I should try modifying?

Thanks for the help!
0 Kudos
Message 8 of 9
(3,950 Views)
Hi,

Well you said earlier you are just trying to read in data from your device.  Can you try starting from scratch and querying your device and work up from there?  I think if we could get some basic communication established that might help.  Are you able to query your device at all with something like *IDN?\r\n

Another route might be trying one of the demos included.  Are there examples that show you how to use the VIs included on the CD?

If you cannot get any communication with VISA, it may be that the software configured for the module is doing some things for you that we aren't aware of.  Like Dennis mentioned earlier, there might be things going on behind the scenes that you would have to explicity do in VISA or LabVIEW.  Is there a manual for your device or can you contact the manufacturer to see if there's a way to talk to the device outside of the configured software?  Portmon is another good suggestion to try (again, thanks Dennis!)

Regards,

Adam W
Applications Engineering
National Instruments

0 Kudos
Message 9 of 9
(3,932 Views)