Using MicroDAQ with Python
Thanks to its flexibility, Python is one of the most popular programming languages. The Microdaq allows use MicroDAQ device in Python applications. All major features like data acquisition and DSP management functions are available now for Python users.
Microdaq
The Microdaq library is a Python programming interface for programming analog input, analog output, digital I/O, on MicroDAQ DAQ devices. The library can be used on Windows and Linux operating systems. The user can use Microdaq library to create data acquisition applications and control applications with real-time processing on MicroDAQ DSP core. Microdaq provides DSP management functions allowing the user to embed real-time processing on dedicated hardware in standard Python application.
Microdaq (1.4.0) function reference
Digital I/O
|
Analog I/O
|
DSP managment
|
Utility
|
More information you can find in __doc__ section of these methods.
Installation
To install microdaq package:>> pip install microdaq
To upgrade:
>> pip install microdaq --upgrade
Example code
This example show how to use MicroDAQ library to read analog input with 100ksps rate:
import microdaq mdaq = microdaq.Device("10.10.1.1") mdaq.ai_scan_init( channels=[1], ai_range=[-10, 10], is_differential=[False], rate=100000, duration=0.1) data = mdaq.ai_scan( scan_count=10000, timeout=True)
For more examples visit Microdaq repository on GitHub.