LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW Crash without notice on Windows (ntdll.dll error): is it a Timed Loop problem?

Dear Community,

I developed a VI that controls a power supply for testing a battery. It is controlled via its VISA driver. In my VI, I have a timed loop with four frames: one for reading the measurements from the instrument (I visualize them in three 2h-charts, one data per second each), one for deciding what to do on the battery (a charge, discharge, etc.), one for writing the setpoints in the instrument (current, voltage, etc), and one for storing the data in a TDMS file. I manage the commands via event handler and queue structure (using two while loops).


The problem is that, randomly, LabVIEW crash whitout error while executing a battery test. The only hint that I have is from Event Viewer of Windows that reports (in Italian) an error generated by ntdll.dll, which seems is the thing that makes LabVIEW crash:


Nome dell'applicazione che ha generato l'errore: LabVIEW.exe, versione: 21.0.1.4002, timestamp: 0x62a97bb5
Nome del modulo che ha generato l'errore: ntdll.dll, versione: 10.0.19041.3693, timestamp: 0x3ab9e7d5
Codice eccezione: 0xc0000374
Offset errore 0x000e6d13
ID processo che ha generato l'errore: 0x1584
Ora di avvio dell'applicazione che ha generato l'errore: 0x01da2a1ead3d2d7e
Percorso dell'applicazione che ha generato l'errore: C:\Program Files (x86)\National Instruments\LabVIEW 2021\LabVIEW.exe
Percorso del modulo che ha generato l'errore: C:\Windows\SYSTEM32\ntdll.dll
ID segnalazione: b8700360-9a56-4e68-814d-2c9b33dddaca
Nome completo pacchetto che ha generato l'errore:
ID applicazione relativo al pacchetto che ha generato l'errore:


No logs from LabVIEW. I am running the VI on Windows 10 Educational in LabVIEW 2021 SP1. I have already tried changing both Windows versions and LabVIEW versions (I developed the VI on LabVIEW 2020) but the problem persists. I have also tried to monitor the memory in search of a memory leak, but seems all ok. I checked also the TDMS reference and seems to open and close properly. The same I did for the instrument communication.


Searching in the community I found this very interesting post: https://forums.ni.com/t5/LabVIEW/Sporadic-App-Crash/td-p/4299898/page/2. In particular, in the second reply on page 2 it is stated that "As NI support has told, don’t use the timed loop on Windows!" and is explained briefly why it can interact with Windows and generate the LabVIEW crash. I found the explanation of this statement very useful, but I did not find any other posts or guides that make this solution, let's say, "official".


Since it appears that I have to modify a bit my VI to replace the Time Loop with a While Loop, I ask you: Do you agree with that statement? Is it true that on Windows is better to avoid using Timed Loop? Thank you very much.

0 Kudos
Message 1 of 1
(977 Views)