Multifunction DAQ

Showing results for 
Search instead for 
Did you mean: 

How to use external excitation with the 9237


I am using the NI 9237 to measure weights with a load cell. 

I am using a full bridge and the createvoltagechannelwithexcitation project in VB.NET


It works OK when I use internal voltage for the excitation.

I would like to get up to 10 Volts and prefer to use external excitation.


So far I am not able to get the external source to function with the NI 9237.


I have the RJ50 cable, so I am using the EX+ and EX- terminals on the 9237 to supply the external voltage.

When I specify external as the source in the software, I expect the NI9237 to give me whatever voltage I have set for output on my power supply.  I should see that at the EX+ and EX- (pins 6 and 7) output from the 9237,  ie it should match what I am putting in on the terminals of the four terminal connection.


I currently only have wired up two of the four pins for external input (the top EX+ and EX-), but I believe this is fine.


To troubleshoot I have a voltmeter across the pin 6 and 7 output.  On internal excitation I max out around 8 volts if I specify 10 as the source.  On external excitation I get closer to 7.8 volts.  But I still get that 7.8 volts even when the external voltage source is turned off.


So, it appears that the NI is still giving me internal excitation.  Why?

I have the 4 terminal connection pushed in as far as it goes.  Is there some kind of hardware check to see we actually have external voltage?  Is there some software switch I need to set besides telling it to use external source?


What are my next steps for troubleshooting





0 Kudos
Message 1 of 21

Hi CR,


What does your code look like? Are you using one of the shipping examples? I don't know what createvoltagechannelwithexcitation project is, but ContAcqCustomVoltageSamples_9237 sounds like a good starting point. Maybe that is what you are using?


What type of CompactDAQ chassis or USB/WLS/ENET carrier are you using? The NI-DAQmx version would be helpful too.


Note that myTask.AIChannels.CreateVoltageChannelWithExcitation() doesn't actually program the NI 9237 hardware. myTask.Control(TaskAction.Commit) or myTask.Start() is necessary to actually program the excitation of the NI 9237.



Brad Keryan
0 Kudos
Message 2 of 21

Hi Brad:

Thanks for your response.


First, I am using Visual Studio 2010, so I am using the most recent version of NI-DAQmx (9.2.3).  The actual dll reference is


You are correct that I started with the ContAcqCustomVoltageSamples_9237.2010 project as the example for my slightly modified code.  I get the same issue using the supplied example as with my modification.


I do start the task before expecting the output to follow my external voltage source.

I have the 9237 in an ENET carrier.


Here is a little sample of how I start up:


Dim chan_name() As String

Dim mydevice As String

Dim rate As Double = 1613 ' 1613 Hz data sample rate - smallest possible

Dim minval As Double = -0.001

Dim maxval As Double = 0.001

Dim scaleit As Double = 586

bridgeConfiguration = AIBridgeConfiguration.FullBridge

excitationSource = AIExcitationSource.External

Dim excitVal As Double = 10 ' 10 volts

Dim gageFact As Double = 1

Dim initVOut As Double = 0 ' v out at rest

Dim gageRes As Double = 350

Dim poissonRatio As Double = 0.3

Dim leadWireRes As Double = 1

customScale = New RangeMapScale(customScaleName, minval, maxval, -scaleit, scaleit)


chan_name = DaqSystem.Local.GetPhysicalChannels(PhysicalChannelTypes.AI, PhysicalChannelAccess.External)

If chan_name.Length > 0 Then

mydevice = chan_name(0)

myTask = New Task()

myAIChannel = myTask.AIChannels.CreateVoltageChannelWithExcitation(mydevice, "", AITerminalConfiguration.Differential, minval, _

maxval, bridgeConfiguration, excitationSource, excitVal, True, customScale.Name)

myTask.Timing.ConfigureSampleClock("", rate, _

SampleClockActiveEdge.Rising, SampleQuantityMode.ContinuousSamples, dataCount)


numchan = myTask.Stream.ChannelsToRead

If numchan = mydevice Then

'myAIChannelReader = New AnalogSingleChannelReader(myTask.Stream)

'myAIChannel.LowpassEnable = True

'myAIChannel.LowpassCutoffFrequency = 100

If null = True Then


tare = 0

End If



myTask.SynchronizeCallbacks = True

Dim temp As Double = myAIChannel.ExcitationActualValue

Dim temp2 As String = myAIChannel.ExcitationSource.ToString

Dim temp3 As String = myAIChannel.ExcitationDCOrAC.ToString


connect = True



I have it running right now.  With external excitation voltage of 6.1 volts supplied to the four terminal external connection, I am getting 7.8 volts across the 6 and 7 pins.


I get this with code above, and using exact sample project.

My code works fine when using internal excitation.  I also gives me output when using external excitation, but I don't understand why the excitation voltage is not following what I input.


What else would you like to know about my set up?

0 Kudos
Message 3 of 21



