background image

4-2

|

ni.com

Chapter 4

PFI

Using PFI Terminals as Timing Input Signals

Use PFI terminals to route external timing signals to many different functions. Each PFI terminal 
can be routed to any of the following signals:

Counter input signals for all counters—Source, Gate, Aux, HW_Arm, A, B, Z

Counter 

n

 Sample Clock

DI Sample Clock (di/SampleClock)

DI Sample Clock Timebase (di/SampleClockTimebase)

DI Reference Trigger (di/ReferenceTrigger)

DO Sample Clock (do/SampleClock)

Most functions allow you to configure the polarity of PFI inputs and whether the input is edge 
or level sensitive.

Exporting Timing Output Signals Using 
PFI Terminals

You can route any of the following timing signals to any PFI terminal configured as an output:

DI Sample Clock (di/SampleClock)

DI Start Trigger  (di/StartTrigger)

DI Reference Trigger  (di/ReferenceTrigger)

DI Pause Trigger (di/PauseTrigger)

DO Sample Clock* (do/SampleClock)

DO Start Trigger (do/StartTrigger)

DO Pause Trigger (do/PauseTrigger)

Counter 

n

 Source

Counter 

n

 Gate

Counter 

n

 Internal Output

Counter 

n

 Sample Clock

Counter 

n

 Counter 

n

 HW Arm

Frequency Output

RTSI<0..7>

PXI_STAR

PXI_Trig<0..7>

Change Detection Event

Note

Signals with an * are inverted before being driven to a terminal; that is, these 

signals are active low.

Summary of Contents for NI 6612

Page 1: ...PCIe 6612...

Page 2: ...NI 6612 User Manual NI 6612 User Manual November 2013 374008B 01...

Page 3: ...ses and current events National Instruments Corporate Headquarters 11500 North Mopac Expressway Austin Texas 78759 3504 USA Tel 512 683 0100 For further support information refer to the Technical Supp...

Page 4: ...Instruments shall not be liable for any delay in performance due to causes beyond its reasonable control The warranty provided herein does not cover damages defects malfunctions or service failures c...

Page 5: ...NTS IN ANY LIFE SUPPORT SYSTEMS WHOSE FAILURE TO PERFORM CAN REASONABLY BE EXPECTED TO CAUSE SIGNIFICANT INJURY TO A HUMAN 2 IN ANY APPLICATION INCLUDING THE ABOVE RELIABILITY OF OPERATION OF THE SOFT...

Page 6: ...ercial areas To minimize interference with radio and television reception and prevent unacceptable performance degradation install and use this product in strict accordance with the instructions in th...

Page 7: ...8 Routing DI Start Trigger to an Output Terminal 2 8 DI Reference Trigger Signal 2 8 Using a Digital Source 2 9 Routing DI Reference Trigger Signal to an Output Terminal 2 9 DI Pause Trigger Signal 2...

Page 8: ...Settings 3 2 Timing Settings 3 3 Trigger Settings 3 4 Other Settings 3 6 Exporting a Terminal Count Signal 3 6 Cascading Counters 3 6 Pulse Measurement 3 6 Create Channel 3 7 Channel Settings 3 7 Tim...

Page 9: ...3 32 Channel Settings 3 33 Timing Settings 3 33 Triggering Setting 3 33 Generating a Waveform with Variable Frequency and Duty Cycle 3 34 Create Channel 3 34 Channel Settings 3 35 Timing Settings 3 35...

Page 10: ...5 Matching Routing Terminology 5 5 Synchronizing Multiple Devices 5 6 PXI Express Devices 5 6 PCI Express Devices 5 7 Real Time System Integration RTSI 5 7 Using RTSI as Outputs 5 8 Using RTSI Termina...

Page 11: ...NI 6612 User Manual National Instruments xi Appendix B Technical Support and Professional Services...

Page 12: ...hat the device is operating properly NI 6612 Specifications Contains specifications specific to the NI 6612 NI DAQmx Help Contains API overviews general information about measurement concepts key NI D...

Page 13: ...ion instructions that accompany your software 2 Installing NI DAQmx The DAQ Getting Started documents contain step by step instructions for installing software and hardware configuring channels and ta...

