Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Help with installation of USB-6363 and Python

Solved!
Go to solution

I'm running Windows 11 with NI device monitor and a USB-6363.  The NI device monitor and USB-6363 appear to be working fine:

 

med_device_0-1735335867692.png

 

I'm also running pycharm community edition  2024.3.1.1, and Python 3.13.1 and the following example:

 

import nidaqmx

with nidaqmx.Task() as task:
task.ai_channels.add_ai_voltage_chan("Dev1/ai0")
task.read()

print("test")

 

When I run the program, I get no errors and no output, except for "test".

 

Any suggestions?  I'm not even sure where to begin.

0 Kudos
Message 1 of 4
(161 Views)
Solution
Accepted by topic author med_device

You need to store the read value in a variable and print it to see the value you read.

 

Try running the DAQmx example, https://github.com/ni/nidaqmx-python/tree/master/examples

 

BTW, only one application can access DAQ hardware, this means, either your Python code must access or the Test panel not both at the same time.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
Message 2 of 4
(134 Views)

Thanks, that worked!

0 Kudos
Message 3 of 4
(123 Views)

Note that python nidaqmx examples  are not that good or let's say exhaustive. Earlier, I got the nice recommendation to look at C examples and translate to python API (which may still not be that easy).

Don't hesitate to post on forum, this will enrich python  usage

0 Kudos
Message 4 of 4
(55 Views)