07-04-2025 01:35 PM
I attempted the continuous sampling in two analog input channels by using task.in_stream.config_logging(). It seems to be acquiring the data, however, it is weird that the measured data from these channels are correlated, which should not be. There are significant artifacts, ideally the Photodetector channel should give the response of device under test and the trigger channel should give the trigger from laser. The trigger channel is acquired to some extent reliably. But the Photodetector channel is unpredictable completely. In addition, the voltage shows negative, which is not possible ideally, I think it is something to do with DAQ. The device under test is a ring resonator and it should have narrow resoannce dips, but the photodetector signal has many peaks and dips.
I am attaching a few instances.
Is it not having sufficient sampling points, or is it sampling faster? This data is at a rate of 250 kHz, and the sweep speed in laser takes 5 sec, I had manual control over stopping the acquisition.
Could you suggest a way out?
07-06-2025 11:27 PM
You may be experiencing some of the disadvantages in multiplexed input DAQ devices, especially ghosting.
How Do I Eliminate Ghosting from My Measurements? - NI
Images attached in previous reply,
Note: please put images in the content unless it is very high resolution so that users don't need to download to see the content.
Which channels were these analog inputs connected to and how?
07-07-2025 05:04 AM
It is true that there is cross-talk and ghosting taking place because I used two adjacent channels ai0 and ai1. I tried with ai0 and ai7, in this case the ghosting effect got reduced, but not devoid of.
In addition, I have a query regarding tdms logging, as the FIFO buffer of DAQ is only 2047 samples, and What should be the sample per channel used so that I can be assured that the data will not be lost.
07-07-2025 06:30 AM - edited 07-07-2025 06:33 AM
@pkp401 wrote:
It is true that there is cross-talk and ghosting taking place because I used two adjacent channels ai0 and ai1. I tried with ai0 and ai7, in this case the ghosting effect got reduced, but not devoid of.
In addition, I have a query regarding tdms logging, as the FIFO buffer of DAQ is only 2047 samples, and What should be the sample per channel used so that I can be assured that the data will not be lost.
If both your signal have very good drive strength, you may not observe ghosting as the signals will be able to fully charge the sample and hold circuit within short period. You can use a unity gain buffer for your signals to improve this.
Don'y worry about FIFO buffer, DAQmx uses DMA and can ensure it is not losing any samples, you can use the highest sample rate supported by DAQ, please share the code if you need someone else to ensure it is not a bottleneck.
07-07-2025 07:14 AM
I am attaching the code, I am manually stopping the acquisition currently.
I am skeptical about how data is acquired, It would be helpful if I get some heading to better acquisition method which can have better time stamps. In manual control, it tends to acquire unwanted data too, which I will figure out how to stop the acquisition as soon as sweep stops. But to assure it does not miss any data logging, I had given a sleep time of sweep duration, is it reliable?
#############Code Snippet#######
07-07-2025 07:20 AM
Is the data logging limited by PC RAM? The way I have defined the time.config() i have included the samples_per_channel as chunk_size (5000) , does it help? And if I don’t use it, will it run out of memory.
What is a better practice?