Page 14: ...conductor cable R6868 Unshielded 68 conductor flat ribbon cable BNC 2121 BNC connector block with built in test features CA 1000 Configurable connector accessory SCB 68A Shielded screw connector bloc...

Page 15: ...d for timing input or output it is called PFI x where x is a number between 0 and 39 representing the PFI line number The same physical pin has two different names depending on whether it is used for...

Page 16: ...cept for the default counter source input pins CI is not populated on the default source input pins in order to allow the measurement of higher speed input signals Table 2 2 lists the lines that do no...

Page 17: ...le sample of data Each of the DIO lines can be used as a static DI or DO line You can use static DIO lines to monitor or control digital signals Each DIO can be individually configured as a digital in...

Page 18: ...transferred across the bus fast enough the FIFO becomes full New acquisitions will overwrite data in the FIFO before it can be transferred to host memory The device generates an error in this case Wit...

Page 19: ...al input timing signals are featured DI Sample Clock Signal DI Sample Clock Timebase Signal DI Start Trigger Signal DI Reference Trigger Signal DI Pause Trigger Signal Signals with an support digital...

Page 20: ...generates DI Sample Clock unless you select some external source DI Start Trigger starts this timing engine and either software or hardware can stop it after a finite acquisition completes When using...

Page 21: ...in number of points are sampled in finite mode After a hardware reference trigger in finite mode With a software command in continuous mode An acquisition that uses a start trigger but not a reference...

Page 22: ...ence Trigger in a pretriggered acquisition operation DI Reference Trigger Signal Use the DI Reference Trigger di ReferenceTrigger signal to stop a measurement acquisition To use a reference trigger sp...

Page 23: ...the measurement acquisition stops on the rising or falling edge of DI Reference Trigger Routing DI Reference Trigger Signal to an Output Terminal DI Reference Trigger can be routed out to any PFI 0 39...

Page 24: ...e to the level of the source not the edge Digital Output Data Generation Methods When performing a digital waveform operation either software timed or hardware timed generations can be performed Softw...

Page 25: ...from a PC buffer to the device s onboard FIFO using DMA before it is written to the output lines one sample at a time Buffered generation typically allow for much faster transfer rates than non buffe...

Page 26: ...ital Waveform Generation Digital waveforms can be generated on the Port 0 DIO lines The DO waveform generation FIFO stores the digital samples NI 6612 has a DMA controller dedicated to moving data fro...

Page 27: ...d to an external source DO Start Trigger starts the timing engine and either the software or hardware can stop it after a finite generation completes When using the DO timing engine a configurable del...

Page 28: ...DO Start Trigger signal while the clock generation is in progress After the clock generation is finished the timing engine waits for another start trigger to begin another clock generation Figure 2 9...

Page 29: ...h the Onboard Clock Source When using any signal other than the onboard clock as the source of your sample clock the generation resumes as soon as the pause trigger is deasserted and another edge of t...

Page 30: ...output limits of the DAQ device NI has several signal conditioning solutions for digital applications requiring high current drive When configuring a PFI or DIO line as an input do not drive the line...

Page 31: ...etection circuitry can interrupt a user program when one of several DIO signals changes state You also can use the output of the DIO change detection circuitry to trigger a DI or counter acquisition o...

Page 32: ...itter all lines in the bus will hold state until the bus becomes stable However each individual line only waits one extra filter tick before changing This prevents a noisy line from holding a valid tr...

Page 33: ...ropagates on the second filtered clock edge as shown in Figure 2 14 Figure 2 14 Case 1 Case 2 If an additional line on the bus also has a transition during the filter clock period the change is not pr...

Page 34: ...include receiving TTL signals and sensing external device states such as the state of the switch shown in the figure Digital output applications include sending TTL signals and driving external device...

Page 35: ...ns Static digital input Static digital output Digital waveform generation Digital waveform acquisition DI change detection Note For more information about programming digital I O applications and trig...

Page 36: ...examples refer to the KnowledgeBase document Where Can I Find NI DAQmx Examples by going to ni com info and entering the Info Code daqmxexp For additional examples refer to zone ni com Signal Integri...

