In EDSDK if an error occours during image transfer (i.e. connection lost, app error,...) when the application restarts and reconnects to the device it's impossible to take a new picture because the EdsSendCommand(hdev,kEdsCameraCommand_TakePicture,0) always return EDS_ERR_DEVICE_BUSY.
This because the previous image data are in camera memory even I switch off the camera. The only solution is to put off the battery!!! Does anyone have a better solution (sofwtare) to send a kind of RESET and release all image data in memory waiting for transfer and let the camera come to normal operation conditions.
I run the SDK under following modes I first set the property to EdsdkWrapper.PropID_SaveTo : EdsdkWrapper.EdsSaveTo.Host
EdsSendCommand EdsdkWrapper.CameraCommand_TakePicture
Questions: How to reset the camera after an abrupt termination so that it can forget about all the half completed transfers? Note that I don't have the IntPtr reference after abrupt termination. (i.e I can't call EdsdkWrapper.EdsDownloadComplete(imageReference))
This is probably because your program exits before the EdsTerminate() function gets executed. You should make sure this function is executed before your program terminates. Or a more crude solution would be to have another program with just the EdsTerminate function. You could run this program before running your application again if an abrupt termination occurred.