Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

register guide for 6220, 6224

Solved!
Go to solution
Hello Guys
 
I purchased PCI NI-6220 and 6224.
And try to make it works on RTX. Yes I'm fully qualified as an RTX expert.
 
My interesting area is how to understand and use Register inside.
 
As you know these two (6220, 6224) devices support AI & DIO.
My purpose on RTX driver is operate 6220&6224 on AI & DIO... It is simple if NI support clear guide how to operate register.
But unfortunatly, there were no detail register operation guide only register map.
 
Could you tell me the essential register(s) to implement AI and DIO ?
It is the main interesting point of all who visit here.
 
ex]
  - How to set D-In or D-Oot direction of available DIO points
  - where to write input or output value within register
  - what is different sequence on AI compare to DIO and which register ?
  - what is mandatory register to transfer data-in or data-out by Digital and Analog?
 
detil register operation gude is highly appreciated.
 
thanks.
BR kevin.jeong
 
0 Kudos
Message 1 of 29
(18,356 Views)
Hi Kevin,
 
I would like to direct you to a post by Tom W under pseudo code for RLP of M Serial Card. He explains that while we do not currently have an M Series register level programming manual we do have a register map that is available for download.
Steve B

0 Kudos
Message 2 of 29
(18,333 Views)
Hello Steve
 
Thanks for your reply.
I already download register map for M series.
But what I interesting area is which, when and how to use proper register for DIO and AI only.
As you can see -- register map file contains just map of more than 160 registers without any explain for how to use, when and which register must call -- no dependency and sequency .
It is somewhat confused and don't know how to deal.
 
Could you list up mandatory or essencial registers for AI and DIO among 160 registers?
It will be helpful.
 
BR Kevin
0 Kudos
Message 3 of 29
(18,326 Views)

Hi Kevin-

You should inspect the NI Measurement Hardware Driver Development Kit (MHDDK) example code in order to find the necessary order of operations for programming the registers of your M Series devices.  That sample code is provided for download on this website.

You will want to download the M Series PCI/PXI, Generic DMA Library, and RTX operating system support files.  Those examples show how to perform single-point and hardware-timed analog input and digital I/O operations, among others.  They should be enough to get you started with programming your devices for RTX.

If you have any questions about the MHDDK examples please feel free to post them in this forum.

Hopefully this helps-

Tom W
National Instruments
0 Kudos
Message 4 of 29
(18,321 Views)
thanks .
But your linking url does not contains any download material.
It only contains brief explain.
could you clearify link to download ?
 
BR Kevin
0 Kudos
Message 5 of 29
(18,242 Views)
Hi Kevin-
 
The first link at the bottom of that document is Download the NI Measurement Hardware DDK.
Tom W
National Instruments
0 Kudos
Message 6 of 29
(18,233 Views)

Hello Tom

Thanks your guide.

I already download all sample code and register map.

At the case of DIO , two sample codes only refer follow registers. Are those enough to cover DIO area ?

    • DIO_Direction (0x28 offset),
    • Static_Digital_Output(0x24 offset),
    • PFI_Output_Select_1~6,
    • PFI_DO

At the case of AIO, the Gain range maps are as follow on 622X series.

How can I set or handle of Gain range ?

And could you guide how to control analog input depend on differential or signal ?

    • +/- 10V     -->0 
    • +/-  5V      -->1
    • +/-  1V      -->4
    • +/- 200mV -->5

BR Kevin

 

 

0 Kudos
Message 7 of 29
(18,220 Views)

Hi Kevin-

Yes, the DIO registers for DIO_Direction and Static_Digital_Output are used for the lines designated as "port0" in the hardware documentation.  PFI_Output_Select and PFI_DO are used for the lines designated as "port1" and port2".

Gain range settings are shown in both the AI and AO examples provided with the MHDDK (see aiConfigureChannel and aoConfigureDAC).

The input terminal configuration (bipolar, rse, etc) is also set using aiConfigureChannel.

.

 

Tom W
National Instruments
0 Kudos
Message 8 of 29
(18,210 Views)

Thanks Tom

good enough to understand !!

Let me confirm that register access.

Refer to register map (for M series) , each register is consist of address, type and size.

DIO_Direction

Address

Is it right to access

0 Kudos
Message 9 of 29
(18,200 Views)

Thanks Tom

good enough to understand !!

Let me confirm that register access.

Refer to register map (for M series) , each register is consist of address, type and size.

  • DIO_Direction
  • Address : 0x028 / Type : Write / Size :32-bit

For example, if  I want to access DIO_Direction register, follow are my design scheme.

  • Get base address as 0x12345678,
  • Call write function NI_Write(0x12345678+0x028, 0xFFFFFFFF)

Is it right? , Do I have to aceess 32bit format always ?

Hope to this is final question.

Thanks

BR Kevin

 



메시지가 07-08-2008 08:14 PM에 YG.Jeong에 의해 편집되었음
0 Kudos
Message 10 of 29
(18,200 Views)