Page 37: ...and generations The embedded counters cannot be programmed independent of the main counter and signals from the embedded counters are not routable Counter measurements support several options for det...

Page 38: ...urement Pulse Width Measurement Two Edge Separation Edge Counting In an Edge Counting measurement task the counter counts the number of active edges of a signal Figure 3 2 shows an example of edge cou...

Page 39: ...via CI CountEdges DirTerm Timing Settings The timing settings determine when the device reads the count value On Demand By default the counter uses On Demand no sample clock timing The counter starts...

Page 40: ...change these behaviors by configuring DAQmx Trigger properties Using an Arm Start Trigger Use an Arm Start Trigger to have the counter begin counting in response to a hardware trigger 1 Set ArmStart...

Page 41: ...a hardware signal set the following DAQmx Channel properties 1 Set CI CountEdges CountReset Enable to True 2 Set CI CountEdges CountReset Term to select the signal that causes the count to reset 3 Set...

Page 42: ...Event OutputBehavior CtrOutEvent Pulse Polarity and CtrOutEvent Toggle IdleState Cascading Counters You can cascade two counters to make a single 64 bit counter For example assuming that you want to u...

Page 43: ...tings By default the counter measures the pulse on a default PFI terminal Refer to Chapter 5 Counter Signal Routing and Clock Generation for more information begins measuring on a rising edge That is...

Page 44: ...DAQmx Start Task 2 The device measures the first full pulse on the signal to measure 3 The device waits until you call DAQmx Read The device ignores the signal to measure while waiting 4 The device re...

Page 45: ...DAQmx Start Task You can change this behavior by setting DAQmx Trigger properties To have the counter begin counting in response to a hardware trigger use an Arm Start Trigger 1 Set ArmStart TrigType...

Page 46: ...are both measurements are the same however data is returned with a different alignment In a Pulse measurement each pair of high and low times is returned as one point of data each point of data consis...

Page 47: ...a measurement duration of 100 s measure the time t it takes to observe a specified number of periods p Figure 3 14 shows an example with a measurement duration of three periods In both cases the frequ...

Page 48: ...implicit timing and specify a number of periods to measure the device returns the measurement after that number of periods of the input signal Note that the time to return a measurement depends on the...

Page 49: ...number of samples sample clock source and other properties CI Freq EnableAveraging Set this property to True By default the counter measures the frequency on a default PFI terminal refer to Chapter 5...

Page 50: ...following DAQmx Create channel CI Frequency Use this VI or function to create the channel DAQmx Timing Sample Clock Use this VI or function to set the number of samples samples clock source and other...

Page 51: ...this VI or function to create the channel CI Freq MeasMeth Set this property to Low Frequency with 1 Counter By default the counter measures the frequency on a default PFI terminal refer to Chapter 5...

Page 52: ...ue and uses the known frequency of the timebase fk to calculate the frequency fx of the signal to measure as Figure 3 18 Frequency Measurement Large Range of Frequencies with Two Counters With N as th...

Page 53: ...z clock as the timebase To change the signals used for this measurement configure the following CI Freq Term The signal to measure comes from an input terminal To change the signal to measure set this...

Page 54: ...owing DAQmx Create channel CI Frequency Use this VI or function to create the channel CI Freq MeasMeth Set this property to High Frequency with 2 Counters Note that this measurement method requires tw...

Page 55: ...for Period measurements are similar to Frequency measurements For example use CI Period Term to change the signal to measure Pulse Width Measurement Note This section describes Pulse Width measurement...

Page 56: ...erminal CI PulseWidth StartingEdge Specifies on which edge rising or falling to begin the measurement CI PulseWidth Units Specifies the units of the measurement Timing Settings The timing settings det...

Page 57: ...igure 3 22 shows an example of Sample Clock timing Figure 3 22 Pulse Width Measurement Sample Clock To use Sample Clock timing use the DAQmx Timing Sample Clock VI or function Trigger Settings By defa...

Page 58: ...input to the counter by enabling a filter Refer to the PFI Filters section in Chapter 4 PFI for more information If you route the same PFI signal to multiple destinations you should enable the Synchro...

