Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Generate TTL Signal with BNC-2110 using Python

Hello everyone,

 

I need to generate a TTL signal to control an AOM(acousto optical modulator) in real time. 

I got a BNC-2110 block from NI which is connected to a PCIe-card. My idea is to connect one of the PFI-channels to the 'User-Defined Signals'-BNC ports and use the output to turn on and off the AOM. 

So far all other instruments are controlled via Python, so I would like to do the same with the BNC-2110.

My problem is that I am rather unexperienced in handling the 'nidaqmx'-packages. I know that I can somehow set the 'DigitalDriveType' or the 'LogicFamily' but I do not know how to actually generate an output. 

I found a few examples but they are not commented, so for me as a beginner not really helpful.

 

I would be grateful for any advise.

Thank you very much in advance.

 

Best regards,

 

Lukas

 

0 Kudos
Message 1 of 2
(566 Views)

There is a DO example in below link which might help you. Setting the level of DOs depends on your DAQ card too, so first you might find out whether it has the option to change DO levels or not. 

https://github.com/ni/nidaqmx-python/tree/master/nidaqmx_examples

Available python functions for NI DAQ are documented in below link.

https://nidaqmx-python.readthedocs.io/en/latest/

 

 

0 Kudos
Message 2 of 2
(379 Views)