Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

about set clock rate and actual clock rate


@John_P1 wrote:

You could connect your signal to RTSI 7 and then use it as the Master Timebase if you wanted to.  I would just use it as the ao/SampleClockTimebase though unless you have counter tasks or something that need to use the same timebase.

 

Either way, you would set the source and rate of the timebase through a DAQmx Timing Property node.

 

 

 

Best Regards,


I think I am getting closer to my goal based on your hints. Let's me restate my understanding here. Now I have an external clock (of 1MHz frequency) connected to /dev1/PFI0, I am going to use it as Master Timebase so I could set the actual sample rate to any rate divde 1MHz (in my case, I use 1kHz). So I use DAQmx Timing Property node to set the master timebase and change the sampel clock rate with DAQ Timing (Sample Clock) to change the down sample rate to 1kHz before starting the task. The code was shown as follow

 

t.png

 

I don't have the device to test it now but do you think this way works? I will use the same way for analog ouput and counter output but at different rate, so I think it is all right to use the same master timebase but set different down sample rate for analog output and counter output, what do you think?

 

Thanks a lot.

0 Kudos
Message 11 of 12
(2,683 Views)

No that wouldn't work:

    • PFI0 can't be routed to the Master Timebase.  It can be routed to the sample clock timebase however (and to the counter's timebase as well).  Refer to the diagram in my last post.

    • If you're using an external timebase you'll have to specify the rate as well.  

    • You aren't starting your task.



Best Regards,

John Passiak
0 Kudos
Message 12 of 12
(2,641 Views)