LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

debbug example prog for NI 9237

Hello all,
 
I have a question regarding debugging of an example program I am trying to use with the NI 9237 strain module for compact Daq.
 
I am using an example program to build my own, but have run into an error that is originating from one of the subVI's.  It is doing the shunt calibration adjustment. It does the shunt calibration calcs and resets the task created in the original program to include the calibration adjustment.
 
The program does OK when I only have one channel, but when I increase to 4 channels, it breaks down.
 
this program seems to be geared for the SCXI (though the help notes say it can be run with the NI 9237).  I have isolated the property node that is giving me problems and have included a screen shot of the error and the sub vi it is located in. I have also included the Lab View program.
 
Basically, it is telling me my ranges for expected strain are too large, which is very troubling because the ranges I specify are very small to begin with. Even leaving the default values gives an error.
 
I have attached the screen shot with the error message and the lab view program.
 
thanks for any advice on how to correct this property node so it can handle 4 strain channels comming from the NI 9237.  
 
Alfonso Lopez
A. Lopez
0 Kudos
Message 1 of 6
(3,741 Views)
Hello Alfonso,

Is there any custom scaling applied to the task that is passed into the subVI "Ni9237 Shunt Cal Channels.vi"?  If so, please try disabling this custom scale before performing offset calibration.  If this works, you can re-enable the custom scale after the offset calibration

Also, you did not include the "Ni9237 Shunt Cal Channels" subVI in your attachment, so I couldn't open it.  If my suggestion doesn't help, please reattach your code with this subVI included. 

Best regards,
0 Kudos
Message 2 of 6
(3,721 Views)

Jarrod,

 

thank you for your comments.

the subvi does not seem to have custom scaling inputs.  The inputs min and max to set the bridge range seems to be the issue. the scale of -0.01 to 0.01 is out of range according to the error, but this is a resonable value for strain.  I have attached an *.LLB file which contains the subvis used in the program. I have also attached a modefied version of the program. It still has the problems with shunt callibration, I only changed the sample clock mode and read method.

 

thanks for your help.

Alfonso

 

A. Lopez
0 Kudos
Message 3 of 6
(3,713 Views)
Hello Alfonso,

Let's go back and work straight from the example program Cont Acq Strain Samples (with Calibration).vi.  If I open that example and run it as is with an actual 9237 module installed on a Compact DAQ chassis, I get no errors.  If I change the "Maximum Value" on the front panel to something outside the operating range of the 9237 (50 for example), I get the following error message:



That error is actually occurring because of the AI.Max property that is being set in the DAQmx Create Channel VI.  That error is not actually generated until the task is committed.  When the "Do Shunt Cal?" button is not on, this error actually occurs at the DAQmx Start Task VI (which is where the task is committed).  When the "Do Shunt Cal?" button is on, the error is occuring at the DAQmx Channel Property AI.Excit.Val because in order to read that value, that task has to be committed.  Committing a task is one of the stages of the Task State Model.  If you're interested, you can find more information on this model in the NI-DAQmx Help under NI-DAQmx Key Concepts >> Channels and Tasks >> Tasks >> Task State Model. 

The bottom line is that I can't reproduce the error that you're getting.  I don't understand how the listed limits could be where there are unless you applied some kind of custom scaling somewhere.  Trying running the example program as I have and see if you can reproduce the same error.

Best regards,

Message Edited by Jarrod B. on 01-17-2007 05:25 PM

Message 4 of 6
(3,701 Views)

Jerrod,

thanks for your reply, it was usefull to go back to the original example program. I still had the error, but tracked it down to a hardware problem since you did not have any issues running the example program. one of the NI 9945 bridge completion modules had a bad screw terminal. I identified one module before starting that was bad but this particular module seems to have a loose screw which does not allow for good connection of the strain guage terminal, it was having intermittent contact. I did not recognize it before as I tested the guages using MAX before hand and everything was OK.

I guess I received a bad lot of bridge completion modules.

Thanks, problem solved.

A. Lopez
0 Kudos
Message 5 of 6
(3,684 Views)
Hello Alfonso,

I'm glad we were able to pinpoint the problem.  Sorry for the connectivity issues you've been having.  If you need help with an RMA (return), please create a service request on the web and select "Phone NI" to speak with someone in person.

Best of luck with your application!

Regards,
0 Kudos
Message 6 of 6
(3,662 Views)