I'm using NI-VISA 2.6.1f2 in Labwindows/CVI 7.0 to dump data out the parallel port to custom hardware. VISA allows me to dump data FAST, by avoiding the kernel-switching involved when using inp and outp.
The problem is, when I exit my application, nothing else can access the parallel port. The only way to get it back for use by other non-VISA applications is to reboot the computer.
My question is this: How can I release the parallel port (or reconfigure, which is my suspicion) so that other applications can use it after I exit my application?
Here's a code snippet:
status = viOpenDefaultRM(&DRM);
status = viOpen(DRM, "PXI::MEMACC", 0, 0, &InHan);
status = viSetAttribute(InHan,
VI_ATTR_DEST_
INCREMENT, 0);
Port = 0x378; // Parallel port "data" port
NBytes = Many;
viMoveOut8(InHan, 8, Port, NBytes, Data);
viClose(InHan);
viClose(DRM);
exit(0);