10-25-2011 07:21 PM
If I am understanding the SPY data, calling the viSetAttribute function in VISA is not a good idea. Some of these calls that supposedly set mundane things like termination and timeout take a considerable amount of time. Is that normal? I am running NI-VXI 3.7 and NI-488.2 2.8.0 on Window 7. The processor is an NI-8108. I am using the built-in GPIB controller. Does it really take 3 seconds to set the timeout value? It appears that setting the attributes takes longer than sending and receiving data.
1. viSetAttribute (GPIB0::8::INSTR (0x025D6668), SEND_END_EN, VI_TRUE)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:18:57.764 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
2. viSetAttribute (GPIB0::8::INSTR (0x025D6668), GPIB_READDR_EN, VI_TRUE)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:18:57.764 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
3. viSetAttribute (GPIB0::8::INSTR (0x025D6668), TMO_VALUE, 10000)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:18:58.813 Call Duration 00:00:03.146
Status: 0 (VI_SUCCESS)
4. viWrite (GPIB0::8::INSTR (0x025D6668), "*TST?..", 7, 7)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:01.960 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
5. viSetAttribute (GPIB0::8::INSTR (0x025D6668), SEND_END_EN, VI_TRUE)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:08.008 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
6. viSetAttribute (GPIB0::8::INSTR (0x025D6668), GPIB_READDR_EN, VI_TRUE)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:08.008 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
7. viSetAttribute (GPIB0::8::INSTR (0x025D6668), TMO_VALUE, 10000)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:09.057 Call Duration 00:00:03.147
Status: 0 (VI_SUCCESS)
8. viWrite (GPIB0::8::INSTR (0x025D6668), "SYST:ERR?..", 11, 11)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:12.204 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
9. viSetAttribute (GPIB0::8::INSTR (0x025D6668), TMO_VALUE, 10000)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:13.253 Call Duration 00:00:03.147
Status: 0 (VI_SUCCESS)
10. viSetAttribute (GPIB0::8::INSTR (0x025D6668), TERMCHAR, 10)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:16.400 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
11. viSetAttribute (GPIB0::8::INSTR (0x025D6668), TERMCHAR_EN, VI_TRUE)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:17.449 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
12. viRead (GPIB0::8::INSTR (0x025D6668), "0, No error..", 200, 13)
Process ID: 0x00000840 Thread ID: 0x000009C4
Start Time: 17:19:18.498 Call Duration 00:00:01.049
Status: 0 (VI_SUCCESS)
debatbae
11-01-2011 06:15 PM
Hello debatbae,
Thanks for the question.
Can you also provide a SPY capture for the other OS you were using? If not, can you let us know what that previous version was?
If you change your timeout value, does the process still take this long? I'm curious, since your other viSetAttribute calls are shorter.
Lastly, is your ultimate goal here to reduce the time viSetAttribute takes to complete? If not, please clarify that.
Thanks,
Lisa
11-02-2011 04:22 PM
Thanks for your reply,
Here is the SPY data from our old op system (Windows 2000). We are trying to migrate our system to Windows 7 to make use of newer NI CPUs which do not support Windows 2000. Our overall goal is to maintain the same throughput if possible. Some of that may require us to rewrite the software. We would like to minimize that part as much as possible.
1. viSetAttribute (GPIB0::8::INSTR (0x01691658), SEND_END_EN, VI_TRUE)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.017 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
2. viSetAttribute (GPIB0::8::INSTR (0x01691658), GPIB_READDR_EN, VI_TRUE)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.017 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
3. viSetAttribute (GPIB0::8::INSTR (0x01691658), TMO_VALUE, 10000)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.017 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
4. viWrite (GPIB0::15::INSTR (0x01691658), "*TST?..", 7, 7)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.017 Call Duration 00:00:00.030
Status: 0 (VI_SUCCESS)
5. viSetAttribute (GPIB0::8::INSTR (0x01691658), SEND_END_EN, VI_TRUE)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.047 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
6. viSetAttribute (GPIB0::8::INSTR (0x01691658), GPIB_READDR_EN, VI_TRUE)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.047 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
7. viSetAttribute (GPIB0::8::INSTR (0x01691658), TMO_VALUE, 10000)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.047 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
8. viWrite (GPIB0::15::INSTR (0x01691658), "SYST:ERR?..", 11, 11)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.047 Call Duration 00:00:00.040
Status: 0 (VI_SUCCESS)
9. viSetAttribute (GPIB0::8::INSTR (0x01691658), TMO_VALUE, 10000)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.087 Call Duration 00:00:00.000
10. viSetAttribute (GPIB0::8::INSTR (0x01691658), TERMCHAR, 10)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.087 Call Duration 00:00:00.010
Status: 0 (VI_SUCCESS)
11. viSetAttribute (GPIB0::8::INSTR (0x01691658), TERMCHAR_EN, VI_TRUE)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.097 Call Duration 00:00:00.000
Status: 0 (VI_SUCCESS)
12. viRead (GPIB0::8::INSTR (0x01691658), "0,No error..", 200, 13)
Process ID: 0x000006F0 Thread ID: 0x000004EC
Start Time: 09:55:30.097 Call Duration 00:00:00.060
Status: 0 (VI_SUCCESS)
I will change the time limit in the Windows 7 version and get the rest of the info to you ASAP.
Thanks,
Dale
11-03-2011 03:33 PM
Thanks debatbae,
I've been looking into this issue for a bit, and I have a few more questions for you:
Thanks for the information!
Lisa
11-03-2011 04:49 PM
Thanks Lisa,
We are using a PXI-8108 not the PXIe-8108.
We have these cards in the chassis:
PXI-8430 4 port Serial
PXI-8320 MXI-2
The versions of drivers in Windows 2000 are:
MAX - 4.2.0.3001
NI-488.2 - 2.42
NI-PAL - 2.0.0
NI-Serial - 1.6.0
NI-VISA - 4.1
NI-VXI - 3.5.0
The versions in Windows 7 are:
MAX - 4.7.1f8
NI PXI Platform Services - 2.5.6
NI System Configuration - 1.1.1f5
NI-488.2 - 2.80
NI-PAL - 2.5.4
NI-Serial - 3.6
NI-VISA - 5.0
NI-VXI - 3.7.0
The GPIB instrument is a Sorensen DLM 40-15
Although this occurs with all GPIB units I have tested.
Dale
11-07-2011 02:57 PM
Hi debatbae,
I'm trying to scrounge up some hardware to replicate your issue on our end right now, and just wanted to update you on what's going on.
Thanks,
Lisa
11-08-2011 11:58 AM
Hi debatbae,
Can you provide a MAX technical report?
From MAX, go to Files >> Create Report. Add your VI.
Thanks,
Lisa
11-08-2011 12:17 PM
And one last question:
Which version of CVI are you running on both machines?
Thanks,
Lisa
11-17-2011 11:50 AM
Hi Lisa,
We are not running any LabView code on our test station. We also do not have CVI installed on it. The NI-VXI loads a CVI run-time system when it installs. That is probably used by the IVI C drivers for the instruments. The Win 7 version is 9.1.0.428. The Win 2000 version is 7.1. I have noticed something which may be of relevance here. We have two different types of test stations. Both have the same software confiurations. The difference is that one station has 3 VXI chassis full of instruments and 10 GPIB instruments. The other station has no VXI instruments and only 4 GPIB instruments. The extra time that we see in the Win 7 I/O is not there on the station that does not use VXI instruments. That station has the 8320 MXI controller also, but nothing is connected to it. Since there are so many instruments used, I am having a hard time discovering which combination results in the slow down. Most of the instruments are interrelated in some way or another.
Dale
11-18-2011 08:44 AM
Good morning Dale,
Can you give me a pretty detailed overview of what your hardware set up looks like as well as how everything is cabled together? If a diagram is easier, that would work as well.
Thanks,
Lisa