Quantcast
Channel: Counter/Timer topics
Viewing all articles
Browse latest Browse all 1271

PXI-6221 Continuous Pulsetrain Generation

$
0
0

Hi,

 

I have a PXI-6221 that I'm trying to use to generate pulsetrains but running into issues.

 

Objective: generate 3 different continuous pulsetrains from PXI-6221 and output two 3 separate PFIs.

 

Problem: when I run the LabView example "Counter - Continuous Output.vi", I can see the pulsetrain generated. However, sometimes I see what looks like old tasks still running. Specifically, this is what I do and see:

  1. Set counter to ctr0 on PXI-6221
  2. Set output terminal to PFI0
  3. Set freq and duty cycle to 10 Hz and 0.5
  4. Run program, see correct pulsetrain on PFI0
  5. Stop program, set output terminal to PFI2
  6. Run program, see the correct pulsetrain on PFI2, but the pulsetrain is also being generated on PFI0. I expect PFI0 to be low at all times. 

Troubleshooting:

  1. If I stop the program and change the counter selection, and then re-run, I see the pulsetrain generating only on a single channel again (expected behavior).
  2. As soon as I try to stop the program, switch the channel but NOT the counter, re-start, I get back to the same error state as previously encountered.

Questions: 

  1. Am I neglecting to clear out a cache or something here? Do I need to do something special to clear out / restart the counters that I'm not already doing. 
  2. Tangentially related - will I be able to generate three different pulsetrains with only two counters available on the PXI-6221? I was thinking of using the same counter to create three different, synchronized pulses (different duty cycles and frequencies, but aligned w/ each other), but the examples I've seen only have a 1:1 relation between counter to output terminal. 

 

Thank you much in advance.

 

I've attached the code I'm testing, but note that this is a LabView example and I have not modified it.


Viewing all articles
Browse latest Browse all 1271

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>