07-22-2010 02:51 PM
Hi Everyone
I have few questions to ask
1) Can register level programming of a third party PCI Daq card be done on LabWindows v8.5 in order to communicate with the PCI DAQ?
If yes, then how it can be done?
2) Suppose if i want to generate two signals on the two analog outputs of 3rd Party PCI daq by using Lab Windows, Can i achieve real time control of the amplitude and frequency of the signals?
3) Are the Inport and Outport functions valid on Lab windows?
If anyone has a simple example or any useful material on this , please share with me.
Any help will be greatly appreciated.
07-23-2010 09:02 AM - edited 07-23-2010 09:02 AM
Hi mhs100,
Performing register level programming(RLP) will require some sort of driver to talk to your hardware resources. NI VISA may work for you as it is compatible with some third-party hardware but I cannot guarantee that. This link has some more RLP information. This should get you started. Post back after you review this document if you have more questions!
Regards,
07-23-2010 01:07 PM
Thanks for your reply but my question remains the same.
07-25-2010 01:36 PM
Anyone plz tell
Can inport( ) and outport ( ) be used on Lab Windows.
I found this code from the previous posts , will this code work ? What does it do?
// define some handy types
typedef int (*T_EtsInp)(unsigned int);
typedef int (*T_EtsOutp)(unsigned int, int);
// undefine existing macro's (which do not work for Embedded Real Time anyways)
#undef inp
#undef outp
// declare inp and outp (byte versions)
T_EtsInp inp;
T_EtsOutp outp;
At process attach or some other convenient spot, but before the actual use of the functions.
// Get module handle
myHandle = GetModuleHandle("ph_exec.exe");
inp = (T_EtsInp) GetProcAddress(myHandle, "EtsInp");
if (inp == NULL)
{
printf("Unable to get proc address for EtsInp");
return 0; // or other finishing action
}
outp = (T_EtsOutp) GetProcAddress(myHandle, "EtsOutp");
if (outp == NULL)
{
printf("Unable to get proc address for EtsOutp");
return 0; // or other finishing action
}
07-26-2010 10:27 AM
Hi mhs100,
Since LabWindows/CVI is a C environment and compiler, you will be able to do any c programming as long as you have the necessary libraries. To address your original questions:
1. while register level programming is definately an option in CVI, I would recommend looking for a driver for the hardware you have. With a driver, you will be able to directly interact with the card without the need for you to call low level functions. If you provide more detail on the card you are using, I would be happy to help you find a driver for it.
2. This is more a question for the hardware manufacturer. If the card is capable of this, then it is acheivable in CVI.
3. the equivalent functions in CVI are inp and outp in the utility library (which will be accessible by including CVIRTE.h).