Can we try and create a task within Measurement and Automation Explorer to see if you are able to see similar behavior. The way that the 9237 works is that when internal excitation is selected, it will attempt to provide the 10 V of excitation to the device. If it cannot provide the ten volts (150mW maximum power output on the 9237) the device will drop down the voltage to levels where 150mW of provided power is sustainable. With external excitation it still allows the 10V of excitation to occur, however it will be at levels higher than the 150mW maximum power output of the 9237. Are you using multiple devices or just one device? Do you know the bridge resistance of this device to find out if the 9237 isn't functioning properly also, or if the 9237 simply can't supply the amount of power to the load cell. If we can run this test in Measurement and Automation Explorer using as few load cells as possible (if using more than one), and select the correct settings for your device, and we notice the same problem, this will help determine some more troubleshooting steps to go through with. 

National Instruments
Software Group Manager
0 Kudos
Message 4 of 21

I am only using one load cell, plugged into the 0 channel.

The nominal resistance is 350 ohms.


I have not tried to create a task in Measurement and Automation Explorer since it says I am not licensed for that feature when I try.  If I understand correctly, I need to have purchased some software with application support.

I am using my Visual Studio to create my own software, and using the generic features of the driver (ie without Measurement Studio).


Is there a way to get a trial license for Measurement and Automation Explorer? 


0 Kudos
Message 5 of 21



As shown in the 9237 Specifications, the maximum power supplied is 150 mW. With a bridge resistance of 350 Ohms, it would require 286 mW of power with 10 V of excitation. When you are applying an external excitation you have to ensure that the value of the external excitation voltage is equal to the voltage that you want to use. So for example with the external excitation of 6.1 V you would not be supplying the voltage that you should expect. Try using an external excitation with 10 V applied into the device. Listed below is how I used to calculate the amount of power consumed by the one load cell. 


P = Vex ^2 / R


National Instruments
Software Group Manager
0 Kudos
Message 6 of 21

Thanks for the response.

Yes I understand the power limitations of the 9237.  I don't expect it to output 10 volts when I ask for that, given my resistance.  I appreciate the reminder.


The example I gave was to show that the 9237 itself was clearly sourcing power (output is more than I was putting in), even when I have external voltage source specified in the software.


I have the same outcome when I actually give it 10 Volts as external source.  It appears to still be using an internal power source, since I still get about 7.8 volts on the pins. 


So, the heart of my question remains.  How can I make it so that I bypass the 9237 as the power source, and instead use the external voltage.  Flipping the software switch has no effect.  Either I am doing something wrong, or it is not working as it should. 

0 Kudos
Message 7 of 21


I spoke with the Product Support Engineer who directly supports the NI 9237. Listed below are his comments on the issue.
When external excitation is enabled on the NI-9237, the excitation ± terminals (pins 6 and 7) disconnect from the internal cDAQ backplane source and connect to the 4 terminal EX ± AI Bridge on the front of the device.  With external excitation enabled, a 2-10 volt external power supply needs to be connected in order to provide excitation.The external excitation pins on the NI-9237 are a direct pass through from the 4 pin connector to the EX +/- pins on each channel.  The voltage is not regulated, the externally supplied voltage is passed directly through to each channel.  Setting a different excitation value in software does not change this behavior.
NOTE: If external excitation is selected but an external excitation source is not connected there will be a voltage present on the (EX ±)  because these channels are not completely decoupled from the internal excitation source.  The voltage here is relative to any previous external excitation source that may have been connected.  This voltage is generally between 4 and 10 volts.
It seems that from the above statement that perhaps the 7.8 V signal that you are seeing is the remnants of the previous internal excitation that you have selected. The internal excitation sourcing should be closed when you select external as the source. How are you connecting the excitation source? Figure 1 on page 6 of the NI User manual shows the connection diagram for connecting the external excitation source. What power supply are you using to supply the external excitation? Can it sufficiently supply the 286 mW (10 V, 28.6 mA)?   


National Instruments
Software Group Manager
0 Kudos
Message 8 of 21

Hi Frank:

Thanks for the continuing interest in this topic. 

As I briefly hinted in my first post I am using the little connector NI supplied to connect to the external EX+ and EX- pins on the 9237 (as shown in Figure 1 on page 6 of the manual).  I just verified again that I actually do get 10 V at the connector before it is plugged into the 9237. 

The power supply itself is very robust, a BK Precision 9110, which can supply up to 100 watts of power (in range of 0-60 volts and up to 5 amps). 


So it sure seems like that 10 V is not making it inside the NI, and we get the residual voltage.


What next? 

0 Kudos
Message 9 of 21



So it seems that we have everything hooked up correctly to the 9237 and your code seems to be correct, as you are choosing the excitation source to be external correctly. Normally the excitation going into the device should be switched off when you select external excitation. I wanted to do a DAQmx create task in Measurement and Automation Explorer, however the error that we were getting was related to not having a Development Environment installed such as Labview, Signal Express, or CVI. One last thing that we can do to test the hardware would be to use a task to verify that the device is functioning correctly. If you would like, we have Signal Express LE which is a simple development environment with limited features that is offered that can do one of these tests.   

National Instruments
Software Group Manager
0 Kudos
Message 10 of 21