ni / nidaqmx-python

A Python API for interacting with NI-DAQmx
Other
434 stars 154 forks source link

Add multi-function synchronization examples #589

Closed WayneDroid closed 4 months ago

WayneDroid commented 4 months ago

What does this Pull Request accomplish?

Why should this Pull Request be merged?

Synchronization examples are required to be released with version 1.0 as specified in the feature scope.

What testing has been done?

run poetry run pytest tests -q - pass image

run examples on physical devices PXIe-6363 - okay

C:\dev\repo2\nidaqmx-python>poetry run python examples\multi-functions-synchronization\cont_ai_di_acq.py
Acquiring samples continuously. Press Enter to stop.

Read:   AI      DI      Total:  AI      DI
        1000    1000            4000    4000

C:\dev\repo2\nidaqmx-python>poetry run python examples\multi-functions-synchronization\ai_ao_sync.py    
Actual sampling rate: 1000 S/s
Acquiring samples continuously. Press Enter to stop.
Acquired data: 1000 samples. Total 5000.

Acquired 5000 total samples.

C:\dev\repo2\nidaqmx-python>poetry run python examples\analog_in\voltage_acq_int_clk_dig_ref.py     
Acquired data: [0.802982, 0.803466, 0.803144, 0.803144, 0.802982, 0.802177, 0.801533, 0.800889, 0.800083, 0.799922, 0.799439, 0.798956, 0.799439, 0.799278, 0.799761, 0.800244, 0.800728, 0.801694, 0.802016, 0.802660, 0.802982, 0.803144, 0.803144, 0.802982, 0.802660, 0.802338, 0.801694, 0.800889, 0.800405, 0.799761, 0.799600, 0.799117, 0.799117, 0.799600, 0.799761, 0.800083, 0.800889, 0.801533, 0.801855, 0.802499, 0.802982, 0.803305, 0.803144, 0.802821, 0.802499, 0.802499, 0.801533, 0.800889, 0.800728, 0.799922, 0.799761, 0.799117, 0.799278, 0.799278, 0.799761, 0.800244, 0.801050, 0.801694, 0.801855, 0.802660, 0.803144, 0.803466, 0.803466, 0.803144, 0.802821, 0.802338, 0.801694, 0.800889, 0.800567, 0.799922, 0.799439, 0.799117, 0.799278, 0.799439, 0.799439, 0.800567, 0.801050, 0.801372, 0.802016, 0.802660, 0.803144, 0.803466, 0.803144, 0.803305, 0.802982, 0.802338, 0.801694, 0.800889, 0.800405, 0.799922, 0.799439, 0.799439, 0.799439, 0.799278, 0.799761, 0.800405, 0.800889, 0.801533, 0.802177, 0.802499]