From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

How to initialize PCI-6251 MITE Controller under RT linux?

Hi, All,
 
Happy New Year!
 
I have a PCI 6251 card.  Since I need to use RT Linux, therefore I need to program from the register level.  I have programed PCI-DAS6402/16(Measurement Computing).  However it seems for this PCI6251, the MITE controller need to be initialized. 
 
I listed my programe as follow, is there anybody can kindly tell me what is wrong?
 
1. find physical board address using
 
   
 
 
2. remap bar0 and bar1 by using ioremap
3.  
 
 
 
 
 
BTW, Where can I find the PIN map for the IDC connector on the corner of the board?  I have the PIN map of the 68 pin SCSI connector on the edge of the board.  
 
Thank you very much!
 
0 Kudos
Message 1 of 4
(7,784 Views)
 

Hello Haihong,
If you download the Measurement Hardware DDK (Driver Development Kit) for M Series devices (click the Download link at the bottom of the page), you can see an example of how the MITE is initialized.  Look in the examples folder and check out main.cpp, the initMite function is the one you are looking for.  And as far as the connector you mentioned, I'm assuming you are talking about the RTSI (Real-Time System Integration) connector.  Hope this helps!

-Alan A.

0 Kudos
Message 2 of 4
(7,741 Views)
Thank you, Alan,
 
I have solved the MITE initialization problem.  Now I am looking for a very easy way to sample a single data using A?D Channel.  Do you have any idea.  Like in my programe for the PCI DAS 6402/16, I used only four lines to performe a single command:
 
write channel configuration word
soft triger to start sampling
read Data from PIPE 
clear PIPE
 
Do you know for M series how to realize a single command/sampling 
 
Thank you in advance
 
Best
 
Haihong
 
 
0 Kudos
Message 3 of 4
(7,731 Views)
Hello Haihong,
This type of sampling, where no timing is needed, we refer to as on-demand sampling.  In the M Series examples, "aiex1.cpp" is an example of an on-demand acquisition.  It will take you more than four commands to set up the board for this type of acquisition, but once the board is propertly configured, it only takes a couple functions to get one sample.  Once you have it set up, you can just call the "aiStardOnDemand" function followed by a fifo read whenever you want a sample. 
-Alan A.
0 Kudos
Message 4 of 4
(7,714 Views)