LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

daqmx base voltage error

I have figured out how to make my while loop, but now I am having trouble writing the data to an excel sheet.  It is writing the voltage to an excel sheet, but I also want it to record the time in another column corresponding to its voltage.  Thanks again for the help.

0 Kudos
Message 11 of 29
(1,549 Views)

If you do not want to the waveform data type from the DAQmx Read and which would contain a timestamp, use one of the functions on the Timing palette. Convert everthing to strings and pass a string array to the write.

Message 12 of 29
(1,536 Views)

I have update my VI with a clear history option, now I still just need to figure out how to export the time with the voltage data on the same .csv sheet.  I have added a tick count (ms) from the timing palette, but I do not know where and how to connect it in order to have it on the .csv file.  Attached is my current VI.

 

Thank you

0 Kudos
Message 13 of 29
(1,491 Views)

You haven't added anything useful. That tick count outside the loop does nothing since it would be updated once.

 

I already told you what to do. Whether you use a tick count (inside the loop), an actual timestamp, or something else, you convert everything to strings and set the Write to Spreadsheet File function for string data. Right click on it - Select Type

 

p.s. Tick count b.y itself is pretty worthless as a timestamp. If you use that, have an initial tick count outside the loop like you have and one inside the loop. Subtract the current tick count from the initial to get the iteration time in msec.

Message 14 of 29
(1,482 Views)

Thanks Dennis, I really appreciate your help. Unfortunately I'm still having some trouble with this. Could you please show me an example of this, either using my VI or another to show how I would get the time to be exported to the .csv file too?

 

Also, this program is being created to read voltage from a Photomultiplier tube, but for some reason when I am testing it, it does not work, only works when I do voltage output from a power supply I have.  The photomultiplier tube gives a signal output on a RC cable and I have that connect to the digital input on the USB-6009.  Attached is the manual for the PMT incase you need it for reference.  Any ideas why it is not reading any voltage?  Instead it is reading a voltage that jumps back and forth between about .5 and 1.5. 

 

 

Thanks again

 

Download All
0 Kudos
Message 15 of 29
(1,449 Views)

According to the datasheet, the output is current and the 6009 can only read voltage. Wiring to a digital input makes even less sense - you configured the VI to acquire from an analog input. Are you attempting to read the current across a known resistor?

 

p.s. Your code modifications are a step backwards in some ways. Here's a modification. I had to replace your base functions with standard DAQmx so you will have to replace them. Since you are doing a single channel and single sample, I used the correct functions for that mode.

0 Kudos
Message 16 of 29
(1,439 Views)

What kind of optical signal are you feeding to the PMT?  Is it a continuous signal or are you counting photons or short pulses of light?

 

What do you measure when you connect a meter or oscilloscope to the output of the PMT module?

 

Lynn

0 Kudos
Message 17 of 29
(1,425 Views)

Thank you for the modification Dennis, I really appreciate the help.

 

As for the PMT, I am measuring a continuous signal.  I think the PMT has a built in converter of current to voltage.  I am basically measuring the strength of light over time as fluorescence dye travels down a small tube and the PMT measures the light that is given off from the glass tube.

 

I'm pretty sure I got it to read successfully once, but haven't been able to get the results again.  As you can see, in 070710, there was a correlation to the values and what was being measured.  The PMT measured the light at around 1.125, and then when I pulled the light source away from the PMT, the values dropped to .08.  Now when I run the PMT, my VI just measures random numbers.  Attached are my data files.  Any idea what the problem might be?  When I try to measure voltage from the signal output of the PMT with a multimeter, I get no reading.  

Download All
0 Kudos
Message 18 of 29
(1,367 Views)

I may have my wiring wrong.  An RC cable is connected to the signal output of the PMT.  I stripped the other end of the RC cable so the positive and negative wires were showing.  I was then plugging the positive wire into the USB-6009 analog input channel.  Do I need to plug the negative end in too?  When I tried this it didn't seem to do anything.  Also, I have no wire for ground, is this a problem too?

0 Kudos
Message 19 of 29
(1,358 Views)

Solis,

 

What do you mean by RC cable?  I have been working in electronics for 40+ years and am not familiar with that terminology.  The data sheet you posted for the PMT module shows a BNC connector for the output.  That implies that your cable is a coaxial cable.  Most likely the shield is connected to ground.  When you measure between the coaxial center conductor and shield with the voltmeter, what do you get?

 

As for the connections to the USB-6009, the shield should connect to one of the many analog ground connections.

 

No wire for ground?  Are you referring to a connection to a rod driven into the earth or do you not have any of the signals called ground connected together?  The grounds of your power supply, the PMT module, the USB-6009, and the computer should all be connected. The earth ground should be connected if available, but the three-wire power cord of the computer or other devices probably provides an earth connection. This must comply with your local electrical codes. If an ohmmeter shows more than a fraction of an ohm between any of those points, you need to add connections.

 

Lynn

0 Kudos
Message 20 of 29
(1,347 Views)