Page 59: ...Second Edge Specifies on which edge of the second signal rising or falling the device ends the measurement CI TwoEdgeSep Units Specifies the units of the measurement Timing Settings The timing setting...

Page 60: ...se Sample Clock timing use the DAQmx Timing Sample Clock VI or function Trigger Settings By default the counter begins measuring when software calls DAQmx Start Task You can change this behaviors by s...

Page 61: ...rature cycle the counter increments When channel B leads channel A in a quadrature cycle the counter decrements The amount of increments and decrements per cycle depends on the type of encoding X1 X2...

Page 62: ...channels A and B You must then ensure that channel Z is high during at least a portion of the phase you specify for reload In Figure 3 30 the reload phase is when both channel A and channel B are low...

Page 63: ...the following parameters Decoding Type For two pulse encoders set this to Two Pulse Counting For quadrature encoders set this to XI X2 or X4 decoding Z index enables z index phase z index value If th...

Page 64: ...mand Timing Sample Clock To precisely control when the device reads the encoder use the DAQmx Timing Sample Clock VI or function With this VI or function you can set the source and rate of the Sample...

Page 65: ...I for more information Linear Position Measurement In a linear position measurement task the counter measures position using a quadrature encoder or two pulse encoder Linear position measurements are...

Page 66: ...ignal begins in a low IdleState The pulse generation begins by calling the Start Task VI or function After waiting for InitialDelay seconds the output goes high for HighTime seconds and then low for L...

Page 67: ...on The NI 6612 can also begin generating pulses in response to a digital trigger Figure 3 36 shows an example using a digital trigger Figure 3 36 Start Trigger Initiates Pulse Generation To use a star...

Page 68: ...m with Constant Frequency and Duty Cycle Create Channel You specify the characteristics of the waveform when you create the channel You can specify in terms of frequency and duty cycle time or ticks F...

Page 69: ...nerated in response to a digital trigger Figure 3 39 Start Trigger Initiates Waveform Generation To use a start trigger call the DAQmx Start Trigger Digital Edge VI or function Inputs to this VI or fu...

Page 70: ...the current pulse idle and active level before beginning the new waveform frequency duty cycle You can specify the waveform buffer in terms of Frequency and duty cycle Idle time and active time of ea...

Page 71: ...gger signal Edge Specifies rising or falling edges The following DAQmx Trigger properties configure the Start Trigger Start Delay Start DelayUnits Specifies the delay from when the trigger occurs to w...

Page 72: ...f the timebase clock 10 ns by default Frequency and duty cycle Create Channel Use one of the following functions to create a channel Select the VI or function that corresponds to the format of the dat...

Page 73: ...Fltr Enable Start DigEdge DigFltr MinPulseWidth To enable and configure a digital filter on the start trigger input This filter eliminate noise on the start trigger signal Refer to Chapter 4 PFI for m...

Page 74: ...3 42 Frequency Generator Circuitry The Frequency Generator can use one of three timebases 20 MHz 10 MHz or 100 kHz The timebase can be divided by any integer from 1 to 16 to create the FREQ OUT signa...

Page 75: ...line Each PFI line is similar Figure 4 1 PFI Circuitry When a terminal is used as a timing input or output signal it is called PFI x where x is an integer from 0 to 39 When a terminal is used as a st...

Page 76: ...ts and whether the input is edge or level sensitive Exporting Timing Output Signals Using PFI Terminals You can route any of the following timing signals to any PFI terminal configured as an output DI...

Page 77: ...unctionality inside the device Refer to the DI Change Detection section of Chapter 2 Digital I O for more information Connecting PFI Input Signals All PFI input connections are referenced to D GND Fig...

Page 78: ...to high transition on an input that has a custom filter set to N 5 Figure 4 3 Filter Example Enabling filters introduces jitter on the input signal The maximum jitter is one period of the timebase Whe...

Page 79: ...ways properly ground yourself and the equipment when handling the DAQ device or connecting to it Signal Integrity Considerations Signal integrity can be optimized by maintaining a common and matched i...

