Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

MHDDK Manual

Hello,

Where can I find a manual for MHDDK ? 

I would like to find : 

  • What are the functions which allow to configurate a channel or a port ?
  • Which are its different parameters ?

    I'd like to find those informations about different NI card families.

I have to find those informations because I have to desing an API for NI card on a linux OS.

 

Can somebody help me ? 

Thanks 

0 Kudos
Message 1 of 24
(11,198 Views)

Hi Stephanie-

 

There is no published manual for the MHDDK.  The example code that ships with the MHDDK is intended to be self-documenting.

 

If you are interested in individual device information, you should look to the hardware manuals.  In another post you mentioned these devices:

 

  • 6220

         There is no published M Series manual for RLP information.  However, the functionality of the M Series timing chip (STC-II) is very similar to the timing chip used on E Series (STC).  You can find useful information in the STC manual for programming the M Series devices.

  • 6509

         This manual contains information about the register set of the NI 6509 and a few other NI DIO devices.

  • 6703

         There is no published manual for AO Series RLP information.  There are only a few AO-specific registers for that device and basic functionality is shown in the MHDDK examples for 670x.

 

Please take some time to view the MHDDK.  It provides programming examples that answer some of the questions you have about configuration and device operation.  If you have any specific questions that the MHDDK does not answer, please post here and we will try to help answer them.

 

Thanks-

Tom W
National Instruments
0 Kudos
Message 2 of 24
(11,193 Views)

Hello,

Please can you explain me what do the 2 parts of example for a PCI-6713  and what can I change ?


  //Call this function to program the buffer size and the number of buffers.
void AO_Counting(tSTC *theSTC)
{
    //Loading counter values in DAQ-STC
    theSTC->Joint_Reset.writeAO_Configuration_Start(1);

    theSTC->AO_BC_Load_A.writeRegister((unsigned)(NumberOfBuffers-1));

    theSTC->AO_Command_1.writeAO_BC_Load(1);

    theSTC->AO_UC_Load_A.writeRegister((unsigned)(PointsPerBuffer));

    theSTC->AO_Command_1.writeAO_UC_Load(1);

    theSTC->AO_UC_Load_A.writeRegister((unsigned)(PointsPerBuffer-1));

    theSTC->Joint_Reset.setAO_Configuration_Start(0);
    theSTC->Joint_Reset.setAO_Configuration_End(1);
    theSTC->Joint_Reset.flush();
}

//Call this function to program the update interval.
void AO_Updating(tSTC *theSTC)
{
    //Program the update interval.
    theSTC->Joint_Reset.writeAO_Configuration_Start(1);

    theSTC->AO_Command_2.writeAO_BC_Gate_Enable(0);

    theSTC->AO_UI_Load_A.writeRegister(0x00000001);

    theSTC->AO_Command_1.writeAO_UI_Load(1);

    theSTC->AO_UI_Load_A.writeRegister(0x00001999);

    theSTC->Joint_Reset.setAO_Configuration_Start(0);
    theSTC->Joint_Reset.setAO_Configuration_End(1);
    theSTC->Joint_Reset.flush();
    return;
}

 

 

I search what is the parameters to change the frequency of my signal.

 

Thank you

0 Kudos
Message 3 of 24
(11,155 Views)

Hi Stephanie-

 

The functionality of those registers is described in the STC Technical Reference Manual.

Tom W
National Instruments
0 Kudos
Message 4 of 24
(11,141 Views)

Thank you veru much !

 

Do you have such manual for the card 6713, 6601, 6512, 6511, 6221, 6220, 6703, 6509 ?

 

 

0 Kudos
Message 5 of 24
(11,128 Views)

Hi Stephanie-

 

The NI 660x devices have an RLP manual, here.  The rest of the devices you mention are discussed in my comments earlier in this thread.

Tom W
National Instruments
Message 6 of 24
(11,120 Views)
thank you very much :smileyhappy:
0 Kudos
Message 7 of 24
(11,118 Views)
hello,

For my card 6713 I want to create a pattern of sine with a variable frequency but I can't.
How do I build my pattern?
What do I put in the AU_Updating to change my frequency?
Do you have an example to show me?
 
Thanks you for your answer.

0 Kudos
Message 8 of 24
(11,088 Views)
 Hello,
Thank you for your support and your responsiveness. But my problems persist !

 First, could you explain me which part of the STC I have to change to update the Rate for a 6713 card in buffered mode ?

 If I have well understand, the function AO_Updating,  is required to change the update rate between 2 samples and  thus the output frequency signal. But if I put 1000 in the register AO_UI_LoadA I get a signal with  20Hz frequency, when I put 100 the frequency is 200Hz and for 50 the frequency is 1kHz. I don't understand how to calculate this value for an expected frequency. Could you tell me how its works ?


 Second, I don't understand how to generate signal on a dedicated channel or on several channels. I compute this code to write in a buffered channel :

 
         //Set Board registers for Waveform generation
         _board-AOWaveformGeneration.writeDacnum((t67xx::tAOWaveformGeneration::tDacnum)numChannel);
         //Reset the AO data FIFO
         _stc-Write_Strobe_2.writeRegister(0x0001);
         //Load the data FIFO
         data_index = 0L;
         while(!fifo_full && (data_index < channels[numChannel].getSizeBuffer())){
             _board-DACFIFOData.writeRegister(data1<<16  | (data2 & 0x0000FFFF));
             data_index = data_index + 2;//Increment by two in an iteration.
             //Check to see if the data FIFO is full.
             fifo_full = _stc-AO_Status_1.readRegister();
             fifo_full = fifo_full & 0x4000;
         }


 When I change the value of numChannel from 0 to 7, the output signal is always transmit on the first channel.
 Please, could you tell me where is the problem about this code ?

Best regards
0 Kudos
Message 9 of 24
(10,964 Views)

Hi Stephanie-

 

The AO_UI counter is used to divide down a timebase and create the update clock signal for AO.  The default timebase is 20MHz.  So, if you load some value into AO_UI, the resulting update clock is 20MHz / AO_UI_Loadx.  If you want an update clock rate of 100Hz, for example, you should choose 20MHz / (200k - 1) because the counter is zero indexed.

 

The actual frequency output of your signal will then depend on the data you pack into the AO FIFO.  Let's say you desire to generate a sine wave of 10Hz.  If your update clock rate is 100Hz, then you need to place a 10 sample array representing a sine wave in the AO FIFO.  In this way, 100 points from the AO FIFO will be cycled through each second.  Because there are 10 samples in each sine period in your AO FIFO set, you will end up with 10 completed sine cycles per second.

 

Without knowing more about your data set I can't comment on why your frequency if varying in a seemingly unexpected way.  Perhaps you are seeing some aliasing in your measurement instrument(?)

 

 

In addition to setting the AOWaveformGeneration register to your specified numChannel, you also need to set AOTimed to indicate your channel(s) to use and AOConfiguration to set up various options for the same channel(s).  Check out the function Configure_Board() from the 67xx MHDDK examples.  Note that the order you specify channels in AOWaveformGeneration.writeDacnum() must match the ordering in which you place samples to be generated in the AO FIFO. 

 

 

Tom W
National Instruments
0 Kudos
Message 10 of 24
(10,956 Views)