Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

Some Questions about NI-6602

Hello!!
I have some question about NI-6602.

1.What is the difference between Port and Line ?
What's the difference of Line nad Portin these function:DIG_In_Line,DIG_Out_Prt,DIG_Line_Config,DIG_In_Prt,DIG_Out_Prt,DIG_Prt_Config

2.If I would like to apply gate to my counter application, is it possible that we give the gate signal via software?
Or I need to connect signal from hardware? If hardware is needed, is it possible to apply another counter's output as my counter's gate input?

3.Can we apply gate to this fuction ND_PULSE_TRAIN_GNR?

4.Can we detect the counter's source is High or Low ?Is there any fuction to read out the source status?
0 Kudos
Message 1 of 4
(3,298 Views)
Hello,

Thank you for contacting National Instruments.

"1.What is the difference between Port and Line?"
A Port is a collection of lines. Usually 8 lines to a port.

"What's the difference of Line nad Portin these function DIG_In_Line, DIG_Out_Prt, DIG_Line_Config, DIG_In_Prt, DIG_Out_Prt, DIG_Prt_Config"
These functions either perform an output or input, or configure your digital ports and lines. Please see the Traditional NI-DAQ Function Reference Help found under Start >> All Programs >> National Instruments >> NI-DAQ >> Traditional NI-DAQ Function Reference Help for more information on these functions.

"2.If I would like to apply gate to my counter application, is it possible that we give the gate signal via software? Or I need to connect signal from hardware? If hardware is needed, is it possible to apply another counter's output as my counter's gate input?"
You can apply a gate signal from software. For example you can use the 6602's Timebase to gate your counter during pulse measurement applications. You can also route a counter's output to the gate of another counter internally. Look up Select_Signal in the Function Reference Help for more details.

"3.Can we apply gate to this function ND_PULSE_TRAIN_GNR?"
I am not sure what you are asking here. ND_PULSE_TRAIN_GNR is a parameter used in the GPCTR_Set_Application function to set up a counter for pulse generation. Please see the page titled "application = ND_PULSE_TRAIN_GNR: GPCTR_Set_Application" in the Function Reference Help more more information about this parameter.

"4.Can we detect the counter's source is High or Low ?Is there any fuction to read out the source status?"
There is no function to read the state of the source pin. You will need to route the source pin to a PFI line and perform a digital read on that line.

I hope this answers your questions. Please feel free to reply if you have any further questions.
0 Kudos
Message 2 of 4
(3,287 Views)
Thanks for your kindly reply.

About Question2,if we want to perform our gate as we click a buttom of our UI or some conditions in our program,not timebase.Is there any function to achieve?

About Question4,Is there any demo or example VB program? Which functions need to be used?

Thanks!
0 Kudos
Message 3 of 4
(3,283 Views)
"About Question2,if we want to perform our gate as we click a buttom of our UI or some conditions in our program,not timebase.Is there any function to achieve?"
The only way to do this would be to write a digital value to the gate of your counter programmatically. You would have to externally wire the DIO pin to the Gate of your counter.

"About Question4,Is there any demo or example VB program? Which functions need to be used?"
To read the digital state of a source pin, you would have to externally wire the pin to a DIO Line and perform a DIO Read. NI-DAQ ships with VB DIO examples. These can be found at C:\Program Files\National Instruments\NI-DAQ\Examples\VBasic\Di. I suggest looking at DIoneLine.VBP.

I hope this helps.
0 Kudos
Message 4 of 4
(3,274 Views)