GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - havocesp/daqmx: A Python wrapper to the National Instruments DAQmx driver.

This repository was archived by the owner on Jul 29, 2022. It is now read-only.
BranchesTags
Open more actions menu
 
 

Latest commit

 

History

62 Commits
62 Commits

Folders and files

NameName
Last commit message
Last commit date
daqmx
daqmx
 
 
examples
examples
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
setup.py
setup.py
 
 
test.py
test.py
 
 

Repository files navigation

daqmx

A [work-in-progress] wrapper to the National Instruments DAQmx driver. It depends on PyDAQmx for callbacks, and all of the functions may be available through PyDAQmx, but the syntax is slightly different to allow for more "Pythonic" programming.

Motivation

PyDAQmx works well, but its members don't show up in Spyder's autocompletion. Also, PyDAQmx uses a lot of mixed case names (including its package name), which can be cumbersome to program with. The goal of this project is to make syntax as clear as possible for rapid application development.

Status

As of yet, only the functions and constants that I have needed are wrapped, so things are a bit incomplete. Use with the knowledge that things are not complete, and feel free to submit pull requests.

Installation

Inside the cloned directory run

python setup.py install

Usage example

import time
import daqmx
import matplotlib.pyplot as plt

# Create a task object
task = daqmx.tasks.Task()

# Create a channel object
channel = daqmx.channels.AnalogInputVoltageChannel()
channel.physical_channel = "Dev1/ai0"
channel.name = "analog input 0"

# Add the channel to the task and activate option to append data in memory
task.add_channel(channel)
task.setup_append_data()

# Run the task for 2 seconds and stop
task.start()
time.sleep(2)
task.stop()
task.clear()

# Plot the resulting data
plt.plot(task.data["time"], task.data["analog input 0"])
plt.show()

About

A Python wrapper to the National Instruments DAQmx driver.

Topics

analogicanalogicodaqdaqmxdata-adquisitiondigital-datanational-instrumentsnipydaqmx

Resources

Readme
GPL-2.0 license
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.