Quantcast
Channel: Instrument Control (GPIB, Serial, VISA, IVI) topics
Viewing all articles
Browse latest Browse all 5565

Obtaining an IVI Driver Session from IVI Logical Name in IVI-COM

$
0
0

Hello everyone,

 

I was wondering if someone can help me understand a few things. I am writing a program in C# using a C DcPwr library. I read that I can use the DllImport function but I'm having some trouble understanding some things.

The function I'm importing is 

ViStatus _VI_FUNC CPX400_init (ViRsrc resourceName, ViBoolean IDQuery, ViBoolean resetDevice, ViSession *newVi)

so I'm confused about two things

The first things is the _VI_FUNC. Can someone explain what that does and how it interacts with the C code.

The second is importing the C function into my C# application. How do I translate the declared types to C# types? I assume I can change ViBoolean to bool, and maybe ViRsrc to string, but how about the others? If I'm wrong, please let me know.

 


Viewing all articles
Browse latest Browse all 5565

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>