Page 80: ...nect your GND signal to the appropriate GND pin as shown in this table If you are using the BNC 2121 simply connect your GND signal to the nearest GND pin Table 4 2 Signals and D GND Pin Number on 68...

Page 81: ...0 23 PFI 24 P0 24 30 PFI 25 P0 25 PFI 26 P0 26 65 PFI 27 P0 27 PFI 28 P0 28 33 PFI 29 P0 29 PFI 30 P0 30 68 PFI 31 P0 31 PFI 32 P1 0 42 PFI 33 P1 1 39 PFI 34 P1 2 42 PFI 35 P1 3 41 PFI 36 P1 4 39 PFI...

Page 82: ...ur system through RTSI User input through the PXI_Star terminal Clocking circuitry Clock Routing Figure 5 1 shows the clock routing circuitry of an NI 6612 device Figure 5 1 Clock Routing Circuitry PX...

Page 83: ...the 20 MHz Timebase by 200 External Reference Clock The external reference clock can be used as a source for the internal timebases 100 MHz Timebase 20 MHz Timebase and 100 kHz Timebase on your device...

Page 84: ...le modules in a PXI Express measurement or control system The PXIe backplane is responsible for generating PXIe_CLK100 independently to each peripheral slot in a PXI Express chassis For more informati...

Page 85: ...Frequency with One Counter Period Frequency High Frequency with Two Counters or Large Range with Two Counters PFI 39 PFI 35 PFI 31 PFI 27 PFI 23 PFI 19 PFI 15 PFI 11 Two Edge Separation Start PFI 37 P...

Page 86: ...k the Device Routes tab at the bottom of the middle pane to see routes that can be made within your device Matching Routing Terminology NI DAQmx and the Device Routes table in MAX use different termin...

Page 87: ...Pause Trigger Synchronizing Multiple Devices Refer to the following sections for information about synchronizing multiple NI 6612 devices PXI Express Devices On PXI Express systems you can synchroniz...

Page 88: ...e to drive the timing engine on multiple devices Share trigger signals between devices Many National Instruments DAQ motion vision and CAN devices support RTSI In a PCI Express system the RTSI bus con...

Page 89: ...l Output Change Detection Event FREQ OUT PFI 0 39 Note Signals with a are inverted before being driven on the RTSI terminals Using RTSI Terminals as Timing Input Signals You can use RTSI terminals to...

Page 90: ...een PXI trigger signals and the DI DO Counter and Clocking systems Use DAQmx properties to configure the desired routes To see a complete list of available routes use the device routes table for your...

Page 91: ...e you to create more applications because of the increased routing capabilities Table 5 5 describes the three differential star DSTAR lines and how they are used For more information refer to the PXI...

Page 92: ...hardware and software technology to achieve high throughput rates and increase system utilization DMA is the default method of data transfer for PCI Express and PXI Express devices NI 6612 devices ha...

Page 93: ...nsferring data Each read or write call in the program initiates the transfer of data Programmed I O is typically used in software timed on demand operations PXI Express Considerations PXI Express Cloc...

Page 94: ...National Instruments 7 1 7 Calibration For the NI 6612 calibration is not required...

Page 95: ...al Instruments A 1 A Pinout and Signal Descriptions Figure A 1 shows the NI PCIe PXIe 6612 pinout The descriptions beside each pin are in the following format Signal Name DIO Context Counter Context D...

Page 96: ...P0 19 CTR 5 SOURCE PFI 20 P0 20 CTR 4 OUT D GND PFI 23 P0 23 CTR 4 SOURCE PFI 24 P0 24 CTR 3 OUT D GND PFI 27 P0 27 CTR 3 SOURCE PFI 28 P0 28 CTR 2 OUT D GND PFI 31 P0 31 CTR 2 SOURCE R GND RESERVED...

Page 97: ...ervice Program SSP with the purchase of most software products and bundles including NI Developer Suite NI also offers flexible extended contract options that guarantee your SSP benefits are available...

Page 98: ...rt and Professional Services You also can visit the Worldwide Offices section of ni com niglobal to access the branch office Web sites which provide up to date contact information support phone number...

Reviews: