Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How to simplify configuration of analog trigger on APFI channel

Hi

 

I want to use a APFI (Analog Programmable Function Interface) channel as a analog trigger and I want the trigger output to be connected to a counter. I am using a PXIe-6363 multifunction DAQ. The X Series User Manual describes how this can be done from a hardware perspective.

 

JesperSJustesen_0-1615462797350.png

 

I have managed to put together a VI that configures the APFI and the counter as intended. I can see that the "Count" is incrementing according to the waveform that I am applying at the physical APFI input. For future reference I want to mention that the key to make this work is using the terminal "AnalogComparisonEvent" which is described here terminals.

 

JesperSJustesen_1-1615463019709.png

 

My question

Is it really necessary to "create channel" before being able to configure the APFI trigger?

 

Elaboration

As depicted in the block diagram, it seems that I need to create a AI task to able to configure the APFI trigger. As I see it, there is absolutely no reason to involve the AI channels (in this case ai0) in the APFI configuration from a hardware perspective.

 

Any good suggestion on how to simplify and/or get rid of the create AI channel is much appreciated.

 

Best regards

Jesper

0 Kudos
Message 1 of 5
(1,647 Views)

I'm open to being corrected by someone who knows for sure, but I'm pretty confident that you need an active AI task to be able to use an analog signal to trigger a counter task as you showed.  The "AnalogComparisonEvent" is needed to provide a digital triggering signal to the internal counter pins, but such events are only generated while a corresponding AI task is configured for analog triggering and is actively in its run state.

 

What I could find in the manual was in the section on Counter Triggering which states that the configured trigger signal gets routed to an internal counter pin.  That tells me it must be a digital signal, not analog, confirming why you can't *directly* configure a counter task to use an analog signal on APFI0 as a trigger.  It was to be indirect, by way of a task that configures and activates the analog comparisons, i.e., an AI task.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy coming to an end (finally!). Permanent license pricing remains WIP. Tread carefully.
0 Kudos
Message 2 of 5
(1,567 Views)

Hi Kevin

 

Thank you very much for your answer.

 

I believe that the input to the "Analog trigger circuitry" is either an (unscaled) analog APFI input or a ordinary (possible scaled) analog input. 
Whatever the source, the circuitry compares the analog input to a programmable trigger DAC (the threshold) and generates a digital output - namely the "AnalogComparisonEvent" signal. This digital signal then act as input to the counter logic, which provenly works fine.

 

JesperSJustesen_0-1615561496629.png

 

Given that I am correct in my understanding of the hardware, I still do not understand why it should be necessary to create an AI task.

 

Best regards

Jesper

0 Kudos
Message 3 of 5
(1,555 Views)

I understand what you mean, but it's not so much that the board *couldn't* have been designed to accomodate analog triggering of a counter task.  Just that (to the best of my knowledge) it *wasn't*.  I have no insight at all about why.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy coming to an end (finally!). Permanent license pricing remains WIP. Tread carefully.
0 Kudos
Message 4 of 5
(1,552 Views)

Hi Kevin

 

Again, thanks for helping. I think that we are on the same page, but in the hope for somebody to chip-in and prove that it can be done without an AI task, I allowed my self to reiterate below.

 

Possible reasons why an AI task is needed to be able to configure analog triggering on APFI channel.

 

  • The hardware design
    I think that it is very unlikely that the Analog trigger circuitry is dependent on any of the general AI circuitry, however it might be the case.
  • The driver and the DAQmx VI's
    It is possible that the drivers and DAQmx VI's has been designed in a way were the AI task is simply needed to be able to configure the APFI - may bee for simplicity reasons...
  • It is actually possible to configure analog triggering on APFI channel without an AI task - I just haven't found anybody to tell me how
    Still hoping for this option 🙂 Please reply if you know more.

Best regards
Jesper

0 Kudos
Message 5 of 5
(1,519 Views)