We have a measurement setup with multiple Analog Discovery 2 units hooked up to a single Linux computer.
The AD2 units are used by separate processes.
If multiple processes have opened AD2 devices, and one of them terminates without explicitly calling 'FDwfDeviceClose' (e.g. due to a hard KILL signal), that device remains unavailable, i.e., FDwfEnumDeviceIsOpened() returns 1 in its pfIsUsed parameter, even though the device is not in use anymore.
The only way I found to make such a device available for use again is to terminate all other programs that control an AD2 device. As soon as the last process controlling an AD2 terminates, all devices revert to 'available' again. (In this case, it doesn't seem to matter if the devices terminate with or without a proper call to 'FDwfDeviceClose'.)
I verified this behavior with 2 AD2s and also 2 Digilent Discovery devices hooked up to a single PC. The Digital Discoveries show the same behavior.
This behavior makes it quite a bit more difficult to use multiple devices on a single computer as we do.
Two questions:
* Where is the 'is in use' status stored? Is it perhaps a flag that is located in the device itself? Or is there somehow stored state in the controlling PC? This could help me understand the issue.
* Is this a fixable issue in the library? Or is it inherent in the way the 'in use' flag is implemented?
Question
Guest
Hi,
We have a measurement setup with multiple Analog Discovery 2 units hooked up to a single Linux computer.
The AD2 units are used by separate processes.
If multiple processes have opened AD2 devices, and one of them terminates without explicitly calling 'FDwfDeviceClose' (e.g. due to a hard KILL signal), that device remains unavailable, i.e., FDwfEnumDeviceIsOpened() returns 1 in its pfIsUsed parameter, even though the device is not in use anymore.
The only way I found to make such a device available for use again is to terminate all other programs that control an AD2 device. As soon as the last process controlling an AD2 terminates, all devices revert to 'available' again. (In this case, it doesn't seem to matter if the devices terminate with or without a proper call to 'FDwfDeviceClose'.)
I verified this behavior with 2 AD2s and also 2 Digilent Discovery devices hooked up to a single PC. The Digital Discoveries show the same behavior.
This behavior makes it quite a bit more difficult to use multiple devices on a single computer as we do.
Two questions:
* Where is the 'is in use' status stored? Is it perhaps a flag that is located in the device itself? Or is there somehow stored state in the controlling PC? This could help me understand the issue.
* Is this a fixable issue in the library? Or is it inherent in the way the 'in use' flag is implemented?
Kind regards,
Sidney
Link to comment
Share on other sites
19 answers to this question
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now