Jump to content
  • 0

LabVIEW Exception: Access violation


Question

Posted

Using MCC hardware, ULx sub-VIs and LabVIEW. Original program included DAQ from two devices (one over TCPIP, which I had never used before).  At very early debugging stage, I was getting weird crashing behaviour.   LabVIEW would throw an error (wrong variant type, etc.), and when I pressed "Stop," I would get a big, pink box with this error: LabVIEW Exception: Access violation (0xC0000005) at EIP=0x0000025143143310 and an opportunity to send a message to NI.  Then the system would hang for close to a minute, then all LabVIEW windows would close.  I don't think I've crashed LabVIEW in 25 years of sporadic use.

I removed the second DAQ device and put all channels on A/D board, but that didn't help. 

I wondered whether the network-location of my files (new feature of our IT security) was causing permissions errors, so I copied the whole file structure to the desktop of my machine (force local).  No joy.

I then wrote a very simple VI to try collecting and plotting (almost) all in one VI (attached).  Still kept getting this error and crashing LabVIEW.

Then I plugged in an NI device and replaced all the ULx sub-VIs with DAQmx equivalents (also attached), and it worked just fine, running off of network files and a home WiFi connection.  Then I re-wrote the DAQ parts of my huge, multi-threaded monstrosity, and it just throws errors into the handler like it should; no crashing.

It doesn't make a lot of sense to me, but it's hard not to blame the MCC ULx sub-VIs.  Is there a software switch/option that I failed to enable?

Any advice gratefully accepted.

EE_SuperSimple_DAQ_MCC.vi EE_SuperSimple_DAQ_NI.vi

6 answers to this question

Recommended Posts

  • 0
Posted

Hello,

I ran your super simple daq mcc vi using one of my USB devices and didn't experience the problem. The problem description you provided sounds a lot like a mismatch between versions of ULx for LabVIEW and InstaCal. My recommendation is to uninstall both InstaCal and ULx for LabVIEW, then reinstall from the latest MCC DAQ Software CD. The following is a link to the CD download: https://www.mccdaq.com/downloads/MCCDaqCD/mccdaq.exe Don't worry about the device InstaCal configuration, uninstalling it leaves behind the configuration file and it should be intact after the reinstalled.

regards...

  • 0
Posted

Thanks for the reply.

I uninstalled, reinstalled, and even used "replace" on all the ULx subroutines.

I can confirm that I was able to run SuperSimpleDAQ for longer than before, but when I press "stop," I still get the error.  Here's a pic of the whole message box:
image.png.a39180294bdbb2eab5aa6025dd7f5410.png

  • 0
Posted

Hello,

I did notice that your super simple daq example selected channels 0-17. We don't have many devices with more than 16 channels so could you let me know its model and serial number, as well as your version of Windows?

Also, I need your forced matrix constant vi...

Thanks,
John

  • 0
Posted (edited)

Ah yes...sorry I left that sub out.  Attached below

Also, I see that I have failed to close the task in the simple VI.  Since I'm (now) not seeing the crash behaviour until I press "stop," is there any chance that that is causing problems?  (I wouldn't expect a problem until the second time, but I dunno.)

 

Windows on my laptop: 
Edition    Windows 10 Enterprise
Version    21H2
Installed on    ‎2/‎15/‎2022
OS build    19044.1766
Experience    Windows Feature Experience Pack 120.2212.4180.0
(Same issue occured on the lab desktop, but I haven't run it there, in a while)
 

The board is inside some Qualisys hardware:
ProdNo 230599
A/D - S/N 388671

edited to add that A/D board is USB-2533
 

EE_DAQ_Force_Matrix_Constant.vi

Edited by framjam
  • 0
Posted

I believe you self diagnosed your system. The error was apparently being caused because you left out the Clear Task when the loop exited. I experienced the error on the second time running the worksheet - without exiting LabVIEW or closing the VI. I added in the Clear Task and Status check inside the loop. Seems to run okay, I ran it about 10 times in a row without issue. 

Take care,

John

EE_SuperSimple_DAQ_MCC_r2.vi EE_DAQ_Force_Matrix_Constant.vi

  • 0
Posted

Finally got a chance to test, today.

I hadn't thought that it was waiting until the second run to fail, but it was.  And when I added a Stop and a Clear Task after the loop, I can now run it a bunch of times without crash.

 

Thanks!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...