Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

Driver Development M-Series

Hello,

 

i have to develop a driver for the NI M-Series (PCI-6232, PCI-6250 and USB-6216).

 

One of our customers wants to use these cards in a Windows XP RTX Environment. My company has been asked to provide a DLL-File, which the application will use to access the Hardware. It is not allowed to use the Windows Driver in this RTX Environment, so we have to use direct Register Access.

 

I do not have any NI hardware at this time,  I'm just trying to find out whether or not this is actually feasible.

 

I have to provide 4 basic functions:

 

- Initialize Device

- Start/Stop a continuous measuring (0 - 16 Analog Channels)

- Read ADC values from card memory (all 16 Channels must be read in <20 microseconds)

- Set a single Digital I/O Channel

 

I already looked into the MHDDK, where i found a lot of code-samples and the register map for the M-Series. However, the information I found does not answer all my questions.

 

So far, I found the aiex1.cpp example quite helpful, but in this one a new scan is triggered for each sample. How can I trigger a continuous measurement? Is this even possible?

 

Is there any way to get a more detailed registermap, with a description of what the registers actually do?

 

Thanks in advance for any help.

 

Regards

reini1981

0 Kudos
Message 1 of 2
(5,962 Views)

Hello Reini,

 

The M Series cards have different modes for acquisition depending on what you need.

 

The hardware timing is probably the mode that you want (aiex3.cpp or aiex4.cpp).  It will give you the opportunity to acquire data at the fastest rates that these cards offer.  However, aiex3.cpp and aiex4.cpp are not a continuous example.  To turn it into a continuous example set continuous to kTrue.  Then you will also need to stop the acquisition when your application decides it is done.  The AI_End_On_End_Of_Scan bit will let you stop the hardware from acquiring more data.  Then your application can read the last data that was acquired.

 

You can use the M Series register map along with the descriptions found in the DAQ-STC Technical Reference Manual to get all of the information you need about how to use the card.

 

http://www.ni.com/pdf/manuals/340934b.pdf

There is even a section on continuous AI (section 2.4.3.3).

 

Steven T.

0 Kudos
Message 2 of 2
(5,948 Views)