LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

'WFM_Op' function crashes windows xp

The code below wil reboot windows xp, when a breakpoint is hit after the 'wfm_op' instruction AND the red 'TERMINATE execution' button from the cvi debugger is hit (If, for example, a (non) fatal runtime error is encountered in a real program).
 
short  ChanVect[1], WaveBuf[6];
#define NIDAQ_PXI6070E_ID    7  // Card on position A7

void main(void)
{ int a = 0, err ;
 
  ChanVect[0] = 0 ;
  err = WFM_Op (NIDAQ_PXI6070E_ID, 1, ChanVect, WaveBuf, 6, 0, 30*6);   // generate INFINITE
  a++ ; // breakpoint set here
}
 
cvi 7.1
Runtime 7.1.0.307
Traditional NiDaq 7.3.0F1
Hardare: PXI6070E
Windows XP SP2
 
I think the debugger is releasing the memory, but the card (driver) is still trying to use it.
 
Any solution ?
 
0 Kudos
Message 1 of 4
(3,251 Views)
Hi Joshua123,
 
This is because you terminate the application abnormaly. Using the terminate will remove you application from memory which prevents the application from properly releasing the hardware. This will most likely result in a Windows blue screen of death (BSOD) when you are in a buffered operation (Input or Output) and you abort it while DMA transfers are inprogress. Defualt configuration for Windows XP is to reboot when you get a BSOD.
 
Regards,
Karsten
0 Kudos
Message 2 of 4
(3,237 Views)
Hi Karsten,
 
In fact you confirm what i already thought.
 
In the meanwhile i have tried if i can repeat the problem on different test equipment.
So far i have tried 2 additional systems.
System 1 had the same hardware configuration (pc with mxi-3 card (glasfiber), pxi rack (1045) with mxi-interface and several pxi cards.
  This is the type of configuration that crashes.
System 2 has a PCI mio16E card
  This system does NOT crash, but restarting the program results in a error stating that a transfer is already in progress (which in fact is correct, because i did not use any initialisation code).
 
As soon as i have a system available, i will try the 'easy io' function "AOGenerateWaveforms", which probably has compatible functionality.
 
My problem is that i have several test engineers who state that rebooting a pc because 'simply'(!!!!!?) aborting a program is NOT acceptable.
'Unfortunately' the 2 different configurations make clear that it is possible.
 
Jos Schuurmans, Philips Lighting, Netherlands
 
 
0 Kudos
Message 3 of 4
(3,232 Views)
Results for 'AOGenerateWaveforms' is exactly the same (system crashes).
 
0 Kudos
Message 4 of 4
(3,229 Views)