05-28-2021 05:17 AM
Hello!
I'm trying to make a program that sends signal to my myDAQ and then reads the signal from there and write the values to file. It works otherwise fine BUT it writes only 117 first values and stops after that. The program doesn't end it continues running but the text files has always only that amount of values. I would need more sample values cause it takes while to read a signal so there is just about constant values at first (well and ofcourse I would either way have more samples to written).
I have no idea what could cause this though I'm really new to this.
05-28-2021 05:47 AM
You are getting a buffer overflow from your DAQ. First of all, the AO is taking 1 second (rather, you are writing 1 second of data at a time). Yet, you expect to be reading from the AI at every 66us. This will not work. So change your DAQmx Read to Analog->Multiple Channels->Multiple Samples->2D Array. Then tell it to read 15000 samples at a time (1 second worth of data to match the AO task). You also will not need the Array To Cluster node after doing this.