Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

ground problem with analog input

Hi,

 we have a problem with reading analog input on NI USB 6259.

Analog and digital outputs work perfect, however reading analog values doesn't work properly due to ground problems.  We even tried connecting the GND pin with AI pin which should give a precise zero, but it doesn't work.

When the same code was used on a PCI 6251 card it worked nicely and always gave zeros.

How can this problem be solved? I understand that working with more devices with different grounds could be a source of problems, however we tried reading a GND pin from the same port of the same USB card - that should always give us an exact zero.

 

Please help.

0 Kudos
Message 1 of 4
(3,716 Views)

sheldon_cooper,
For future reference, this question would be better posted in the Multifunction DAQ board.

 

Could you please provide some more information on your setup?

  • What connector block are you using? Is it the SCB-68
  • The USB-6259 is an M Series device. SCB-68 pinouts for M Series devices can be found at the following page: SCB-68 Quick Reference Labels for M Series 
  • After consulting the above pinout, can you describe how you have your system wired? A visual diagram or picture would be very helpful.
  • What numeric value is the analog input task measuring when connected to a voltage source?
  • What is it measuring when connected to ground?
  • What is it measuring when left disconnected?
  • Does this happen on all AI channels, or just one in particular?
  • How are you measuring the voltage reading in software? (MAX Test Panels, LabVIEW example, LabVIEW custom code). Please try Test Panels in Measurement & Automation Explorer, and the LabVIEW example located at Help > Find Examples > Hardware Input and Output > DAQmx > Analog Measurements > Voltage > Acq&Graph Voltage-Int Clk.vi
Jared A.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 4
(3,697 Views)

Could you please provide some more information on your setup?

  • What connector block are you using? Is it the SCB-68?
    No. we directly use the card connector itself with a simple reduction that gives us more space for  cable soldering. I think it came with the card.

  • The USB-6259 is an M Series device. SCB-68 pinouts for M Series devices can be found at the following page: SCB-68 Quick Reference Labels for M Series
    We have the pinouts, no problem with that.

  • After consulting the above pinout, can you describe how you have your system wired? A visual diagram or picture would be very helpful.
    Yes. It is attached. From the diagram you can see that AI0 reads a digital value from P0.3. Logical one is generated, so the analog input should read 5 Volts. This does not work. However, if a Digital ground is connected to AI8 it works flawlessly and the AI0 reads 5 Volts. This was discovered experimentally and seems weird.

  • Does this happen on all AI channels, or just one in particular?
    Yes, it happens to all the channles. We tried the same thing for AI2 - it doesn't work unless DGND is connected to AI10, which is next to AI2. It's the same when reading an analog output source, the DGND has to be connected to the AI10.

  • How are you measuring the voltage reading in software?
    We're using plain C. It works great, no problem with that.

 

How should our problem be officialy solved? We tried connecting the grounds (both digital and anlog) and nothing worked, we tried several combinations. There's no problem with generating digital or analog values/waveforms. There's only problem when reading voltages. This was the only solution that worked, but we'd like to do it the "official" way...

 

Thank you.

0 Kudos
Message 3 of 4
(3,671 Views)

shledon_cooper,

 

It appears that you have the analog inputs configured in differential mode. For Channel 0 AI0 is the +input and AI8 is the -input.  Similarly, the AI2, AI10 pair serve Channel 2.

 

You can either leave it that way and ground all the -inputs or reconfigure to single ended.

 

Lynn

0 Kudos
Message 4 of 4
(3,659 Views)