Hi,
We have a set of 10 ASI183MM Pro cameras, each running on it's own Raspberry Pi 3B+ (for https://huntsman.space). We've found that exposures sometimes end with FAILED status for no apparent reason, and once this has happened the camera is in an unusable state. It still shows up as connected according to ASIGetNumOfConnectedCameras(), ASIGetCameraProperty() works, and so (apparently) does ASIOpenCamera() and ASICloseCamera(), but calling any other function results in a GENERAL_ERROR. The only way we are able to recover is to reboot the Raspberry Pi (which also power cycles the attached camera).
We found this old forum thread, that seems to describe a similar issue: https://bbs.astronomy-imaging-camera.com/viewtopic.php?f=29&t=7685&p=16087&hilit=error+calling
In that thread wulfblat concluded that the problem was triggered by calling ASIGetExpStatus() too soon after the exposure finishes, which sounds like it could explain the occasional random failures we are seeing. In our code we start the exposure, wait for the exposure time, then start calling ASIGetExpStatus() every 0.01 seconds until we get a status that is not WORKING.
Later in that thread wulfblat and Support2@ZWO moved the discussion to email, where they apparently worked out a solution but did not post it back to the thread so unfortunately we still don't know how to avoid these failed exposures. Can anyone help us?