DATAQ Instruments is pleased to offer Python programming support for model DI-245, DI-2008, DI-1100, DI-1110, DI-1120, DI-2108, DI-4108, DI-4208 and the upcoming DI-4718B.
Python is a popular high level programming language, with a large and enthusiastic user base. When used in conjunction with the latest generation of DATAQ Instruments data loggers, Python allows you to create customer data acquisition and analysis applications for your specific needs. With a fully documented protocol and a series of well commented example programs, even a novice Python programmer will be able acquire, store and manipulate data using Python and any supported DATAQ Instruments data acquisition instrument.
Getting Started
Example programs are downloadable from the DATAQ Instruments GitHub page. GitHub features an eclectic online community of 31 million developers, sharing ideas, networking and reviewing code in a free and open forum.
On our GitHub page you’ll find example programs written specifically for the DI-245, DI-2008, DI-1100 and DI-1110. A ‘universal’ DataqStarterKit.py example program is used to demonstrate Python programming for the DI-1120, DI-2108, DI-4108, DI-4208 and DI-4718B. Requisite drivers for these products can also be found on the GitHub page.
In all cases, begin by disconnecting any DATAQ devices that you do not intend use with a particular example program. This will prevent the program from detecting the wrong vendor identification (VID) number.
Next you’ll need to ensure that the instrument is placed in CDC communication mode. For guidance, go to: https://www.dataq.com/blog/data-acquisition/usb-daq-products-support-libusb-cdc/
Finally, in the case of DI-245, DI-2008, DI-1100 and DI-1110 series instruments (placed in CDC mode), simply run the instrument-specific example program.
In the case of the DI-1120, DI-2108, DI-4108, DI-4208 and DI-4718B (using the DataqStarterKit.py example), you’ll first need to uncomment the appropriate slist and analog_ranges sections of the program.
Note that protocol documentation for any of the products mentioned above can be found on their corresponding product pages under ‘Details’.
10 Comments
Daqhelper
Kenneth,
Please submit a support ticket to resolve this and similar issues.
You can submit a support ticket at:
https://help.dataq.com/portal/newticket/
Regards,
Shawn MacDonald
Application Engineer
DATAQ Instruments Inc.
Sam Perry
Hi, I have a Windaq/Python related library that enables me to import
.WDQ
files directly into python3. See my . It’s useful for small to medium size files. Using pandas to store the imported data makes data analysis super easy. Feel free to modify what I have to make it better or more useful. When I get a chance I will add a repo for the code I have to process large windaq files (4G) and to merge multiple files but right now it is burred deep within private code that I cannot share until I modify it. Thanks for your great products and making my job easier.Laurie Steven
I am logging 10 hrs of respiratory data at 10S/s for a DI-1100.
Is it possible to compute and display resp rate as the data is being acquired ?
If so what is the preferred method/software to use ? eg. Python, Matlab etc.
Thanks.
Daqhelper
Hello Laurie,
To acquire rate, you might consider the DI-2108, with four analog voltage inputs (expandable to eight) and a built-in Rate channel.
WinDaq data acquisition software is included at no additional charge.
You’ll find the DI-2108 on our website at:
https://www.dataq.com/products/di-2108/
Regards,
Shawn MacDonald
Application Engineer
DATAQ Instruments Inc.
Daqhelper
Laurie,
While the DI-1100 does not have a rate channel, you can use the Frequency acquisition method on one of the analog inputs to acquire rate.
To do so, you’ll first need to uncheck the ‘Auto’ option in the ‘Maximum Sample Rate’ dialog box (Edit>>Preferences>>Maximum Sample Rate).
You’ll find a document on using the Frequency acquisition method at:
https://www.dataq.com/data-acquisition/general-education-tutorials/frequency-true-rms-daq.html
Regards,
Shawn MacDonald
Application Engineer
DATAQ Instruments Inc.
Gary Floyd
I have two DI1100s. One of them is working just fine. It switches to CDC with no problems. The other unit will not switch to CDC. Tried both continuous hold of Event button and rapid pushing of the button. By the way the one that does work requires the rapid pushing instead of continuous holding. The one that doesn’t work goes blue instead of red on the active led. Thoughts?
Daqhelper
Hello Gary,
Please send a complete shipping address to smacdonald@dataq.com and we’ll send out a complementary DI-1100.
Regards,
Shawn MacDonald
Application Engineer
DATAQ Instruments Inc.
andres jhonatan
buenas tardes, dias, noches, tengo u DI 718B como seria el programa en phyton para este modelo?
Daqhelper
Hola Andrés,
No ofrecemos compatibilidad con Python para el DI-718B.
Para la compatibilidad con Python, debe considerar su reemplazo contemporáneo, el DI-4718B.
Hay un protocolo de comando publicado para el DI-4718B y ejemplos de trabajo en nuestra página de GitHub en:
https://github.com/dataq-instruments/Simple-Python-Examples
Regards,
Shawn MacDonald
Application Engineer
DATAQ Instruments Inc.
Gary
I have two DI1100. They are running on Python. One works perfectly collecting 20 samples/second. The other, running on the same computer/software/cables, collects 1.33 samples/second. They both need to collect 20 samples/second. Any thoughts?