Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

How does ThreadStatus differ from ProcessStatus in class GPIBStatus?

When working with the GPIBStatus class of the NationalInstruments.NI4882 namespace there is a process status and a thread status. If I do not use notify, begin read, or begin write would there be a difference between the two values? Also, Could someone suggest some good reading material on writing multithreaded GPIB applications with Visual Studio dotNET and Measurement Studio.
0 Kudos
Message 1 of 3
(3,745 Views)
The article "Developing Multithreaded GPIB Applications in Windows NT and Windows 95" on NI developer zone has good material on developing multithreaded GPIB applications. You should become familiar with this and also the .NET thread functions.

To answer your original question, ThreadStatus contains the GPIB status value for that thread. It is equivalent to calling the GPIB function ThreadIbsta(). ProcessStatus returns the last status for that particular process.

As an example if you had a multithreaded program with two threads; thread A and thread B and thread A called a GPIB call that returned with a mask of Complete, ControllerInCharge, and Attention, then spawned thread B with called a GPIB call that returned with a mask of Complete. Afte
r these calls occurred if you called ThreadStatus from Thread A the value would be Complete, ControllerInCharge, and Attention. If you called ThreadStatus from process B the value would be Complete. If you called Process status from either thread the value would be Complete.
Message 2 of 3
(3,745 Views)

Hello -

Click here to access the "Developing Multithreaded GPIB Applications in Windows NT and Windows 95" document.

Have a great day!

Becky B.
Applications Engineer
National Instruments

Becky Linton
National Instruments
Field Engineer
Office: 734-464-2463
Cell: 248-709-2822
Email: becky.linton@ni.com
0 Kudos
Message 3 of 3
(3,745 Views)